Changeset 78f02c3 in sasview for src/sas/calculator/media


Ignore:
Timestamp:
Feb 14, 2015 10:12:40 AM (9 years ago)
Author:
smk78
Branches:
master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
898a8b9
Parents:
3e2ebbb
Message:

Level 1 sphinx-ready commit of remaining help files

Location:
src/sas/calculator/media
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • src/sas/calculator/media/density_calculator_help.rst

    r37bbd5f r78f02c3  
    11..density_calculator_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. 
    25 
    36Density/Volume Calculator Tool 
    47============================== 
    58 
    6 Placeholder for density calculator help 
     9Description 
     10----------- 
     11 
     12This tool is to calculate the mass density from the molar volume or vice  
     13versa. To calculate the mass density, the chemical formula and molar volume  
     14should be provided. 
     15 
     16.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ 
     17 
     18How To 
     19------ 
     20 
     211. Molecular Formula: The chemical formula of ONE molecule or ONE atom. For  
     22mixtures, the ratio of the each molecules should be used; for example,  
     23(H2O)0.5(D2O)0.5. 
     24 
     252. Select input (molar volume or mass density) from combobox. Then type in the  
     26input value. 
     27 
     283. Click the 'Calculate' button to perform the calculation. 
     29 
     304. Outputs also include the molar mass (weight) that depends only on the  
     31chemical formula 
     32 
     33.. image:: density_tutor.gif 
  • src/sas/calculator/media/kiessig_calculator_help.rst

    r37bbd5f r78f02c3  
    11..kiessig_calculator_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. 
    25 
    36Kiessig Thickness Calculator Tool 
    47================================= 
    58 
    6 Placeholder for Kiessig calculator help 
     9Description 
     10----------- 
     11 
     12This tool is to approximately estimate the thickness of a layer or the  
     13diameter of particles from the Kiessig fringe in SAS/NR data, and using the  
     14Kiessig relation 
     15 
     16thickness = 2*Pi/fringe_width. 
     17   
     18.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ 
     19 
     20 
     21How To 
     22------ 
     23 
     24To get a rough thickness or particle size, just type the Kiessig fringe width  
     25(in units of 1/Angstrom) and click on the 'Compute' button. Then the output  
     26value will be show up in the 'Thickness' text box. 
  • src/sas/calculator/media/resolution_calculator_help.rst

    r37bbd5f r78f02c3  
    11..resolution_calculator_help.rst 
    22 
    3 Resolution Calculator 
    4 ===================== 
     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. 
    55 
    6 Placeholder for resolution calculator help 
     6Q Resolution Estimator 
     7====================== 
     8 
     9Description 
     10----------- 
     11 
     12This tool is to approximately estimate the resolution of Q based on the SAS  
     13instrumental parameter values assuming that the detector is flat and vertical  
     14to the incident beam direction. 
     15 
     16.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ 
     17 
     18How To 
     19------ 
     20 
     211. Select the source and source type (Monochromatic or TOF). Note that the  
     22computational difference between the sources is only the gravitational  
     23contribution due to the mass. 
     24 
     252. Change the default values of the instrumental parameters as desired. 
     26 
     273. The input formats of wavelength and its spread (=FWHM/wavelength) depend on  
     28the source type.For monochromatic wave, the inputs are just one values as shown  
     29with the defaults.For TOF, the min and max values should be separated by "-"  
     30to describe the wavelength band range. Optionally, the input of the wavelength  
     31(NOT of the wavelength spread) could be extended by adding "; --" where the --  
     32is the number of the bins for the numerical integration. Otherwise, the  
     33default value "10" bins will be used. The same number of bins will be used  
     34for the corresponding wavelength spread in either cases. 
     35 
     364. For TOF, the default wavelength spectrum is flat. The custom spectrum file  
     37(with 2 column text: wavelength(A) vs. intensity) can also be loaded by  
     38selecting "Add new" in the combobox. 
     39 
     405. Once set all the input values, click the compute button. Depending on  
     41computation loads the calculation time will vary. 
     42 
     436. 1D and 2D dQ will be displayed in the text-box at the bottom of the panel.  
     44Two dimensional resolution weight distribution (2D elliptical Gaussian  
     45function) will also be displayed in the plot panel even if the Q inputs are  
     46outside of the detector limit. The red lines indicate the limits of the  
     47detector (if a green lines appear (for TOF), it indicates the limits of the  
     48maximum q range for the largest wavelength due to the size of the detector).  
     49Note that the effect from the beam block is ignored, so in the small q region  
     50near the beam block  
     51 
     52[ie., q<2*pi*(beam block diameter) / (sample to detector distance) / lamda_min]  
     53 
     54the variance is slightly under estimated. 
     55 
     567. The summary can be accessed by clicking the 'light-bulb' icon at the bottom  
     57of the SasView main window. 
     58 
     59.. image:: resolution_tutor.gif 
     60 
     61.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ 
     62 
     63Theory 
     64------ 
     65 
     66The scattering wave transfer vector is by definition 
     67 
     68.. image:: q.gif 
     69 
     70In the limit of the small angle, the variance of q in the first order  
     71approximation is 
     72 
     73.. image:: sigma_q.gif 
     74 
     75In summary, the geometric and gravitational contributions depending on the  
     76shape of each factors can be expressed as shown the table. 
     77 
     78.. image:: sigma_table.gif 
     79 
     80Finally, we use a Gaussian function to describe the 2D weighting distribution  
     81of the uncertainty in q. 
     82 
     83.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ 
     84 
     85References 
     86---------- 
     87D.F.R. Mildner and J.M. Carpenter, J. Appl. Cryst. 17, 249-256 (1984) 
     88 
     89D.F.R. Mildner, J.M. Carpenter and D.L. Worcester, J. Appl. Cryst. 19, 311-319  
     90(1986) 
  • src/sas/calculator/media/sas_calculator_help.rst

    r37bbd5f r78f02c3  
    11..sas_calculator_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 
     6.. |beta| unicode:: U+03B2 
     7.. |gamma| unicode:: U+03B3 
     8.. |theta| unicode:: U+03B8 
     9.. |mu| unicode:: U+03BC 
     10.. |sigma| unicode:: U+03C3 
     11.. |phi| unicode:: U+03C6 
     12 
     13.. |equiv| unicode:: U+2261 
     14.. |noteql| unicode:: U+2260 
    215 
    316Generic Scattering Calculator Tool 
    417================================== 
    518 
    6 Placeholder for generic SAS calculator help 
     19Polarization and Magnetic Scattering 
     20 
     21Theory_  
     22GUI_  
     23PDB_Data_  
     24 
     25.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ 
     26 
     27.. _Theory: 
     28 
     29Theory 
     30------ 
     31 
     32In general, a particle with a volume V can be described by an ensemble  
     33containing N 3-dimensional rectangular pixels where each pixels are much  
     34smaller than V. Assuming that all the pixel sizes are same, the elastic  
     35scattering intensity by the particle 
     36 
     37.. image:: gen_i.gif 
     38 
     39where /beta/jand rj are the scattering length density and the position of the  
     40j'th pixel respectively. And the total volume 
     41 
     42.. image:: v_j.gif 
     43 
     44for /beta/j/noteql/0 where vj is the volume of the j'th pixel (or the j'th  
     45natural atomic volume (= atomic mass/natural molar density/Avogadro number) for  
     46the atomic structures). The total volume V can be corrected by users. This  
     47correction is useful especially for an atomic structure (taken from a pdb file)  
     48to get the right normalization. Note that the /beta/j displayed in GUI may be  
     49incorrect but will not affect the scattering computation if the correction of  
     50the total volume is made. The scattering length density (SLD) of each pixel  
     51where the SLD is uniform, is a combination of the nuclear and magnetic SLDs and  
     52depends on the spin states of the neutrons as follows:For magnetic scattering,  
     53only the magnetization component, *M*perp, perpendicular to the scattering  
     54vector *Q* contributes to the the magnetic scattering length. (Figure below). 
     55 
     56.. image:: mag_vector.bmp 
     57 
     58The magnetic scattering length density is then 
     59 
     60.. image:: dm_eq.gif 
     61 
     62where /gamma/= -1.913 the gyromagnetic ratio, /mu/B is the Bohr magneton, r0 is  
     63the classical radius of electron, and */sigma/* is the Pauli spin. 
     64 
     65For polarized neutron, the magnetic scattering is depending on the spin states. 
     66 
     67Let's consider that the incident neutrons are polarised parallel (+)/  
     68anti-parallel (-) to the x' axis (See both Figures above). The possible  
     69out-coming states then are + and - states for both incident states, where  
     70 
     71- Non-spin flips: (+ +) and (- -) 
     72- Spin flips:     (+ -) and (- +) 
     73 
     74.. image:: gen_mag_pic.bmp 
     75 
     76Now, let's assume that the angles of the *Q*  vector and the spin-axis (x')  
     77from x-axis are /phi/ and /theta/up respectively (See Figure above). Then,  
     78depending upon the polarization (spin) state of neutrons, the scattering  
     79length densities, including the nuclear scattering length density (/beta/N)  
     80are given as, for non-spin-flips 
     81 
     82.. image:: sld1.gif 
     83 
     84and for spin-flips 
     85 
     86.. image:: sld2.gif 
     87 
     88where 
     89 
     90.. image:: mxp.gif 
     91 
     92.. image:: myp.gif 
     93 
     94.. image:: mzp.gif 
     95 
     96.. image:: mqx.gif 
     97 
     98.. image:: mqy.gif 
     99 
     100Here, the M0x, M0yand M0zare the x, y and z components of the magnetisation  
     101vector given in the xyz lab frame.  
     102 
     103.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ 
     104 
     105.. _GUI: 
     106 
     107GUI 
     108--- 
     109 
     110.. image:: gen_gui_help.bmp 
     111 
     112After the computation, the result will be listed in the 'Theory' box in the  
     113data explorer panel on the main window.The 'Up_frac_in' and 'Up_frac_out' are  
     114the ratio, (spin up) /(spin up + spin down) neutrons before the sample and at  
     115the analyzer, respectively. 
     116 
     117*Note I: The values of 'Up_frac_in' and 'Up_frac_out' must be in the range  
     118between 0 and 1. For example, both values are 0.5 for unpolarized neutrons.* 
     119 
     120*Note II: This computation is totally based on the pixel (or atomic) data  
     121fixed in the xyz coordinates. Thus no angular orientational averaging is  
     122considered.* 
     123 
     124*Note III: For the nuclear scattering length density, only the real component  
     125is taken account.* 
     126 
     127.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ 
     128 
     129.. _PDB_Data: 
     130 
     131PDB Data 
     132-------- 
     133 
     134This Generic scattering calculator also supports some pdb files without  
     135considering polarized/magnetic scattering so that the related parameters  
     136such as Up_*** will be ignored (see the Picture below). The calculation for  
     137fixed orientation uses (the first) Equation above resulting in a 2D output,  
     138whileas the scattering calculation averaged over all the orientations uses  
     139the Debye equation providing a 1D output 
     140 
     141.. image:: gen_debye_eq.gif 
     142 
     143where vj /beta/j /equiv/ bj the scattering length of the j'th atom. The resultant outputs  
     144will be displayed in the DataExplorer for further uses. 
     145 
     146.. image:: pdb_combo.jpg 
  • src/sas/calculator/media/sld_calculator_help.rst

    r2dee849 r78f02c3  
    11..sld_calculator_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. 
    25 
    36SLD Calculator Tool 
    47=================== 
    58 
    6 Placeholder for SLD calculator help 
     9Description 
     10----------- 
     11 
     12The neutron scattering length density is defined as 
     13 
     14SLD = (b_c1 +b_c2+...+b_cn )/Vm 
     15 
     16where  
     17 
     18b_ci is the bound coherent scattering length of ith of n atoms in a molecule  
     19with the molecular volume Vm 
     20 
     21.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ 
     22 
     23How to Format the Compound Name 
     24------------------------------- 
     25 
     26To calculate scattering length densities enter a compound and a mass density  
     27and click "Calculate". Entering a wavelength value is optional (a default  
     28value of 6.0 Angstroms will be used). 
     29 
     30* Formula strings consist of counts and atoms such as "CaCO3+6H2O". 
     31 
     32* Groups can be separated by *'+'* or *space*, so "CaCO3 6H2O" works as well. 
     33 
     34* Groups and be defined using parentheses, such as "CaCO3(H2O)6". 
     35 
     36* Parentheses can be nested, such as "(CaCO3(H2O)6)1". 
     37 
     38* Isotopes are represented by their index, e.g., "CaCO[18]3+6H2O", H[1], or  
     39H[2]. 
     40 
     41* Counts can be integer or decimal, e.g. "CaCO3+(3HO0.5)2". 
     42 
     43* Other compositions can be calculated as well, for example, for a 70-30  
     44mixture of H2O/D2O write *H14O7+ D6O3* or more simply *H7D3O5* (i.e. this says  
     457 hydrogens, 3 deuteriums, and 5 oxygens) and the mass density calculated  
     46based on the percentages of H and D. 
     47 
     48* Type *C[13]6 H[2]12 O[18]6* for C(13)6H(2)12O(18)6 (6 Carbon-13 atoms, 12  
     49deuterium atoms, and 6 Oxygen-18 atoms) 
  • src/sas/calculator/media/slit_calculator_help.rst

    r37bbd5f r78f02c3  
    11..slit_calculator_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. 
    25 
    36Slit Size Calculator Tool 
    47========================= 
    58 
    6 Placeholder for slit calculator help 
     9Description 
     10----------- 
     11This tool is for X-ray users to calculate the slit size (FWHM/2) for smearing  
     12based on their half beam profile data (SAXSess). 
     13 
     14.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ 
     15 
     16How To 
     17------- 
     18To calculate the slit size (FWHM/2), just load the beam profile data using the  
     19browse button. 
     20 
     21Once a data is loaded, the slit size will be computed and show up in the text  
     22box. 
     23 
     24Because the unit is not specified in the data file, we do not convert it into  
     251/Angstrom so  users are responsible for converting the units of their data. 
     26 
     27Note: This slit size calculator only works for beam profile data produced by  
     28'SAXSess'. 
     29 
     30To see the file format, check the file, 'beam profile.DAT', in the 'test'  
     31folder of SasView. 
Note: See TracChangeset for help on using the changeset viewer.