Debian Codegraph @

hugo/content/ref/instr/scan/full-divergence/index.md

raw
1 +++
2 title = "Beam Wavelength Spread"
3 weight = 65
4 +++
5
6 ### Beam Wavelength Spread in Specular Simulations
7
8 This example demonstrates beam wavelength spread effects in reflectivity computations.
9 All simulation parameters (except for those related to beam spread itself)
10 coincide with those defined in
11 [reflectometry simulation tutorial](/ref/sim/class/specular).
12
13 In real specular experiments the observed reflectivity is always affected
14 by the beam spread in both wavelength and incident angle.
15
16 {{< galleryscg >}}
17 {{< figscg src="/img/auto/specular/BeamFullDivergence.png" width="500px" caption="Scattering intensity">}}
18 {{< /galleryscg >}}
19
20 In this example the following parameters related to the spread of the beam were set to the simulation:
21
22 * Gaussian distributions both in wavelength and incident angle
23 * The mean value for beam wavelength $\lambda_0 = 0.154$ nm
24 * Standard deviation in the wavelength $\sigma_{\lambda} = 0.01 \cdot \lambda_0$
25 * Standard deviation in the incident angle $\sigma_{\alpha} = 0.01^{\circ}$
26
27 As one can see from the Python script, the definitions of beam parameter distributions
28 match ones described in [similar example for GISAS simulations](/ref/instr/beam/divergence).
29 However, in the case of the incident angle one should always use a distribution with zero mean,
30 since the actual mean value is substituted by `SpecularSimulation` in dependence on the
31 defined grazing angle range.
32 If the distribution of the incident angle has non-zero mean value, an exception
33 is thrown:
34
35 ```python
36 terminate called after throwing an instance of 'std::runtime_error'
37 what(): Error in SpecularSimulation: parameter distribution of beam grazing angle should have zero mean.
38 ```
39
40 {{< show-ex file="specular/BeamFullDivergence.py" >}}