McStas logo McStas - A neutron ray-trace simulation package ILL; PSI; ESS Niels Bohr Institute DTU Physics NEXMAP


About McStas
 Conditions of use
 Project funding

 Other Downloads (share)

Mailing list

Search web/mailinglist

 Wiki (GitHub)
 McStas manual


Report bugs (GitHub)

Code-repository (GitHub)

McStas: Monitor_Sqw Component

[ Identification | Description | Input parameters | Output parameters | Links ]

The Monitor_Sqw Component

This component is a Sqw Monitor that records the dynamic structure factor S(q,w) from a scattering location, seen from a detector location.



This component is a specialized Monitor_nD variation, which records the S(q,w)
scattering law. It accepts about the same parameters as the Monitor_nD, but makes
use of the 'q' and 'w' user variables. The neutrons are restored in their previous
state after neing detected (restore_neutron=1).

The monitor records the intensity as a function of q=kf-ki and w=Ef-Ei were the
'f' refers to the component location, and the 'i' refers to the component located
at 'index' relative to the component location.

The component uses automatic limits, and is thus not recommended with MPI/multiprocessing.
In this case, the limits should be set manually, e.g. user1=q and user2=w
  options="user1 limits=[0 10] bins=100, user2 limits=[-50 50] bins=200"

A usage example is for instance:
  COMPONENT sample = Isotropic_Sqw(...)

  COMPONENT sqw = Monitor_Sqw(index=-1, radius=2, yheight=2, bins=128)

This component can be used to generate dynamic structure factors comvolved with
the instrument response, and compare with molecular dynamics results (using e.g. nMoldyn).
The incoming beam (e.g. at the sample) must be monochromatic.

Input parameters

Parameters in boldface are required; the others are optional.
Name Unit Description Default
user3 FLT_MAX
xwidth m Width of detector. 0
yheight m Height of detector. 0
zdepth m Thickness of detector (z). 0
xmin m Lower x bound of opening 0
xmax m Upper x bound of opening 0
ymin m Lower y bound of opening 0
ymax m Upper y bound of opening 0
zmin m Lower z bound of opening 0
zmax m Upper z bound of opening 0
radius m Radius of sphere/banana shape monitor 0
bins 1 Number of bins to force for all variables. Use 'bins' keyword in 'options' for heterogeneous bins 0
min -1e40
max 1e40
index 1 Index of the component where scattering occurs with respect to the location of the Monitor_Sqw location in the instrument description. The index is usually negative, and should point to e.g. a Isotropic_Sqw, , PowderN, or Single_crystal instance. index=-1 for the previous component. -1
options str String that specifies the configuration of the monitor The general syntax is "[x] options..." (see Descr.). 0
filename str Output file name. If not set an automatic file name is used. 0
geometry str Name of an OFF file to specify a complex geometry detector 0
username3 0
nowritefile 1 If set, monitor will skip writing to disk 0

Output parameters

Name Unit Description Default
DEFS struct structure containing Monitor_nD Defines  
Vars struct structure containing Monitor_nD variables  


[ Identification | Description | Input parameters | Output parameters | Links ]

Generated automatically by McDoc, Peter Willendrup <> / Wed Jan 12 15:13:31 2022

Last Modified: Wednesday, 12-Jan-2022 16:13:31 CET
Search website mailinglist archive GitHub repos