source: sasview/src/sas/sasgui/perspectives/pr/media/pr_help.rst @ 1abd19c

ESS_GUIESS_GUI_DocsESS_GUI_batch_fittingESS_GUI_bumps_abstractionESS_GUI_iss1116ESS_GUI_iss879ESS_GUI_iss959ESS_GUI_openclESS_GUI_orderingESS_GUI_sync_sascalccostrafo411magnetic_scattrelease-4.2.2ticket-1009ticket-1094-headlessticket-1242-2d-resolutionticket-1243ticket-1249ticket885unittest-saveload
Last change on this file since 1abd19c was 1abd19c, checked in by lewis, 5 years ago

Add note about error on background value to docs

  • Property mode set to 100644
File size: 2.9 KB
RevLine 
[ec392464]1.. pr_help.rst
2
3.. This is a port of the original SasView html help file to ReSTructured text
4.. by S King, ISIS, during SasView CodeCamp-III in Feb 2015.
5
[b64b87c]6P(r) Calculation
7================
[ec392464]8
[8a22b5b]9Description
10-----------
[ec392464]11
[1221196]12This tool calculates a real-space distance distribution function, *P(r)*, using
13the inversion approach (Moore, 1980).
[8a22b5b]14
15*P(r)* is set to be equal to an expansion of base functions of the type
16
[0391dae]17.. math::
18  \Phi_{n(r)} = 2 r sin(\frac{\pi n r}{D_{max}})
[ec392464]19
[0391dae]20The coefficient of each base function in the expansion is found by performing
[8a22b5b]21a least square fit with the following fit function
22
[0391dae]23.. math::
[ec392464]24
[0391dae]25  \chi^2=\frac{\sum_i (I_{meas}(Q_i)-I_{th}(Q_i))^2}{error^2}+Reg\_term
[1221196]26
[ec392464]27
[0391dae]28where $I_{meas}(Q_i)$ is the measured scattering intensity and $I_{th}(Q_i)$ is
[1221196]29the prediction from the Fourier transform of the *P(r)* expansion.
[0391dae]30
[1221196]31The $Reg\_term$ term is a regularization term set to the second derivative
[0391dae]32$d^2P(r)/d^2r$ integrated over $r$. It is used to produce a smooth *P(r)* output.
[ec392464]33
[8a22b5b]34.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
[ec392464]35
[b64b87c]36Using P(r) inversion
37--------------------
[ec392464]38
[8a22b5b]39The user must enter
40
41*  *Number of terms*: the number of base functions in the P(r) expansion.
[1221196]42
[8a22b5b]43*  *Regularization constant*: a multiplicative constant to set the size of
[ec392464]44   the regularization term.
45
[8a22b5b]46*  *Maximum distance*: the maximum distance between any two points in the
[ec392464]47   system.
[8a22b5b]48
[0391dae]49P(r) inversion requires that the background be perfectly subtracted.  This is
50often difficult to do well and thus many data sets will include a background.
[1abd19c]51For those cases, the user should check the "Estimate background level" option
52and the module will do its best to estimate it. If you know the background value
53for your data, select the "Input manual background level" option. Note that
54this value will be treated as having 0 error.
[0391dae]55
56The P(r) module is constantly computing in the background what the optimum
57*number of terms* should be as well as the optimum *regularization constant*.
58These are constantly updated in the buttons next to the entry boxes on the GUI.
59These are almost always close and unless the user has a good reason to choose
60differently they should just click on the buttons to accept both.  {D_max} must
61still be set by the user.  However, besides looking at the output, the user can
62click the explore button which will bring up a graph of chi^2 vs Dmax over a
63range around the current Dmax.  The user can change the range and the number of
64points to explore in that range.  They can also choose to plot several other
65parameters as a function of Dmax including: I0, Rg, Oscillation parameter,
66background, positive fraction, and 1-sigma positive fraction.
67
[8a22b5b]68.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
69
70Reference
71---------
72
73P.B. Moore
74*J. Appl. Cryst.*, 13 (1980) 168-175
75
76.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
77
[0391dae]78.. note::  This help document was last modified by Paul Butler, 05 September, 2016
Note: See TracBrowser for help on using the repository browser.