Off-specular scattering simulation

To set up and run a simulation with off-specular scattering, use

import bornagain as ba
scan = ...
sample = ...
detector = ba.OffspecDetector(...)
simulation = ba.OffspecSimulation(scan, sample, detector)
# ... set options
result = simulation.simulate()

Supported scan types: grazing angle scan, wavelength scan.

For absorbing media of incidence or exit, amplitudes use the same normalization planes as scattering simulations. Attenuation on the external paths to the source and detector is not included.

For the constructor arguments, see sections scan, sample, and OffspecDetector.

Use OffspecDetector for a 2D map, or SlitOffspecDetector for a 1D scan with one exit angle per scan point. See the constant-two-theta example.

For optional settings, see simulation options.

For the return type of function simulate(), see Datafield.

Examples