Skip to content
Snippets Groups Projects
Commit cd8a2bc3 authored by Wuttke, Joachim's avatar Wuttke, Joachim
Browse files

GISAS reference

parent cb23420e
No related branches found
No related tags found
1 merge request!1476webdoc: regularize Offspec and GISAS sim
Pipeline #92437 passed
......@@ -5,8 +5,29 @@ weight = 30
## GISAS simulation
In BornAgain, grazing-incidence small-angle scattering (GISAS)
is computed using the distorted-wave Born approximation (DWBA).
To set up and run a scattering simulation, use
```python
import bornagain as ba
beam = ...
sample = ...
detector = ...
simulation = ba.ScatteringSimulation(scan, sample, detector)
# ... set options
result = simulation.simulate()
```
For the constructor arguments, see sections [beam]({{% ref-py "instr/beam" %}}),
[sample]({{% ref-py "sample" %}}), and [detector]({{% ref-py "instr/det" %}}).
For optional settings, see [simulation options]({{% ref-py "sim/options" %}}).
Furthermore, there are examples
for [setting masks]({{% ref-py "fitting/advanced/fit-with-masks" %}})
and [setting a region of interest]({{% ref-py "fitting/instrument-description" %}}).
For the return type of function `simulate()`,
see [SimulationResult]({{% ref-py "result/simulation-result" %}}).
### Example
In the following introductory example,
we take a standard sample model from module
......@@ -39,7 +60,7 @@ The spherical detector has nPix=200 bins for both coordinate axis.
The azimuthal angle $\varphi\_\text{f}$ extends from $-2^\circ$ to $+2^\circ$;
the glancing angle $\alpha\_\text{f}$ from $0^\circ$ to $3^\circ$.
### Main program
#### Main program
The last stance in the script is the main program.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment