source: sasview/src/sas/models/media/model_functions.rst @ e8e3e38

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.1.1release-4.1.2release-4.2.2release_4.0.1ticket-1009ticket-1094-headlessticket-1242-2d-resolutionticket-1243ticket-1249ticket885unittest-saveload
Last change on this file since e8e3e38 was a342928, checked in by smk78, 9 years ago

Formatting improvement to equations in CoreShellEllipsoidXTModel
(suggested by Richard)

  • Property mode set to 100644
File size: 165.5 KB
RevLine 
[1c03e14]1.. model_functions.rst
2
3.. This is a port of the original SasView model_functions.html to ReSTructured text
[6386cd8]4.. by S King, ISIS, during and after SasView CodeCamp-II in April 2014.
5
6.. Thanks are due to A Jackson & P Kienzle for advice on RST!
7
8.. The CoreShellEllipsoidXTModel was ported and documented by R K Heenan, ISIS, Apr 2014
9.. The RectangularPrism models were coded and documented by M A Gonzalez, ILL, Apr 2014
10
11.. To do:
12.. Add example parameters/plots for the CoreShellEllipsoidXTModel
13.. Add example parameters/plots for the RectangularPrism models
14.. Check the content against the NIST Igor Help File
15.. Wordsmith the content for consistency of style, etc
16
17
18
19.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
20
[1c03e14]21
[ee9fa94]22.. note::  The contents of this document are presented in good faith and are
23           believed to be mostly correct and accurate, however they have not
24           yet been rigorously checked for errors. June2015
[fb07044d]25
[1c03e14]26
27.. Set up some substitutions to make life easier...
28
29.. |alpha| unicode:: U+03B1
30.. |beta| unicode:: U+03B2
31.. |gamma| unicode:: U+03B3
32.. |delta| unicode:: U+03B4
33.. |epsilon| unicode:: U+03B5
34.. |zeta| unicode:: U+03B6
35.. |eta| unicode:: U+03B7
36.. |theta| unicode:: U+03B8
37.. |iota| unicode:: U+03B9
38.. |kappa| unicode:: U+03BA
39.. |lambda| unicode:: U+03BB
40.. |mu| unicode:: U+03BC
41.. |nu| unicode:: U+03BD
42.. |xi| unicode:: U+03BE
43.. |omicron| unicode:: U+03BF
44.. |pi| unicode:: U+03C0
45.. |rho| unicode:: U+03C1
46.. |sigma| unicode:: U+03C3
47.. |tau| unicode:: U+03C4
48.. |upsilon| unicode:: U+03C5
49.. |phi| unicode:: U+03C6
50.. |chi| unicode:: U+03C7
51.. |psi| unicode:: U+03C8
52.. |omega| unicode:: U+03C9
53.. |biggamma| unicode:: U+0393
[93b6fcc]54.. |bigdelta| unicode:: U+0394
55.. |bigzeta| unicode:: U+039E
[38d4102]56.. |bigpsi| unicode:: U+03A8
[1c03e14]57.. |drho| replace:: |bigdelta|\ |rho|
58.. |Ang| unicode:: U+212B
59.. |Ang^-1| replace:: |Ang|\ :sup:`-1`
60.. |Ang^2| replace:: |Ang|\ :sup:`2`
61.. |Ang^-2| replace:: |Ang|\ :sup:`-2`
62.. |Ang^3| replace:: |Ang|\ :sup:`3`
[58eccf6]63.. |Ang^-3| replace:: |Ang|\ :sup:`-3`
64.. |Ang^-4| replace:: |Ang|\ :sup:`-4`
[1c03e14]65.. |cm^-1| replace:: cm\ :sup:`-1`
66.. |cm^2| replace:: cm\ :sup:`2`
67.. |cm^-2| replace:: cm\ :sup:`-2`
68.. |cm^3| replace:: cm\ :sup:`3`
69.. |cm^-3| replace:: cm\ :sup:`-3`
70.. |sr^-1| replace:: sr\ :sup:`-1`
71.. |P0| replace:: P\ :sub:`0`\
72.. |A2| replace:: A\ :sub:`2`\
73
74
75
76.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
77
78
79
80.. Actual document starts here...
81
[5e880fe1]82.. _SasView_model_functions:
83
[1c03e14]84SasView Model Functions
85=======================
86
[98b30b4]87.. _Background:
[1c03e14]88
[98b30b4]891. Background
[1c03e14]90---------------
91
92Many of our models use the form factor calculations implemented in a c-library provided by the NIST Center for Neutron
[6386cd8]93Research and thus some content and figures in this document are originated from or shared with the NIST SANS Igor-based
94analysis package.
[1c03e14]95
96This software provides form factors for various particle shapes. After giving a mathematical definition of each model,
97we show the list of parameters available to the user. Validation plots for each model are also presented.
98
99Instructions on how to use SasView itself are available separately.
100
101To easily compare to the scattering intensity measured in experiments, we normalize the form factors by the volume of
102the particle
103
104.. image:: img/image001.PNG
105
106with
107
108.. image:: img/image002.PNG
109
110where |P0|\ *(q)* is the un-normalized form factor, |rho|\ *(r)* is the scattering length density at a given
111point in space and the integration is done over the volume *V* of the scatterer.
112
113For systems without inter-particle interference, the form factors we provide can be related to the scattering intensity
114by the particle volume fraction
115
116.. image:: img/image003.PNG
117
118Our so-called 1D scattering intensity functions provide *P(q)* for the case where the scatterer is randomly oriented. In
[6386cd8]119that case, the scattering intensity only depends on the length of *q* . The intensity measured on the plane of the SAS
[1c03e14]120detector will have an azimuthal symmetry around *q*\ =0 .
121
122Our so-called 2D scattering intensity functions provide *P(q,* |phi| *)* for an oriented system as a function of a
123q-vector in the plane of the detector. We define the angle |phi| as the angle between the q vector and the horizontal
124(x) axis of the plane of the detector.
125
126For information about polarised and magnetic scattering, click here_.
127
128.. _here: polar_mag_help.html
129
130
131
132.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
133
134
135
136.. _Model:
137
1382. Model functions
139------------------
140
141.. _Shape-based:
142
1432.1 Shape-based Functions
144-------------------------
145
146Sphere-based
147------------
148
149- SphereModel_ (including magnetic 2D version)
150- BinaryHSModel_
151- FuzzySphereModel_
152- RaspBerryModel_
153- CoreShellModel_ (including magnetic 2D version)
[7072ce6]154- MicelleSphCoreModel_
[1c03e14]155- CoreMultiShellModel_ (including magnetic 2D version)
156- Core2ndMomentModel_
157- MultiShellModel_
158- OnionExpShellModel_
159- VesicleModel_
160- SphericalSLDModel_
161- LinearPearlsModel_
162- PearlNecklaceModel_
163
164Cylinder-based
165--------------
166
167- CylinderModel_ (including magnetic 2D version)
168- HollowCylinderModel_
[38d4102]169- CappedCylinderModel_
170- CoreShellCylinderModel_
171- EllipticalCylinderModel_
[77cfcf0]172- FlexibleCylinderModel_
173- FlexCylEllipXModel_
174- CoreShellBicelleModel_
175- BarBellModel_
176- StackedDisksModel_
177- PringleModel_
[1c03e14]178
179Ellipsoid-based
180---------------
181
[990c2eb]182- EllipsoidModel_
183- CoreShellEllipsoidModel_
184- CoreShellEllipsoidXTModel_
[bf8c07b]185- TriaxialEllipsoidModel_
[1c03e14]186
187Lamellae
188--------
189
[1127c32]190- LamellarModel_
191- LamellarFFHGModel_
192- LamellarPSModel_
193- LamellarPSHGModel_
[1c03e14]194
195Paracrystals
196------------
197
[1127c32]198- LamellarPCrystalModel_
[d4117ccb]199- SCCrystalModel_
200- FCCrystalModel_
201- BCCrystalModel_
[1c03e14]202
203Parallelpipeds
204--------------
205
[bf8c07b]206- ParallelepipedModel_ (including magnetic 2D version)
207- CSParallelepipedModel_
[6386cd8]208- RectangularPrismModel_
209- RectangularHollowPrismModel_
210- RectangularHollowPrismInfThinWallsModel_
[1c03e14]211
212.. _Shape-independent:
213
2142.2 Shape-Independent Functions
215-------------------------------
216
[6386cd8]217(In alphabetical order)
218
[4ed2d0a1]219- AbsolutePower_Law_
[93b6fcc]220- BEPolyelectrolyte_
221- BroadPeakModel_
222- CorrLength_
223- DABModel_
224- Debye_
225- FractalModel_
226- FractalCoreShell_
227- GaussLorentzGel_
[6386cd8]228- GelFitModel_
[93b6fcc]229- Guinier_
230- GuinierPorod_
[6386cd8]231- LineModel_
[93b6fcc]232- Lorentz_
233- MassFractalModel_
234- MassSurfaceFractal_
[6386cd8]235- PeakGaussModel_
236- PeakLorentzModel_
237- Poly_GaussCoil_
238- PolyExclVolume_
239- PorodModel_
240- RPA10Model_
241- StarPolymer_
[93b6fcc]242- SurfaceFractalModel_
243- TeubnerStrey_
[6386cd8]244- TwoLorentzian_
245- TwoPowerLaw_
246- UnifiedPowerRg_
247- ReflectivityModel_
248- ReflectivityIIModel_
[1c03e14]249
250.. _Structure-factor:
251
2522.3 Structure Factor Functions
253------------------------------
254
255- HardSphereStructure_
256- SquareWellStructure_
257- HayterMSAStructure_
258- StickyHSStructure_
259
260.. _Customised:
261
2622.4 Customized Functions
263------------------------
264
265- testmodel_
266- testmodel_2_
267- sum_p1_p2_
268- sum_Ap1_1_Ap2_
269- polynomial5_
270- sph_bessel_jn_
271
[ee9fa94]272Also see the documentation on :ref:`Adding_your_own_models` under Fitting Data.
273
[1c03e14]274
275
276.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
277
278
279
280.. _References:
281
2823. References
283-------------
284
285*Small-Angle Scattering of X-Rays*
[93b6fcc]286A Guinier and G Fournet
[1c03e14]287John Wiley & Sons, New York (1955)
288
[93b6fcc]289P Stckel, R May, I Strell, Z Cejka, W Hoppe, H Heumann, W Zillig and H Crespi
[1c03e14]290*Eur. J. Biochem.*, 112, (1980), 411-417
291
[93b6fcc]292G Porod
[1c03e14]293in *Small Angle X-ray Scattering*
[93b6fcc]294(editors) O Glatter and O Kratky
[1c03e14]295Academic Press (1982)
296
297*Structure Analysis by Small-Angle X-Ray and Neutron Scattering*
[93b6fcc]298L.A Feigin and D I Svergun
[1c03e14]299Plenum Press, New York (1987)
300
[93b6fcc]301S Hansen
[1c03e14]302*J. Appl. Cryst.* 23, (1990), 344-346
303
[93b6fcc]304S J Henderson
[1c03e14]305*Biophys. J.* 70, (1996), 1618-1627
306
[93b6fcc]307B C McAlister and B P Grady
[1c03e14]308*J. Appl. Cryst.* 31, (1998), 594-599
309
[93b6fcc]310S R Kline
[1c03e14]311*J Appl. Cryst.* 39(6), (2006), 895
312
313**Also see the references at the end of the each model function descriptions.**
314
315
316
317.. ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ
318
319
320
321Model Definitions
322-----------------
323
324.. _SphereModel:
325
326**2.1.1. SphereModel**
327
328This model provides the form factor, *P(q)*, for a monodisperse spherical particle with uniform scattering length
329density. The form factor is normalized by the particle volume as described below.
330
331For information about polarised and magnetic scattering, click here_.
332
333.. _here: polar_mag_help.html
334
335*2.1.1.1. Definition*
336
337The 1D scattering intensity is calculated in the following way (Guinier, 1955)
338
339.. image:: img/image004.PNG
340
341where *scale* is a volume fraction, *V* is the volume of the scatterer, *r* is the radius of the sphere, *bkg* is
342the background level and *sldXXX* is the scattering length density (SLD) of the scatterer or the solvent.
343
344Note that if your data is in absolute scale, the *scale* should represent the volume fraction (which is unitless) if
345you have a good fit. If not, it should represent the volume fraction \* a factor (by which your data might need to be
346rescaled).
347
348The 2D scattering intensity is the same as above, regardless of the orientation of the q vector.
349
350The returned value is scaled to units of |cm^-1| and the parameters of the SphereModel are the following:
351
352==============  ========  =============
353Parameter name  Units     Default value
354==============  ========  =============
355scale           None      1
356radius          |Ang|     60
357sldSph          |Ang^-2|  2.0e-6
358sldSolv         |Ang^-2|  1.0e-6
359background      |cm^-1|   0
360==============  ========  =============
361
362Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron
363Research (Kline, 2006).
364
365REFERENCE
[bf8c07b]366
[93b6fcc]367A Guinier and G. Fournet, *Small-Angle Scattering of X-Rays*, John Wiley and Sons, New York, (1955)
[1c03e14]368
369*2.1.1.2. Validation of the SphereModel*
370
371Validation of our code was done by comparing the output of the 1D model to the output of the software provided by the
372NIST (Kline, 2006). Figure 1 shows a comparison of the output of our model and the output of the NIST software.
373
[7f42aad]374.. image:: img/image005.jpg
[1c03e14]375
376Figure 1: Comparison of the DANSE scattering intensity for a sphere with the output of the NIST SANS analysis software.
377The parameters were set to: Scale=1.0, Radius=60 |Ang|, Contrast=1e-6 |Ang^-2|, and Background=0.01 |cm^-1|.
378
[93b6fcc]379*2013/09/09 and 2014/01/06 - Description reviewed by S King and P Parker.*
[1c03e14]380
381
382
383.. _BinaryHSModel:
384
385**2.1.2. BinaryHSModel**
386
387*2.1.2.1. Definition*
388
389This model (binary hard sphere model) provides the scattering intensity, for binary mixture of spheres including hard
390sphere interaction between those particles. Using Percus-Yevick closure, the calculation is an exact multi-component
391solution
392
393.. image:: img/image006.PNG
394
395where *Sij* are the partial structure factors and *fi* are the scattering amplitudes of the particles. The subscript 1
396is for the smaller particle and 2 is for the larger. The number fraction of the larger particle, (*x* = n2/(n1+n2),
397where *n* = the number density) is internally calculated based on
398
399.. image:: img/image007.PNG
400
401The 2D scattering intensity is the same as 1D, regardless of the orientation of the *q* vector which is defined as
402
403.. image:: img/image008.PNG
404
405The parameters of the BinaryHSModel are the following (in the names, *l* (or *ls*\ ) stands for larger spheres
406while *s* (or *ss*\ ) for the smaller spheres).
407
408==============  ========  =============
409Parameter name  Units     Default value
410==============  ========  =============
411background      |cm^-1|   0.001
412l_radius        |Ang|     100.0
413ss_sld          |Ang^-2|  0.0
414ls_sld          |Ang^-2|  3e-6
415solvent_sld     |Ang^-2|  6e-6
416s_radius        |Ang|     25.0
417vol_frac_ls     None      0.1
418vol_frac_ss     None      0.2
419==============  ========  =============
420
[7f42aad]421.. image:: img/image009.jpg
[1c03e14]422
423*Figure. 1D plot using the default values above (w/200 data point).*
424
425Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron
426Research (Kline, 2006).
427
428See the reference for details.
429
430REFERENCE
[bf8c07b]431
[93b6fcc]432N W Ashcroft and D C Langreth, *Physical Review*, 156 (1967) 685-692
[1c03e14]433[Errata found in *Phys. Rev.* 166 (1968) 934]
434
435
436
437.. _FuzzySphereModel:
438
439**2.1.3. FuzzySphereModel**
440
441This model is to calculate the scattering from spherical particles with a "fuzzy" interface.
442
443*2.1.3.1. Definition*
444
445The scattering intensity *I(q)* is calculated as:
446
447.. image:: img/image010.PNG
448
449where the amplitude *A(q)* is given as the typical sphere scattering convoluted with a Gaussian to get a gradual
450drop-off in the scattering length density
451
452.. image:: img/image011.PNG
453
454Here |A2|\ *(q)* is the form factor, *P(q)*. The scale is equivalent to the volume fraction of spheres, each of
455volume, *V*\. Contrast (|drho|) is the difference of scattering length densities of the sphere and the surrounding
456solvent.
457
458Poly-dispersion in radius and in fuzziness is provided for.
459
460The returned value is scaled to units of |cm^-1|\ |sr^-1|; ie, absolute scale.
461
462From the reference
463
464  The "fuzziness" of the interface is defined by the parameter |sigma| :sub:`fuzzy`\ . The particle radius *R*
465  represents the radius of the particle where the scattering length density profile decreased to 1/2 of the core
466  density. The |sigma| :sub:`fuzzy`\ is the width of the smeared particle surface; i.e., the standard deviation
467  from the average height of the fuzzy interface. The inner regions of the microgel that display a higher density
468  are described by the radial box profile extending to a radius of approximately *Rbox* ~ *R* - 2\ |sigma|\ . The
469  profile approaches zero as *Rsans* ~ *R* + 2\ |sigma|\ .
470
471For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
472
473.. image:: img/image008.PNG
474
475This example dataset is produced by running the FuzzySphereModel, using 200 data points, *qmin* = 0.001 -1,
476*qmax* = 0.7 |Ang^-1| and the default values
477
478==============  ========  =============
479Parameter name  Units     Default value
480==============  ========  =============
481scale           None      1.0
482radius          |Ang|     60
483fuzziness       |Ang|     10
484sldSolv         |Ang^-2|  3e-6
485sldSph          |Ang^-2|  1e-6
486background      |cm^-1|   0.001
487==============  ========  =============
488
[7f42aad]489.. image:: img/image012.jpg
[1c03e14]490
491*Figure. 1D plot using the default values (w/200 data point).*
492
493REFERENCE
[bf8c07b]494
[93b6fcc]495M Stieger, J. S Pedersen, P Lindner, W Richtering, *Langmuir*, 20 (2004) 7283-7292
[1c03e14]496
497
498
499.. _RaspBerryModel:
500
501**2.1.4. RaspBerryModel**
502
503Calculates the form factor, *P(q)*, for a "Raspberry-like" structure where there are smaller spheres at the surface
504of a larger sphere, such as the structure of a Pickering emulsion.
505
506*2.1.4.1. Definition*
507
508The structure is:
509
[7f42aad]510.. image:: img/raspberry_pic.jpg
[1c03e14]511
512where *Ro* = the radius of the large sphere, *Rp* = the radius of the smaller sphere on the surface, |delta| = the
513fractional penetration depth, and surface coverage = fractional coverage of the large sphere surface (0.9 max).
514
515The large and small spheres have their own SLD, as well as the solvent. The surface coverage term is a fractional
516coverage (maximum of approximately 0.9 for hexagonally-packed spheres on a surface). Since not all of the small
517spheres are necessarily attached to the surface, the excess free (small) spheres scattering is also included in the
518calculation. The function calculated follows equations (8)-(12) of the reference below, and the equations are not
519reproduced here.
520
521The returned value is scaled to units of |cm^-1|. No inter-particle scattering is included in this model.
522
523For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
524
525.. image:: img/image008.PNG
526
527This example dataset is produced by running the RaspBerryModel, using 2000 data points, *qmin* = 0.0001 |Ang^-1|,
528*qmax* = 0.2 |Ang^-1| and the default values below, where *Ssph/Lsph* stands for smaller or larger sphere, respectively,
529and *surfrac_Ssph* is the surface fraction of the smaller spheres.
530
531==============  ========  =============
532Parameter name  Units     Default value
533==============  ========  =============
534delta_Ssph      None      0
535radius_Lsph     |Ang|     5000
536radius_Ssph     |Ang|     100
537sld_Lsph        |Ang^-2|  -4e-07
538sld_Ssph        |Ang^-2|  3.5e-6
539sld_solv        |Ang^-2|  6.3e-6
540surfrac_Ssph    None      0.4
541volf_Lsph       None      0.05
542volf_Lsph       None      0.005
543background      |cm^-1|   0
544==============  ========  =============
545
[7f42aad]546.. image:: img/raspberry_plot.jpg
[1c03e14]547
548*Figure. 1D plot using the values of /2000 data points.*
549
550REFERENCE
[bf8c07b]551
[93b6fcc]552K Larson-Smith, A Jackson, and D C Pozzo, *Small angle scattering model for Pickering emulsions and raspberry*
[1c03e14]553*particles*, *Journal of Colloid and Interface Science*, 343(1) (2010) 36-41
554
555
556
557.. _CoreShellModel:
558
559**2.1.5. CoreShellModel**
560
561This model provides the form factor, *P(q)*, for a spherical particle with a core-shell structure. The form factor is
562normalized by the particle volume.
563
564For information about polarised and magnetic scattering, click here_.
565
566*2.1.5.1. Definition*
567
568The 1D scattering intensity is calculated in the following way (Guinier, 1955)
569
570.. image:: img/image013.PNG
571
572where *scale* is a scale factor, *Vs* is the volume of the outer shell, *Vc* is the volume of the core, *rs* is the
573radius of the shell, *rc* is the radius of the core, *c* is the scattering length density of the core, *s* is the
574scattering length density of the shell, *solv* is the scattering length density of the solvent, and *bkg* is the
575background level.
576
577The 2D scattering intensity is the same as *P(q)* above, regardless of the orientation of the *q* vector.
578
579NB: The outer most radius (ie, = *radius* + *thickness*) is used as the effective radius for *S(Q)* when
580*P(Q)* \* *S(Q)* is applied.
581
582The returned value is scaled to units of |cm^-1| and the parameters of the CoreShellModel are the following
583
584==============  ========  =============
585Parameter name  Units     Default value
586==============  ========  =============
587scale           None      1.0
588(core) radius   |Ang|     60
589thickness       |Ang|     10
590core_sld        |Ang^-2|  1e-6
591shell_sld       |Ang^-2|  2e-6
592solvent_sld     |Ang^-2|  3e-6
593background      |cm^-1|   0.001
594==============  ========  =============
595
596Here, *radius* = the radius of the core and *thickness* = the thickness of the shell.
597
598Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron
599Research (Kline, 2006).
600
601REFERENCE
[bf8c07b]602
[93b6fcc]603A Guinier and G Fournet, *Small-Angle Scattering of X-Rays*, John Wiley and Sons, New York, (1955)
[1c03e14]604
605*2.1.5.2. Validation of the core-shell sphere model*
606
607Validation of our code was done by comparing the output of the 1D model to the output of the software provided by
608NIST (Kline, 2006). Figure 1 shows a comparison of the output of our model and the output of the NIST software.
609
[7f42aad]610.. image:: img/image014.jpg
[1c03e14]611
612Figure 1: Comparison of the SasView scattering intensity for a core-shell sphere with the output of the NIST SANS
613analysis software. The parameters were set to: *Scale* = 1.0, *Radius* = 60 , *Contrast* = 1e-6 |Ang^-2|, and
614*Background* = 0.001 |cm^-1|.
615
616
617
618.. _CoreMultiShellModel:
619
620**2.1.6. CoreMultiShellModel**
621
622This model provides the scattering from a spherical core with 1 to 4 concentric shell structures. The SLDs of the core
623and each shell are individually specified.
624
625For information about polarised and magnetic scattering, click here_.
626
627*2.1.6.1. Definition*
628
629This model is a trivial extension of the CoreShell function to a larger number of shells. See the CoreShell function
630for a diagram and documentation.
631
[77cfcf0]632The returned value is scaled to units of |cm^-1|\ |sr^-1|, absolute scale.
[1c03e14]633
634Be careful! The SLDs and scale can be highly correlated. Hold as many of these parameters fixed as possible.
635
636The 2D scattering intensity is the same as P(q) of 1D, regardless of the orientation of the q vector.
637
638NB: The outer most radius (ie, = *radius* + 4 *thicknesses*) is used as the effective radius for *S(Q)* when
639*P(Q)* \* *S(Q)* is applied.
640
641The returned value is scaled to units of |cm^-1| and the parameters of the CoreMultiShell model are the following
642
643==============  ========  =============
644Parameter name  Units     Default value
645==============  ========  =============
646scale           None      1.0
647rad_core        |Ang|     60
648sld_core        |Ang^-2|  6.4e-6
649sld_shell1      |Ang^-2|  1e-6
650sld_shell2      |Ang^-2|  2e-6
651sld_shell3      |Ang^-2|  3e-6
652sld_shell4      |Ang^-2|  4e-6
653sld_solv        |Ang^-2|  6.4e-6
654thick_shell1    |Ang|     10
655thick_shell2    |Ang|     10
656thick_shell3    |Ang|     10
657thick_shell4    |Ang|     10
658background      |cm^-1|   0.001
659==============  ========  =============
660
661NB: Here, *rad_core* = the radius of the core, *thick_shelli* = the thickness of the shell *i* and
662*sld_shelli* = the SLD of the shell *i*. *sld_core* and the *sld_solv* are the SLD of the core and the solvent,
663respectively.
664
665Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron
666Research (Kline, 2006).
667
668This example dataset is produced by running the CoreMultiShellModel using 200 data points, *qmin* = 0.001 -1,
669*qmax* = 0.7 -1 and the above default values.
670
[7f42aad]671.. image:: img/image015.jpg
[1c03e14]672
673*Figure: 1D plot using the default values (w/200 data point).*
674
675The scattering length density profile for the default sld values (w/ 4 shells).
676
[7f42aad]677.. image:: img/image016.jpg
[1c03e14]678
679*Figure: SLD profile against the radius of the sphere for default SLDs.*
680
681REFERENCE
[bf8c07b]682
683See the CoreShellModel_ documentation.
[1c03e14]684
685
686
687.. _Core2ndMomentModel:
688
689**2.1.7. Core2ndMomentModel**
690
691This model describes the scattering from a layer of surfactant or polymer adsorbed on spherical particles under the
692conditions that (i) the particles (cores) are contrast-matched to the dispersion medium, (ii) *S(Q)* ~ 1 (ie, the
693particle volume fraction is dilute), (iii) the particle radius is >> layer thickness (ie, the interface is locally
694flat), and (iv) scattering from excess unadsorbed adsorbate in the bulk medium is absent or has been corrected for.
695
696Unlike a core-shell model, this model does not assume any form for the density distribution of the adsorbed species
697normal to the interface (cf, a core-shell model which assumes the density distribution to be a homogeneous
698step-function). For comparison, if the thickness of a (core-shell like) step function distribution is *t*, the second
699moment, |sigma| = sqrt((*t* :sup:`2` )/12). The |sigma| is the second moment about the mean of the density distribution
700(ie, the distance of the centre-of-mass of the distribution from the interface).
701
702*2.1.7.1. Definition*
703
704The *I* :sub:`0` is calculated in the following way (King, 2002)
705
[7f42aad]706.. image:: img/secondmeq1.jpg
[1c03e14]707
708where *scale* is a scale factor, *poly* is the sld of the polymer (or surfactant) layer, *solv* is the sld of the
709solvent/medium and cores, |phi|\ :sub:`cores` is the volume fraction of the core paraticles, and |biggamma| and
710|delta| are the adsorbed amount and the bulk density of the polymers respectively. The |sigma| is the second moment
711of the thickness distribution.
712
713Note that all parameters except the |sigma| are correlated for fitting so that fitting those with more than one
714parameter will generally fail. Also note that unlike other shape models, no volume normalization is applied to this
715model (the calculation is exact).
716
717The returned value is scaled to units of |cm^-1| and the parameters are the following
718
719==============  ========  =============
720Parameter name  Units     Default value
721==============  ========  =============
722scale           None      1.0
723density_poly    g/cm2     0.7
724radius_core     |Ang|     500
725ads_amount      mg/m 2    1.9
726second_moment   |Ang|     23.0
727volf_cores      None      0.14
728sld_poly        |Ang^-2|  1.5e-6
729sld_solv        |Ang^-2|  6.3e-6
730background      |cm^-1|   0.0
731==============  ========  =============
732
[7f42aad]733.. image:: img/secongm_fig1.jpg
[1c03e14]734
735REFERENCE
[bf8c07b]736
[93b6fcc]737S King, P Griffiths, J. Hone, and T Cosgrove, *SANS from Adsorbed Polymer Layers*,
[1c03e14]738*Macromol. Symp.*, 190 (2002) 33-42
739
740
741
742.. _MultiShellModel:
743
744**2.1.8. MultiShellModel**
745
746This model provides the form factor, *P(q)*, for a multi-lamellar vesicle with *N* shells where the core is filled with
747solvent and the shells are interleaved with layers of solvent. For *N* = 1, this returns the VesicleModel (above).
748
[7f42aad]749.. image:: img/image020.jpg
[1c03e14]750
751The 2D scattering intensity is the same as 1D, regardless of the orientation of the *q* vector which is defined as
752
753.. image:: img/image008.PNG
754
755NB: The outer most radius (= *core_radius* + *n_pairs* \* *s_thickness* + (*n_pairs* - 1) \* *w_thickness*) is used
756as the effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
757
758The returned value is scaled to units of |cm^-1| and the parameters of the MultiShellModel are the following
759
760==============  ========  =============
761Parameter name  Units     Default value
762==============  ========  =============
763scale           None      1.0
764core_radius     |Ang|     60.0
765n_pairs         None      2.0
766core_sld        |Ang^-2|  6.3e-6
767shell_sld       |Ang^-2|  0.0
768background      |cm^-1|   0.0
769s_thickness     |Ang|     10
770w_thickness     |Ang|     10
771==============  ========  =============
772
773NB: *s_thickness* is the shell thickness while the *w_thickness* is the solvent thickness, and *n_pair*
774is the number of shells.
775
[7f42aad]776.. image:: img/image021.jpg
[1c03e14]777
778*Figure. 1D plot using the default values (w/200 data point).*
779
780Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron
781Research (Kline, 2006).
782
783REFERENCE
[bf8c07b]784
[93b6fcc]785B Cabane, *Small Angle Scattering Methods*, in *Surfactant Solutions: New Methods of Investigation*, Ch.2,
786Surfactant Science Series Vol. 22, Ed. R Zana and M Dekker, New York, (1987).
[1c03e14]787
788
789
790.. _OnionExpShellModel:
791
792**2.1.9. OnionExpShellModel**
793
794This model provides the form factor, *P(q)*, for a multi-shell sphere where the scattering length density (SLD) of the
795each shell is described by an exponential (linear, or flat-top) function. The form factor is normalized by the volume
796of the sphere where the SLD is not identical to the SLD of the solvent. We currently provide up to 9 shells with this
797model.
798
799*2.1.9.1. Definition*
800
801The 1D scattering intensity is calculated in the following way
802
[7f42aad]803.. image:: img/image022.gif
[1c03e14]804
[7f42aad]805.. image:: img/image023.gif
[1c03e14]806
807where, for a spherically symmetric particle with a particle density |rho|\ *(r)*
808
[7f42aad]809.. image:: img/image024.gif
[1c03e14]810
811so that
812
[7f42aad]813.. image:: img/image025.gif
[1c03e14]814
[7f42aad]815.. image:: img/image026.gif
[1c03e14]816
[7f42aad]817.. image:: img/image027.gif
[1c03e14]818
819Here we assumed that the SLDs of the core and solvent are constant against *r*.
820
821Now lets consider the SLD of a shell, *r*\ :sub:`shelli`, defined by
822
[7f42aad]823.. image:: img/image028.gif
[1c03e14]824
825An example of a possible SLD profile is shown below where *sld_in_shelli* (|rho|\ :sub:`in`\ ) and
826*thick_shelli* (|bigdelta|\ *t* :sub:`shelli`\ ) stand for the SLD of the inner side of the *i*\ th shell and the
827thickness of the *i*\ th shell in the equation above, respectively.
828
829For \| *A* \| > 0,
830
[7f42aad]831.. image:: img/image029.gif
[1c03e14]832
833For *A* ~ 0 (eg., *A* = -0.0001), this function converges to that of the linear SLD profile (ie,
834|rho|\ :sub:`shelli`\ *(r)* = *A*\ :sup:`'` ( *r* - *r*\ :sub:`shelli` - 1) / |bigdelta|\ *t* :sub:`shelli`) + *B*\ :sup:`'`),
835so this case is equivalent to
836
[7f42aad]837.. image:: img/image030.gif
[1c03e14]838
[7f42aad]839.. image:: img/image031.gif
[1c03e14]840
[7f42aad]841.. image:: img/image032.gif
[1c03e14]842
[7f42aad]843.. image:: img/image033.gif
[1c03e14]844
845For *A* = 0, the exponential function has no dependence on the radius (so that *sld_out_shell* (|rho|\ :sub:`out`) is
846ignored this case) and becomes flat. We set the constant to |rho|\ :sub:`in` for convenience, and thus the form
847factor contributed by the shells is
848
[7f42aad]849.. image:: img/image034.gif
[1c03e14]850
[7f42aad]851.. image:: img/image035.gif
[1c03e14]852
853In the equation
854
[7f42aad]855.. image:: img/image036.gif
[1c03e14]856
857Finally, the form factor can be calculated by
858
[7f42aad]859.. image:: img/image037.gif
[1c03e14]860
861where
862
[7f42aad]863.. image:: img/image038.gif
[1c03e14]864
865and
866
[7f42aad]867.. image:: img/image039.gif
[1c03e14]868
869The 2D scattering intensity is the same as *P(q)* above, regardless of the orientation of the *q* vector which is
870defined as
871
[7f42aad]872.. image:: img/image040.gif
[1c03e14]873
874NB: The outer most radius is used as the effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
875
876The returned value is scaled to units of |cm^-1| and the parameters of this model (for only one shell) are the following
877
878==============  ========  =============
879Parameter name  Units     Default value
880==============  ========  =============
881A_shell1        None      1
882scale           None      1.0
883rad_core        |Ang|     200
884thick_shell1    |Ang|     50
885sld_core        |Ang^-2|  1.0e-06
886sld_in_shell1   |Ang^-2|  1.7e-06
887sld_out_shell1  |Ang^-2|  2.0e-06
888sld_solv        |Ang^-2|  6.4e-06
889background      |cm^-1|   0.0
890==============  ========  =============
891
892NB: *rad_core* represents the core radius (*R1*) and *thick_shell1* (*R2* - *R1*) is the thickness of the shell1, etc.
893
[7f42aad]894.. image:: img/image041.jpg
[1c03e14]895
896*Figure. 1D plot using the default values (w/400 point).*
897
[7f42aad]898.. image:: img/image042.jpg
[1c03e14]899
900*Figure. SLD profile from the default values.*
901
902REFERENCE
[bf8c07b]903
[93b6fcc]904L A Feigin and D I Svergun, *Structure Analysis by Small-Angle X-Ray and Neutron Scattering*,
[1c03e14]905Plenum Press, New York, (1987).
906
907
908
909.. _VesicleModel:
910
911**2.1.10. VesicleModel**
912
913This model provides the form factor, *P(q)*, for an unilamellar vesicle. The form factor is normalized by the volume
914of the shell.
915
916*2.1.10.1. Definition*
917
918The 1D scattering intensity is calculated in the following way (Guinier, 1955)
919
920.. image:: img/image017.PNG
921
922where *scale* is a scale factor, *Vshell* is the volume of the shell, *V1* is the volume of the core, *V2* is the total
923volume, *R1* is the radius of the core, *R2* is the outer radius of the shell, |rho|\ :sub:`1` is the scattering
924length density of the core and the solvent, |rho|\ :sub:`2` is the scattering length density of the shell, *bkg* is
925the background level, and *J1* = (sin\ *x*- *x* cos\ *x*)/ *x* :sup:`2`\ . The functional form is identical to a
926"typical" core-shell structure, except that the scattering is normalized by the volume that is contributing to the
927scattering, namely the volume of the shell alone. Also, the vesicle is best defined in terms of a core radius (= *R1*)
928and a shell thickness, *t*.
929
[7f42aad]930.. image:: img/image018.jpg
[1c03e14]931
932The 2D scattering intensity is the same as *P(q)* above, regardless of the orientation of the *q* vector which is
933defined as
934
935.. image:: img/image008.PNG
936
937NB: The outer most radius (= *radius* + *thickness*) is used as the effective radius for *S(Q)* when *P(Q)* \* *S(Q)*
938is applied.
939
940The returned value is scaled to units of |cm^-1| and the parameters of the VesicleModel are the following
941
942==============  ========  =============
943Parameter name  Units     Default value
944==============  ========  =============
945scale           None      1.0
946radius          |Ang|     100
947thickness       |Ang|     30
948core_sld        |Ang^-2|  6.3e-6
949shell_sld       |Ang^-2|  0
950background      |cm^-1|   0.0
951==============  ========  =============
952
953NB: *radius* represents the core radius (*R1*) and the *thickness* (*R2* - *R1*) is the shell thickness.
954
[7f42aad]955.. image:: img/image019.jpg
[1c03e14]956
957*Figure. 1D plot using the default values (w/200 data point).*
958
959Our model uses the form factor calculations implemented in a c-library
960provided by the NIST Center for Neutron Research (Kline, 2006).
961
962REFERENCE
[bf8c07b]963
[93b6fcc]964A Guinier and G. Fournet, *Small-Angle Scattering of X-Rays*, John Wiley and Sons, New York, (1955)
[1c03e14]965
966
967
968.. _SphericalSLDModel:
969
970**2.1.11. SphericalSLDModel**
971
972Similarly to the OnionExpShellModel, this model provides the form factor, *P(q)*, for a multi-shell sphere, where the
973interface between the each neighboring shells can be described by one of a number of functions including error,
974power-law, and exponential functions. This model is to calculate the scattering intensity by building a continuous
975custom SLD profile against the radius of the particle. The SLD profile is composed of a flat core, a flat solvent,
976a number (up to 9 ) flat shells, and the interfacial layers between the adjacent flat shells (or core, and solvent)
977(see below). Unlike the OnionExpShellModel (using an analytical integration), the interfacial layers here are
978sub-divided and numerically integrated assuming each of the sub-layers are described by a line function. The number
979of the sub-layer can be given by users by setting the integer values of *npts_inter* in the GUI. The form factor is
980normalized by the total volume of the sphere.
981
982*2.1.11.1. Definition*
983
984The 1D scattering intensity is calculated in the following way:
985
[7f42aad]986.. image:: img/image022.gif
[1c03e14]987
[7f42aad]988.. image:: img/image043.gif
[1c03e14]989
990where, for a spherically symmetric particle with a particle density |rho|\ *(r)*
991
[7f42aad]992.. image:: img/image024.gif
[1c03e14]993
994so that
995
[7f42aad]996.. image:: img/image044.gif
[1c03e14]997
[7f42aad]998.. image:: img/image045.gif
[1c03e14]999
[7f42aad]1000.. image:: img/image046.gif
[1c03e14]1001
[7f42aad]1002.. image:: img/image047.gif
[1c03e14]1003
[7f42aad]1004.. image:: img/image048.gif
[1c03e14]1005
[7f42aad]1006.. image:: img/image027.gif
[1c03e14]1007
1008Here we assumed that the SLDs of the core and solvent are constant against *r*. The SLD at the interface between
1009shells, |rho|\ :sub:`inter_i`, is calculated with a function chosen by an user, where the functions are
1010
10111) Exp
1012
[7f42aad]1013.. image:: img/image049.gif
[1c03e14]1014
10152) Power-Law
1016
[7f42aad]1017.. image:: img/image050.gif
[1c03e14]1018
10193) Erf
1020
[7f42aad]1021.. image:: img/image051.gif
[1c03e14]1022
1023The functions are normalized so that they vary between 0 and 1, and they are constrained such that the SLD is
1024continuous at the boundaries of the interface as well as each sub-layers. Thus *B* and *C* are determined.
1025
1026Once |rho|\ :sub:`rinter_i` is found at the boundary of the sub-layer of the interface, we can find its contribution
1027to the form factor *P(q)*
1028
[7f42aad]1029.. image:: img/image052.gif
[1c03e14]1030
[7f42aad]1031.. image:: img/image053.gif
[1c03e14]1032
[7f42aad]1033.. image:: img/image054.gif
[1c03e14]1034
1035where we assume that |rho|\ :sub:`inter_i`\ *(r)* can be approximately linear within a sub-layer *j*.
1036
1037In the equation
1038
[7f42aad]1039.. image:: img/image055.gif
[1c03e14]1040
1041Finally, the form factor can be calculated by
1042
[7f42aad]1043.. image:: img/image037.gif
[1c03e14]1044
1045where
1046
[7f42aad]1047.. image:: img/image038.gif
[1c03e14]1048
1049and
1050
[7f42aad]1051.. image:: img/image056.gif
[1c03e14]1052
1053The 2D scattering intensity is the same as *P(q)* above, regardless of the orientation of the *q* vector which is
1054defined as
1055
[7f42aad]1056.. image:: img/image040.gif
[1c03e14]1057
1058NB: The outer most radius is used as the effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
1059
1060The returned value is scaled to units of |cm^-1| and the parameters of this model (for just one shell) are the following
1061
1062==============  ========  =============
1063Parameter name  Units     Default value
1064==============  ========  =============
1065background      |cm^-1|   0.0
1066npts_inter      None      35
1067scale           None      1
1068sld_solv        |Ang^-2|  1e-006
1069func_inter1     None      Erf
1070nu_inter        None      2.5
1071thick_inter1    |Ang|     50
1072sld_flat1       |Ang^-2|  4e-006
1073thick_flat1     |Ang|     100
1074func_inter0     None      Erf
1075nu_inter0       None      2.5
1076rad_core0       |Ang|     50
1077sld_core0       |Ang^-2|  2.07e-06
1078thick_core0     |Ang|     50
1079==============  ========  =============
1080
1081NB: *rad_core0* represents the core radius (*R1*).
1082
[7f42aad]1083.. image:: img/image057.jpg
[1c03e14]1084
1085*Figure. 1D plot using the default values (w/400 point).*
1086
[7f42aad]1087.. image:: img/image058.jpg
[1c03e14]1088
1089*Figure. SLD profile from the default values.*
1090
1091REFERENCE
[bf8c07b]1092
[93b6fcc]1093L A Feigin and D I Svergun, *Structure Analysis by Small-Angle X-Ray and Neutron Scattering*,
[1c03e14]1094Plenum Press, New York, (1987)
1095
1096
1097
1098.. _LinearPearlsModel:
1099
1100**2.1.12. LinearPearlsModel**
1101
1102This model provides the form factor for *N* spherical pearls of radius *R* linearly joined by short strings (or segment
1103length or edge separation) *l* (= *A* - 2\ *R*)). *A* is the center-to-center pearl separation distance. The thickness
1104of each string is assumed to be negligible.
1105
1106.. image:: img/linearpearls.jpg
1107
1108*2.1.12.1. Definition*
1109
1110The output of the scattering intensity function for the LinearPearlsModel is given by (Dobrynin, 1996)
1111
1112.. image:: img/linearpearl_eq1.gif
1113
1114where the mass *m*\ :sub:`p` is (SLD\ :sub:`pearl` - SLD\ :sub:`solvent`) \* (volume of *N* pearls). V is the total
1115volume.
1116
1117The 2D scattering intensity is the same as *P(q)* above, regardless of the orientation of the *q* vector.
1118
1119The returned value is scaled to units of |cm^-1| and the parameters of the LinearPearlsModel are the following
1120
1121===============  ========  =============
1122Parameter name   Units     Default value
1123===============  ========  =============
1124scale            None      1.0
1125radius           |Ang|     80.0
1126edge_separation  |Ang|     350.0
1127num_pearls       None      3
1128sld_pearl        |Ang^-2|  1e-6
1129sld_solv         |Ang^-2|  6.3e-6
1130background       |cm^-1|   0.0
1131===============  ========  =============
1132
1133NB: *num_pearls* must be an integer.
1134
1135.. image:: img/linearpearl_plot.jpg
1136
1137REFERENCE
[bf8c07b]1138
[93b6fcc]1139A V Dobrynin, M Rubinstein and S P Obukhov, *Macromol.*, 29 (1996) 2974-2979
[1c03e14]1140
1141
1142
1143.. _PearlNecklaceModel:
1144
1145**2.1.13. PearlNecklaceModel**
1146
1147This model provides the form factor for a pearl necklace composed of two elements: *N* pearls (homogeneous spheres
1148of radius *R*) freely jointed by *M* rods (like strings - with a total mass *Mw* = *M* \* *m*\ :sub:`r` + *N* \* *m*\ :sub:`s`,
1149and the string segment length (or edge separation) *l* (= *A* - 2\ *R*)). *A* is the center-to-center pearl separation
1150distance.
1151
1152.. image:: img/pearl_fig.jpg
1153
1154*2.1.13.1. Definition*
1155
1156The output of the scattering intensity function for the PearlNecklaceModel is given by (Schweins, 2004)
1157
1158.. image:: img/pearl_eq1.gif
1159
1160where
1161
1162.. image:: img/pearl_eq2.gif
1163
1164.. image:: img/pearl_eq3.gif
1165
1166.. image:: img/pearl_eq4.gif
1167
1168.. image:: img/pearl_eq5.gif
1169
1170.. image:: img/pearl_eq6.gif
1171
1172and
1173
1174.. image:: img/pearl_eq7.gif
1175
1176where the mass *m*\ :sub:`i` is (SLD\ :sub:`i` - SLD\ :sub:`solvent`) \* (volume of the *N* pearls/rods). *V* is the
1177total volume of the necklace.
1178
1179The 2D scattering intensity is the same as *P(q)* above, regardless of the orientation of the *q* vector.
1180
1181The returned value is scaled to units of |cm^-1| and the parameters of the PearlNecklaceModel are the following
1182
1183===============  ========  =============
1184Parameter name   Units     Default value
1185===============  ========  =============
1186scale            None      1.0
1187radius           |Ang|     80.0
1188edge_separation  |Ang|     350.0
1189num_pearls       None      3
1190sld_pearl        |Ang^-2|  1e-6
1191sld_solv         |Ang^-2|  6.3e-6
1192sld_string       |Ang^-2|  1e-6
1193thick_string
1194(=rod diameter)  |Ang|     2.5
1195background       |cm^-1|   0.0
1196===============  ========  =============
1197
1198NB: *num_pearls* must be an integer.
1199
1200.. image:: img/pearl_plot.jpg
1201
1202REFERENCE
[bf8c07b]1203
[93b6fcc]1204R Schweins and K Huber, *Particle Scattering Factor of Pearl Necklace Chains*, *Macromol. Symp.* 211 (2004) 25-42 2004
[1c03e14]1205
1206
1207
1208.. _CylinderModel:
1209
1210**2.1.14. CylinderModel**
1211
1212This model provides the form factor for a right circular cylinder with uniform scattering length density. The form
1213factor is normalized by the particle volume.
1214
1215For information about polarised and magnetic scattering, click here_.
1216
1217*2.1.14.1. Definition*
1218
1219The output of the 2D scattering intensity function for oriented cylinders is given by (Guinier, 1955)
1220
1221.. image:: img/image059.PNG
1222
1223where
1224
1225.. image:: img/image060.PNG
1226
1227and |alpha| is the angle between the axis of the cylinder and the *q*-vector, *V* is the volume of the cylinder,
[58eccf6]1228*L* is the length of the cylinder, *r* is the radius of the cylinder, and |drho| (contrast) is the
[1c03e14]1229scattering length density difference between the scatterer and the solvent. *J1* is the first order Bessel function.
1230
1231To provide easy access to the orientation of the cylinder, we define the axis of the cylinder using two angles |theta|
1232and |phi|. Those angles are defined in Figure 1.
1233
[7f42aad]1234.. image:: img/image061.jpg
[1c03e14]1235
1236*Figure 1. Definition of the angles for oriented cylinders.*
1237
[7f42aad]1238.. image:: img/image062.jpg
[1c03e14]1239
1240*Figure 2. Examples of the angles for oriented pp against the detector plane.*
1241
1242NB: The 2nd virial coefficient of the cylinder is calculated based on the radius and length values, and used as the
1243effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
1244
1245The returned value is scaled to units of |cm^-1| and the parameters of the CylinderModel are the following:
1246
1247==============  ========  =============
1248Parameter name  Units     Default value
1249==============  ========  =============
1250scale           None      1.0
1251radius          |Ang|     20.0
1252length          |Ang|     400.0
1253contrast        |Ang^-2|  3.0e-6
1254background      |cm^-1|   0.0
1255cyl_theta       degree    60
1256cyl_phi         degree    60
1257==============  ========  =============
1258
1259The output of the 1D scattering intensity function for randomly oriented cylinders is then given by
1260
1261.. image:: img/image063.PNG
1262
1263The *cyl_theta* and *cyl_phi* parameter are not used for the 1D output. Our implementation of the scattering kernel
1264and the 1D scattering intensity use the c-library from NIST.
1265
[38d4102]1266*2.1.14.2. Validation of the CylinderModel*
[1c03e14]1267
1268Validation of our code was done by comparing the output of the 1D model to the output of the software provided by the
1269NIST (Kline, 2006). Figure 3 shows a comparison of the 1D output of our model and the output of the NIST software.
1270
[7f42aad]1271.. image:: img/image065.jpg
[1c03e14]1272
[38d4102]1273*Figure 3: Comparison of the SasView scattering intensity for a cylinder with the output of the NIST SANS analysis*
1274*software.* The parameters were set to: *Scale* = 1.0, *Radius* = 20 |Ang|, *Length* = 400 |Ang|,
[1c03e14]1275*Contrast* = 3e-6 |Ang^-2|, and *Background* = 0.01 |cm^-1|.
1276
1277In general, averaging over a distribution of orientations is done by evaluating the following
1278
1279.. image:: img/image064.PNG
1280
1281where *p(*\ |theta|,\ |phi|\ *)* is the probability distribution for the orientation and |P0|\ *(q,*\ |alpha|\ *)* is
1282the scattering intensity for the fully oriented system. Since we have no other software to compare the implementation
1283of the intensity for fully oriented cylinders, we can compare the result of averaging our 2D output using a uniform
1284distribution *p(*\ |theta|,\ |phi|\ *)* = 1.0. Figure 4 shows the result of such a cross-check.
1285
[7f42aad]1286.. image:: img/image066.jpg
[1c03e14]1287
[38d4102]1288*Figure 4: Comparison of the intensity for uniformly distributed cylinders calculated from our 2D model and the*
1289*intensity from the NIST SANS analysis software.* The parameters used were: *Scale* = 1.0, *Radius* = 20 |Ang|,
1290*Length* = 400 |Ang|, *Contrast* = 3e-6 |Ang^-2|, and *Background* = 0.0 |cm^-1|.
[1c03e14]1291
1292
1293
1294.. _HollowCylinderModel:
1295
1296**2.1.15. HollowCylinderModel**
1297
1298This model provides the form factor, *P(q)*, for a monodisperse hollow right angle circular cylinder (tube) where the
1299form factor is normalized by the volume of the tube
1300
1301*P(q)* = *scale* \* *<F*\ :sup:`2`\ *>* / *V*\ :sub:`shell` + *background*
1302
1303where the averaging < > is applied only for the 1D calculation.
1304
1305The inside and outside of the hollow cylinder are assumed have the same SLD.
1306
[38d4102]1307*2.1.15.1 Definition*
1308
[1c03e14]1309The 1D scattering intensity is calculated in the following way (Guinier, 1955)
1310
1311.. image:: img/image072.PNG
1312
1313where *scale* is a scale factor, *J1* is the 1st order Bessel function, *J1(x)* = (sin *x* - *x* cos *x*)/ *x*\ :sup:`2`.
1314
1315To provide easy access to the orientation of the core-shell cylinder, we define the axis of the cylinder using two
1316angles |theta| and |phi|\ . As for the case of the cylinder, those angles are defined in Figure 2 of the CylinderModel.
1317
1318NB: The 2nd virial coefficient of the cylinder is calculated based on the radius and 2 length values, and used as the
1319effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
1320
1321In the parameters, the contrast represents SLD :sub:`shell` - SLD :sub:`solvent` and the *radius* = *R*\ :sub:`shell`
1322while *core_radius* = *R*\ :sub:`core`.
1323
1324==============  ========  =============
1325Parameter name  Units     Default value
1326==============  ========  =============
1327scale           None      1.0
1328radius          |Ang|     30
1329length          |Ang|     400
1330core_radius     |Ang|     20
1331sldCyl          |Ang^-2|  6.3e-6
1332sldSolv         |Ang^-2|  5e-06
1333background      |cm^-1|   0.01
1334==============  ========  =============
1335
[7f42aad]1336.. image:: img/image074.jpg
[1c03e14]1337
1338*Figure. 1D plot using the default values (w/1000 data point).*
1339
1340Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
1341(Kline, 2006).
1342
[7f42aad]1343.. image:: img/image061.jpg
[1c03e14]1344
[38d4102]1345*Figure. Definition of the angles for the oriented HollowCylinderModel.*
[1c03e14]1346
[7f42aad]1347.. image:: img/image062.jpg
[1c03e14]1348
[38d4102]1349*Figure. Examples of the angles for oriented pp against the detector plane.*
[1c03e14]1350
1351REFERENCE
[bf8c07b]1352
[93b6fcc]1353L A Feigin and D I Svergun, *Structure Analysis by Small-Angle X-Ray and Neutron Scattering*, Plenum Press,
[38d4102]1354New York, (1987)
[1c03e14]1355
1356
1357
1358.. _CappedCylinderModel:
1359
1360**2.1.16 CappedCylinderModel**
1361
[38d4102]1362Calculates the scattering from a cylinder with spherical section end-caps. This model simply becomes the ConvexLensModel
1363when the length of the cylinder *L* = 0, that is, a sphereocylinder with end caps that have a radius larger than that
1364of the cylinder and the center of the end cap radius lies within the cylinder. See the diagram for the details
[1c03e14]1365of the geometry and restrictions on parameter values.
1366
[38d4102]1367*2.1.16.1. Definition*
[1c03e14]1368
[77cfcf0]1369The returned value is scaled to units of |cm^-1|\ |sr^-1|, absolute scale.
[1c03e14]1370
[38d4102]1371The Capped Cylinder geometry is defined as
[1c03e14]1372
[7f42aad]1373.. image:: img/image112.jpg
[1c03e14]1374
[38d4102]1375where *r* is the radius of the cylinder. All other parameters are as defined in the diagram. Since the end cap radius
1376*R* >= *r* and by definition for this geometry *h* < 0, *h* is then defined by *r* and *R* as
[1c03e14]1377
[38d4102]1378*h* = -1 \* sqrt(*R*\ :sup:`2` - *r*\ :sup:`2`)
[1c03e14]1379
[38d4102]1380The scattered intensity *I(q)* is calculated as
[1c03e14]1381
[7f42aad]1382.. image:: img/image113.jpg
[1c03e14]1383
[38d4102]1384where the amplitude *A(q)* is given as
[1c03e14]1385
[7f42aad]1386.. image:: img/image114.jpg
[1c03e14]1387
[38d4102]1388The < > brackets denote an average of the structure over all orientations. <\ *A*\ :sup:`2`\ *(q)*> is then the form
1389factor, *P(q)*. The scale factor is equivalent to the volume fraction of cylinders, each of volume, *V*. Contrast is the
1390difference of scattering length densities of the cylinder and the surrounding solvent.
[1c03e14]1391
[38d4102]1392The volume of the Capped Cylinder is (with *h* as a positive value here)
[1c03e14]1393
[7f42aad]1394.. image:: img/image115.jpg
[1c03e14]1395
[6386cd8]1396and its radius-of-gyration
[1c03e14]1397
[7f42aad]1398.. image:: img/image116.jpg
[1c03e14]1399
[38d4102]1400**The requirement that** *R* >= *r* **is not enforced in the model! It is up to you to restrict this during analysis.**
[1c03e14]1401
[38d4102]1402This following example dataset is produced by running the MacroCappedCylinder(), using 200 data points,
1403*qmin* = 0.001 |Ang^-1|, *qmax* = 0.7 |Ang^-1| and the default values
[1c03e14]1404
1405==============  ========  =============
1406Parameter name  Units     Default value
1407==============  ========  =============
1408scale           None      1.0
1409len_cyl         |Ang|     400.0
1410rad_cap         |Ang|     40.0
1411rad_cyl         |Ang|     20.0
1412sld_capcyl      |Ang^-2|  1.0e-006
1413sld_solv        |Ang^-2|  6.3e-006
1414background      |cm^-1|   0
1415==============  ========  =============
1416
[7f42aad]1417.. image:: img/image117.jpg
[1c03e14]1418
1419*Figure. 1D plot using the default values (w/256 data point).*
1420
[38d4102]1421For 2D data: The 2D scattering intensity is calculated similar to the 2D cylinder model. For example, for
1422|theta| = 45 deg and |phi| =0 deg with default values for other parameters
[1c03e14]1423
[7f42aad]1424.. image:: img/image118.jpg
[1c03e14]1425
1426*Figure. 2D plot (w/(256X265) data points).*
1427
[7f42aad]1428.. image:: img/image061.jpg
[1c03e14]1429
[38d4102]1430*Figure. Definition of the angles for oriented 2D cylinders.*
[1c03e14]1431
[38d4102]1432.. image:: img/image062.jpg
[1c03e14]1433
[38d4102]1434*Figure. Examples of the angles for oriented pp against the detector plane.*
[1c03e14]1435
[38d4102]1436REFERENCE
[bf8c07b]1437
[93b6fcc]1438H Kaya, *J. Appl. Cryst.*, 37 (2004) 223-230
[bf8c07b]1439
[93b6fcc]1440H Kaya and N-R deSouza, *J. Appl. Cryst.*, 37 (2004) 508-509 (addenda and errata)
[1c03e14]1441
1442
1443
1444.. _CoreShellCylinderModel:
1445
[38d4102]1446**2.1.17. CoreShellCylinderModel**
[1c03e14]1447
[38d4102]1448This model provides the form factor for a circular cylinder with a core-shell scattering length density profile. The
1449form factor is normalized by the particle volume.
[1c03e14]1450
[38d4102]1451*2.1.17.1. Definition*
[1c03e14]1452
[38d4102]1453The output of the 2D scattering intensity function for oriented core-shell cylinders is given by (Kline, 2006)
[1c03e14]1454
[38d4102]1455.. image:: img/image067.PNG
[1c03e14]1456
[38d4102]1457where
[1c03e14]1458
[38d4102]1459.. image:: img/image068.PNG
[1c03e14]1460
[38d4102]1461.. image:: img/image239.PNG
[1c03e14]1462
[38d4102]1463and |alpha| is the angle between the axis of the cylinder and the *q*\ -vector, *Vs* is the volume of the outer shell
1464(i.e. the total volume, including the shell), *Vc* is the volume of the core, *L* is the length of the core, *r* is the
1465radius of the core, *t* is the thickness of the shell, |rho|\ :sub:`c` is the scattering length density of the core,
1466|rho|\ :sub:`s` is the scattering length density of the shell, |rho|\ :sub:`solv` is the scattering length density of
1467the solvent, and *bkg* is the background level. The outer radius of the shell is given by *r+t* and the total length of
1468the outer shell is given by *L+2t*. *J1* is the first order Bessel function.
[1c03e14]1469
[7f42aad]1470.. image:: img/image069.jpg
[1c03e14]1471
[38d4102]1472To provide easy access to the orientation of the core-shell cylinder, we define the axis of the cylinder using two
1473angles |theta| and |phi|\ . As for the case of the cylinder, those angles are defined in Figure 2 of the CylinderModel.
[1c03e14]1474
[38d4102]1475NB: The 2nd virial coefficient of the cylinder is calculated based on the radius and 2 length values, and used as the
1476effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
[1c03e14]1477
[38d4102]1478The returned value is scaled to units of |cm^-1| and the parameters of the core-shell cylinder model are the following
[1c03e14]1479
1480==============  ========  =============
1481Parameter name  Units     Default value
1482==============  ========  =============
1483scale           None      1.0
1484radius          |Ang|     20.0
1485thickness       |Ang|     10.0
1486length          |Ang|     400.0
1487core_sld        |Ang^-2|  1e-6
1488shell_sld       |Ang^-2|  4e-6
1489solvent_sld     |Ang^-2|  1e-6
1490background      |cm^-1|   0.0
1491axis_theta      degree    90
1492axis_phi        degree    0.0
1493==============  ========  =============
1494
[38d4102]1495The output of the 1D scattering intensity function for randomly oriented cylinders is then given by the equation above.
[1c03e14]1496
[38d4102]1497The *axis_theta* and *axis_phi* parameters are not used for the 1D output. Our implementation of the scattering kernel
1498and the 1D scattering intensity use the c-library from NIST.
[1c03e14]1499
[38d4102]1500*2.1.17.2. Validation of the CoreShellCylinderModel*
[1c03e14]1501
[38d4102]1502Validation of our code was done by comparing the output of the 1D model to the output of the software provided by the
1503NIST (Kline, 2006). Figure 1 shows a comparison of the 1D output of our model and the output of the NIST software.
[1c03e14]1504
[7f42aad]1505.. image:: img/image070.jpg
[1c03e14]1506
[38d4102]1507*Figure 1: Comparison of the SasView scattering intensity for a core-shell cylinder with the output of the NIST SANS*
1508*analysis software.* The parameters were set to: *Scale* = 1.0, *Radius* = 20 |Ang|, *Thickness* = 10 |Ang|,
1509*Length* = 400 |Ang|, *Core_sld* = 1e-6 |Ang^-2|, *Shell_sld* = 4e-6 |Ang^-2|, *Solvent_sld* = 1e-6 |Ang^-2|,
1510and *Background* = 0.01 |cm^-1|.
[1c03e14]1511
[38d4102]1512Averaging over a distribution of orientation is done by evaluating the equation above. Since we have no other software
1513to compare the implementation of the intensity for fully oriented cylinders, we can compare the result of averaging our
15142D output using a uniform distribution *p(*\ |theta|,\ |phi|\ *)* = 1.0. Figure 2 shows the result of such a cross-check.
[1c03e14]1515
[7f42aad]1516.. image:: img/image071.jpg
[1c03e14]1517
[38d4102]1518*Figure 2: Comparison of the intensity for uniformly distributed core-shell cylinders calculated from our 2D model and*
1519*the intensity from the NIST SANS analysis software.* The parameters used were: *Scale* = 1.0, *Radius* = 20 |Ang|,
1520*Thickness* = 10 |Ang|, *Length* =400 |Ang|, *Core_sld* = 1e-6 |Ang^-2|, *Shell_sld* = 4e-6 |Ang^-2|,
1521*Solvent_sld* = 1e-6 |Ang^-2|, and *Background* = 0.0 |cm^-1|.
[1c03e14]1522
[7f42aad]1523.. image:: img/image061.jpg
[1c03e14]1524
[38d4102]1525*Figure. Definition of the angles for oriented core-shell cylinders.*
[1c03e14]1526
[7f42aad]1527.. image:: img/image062.jpg
[1c03e14]1528
[38d4102]1529*Figure. Examples of the angles for oriented pp against the detector plane.*
[1c03e14]1530
15312013/11/26 - Description reviewed by Heenan, R.
1532
1533
1534
1535.. _EllipticalCylinderModel:
1536
1537**2.1.18 EllipticalCylinderModel**
1538
[38d4102]1539This function calculates the scattering from an elliptical cylinder.
[1c03e14]1540
[38d4102]1541*2.1.18.1 Definition for 2D (orientated system)*
[1c03e14]1542
[38d4102]1543The angles |theta| and |phi| define the orientation of the axis of the cylinder. The angle |bigpsi| is defined as the
1544orientation of the major axis of the ellipse with respect to the vector *Q*\ . A gaussian polydispersity can be added
1545to any of the orientation angles, and also for the minor radius and the ratio of the ellipse radii.
[1c03e14]1546
[38d4102]1547.. image:: img/image098.gif
[1c03e14]1548
[38d4102]1549*Figure.* *a* = *r_minor* and |nu|\ :sub:`n` = *r_ratio* (i.e., *r_major* / *r_minor*).
[1c03e14]1550
[38d4102]1551The function calculated is
[1c03e14]1552
[38d4102]1553.. image:: img/image099.PNG
[1c03e14]1554
[38d4102]1555with the functions
[1c03e14]1556
[38d4102]1557.. image:: img/image100.PNG
[1c03e14]1558
[38d4102]1559and the angle |bigpsi| is defined as the orientation of the major axis of the ellipse with respect to the vector *q*\ .
[1c03e14]1560
[38d4102]1561*2.1.18.2 Definition for 1D (no preferred orientation)*
[1c03e14]1562
[38d4102]1563The form factor is averaged over all possible orientation before normalized by the particle volume
[1c03e14]1564
[38d4102]1565*P(q)* = *scale* \* <*F*\ :sup:`2`> / *V*
[1c03e14]1566
1567The returned value is scaled to units of |cm^-1|.
1568
[38d4102]1569To provide easy access to the orientation of the elliptical cylinder, we define the axis of the cylinder using two
1570angles |theta|, |phi| and |bigpsi|. As for the case of the cylinder, the angles |theta| and |phi| are defined on
1571Figure 2 of CylinderModel. The angle |bigpsi| is the rotational angle around its own long_c axis against the *q* plane.
1572For example, |bigpsi| = 0 when the *r_minor* axis is parallel to the *x*\ -axis of the detector.
[1c03e14]1573
[38d4102]1574All angle parameters are valid and given only for 2D calculation; ie, an oriented system.
[1c03e14]1575
[7f42aad]1576.. image:: img/image101.jpg
[1c03e14]1577
[38d4102]1578*Figure. Definition of angles for 2D*
[1c03e14]1579
[7f42aad]1580.. image:: img/image062.jpg
[1c03e14]1581
[38d4102]1582*Figure. Examples of the angles for oriented elliptical cylinders against the detector plane.*
[1c03e14]1583
[38d4102]1584NB: The 2nd virial coefficient of the cylinder is calculated based on the averaged radius (= sqrt(*r_minor*\ :sup:`2` \* *r_ratio*))
1585and length values, and used as the effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
[1c03e14]1586
1587==============  ========  =============
1588Parameter name  Units     Default value
1589==============  ========  =============
1590scale           None      1.0
1591r_minor         |Ang|     20.0
1592r_ratio         |Ang|     1.5
1593length          |Ang|     400.0
1594sldCyl          |Ang^-2|  4e-06
1595sldSolv         |Ang^-2|  1e-06
1596background      |cm^-1|   0
1597==============  ========  =============
1598
[7f42aad]1599.. image:: img/image102.jpg
[1c03e14]1600
1601*Figure. 1D plot using the default values (w/1000 data point).*
1602
[38d4102]1603*2.1.18.3 Validation of the EllipticalCylinderModel*
[1c03e14]1604
[38d4102]1605Validation of our code was done by comparing the output of the 1D calculation to the angular average of the output of
1606the 2D calculation over all possible angles. The figure below shows the comparison where the solid dot refers to
1607averaged 2D values while the line represents the result of the 1D calculation (for the 2D averaging, values of 76, 180,
1608and 76 degrees are taken for the angles of |theta|, |phi|, and |bigpsi| respectively).
[1c03e14]1609
[7f42aad]1610.. image:: img/image103.gif
[1c03e14]1611
1612*Figure. Comparison between 1D and averaged 2D.*
1613
[38d4102]1614In the 2D average, more binning in the angle |phi| is necessary to get the proper result. The following figure shows
1615the results of the averaging by varying the number of angular bins.
[1c03e14]1616
[7f42aad]1617.. image:: img/image104.gif
[1c03e14]1618
1619*Figure. The intensities averaged from 2D over different numbers of bins and angles.*
1620
1621REFERENCE
[bf8c07b]1622
[93b6fcc]1623L A Feigin and D I Svergun, *Structure Analysis by Small-Angle X-Ray and Neutron Scattering*, Plenum,
[38d4102]1624New York, (1987)
[1c03e14]1625
1626
1627
1628.. _FlexibleCylinderModel:
1629
1630**2.1.19. FlexibleCylinderModel**
1631
[38d4102]1632This model provides the form factor, *P(q)*, for a flexible cylinder where the form factor is normalized by the volume
1633of the cylinder. **Inter-cylinder interactions are NOT provided for.**
[1c03e14]1634
[38d4102]1635*P(q)* = *scale* \* <*F*\ :sup:`2`> / *V* + *background*
[1c03e14]1636
[38d4102]1637where the averaging < > is applied over all orientations for 1D.
[1c03e14]1638
[38d4102]1639The 2D scattering intensity is the same as 1D, regardless of the orientation of the *q* vector which is defined as
1640
1641.. image:: img/image040.gif
1642
1643*2.1.19.1. Definition*
1644
[7f42aad]1645.. image:: img/image075.jpg
[38d4102]1646
1647The chain of contour length, *L*, (the total length) can be described as a chain of some number of locally stiff
1648segments of length *l*\ :sub:`p`\ , the persistence length (the length along the cylinder over which the flexible
1649cylinder can be considered a rigid rod). The Kuhn length (*b* = 2 \* *l* :sub:`p`) is also used to describe the
1650stiffness of a chain.
1651
1652The returned value is in units of |cm^-1|, on absolute scale.
1653
1654In the parameters, the sldCyl and sldSolv represent the SLD of the chain/cylinder and solvent respectively.
[1c03e14]1655
1656==============  ========  =============
1657Parameter name  Units     Default value
1658==============  ========  =============
1659scale           None      1.0
1660radius          |Ang|     20
1661length          |Ang|     1000
1662sldCyl          |Ang^-2|  1e-06
1663sldSolv         |Ang^-2|  6.3e-06
1664background      |cm^-1|   0.01
1665kuhn_length     |Ang|     100
1666==============  ========  =============
1667
[7f42aad]1668.. image:: img/image076.jpg
[1c03e14]1669
1670*Figure. 1D plot using the default values (w/1000 data point).*
1671
[38d4102]1672Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
1673(Kline, 2006).
[1c03e14]1674
[38d4102]1675From the reference
[1c03e14]1676
[38d4102]1677  "Method 3 With Excluded Volume" is used. The model is a parametrization of simulations of a discrete representation
1678  of the worm-like chain model of Kratky and Porod applied in the pseudocontinuous limit. See equations (13,26-27) in
1679  the original reference for the details.
[1c03e14]1680
[38d4102]1681REFERENCE
[bf8c07b]1682
[93b6fcc]1683J S Pedersen and P Schurtenberger. *Scattering functions of semiflexible polymers with and without excluded volume*
[38d4102]1684*effects*. *Macromolecules*, 29 (1996) 7602-7612
[1c03e14]1685
[38d4102]1686Correction of the formula can be found in
[bf8c07b]1687
[93b6fcc]1688W R Chen, P D Butler and L J Magid, *Incorporating Intermicellar Interactions in the Fitting of SANS Data from*
[4ed2d0a1]1689*Cationic Wormlike Micelles*. *Langmuir*, 22(15) 2006 6539–6548
[1c03e14]1690
1691
1692
1693.. _FlexCylEllipXModel:
1694
1695**2.1.20 FlexCylEllipXModel**
1696
[38d4102]1697This model calculates the form factor for a flexible cylinder with an elliptical cross section and a uniform scattering
1698length density. The non-negligible diameter of the cylinder is included by accounting for excluded volume interactions
1699within the walk of a single cylinder. The form factor is normalized by the particle volume such that
[1c03e14]1700
[38d4102]1701*P(q)* = *scale* \* <*F*\ :sup:`2`> / *V* + *background*
1702
1703where < > is an average over all possible orientations of the flexible cylinder.
1704
1705*2.1.20.1. Definition*
[1c03e14]1706
[38d4102]1707The function calculated is from the reference given below. From that paper, "Method 3 With Excluded Volume" is used.
1708The model is a parameterization of simulations of a discrete representation of the worm-like chain model of Kratky and
1709Porod applied in the pseudo-continuous limit. See equations (13, 26-27) in the original reference for the details.
[1c03e14]1710
[38d4102]1711NB: there are several typos in the original reference that have been corrected by WRC. Details of the corrections are
1712in the reference below. Most notably
[1c03e14]1713
[38d4102]1714- Equation (13): the term (1 - w(QR)) should swap position with w(QR)
[1c03e14]1715
[38d4102]1716- Equations (23) and (24) are incorrect; WRC has entered these into Mathematica and solved analytically. The results
1717  were then converted to code.
[1c03e14]1718
1719- Equation (27) should be q0 = max(a3/sqrt(RgSquare),3) instead of max(a3*b/sqrt(RgSquare),3)
1720
1721- The scattering function is negative for a range of parameter values and q-values that are experimentally accessible. A correction function has been added to give the proper behavior.
1722
[7f42aad]1723.. image:: img/image077.jpg
[1c03e14]1724
[38d4102]1725The chain of contour length, *L*, (the total length) can be described as a chain of some number of locally stiff
1726segments of length *l*\ :sub:`p`\ , the persistence length (the length along the cylinder over which the flexible
1727cylinder can be considered a rigid rod). The Kuhn length (*b* = 2 \* *l* :sub:`p`) is also used to describe the
1728stiffness of a chain.
[1c03e14]1729
[38d4102]1730The cross section of the cylinder is elliptical, with minor radius *a*\ . The major radius is larger, so of course,
1731**the axis ratio (parameter 4) must be greater than one.** Simple constraints should be applied during curve fitting to
1732maintain this inequality.
[1c03e14]1733
1734The returned value is in units of |cm^-1|, on absolute scale.
1735
[38d4102]1736In the parameters, *sldCyl* and *sldSolv* represent the SLD of the chain/cylinder and solvent respectively. The
1737*scale*, and the contrast are both multiplicative factors in the model and are perfectly correlated. One or both of
1738these parameters must be held fixed during model fitting.
[1c03e14]1739
[38d4102]1740If the scale is set equal to the particle volume fraction, |phi|, the returned value is the scattered intensity per
1741unit volume, *I(q)* = |phi| \* *P(q)*.
[1c03e14]1742
[38d4102]1743**No inter-cylinder interference effects are included in this calculation.**
[1c03e14]1744
[38d4102]1745For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]1746
[38d4102]1747.. image:: img/image008.PNG
[1c03e14]1748
[38d4102]1749This example dataset is produced by running the Macro FlexCylEllipXModel, using 200 data points, *qmin* = 0.001 |Ang^-1|,
1750*qmax* = 0.7 |Ang^-1| and the default values below
[1c03e14]1751
1752==============  ========  =============
1753Parameter name  Units     Default value
1754==============  ========  =============
1755axis_ratio      None      1.5
1756background      |cm^-1|   0.0001
1757Kuhn_length     |Ang|     100
1758Contour length  |Ang|     1e+3
1759radius          |Ang|     20.0
1760scale           None      1.0
1761sldCyl          |Ang^-2|  1e-6
1762sldSolv         |Ang^-2|  6.3e-6
1763==============  ========  =============
1764
[7f42aad]1765.. image:: img/image078.jpg
[1c03e14]1766
1767*Figure. 1D plot using the default values (w/200 data points).*
1768
[38d4102]1769REFERENCE
[bf8c07b]1770
[93b6fcc]1771J S Pedersen and P Schurtenberger. *Scattering functions of semiflexible polymers with and without excluded volume*
[38d4102]1772*effects*. *Macromolecules*, 29 (1996) 7602-7612
1773
1774Correction of the formula can be found in
[bf8c07b]1775
[93b6fcc]1776W R Chen, P D Butler and L J Magid, *Incorporating Intermicellar Interactions in the Fitting of SANS Data from*
[4ed2d0a1]1777*Cationic Wormlike Micelles*. *Langmuir*, 22(15) 2006 6539–6548
[38d4102]1778
[1c03e14]1779
1780
1781.. _CoreShellBicelleModel:
1782
1783**2.1.21 CoreShellBicelleModel**
1784
[77cfcf0]1785This model provides the form factor for a circular cylinder with a core-shell scattering length density profile. The
1786form factor is normalized by the particle volume.
[1c03e14]1787
[77cfcf0]1788This model is a more general case of core-shell cylinder model (see above and reference below) in that the parameters
1789of the shell are separated into a face-shell and a rim-shell so that users can set different values of the thicknesses
1790and SLDs.
[1c03e14]1791
[7f42aad]1792.. image:: img/image240.png
[1c03e14]1793
[77cfcf0]1794*(Graphic from DOI: 10.1039/C0NP00002G)*
1795
1796The returned value is scaled to units of |cm^-1| and the parameters of the CoreShellBicelleModel are the following
[1c03e14]1797
1798==============  ========  =============
1799Parameter name  Units     Default value
1800==============  ========  =============
1801scale           None      1.0
1802radius          |Ang|     20.0
1803rim_thick       |Ang|     10.0
1804face_thick      |Ang|     10.0
1805length          |Ang|     400.0
1806core_sld        |Ang^-2|  1e-6
1807rim_sld         |Ang^-2|  4e-6
1808face_sld        |Ang^-2|  4e-6
1809solvent_sld     |Ang^-2|  1e-6
1810background      |cm^-1|   0.0
1811axis_theta      degree    90
1812axis_phi        degree    0.0
1813==============  ========  =============
1814
[77cfcf0]1815The output of the 1D scattering intensity function for randomly oriented cylinders is then given by the equation above.
[1c03e14]1816
[77cfcf0]1817The *axis_theta* and *axis_phi* parameters are not used for the 1D output. Our implementation of the scattering kernel
1818and the 1D scattering intensity use the c-library from NIST.
[1c03e14]1819
[77cfcf0]1820.. image:: img/cscylbicelle_pic.jpg
[1c03e14]1821
1822*Figure. 1D plot using the default values (w/200 data point).*
1823
[7f42aad]1824.. image:: img/image061.jpg
[1c03e14]1825
[77cfcf0]1826*Figure. Definition of the angles for the oriented CoreShellBicelleModel.*
[1c03e14]1827
[7f42aad]1828.. image:: img/image062.jpg
[1c03e14]1829
[77cfcf0]1830*Figure. Examples of the angles for oriented pp against the detector plane.*
[1c03e14]1831
1832REFERENCE
[bf8c07b]1833
[93b6fcc]1834L A Feigin and D I Svergun, *Structure Analysis by Small-Angle X-Ray and Neutron Scattering*, Plenum Press,
[77cfcf0]1835New York, (1987)
[1c03e14]1836
1837
1838
1839.. _BarBellModel:
1840
1841**2.1.22. BarBellModel**
1842
[77cfcf0]1843Calculates the scattering from a barbell-shaped cylinder (This model simply becomes the DumBellModel when the length of
1844the cylinder, *L*, is set to zero). That is, a sphereocylinder with spherical end caps that have a radius larger than
1845that of the cylinder and the center of the end cap radius lies outside of the cylinder. All dimensions of the BarBell
1846are considered to be monodisperse. See the diagram for the details of the geometry and restrictions on parameter values.
[1c03e14]1847
[77cfcf0]1848*2.1.22.1. Definition*
[1c03e14]1849
[77cfcf0]1850The returned value is scaled to units of |cm^-1|\ |sr^-1|, absolute scale.
[1c03e14]1851
1852The barbell geometry is defined as
1853
[7f42aad]1854.. image:: img/image105.jpg
[1c03e14]1855
[77cfcf0]1856where *r* is the radius of the cylinder. All other parameters are as defined in the diagram.
[1c03e14]1857
[77cfcf0]1858Since the end cap radius
1859*R* >= *r* and by definition for this geometry *h* < 0, *h* is then defined by *r* and *R* as
[1c03e14]1860
[77cfcf0]1861*h* = -1 \* sqrt(*R*\ :sup:`2` - *r*\ :sup:`2`)
[1c03e14]1862
[77cfcf0]1863The scattered intensity *I(q)* is calculated as
[1c03e14]1864
[77cfcf0]1865.. image:: img/image106.PNG
[1c03e14]1866
[77cfcf0]1867where the amplitude *A(q)* is given as
[1c03e14]1868
[77cfcf0]1869.. image:: img/image107.PNG
[1c03e14]1870
[77cfcf0]1871The < > brackets denote an average of the structure over all orientations. <*A* :sup:`2`\ *(q)*> is then the form
1872factor, *P(q)*. The scale factor is equivalent to the volume fraction of cylinders, each of volume, *V*. Contrast is
1873the difference of scattering length densities of the cylinder and the surrounding solvent.
[1c03e14]1874
[77cfcf0]1875The volume of the barbell is
[1c03e14]1876
[7f42aad]1877.. image:: img/image108.jpg
[1c03e14]1878
1879
[6386cd8]1880and its radius-of-gyration is
[1c03e14]1881
[7f42aad]1882.. image:: img/image109.jpg
[1c03e14]1883
[77cfcf0]1884**The requirement that** *R* >= *r* **is not enforced in the model!** It is up to you to restrict this during analysis.
[1c03e14]1885
[77cfcf0]1886This example dataset is produced by running the Macro PlotBarbell(), using 200 data points, *qmin* = 0.001 |Ang^-1|,
1887*qmax* = 0.7 |Ang^-1| and the following default values
[1c03e14]1888
1889==============  ========  =============
1890Parameter name  Units     Default value
1891==============  ========  =============
1892scale           None      1.0
1893len_bar         |Ang|     400.0
1894rad_bar         |Ang|     20.0
1895rad_bell        |Ang|     40.0
1896sld_barbell     |Ang^-2|  1.0e-006
1897sld_solv        |Ang^-2|  6.3e-006
1898background      |cm^-1|   0
1899==============  ========  =============
1900
[7f42aad]1901.. image:: img/image110.jpg
[1c03e14]1902
1903*Figure. 1D plot using the default values (w/256 data point).*
1904
[77cfcf0]1905For 2D data: The 2D scattering intensity is calculated similar to the 2D cylinder model. For example, for
1906|theta| = 45 deg and |phi| = 0 deg with default values for other parameters
[1c03e14]1907
[7f42aad]1908.. image:: img/image111.jpg
[1c03e14]1909
1910*Figure. 2D plot (w/(256X265) data points).*
1911
[7f42aad]1912.. image:: img/image061.jpg
[1c03e14]1913
[77cfcf0]1914*Figure. Examples of the angles for oriented pp against the detector plane.*
[1c03e14]1915
[7f42aad]1916.. image:: img/image062.jpg
[1c03e14]1917
1918Figure. Definition of the angles for oriented 2D barbells.
1919
[77cfcf0]1920REFERENCE
[bf8c07b]1921
[93b6fcc]1922H Kaya, *J. Appl. Cryst.*, 37 (2004) 37 223-230
[bf8c07b]1923
[93b6fcc]1924H Kaya and N R deSouza, *J. Appl. Cryst.*, 37 (2004) 508-509 (addenda and errata)
[77cfcf0]1925
[1c03e14]1926
1927
1928.. _StackedDisksModel:
1929
1930**2.1.23. StackedDisksModel**
1931
[77cfcf0]1932This model provides the form factor, *P(q)*, for stacked discs (tactoids) with a core/layer structure where the form
1933factor is normalized by the volume of the cylinder. Assuming the next neighbor distance (d-spacing) in a stack of
1934parallel discs obeys a Gaussian distribution, a structure factor *S(q)* proposed by Kratky and Porod in 1949 is used
1935in this function.
[1c03e14]1936
[77cfcf0]1937Note that the resolution smearing calculation uses 76 Gauss quadrature points to properly smear the model since the
1938function is HIGHLY oscillatory, especially around the *q*-values that correspond to the repeat distance of the layers.
[1c03e14]1939
[77cfcf0]1940The 2D scattering intensity is the same as 1D, regardless of the orientation of the *q* vector which is defined as
[1c03e14]1941
[77cfcf0]1942.. image:: img/image008.PNG
[1c03e14]1943
[77cfcf0]1944The returned value is in units of |cm^-1| |sr^-1|, on absolute scale.
[1c03e14]1945
[77cfcf0]1946*2.1.23.1 Definition*
[1c03e14]1947
[7f42aad]1948.. image:: img/image079.gif
[1c03e14]1949
[4ed2d0a1]1950The scattering intensity *I(q)* is
[1c03e14]1951
[77cfcf0]1952.. image:: img/image081.PNG
[1c03e14]1953
[77cfcf0]1954where the contrast
[1c03e14]1955
[77cfcf0]1956.. image:: img/image082.PNG
[1c03e14]1957
[77cfcf0]1958and *N* is the number of discs per unit volume, |alpha| is the angle between the axis of the disc and *q*, and *Vt*
1959and *Vc* are the total volume and the core volume of a single disc, respectively.
[1c03e14]1960
[77cfcf0]1961.. image:: img/image083.PNG
[1c03e14]1962
[77cfcf0]1963where *d* = thickness of the layer (*layer_thick*), 2\ *h* = core thickness (*core_thick*), and *R* = radius of the
1964disc (*radius*).
[1c03e14]1965
[77cfcf0]1966.. image:: img/image084.PNG
[1c03e14]1967
[77cfcf0]1968where *n* = the total number of the disc stacked (*n_stacking*), *D* = the next neighbor center-to-center distance
1969(*d-spacing*), and |sigma|\ D= the Gaussian standard deviation of the d-spacing (*sigma_d*).
[1c03e14]1970
[77cfcf0]1971To provide easy access to the orientation of the stacked disks, we define the axis of the cylinder using two angles
1972|theta| and |phi|. These angles are defined on Figure 2 of CylinderModel.
[1c03e14]1973
[77cfcf0]1974NB: The 2nd virial coefficient of the cylinder is calculated based on the *radius* and *length* = *n_stacking* \*
1975(*core_thick* + 2 \* *layer_thick*) values, and used as the effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
[1c03e14]1976
1977==============  ========  =============
1978Parameter name  Units     Default value
1979==============  ========  =============
1980background      |cm^-1|   0.001
1981core_sld        |Ang^-2|  4e-006
1982core_thick      |Ang|     10
1983layer_sld       |Ang^-2|  0
1984layer_thick     |Ang|     15
1985n_stacking      None      1
1986radius          |Ang|     3e+03
1987scale           None      0.01
1988sigma_d         |Ang|     0
1989solvent_sld     |Ang^-2|  5e-06
1990==============  ========  =============
1991
[7f42aad]1992.. image:: img/image085.jpg
[1c03e14]1993
1994*Figure. 1D plot using the default values (w/1000 data point).*
1995
[7f42aad]1996.. image:: img/image086.jpg
[1c03e14]1997
[77cfcf0]1998*Figure. Examples of the angles for oriented stackeddisks against the detector plane.*
[1c03e14]1999
[7f42aad]2000.. image:: img/image062.jpg
[1c03e14]2001
[77cfcf0]2002*Figure. Examples of the angles for oriented pp against the detector plane.*
[1c03e14]2003
[77cfcf0]2004Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
2005(Kline, 2006)
[1c03e14]2006
2007REFERENCE
[bf8c07b]2008
[93b6fcc]2009A Guinier and G Fournet, *Small-Angle Scattering of X-Rays*, John Wiley and Sons, New York, 1955
[bf8c07b]2010
[93b6fcc]2011O Kratky and G Porod, *J. Colloid Science*, 4, (1949) 35
[bf8c07b]2012
[93b6fcc]2013J S Higgins and H C Benoit, *Polymers and Neutron Scattering*, Clarendon, Oxford, 1994
[1c03e14]2014
2015
2016
2017.. _PringleModel:
2018
2019**2.1.24. PringleModel**
2020
[77cfcf0]2021This model provides the form factor, *P(q)*, for a 'pringle' or 'saddle-shaped' object (a hyperbolic paraboloid).
[1c03e14]2022
[7f42aad]2023.. image:: img/image241.png
[1c03e14]2024
[77cfcf0]2025*(Graphic from Matt Henderson, matt@matthen.com)*
[1c03e14]2026
2027The returned value is in units of |cm^-1|, on absolute scale.
2028
[77cfcf0]2029The form factor calculated is
[1c03e14]2030
[77cfcf0]2031.. image:: img/pringle_eqn_1.jpg
[1c03e14]2032
2033where
2034
[77cfcf0]2035.. image:: img/pringle_eqn_2.jpg
[1c03e14]2036
[77cfcf0]2037The parameters of the model and a plot comparing the pringle model with the equivalent cylinder are shown below.
[1c03e14]2038
2039==============  ========  =============
2040Parameter name  Units     Default value
2041==============  ========  =============
2042background      |cm^-1|   0.0
2043alpha           None      0.001
2044beta            None      0.02
2045radius          |Ang|     60
2046scale           None      1
2047sld_pringle     |Ang^-2|  1e-06
2048sld_solvent     |Ang^-2|  6.3e-06
2049thickness       |Ang|     10
2050==============  ========  =============
2051
[77cfcf0]2052.. image:: img/pringle-vs-cylinder.png
[1c03e14]2053
2054*Figure. 1D plot using the default values (w/150 data point).*
2055
2056REFERENCE
[bf8c07b]2057
[93b6fcc]2058S Alexandru Rautu, Private Communication.
[1c03e14]2059
2060
2061
2062.. _EllipsoidModel:
2063
2064**2.1.25. EllipsoidModel**
2065
[ca1af82]2066This model provides the form factor for an ellipsoid (ellipsoid of revolution) with uniform scattering length density.
2067The form factor is normalized by the particle volume.
[1c03e14]2068
[ca1af82]2069*2.1.25.1. Definition*
[1c03e14]2070
[ca1af82]2071The output of the 2D scattering intensity function for oriented ellipsoids is given by (Feigin, 1987)
[1c03e14]2072
[ca1af82]2073.. image:: img/image059.PNG
[1c03e14]2074
[ca1af82]2075where
[1c03e14]2076
[ca1af82]2077.. image:: img/image119.PNG
[1c03e14]2078
[ca1af82]2079and
[1c03e14]2080
[ca1af82]2081.. image:: img/image120.PNG
[1c03e14]2082
[ca1af82]2083|alpha| is the angle between the axis of the ellipsoid and the *q*\ -vector, *V* is the volume of the ellipsoid, *Ra*
2084is the radius along the rotational axis of the ellipsoid, *Rb* is the radius perpendicular to the rotational axis of
[58eccf6]2085the ellipsoid and |drho| (contrast) is the scattering length density difference between the scatterer and
[ca1af82]2086the solvent.
[1c03e14]2087
[ca1af82]2088To provide easy access to the orientation of the ellipsoid, we define the rotation axis of the ellipsoid using two
2089angles |theta| and |phi|\ . These angles are defined on Figure 2 of the CylinderModel_. For the ellipsoid, |theta|
2090is the angle between the rotational axis and the *z*\ -axis.
[1c03e14]2091
[ca1af82]2092NB: The 2nd virial coefficient of the solid ellipsoid is calculated based on the *radius_a* and *radius_b* values, and
2093used as the effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
[1c03e14]2094
[ca1af82]2095The returned value is scaled to units of |cm^-1| and the parameters of the EllipsoidModel are the following
[1c03e14]2096
2097================  ========  =============
2098Parameter name    Units     Default value
2099================  ========  =============
2100scale             None      1.0
2101radius_a (polar)  |Ang|     20.0
2102radius_b (equat)  |Ang|     400.0
2103sldEll            |Ang^-2|  4.0e-6
2104sldSolv           |Ang^-2|  1.0e-6
2105background        |cm^-1|   0.0
2106axis_theta        degree    90
2107axis_phi          degree    0.0
2108================  ========  =============
2109
[ca1af82]2110The output of the 1D scattering intensity function for randomly oriented ellipsoids is then given by the equation
2111above.
[1c03e14]2112
[7f42aad]2113.. image:: img/image121.jpg
[1c03e14]2114
[ca1af82]2115The *axis_theta* and *axis_phi* parameters are not used for the 1D output. Our implementation of the scattering
2116kernel and the 1D scattering intensity use the c-library from NIST.
[1c03e14]2117
[7f42aad]2118.. image:: img/image122.jpg
[1c03e14]2119
[ca1af82]2120*Figure. The angles for oriented ellipsoid.*
[1c03e14]2121
[ca1af82]2122*2.1.25.1. Validation of the EllipsoidModel*
[1c03e14]2123
[ca1af82]2124Validation of our code was done by comparing the output of the 1D model to the output of the software provided by the
2125NIST (Kline, 2006). Figure 1 below shows a comparison of the 1D output of our model and the output of the NIST
2126software.
[1c03e14]2127
[7f42aad]2128.. image:: img/image123.jpg
[1c03e14]2129
[ca1af82]2130*Figure 1: Comparison of the SasView scattering intensity for an ellipsoid with the output of the NIST SANS analysis*
2131*software.* The parameters were set to: *Scale* = 1.0, *Radius_a* = 20, *Radius_b* = 400, *Contrast* = 3e-6 |Ang^-2|,
2132and *Background* = 0.01 |cm^-1|.
[1c03e14]2133
[ca1af82]2134Averaging over a distribution of orientation is done by evaluating the equation above. Since we have no other software
2135to compare the implementation of the intensity for fully oriented ellipsoids, we can compare the result of averaging
2136our 2D output using a uniform distribution *p(*\ |theta|,\ |phi|\ *)* = 1.0. Figure 2 shows the result of such a
[1c03e14]2137cross-check.
2138
[7f42aad]2139.. image:: img/image124.jpg
[1c03e14]2140
[ca1af82]2141*Figure 2: Comparison of the intensity for uniformly distributed ellipsoids calculated from our 2D model and the*
2142*intensity from the NIST SANS analysis software.* The parameters used were: *Scale* = 1.0, *Radius_a* = 20,
2143*Radius_b* = 400, *Contrast* = 3e-6 |Ang^-2|, and *Background* = 0.0 |cm^-1|.
[1c03e14]2144
[ca1af82]2145The discrepancy above *q* = 0.3 |cm^-1| is due to the way the form factors are calculated in the c-library provided by
2146NIST. A numerical integration has to be performed to obtain *P(q)* for randomly oriented particles. The NIST software
2147performs that integration with a 76-point Gaussian quadrature rule, which will become imprecise at high q where the
2148amplitude varies quickly as a function of *q*. The SasView result shown has been obtained by summing over 501
2149equidistant points in . Our result was found to be stable over the range of *q* shown for a number of points higher
2150than 500.
[1c03e14]2151
[ca1af82]2152REFERENCE
[bf8c07b]2153
[93b6fcc]2154L A Feigin and D I Svergun. *Structure Analysis by Small-Angle X-Ray and Neutron Scattering*, Plenum,
[ca1af82]2155New York, 1987.
[1c03e14]2156
2157
2158
2159.. _CoreShellEllipsoidModel:
2160
2161**2.1.26. CoreShellEllipsoidModel**
2162
[990c2eb]2163This model provides the form factor, *P(q)*, for a core shell ellipsoid (below) where the form factor is normalized by
2164the volume of the cylinder.
[1c03e14]2165
[990c2eb]2166*P(q)* = *scale* \* <*f*\ :sup:`2`> / *V* + *background*
[1c03e14]2167
[990c2eb]2168where the volume *V* = (4/3)\ |pi| (*r*\ :sub:`maj` *r*\ :sub:`min`\ :sup:`2`) and the averaging < > is applied over
2169all orientations for 1D.
[1c03e14]2170
[7f42aad]2171.. image:: img/image125.gif
[1c03e14]2172
[990c2eb]2173The returned value is in units of |cm^-1|, on absolute scale.
[1c03e14]2174
[990c2eb]2175*2.1.26.1. Definition*
[1c03e14]2176
[990c2eb]2177The form factor calculated is
[1c03e14]2178
[990c2eb]2179.. image:: img/image126.PNG
[1c03e14]2180
[990c2eb]2181To provide easy access to the orientation of the core-shell ellipsoid, we define the axis of the solid ellipsoid using
2182two angles |theta| and |phi|\ . These angles are defined on Figure 2 of the CylinderModel_. The contrast is defined as
2183SLD(core) - SLD(shell) and SLD(shell) - SLD(solvent).
[1c03e14]2184
[990c2eb]2185In the parameters, *equat_core* = equatorial core radius, *polar_core* = polar core radius, *equat_shell* =
2186*r*\ :sub:`min` (or equatorial outer radius), and *polar_shell* = = *r*\ :sub:`maj` (or polar outer radius).
[1c03e14]2187
[990c2eb]2188NB: The 2nd virial coefficient of the solid ellipsoid is calculated based on the *radius_a* (= *polar_shell*) and
2189*radius_b* (= *equat_shell*) values, and used as the effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
[1c03e14]2190
2191==============  ========  =============
2192Parameter name  Units     Default value
2193==============  ========  =============
2194background      |cm^-1|   0.001
2195equat_core      |Ang|     200
2196equat_shell     |Ang|     250
2197sld_solvent     |Ang^-2|  6e-06
2198ploar_shell     |Ang|     30
2199ploar_core      |Ang|     20
2200scale           None      1
2201sld_core        |Ang^-2|  2e-06
2202sld_shell       |Ang^-2|  1e-06
2203==============  ========  =============
2204
[7f42aad]2205.. image:: img/image127.jpg
[1c03e14]2206
2207*Figure. 1D plot using the default values (w/1000 data point).*
2208
[7f42aad]2209.. image:: img/image122.jpg
[1c03e14]2210
[990c2eb]2211*Figure. The angles for oriented CoreShellEllipsoid.*
[1c03e14]2212
[990c2eb]2213Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
2214(Kline, 2006).
[1c03e14]2215
2216REFERENCE
[bf8c07b]2217
[93b6fcc]2218M Kotlarchyk, S H Chen, *J. Chem. Phys.*, 79 (1983) 2461
[bf8c07b]2219
[93b6fcc]2220S J Berr, *Phys. Chem.*, 91 (1987) 4760
[1c03e14]2221
2222
2223
[77cfcf0]2224.. _CoreShellEllipsoidXTModel:
2225
2226**2.1.27. CoreShellEllipsoidXTModel**
2227
2228An alternative version of *P(q)* for the core-shell ellipsoid (see CoreShellEllipsoidModel), having as parameters the
2229core axial ratio *X* and a shell thickness, which are more often what we would like to determine.
2230
2231This model is also better behaved when polydispersity is applied than the four independent radii in
2232CoreShellEllipsoidModel.
2233
[990c2eb]2234*2.1.27.1. Definition*
[77cfcf0]2235
2236.. image:: img/image125.gif
2237
2238The geometric parameters of this model are
2239
2240  *equat_core* = equatorial core radius = *Rminor_core*
[a342928]2241 
[77cfcf0]2242  *X_core* = *polar_core* / *equat_core* = *Rmajor_core* / *Rminor_core*
[a342928]2243 
[77cfcf0]2244  *T_shell* = *equat_outer* - *equat_core* = *Rminor_outer* - *Rminor_core*
[a342928]2245 
[77cfcf0]2246  *XpolarShell* = *Tpolar_shell* / *T_shell* = (*Rmajor_outer* - *Rmajor_core*)/(*Rminor_outer* - *Rminor_core*)
2247
2248In terms of the original radii
2249
2250  *polar_core* = *equat_core* \* *X_core*
[a342928]2251 
[77cfcf0]2252  *equat_shell* = *equat_core* + *T_shell*
[a342928]2253 
[77cfcf0]2254  *polar_shell* = *equat_core* \* *X_core* + *T_shell* \* *XpolarShell*
2255
2256  (where we note that "shell" perhaps confusingly, relates to the outer radius)
2257
2258When *X_core* < 1 the core is oblate; when *X_core* > 1  it is prolate. *X_core* = 1 is a spherical core.
2259
2260For a fixed shell thickness *XpolarShell* = 1, to scale the shell thickness pro-rata with the radius
2261*XpolarShell* = *X_core*.
2262
2263When including an *S(q)*, the radius in *S(q)* is calculated to be that of a sphere with the same 2nd virial
2264coefficient of the **outer** surface of the ellipsoid. This may have some undesirable effects if the aspect ratio of
2265the ellipsoid is large (ie, if *X* << 1 or *X* >> 1), when the *S(q)* - which assumes spheres - will not in any case
2266be valid.
2267
[6386cd8]2268If SAS data are in absolute units, and the SLDs are correct, then *scale* should be the total volume fraction of the
[77cfcf0]2269"outer particle". When *S(q)* is introduced this moves to the *S(q)* volume fraction, and *scale* should then be 1.0,
2270or contain some other units conversion factor (for example, if you have SAXS data).
2271
2272==============  ========  =============
2273Parameter name  Units     Default value
2274==============  ========  =============
2275background      |cm^-1|   0.001
2276equat_core      |Ang|     20
2277scale           None      0.05
2278sld_core        |Ang^-2|  2.0e-6
2279sld_shell       |Ang^-2|  1.0e-6
2280sld_solv        |Ang^-2|  6.3e-6
2281T_shell         |Ang|     30
2282X_core          None      3.0
2283XpolarShell     None      1.0
2284==============  ========  =============
2285
2286REFERENCE
[bf8c07b]2287
[93b6fcc]2288R K Heenan, Private communication
[77cfcf0]2289
2290
2291
[bf8c07b]2292.. _TriaxialEllipsoidModel:
[1c03e14]2293
[77cfcf0]2294**2.1.28. TriaxialEllipsoidModel**
[1c03e14]2295
[990c2eb]2296This model provides the form factor, *P(q)*, for an ellipsoid (below) where all three axes are of different lengths,
2297i.e., *Ra* =< *Rb* =< *Rc*\ . **Users should maintain this inequality for all calculations**.
[1c03e14]2298
[990c2eb]2299*P(q)* = *scale* \* <*f*\ :sup:`2`> / *V* + *background*
[1c03e14]2300
[990c2eb]2301where the volume *V* = (4/3)\ |pi| (*Ra* *Rb* *Rc*), and the averaging < > is applied over all orientations for 1D.
[1c03e14]2302
[7f42aad]2303.. image:: img/image128.jpg
[1c03e14]2304
2305The returned value is in units of |cm^-1|, on absolute scale.
2306
[990c2eb]2307*2.1.28.1. Definition*
2308
2309The form factor calculated is
[1c03e14]2310
[990c2eb]2311.. image:: img/image129.PNG
[1c03e14]2312
[990c2eb]2313To provide easy access to the orientation of the triaxial ellipsoid, we define the axis of the cylinder using the
2314angles |theta|, |phi| and |bigpsi|. These angles are defined on Figure 2 of the CylinderModel_. The angle |bigpsi| is
2315the rotational angle around its own *semi_axisC* axis against the *q* plane. For example, |bigpsi| = 0 when the
2316*semi_axisA* axis is parallel to the *x*-axis of the detector.
[1c03e14]2317
[6386cd8]2318The radius-of-gyration for this system is *Rg*\ :sup:`2` = (*Ra*\ :sup:`2` *Rb*\ :sup:`2` *Rc*\ :sup:`2`)/5.
[1c03e14]2319
[990c2eb]2320The contrast is defined as SLD(ellipsoid) - SLD(solvent). In the parameters, *semi_axisA* = *Ra* (or minor equatorial
2321radius), *semi_axisB* = *Rb* (or major equatorial radius), and *semi_axisC* = *Rc* (or polar radius of the ellipsoid).
[1c03e14]2322
[990c2eb]2323NB: The 2nd virial coefficient of the triaxial solid ellipsoid is calculated based on the
2324*radius_a* (= *semi_axisC*\ ) and *radius_b* (= sqrt(*semi_axisA* \* *semi_axisB*)) values, and used as the effective
2325radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
[1c03e14]2326
2327==============  ========  =============
2328Parameter name  Units     Default value
2329==============  ========  =============
2330background      |cm^-1|   0.0
2331semi_axisA      |Ang|     35
2332semi_axisB      |Ang|     100
2333semi_axisC      |Ang|     400
2334scale           None      1
2335sldEll          |Ang^-2|  1.0e-06
2336sldSolv         |Ang^-2|  6.3e-06
2337==============  ========  =============
2338
[7f42aad]2339.. image:: img/image130.jpg
[1c03e14]2340
2341*Figure. 1D plot using the default values (w/1000 data point).*
2342
[990c2eb]2343*2.1.28.2.Validation of the TriaxialEllipsoidModel*
[1c03e14]2344
[990c2eb]2345Validation of our code was done by comparing the output of the 1D calculation to the angular average of the output of
23462D calculation over all possible angles. The Figure below shows the comparison where the solid dot refers to averaged
23472D while the line represents the result of 1D calculation (for 2D averaging, 76, 180, and 76 points are taken for the
2348angles of |theta|, |phi|, and |psi| respectively).
[1c03e14]2349
[7f42aad]2350.. image:: img/image131.gif
[1c03e14]2351
2352*Figure. Comparison between 1D and averaged 2D.*
2353
[7f42aad]2354.. image:: img/image132.jpg
[1c03e14]2355
[990c2eb]2356*Figure. The angles for oriented ellipsoid.*
[1c03e14]2357
[990c2eb]2358Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
2359(Kline, 2006)
[1c03e14]2360
2361REFERENCE
[bf8c07b]2362
[93b6fcc]2363L A Feigin and D I Svergun, *Structure Analysis by Small-Angle X-Ray and Neutron Scattering*, Plenum,
[990c2eb]2364New York, 1987.
[1c03e14]2365
2366
2367
2368.. _LamellarModel:
2369
[77cfcf0]2370**2.1.29. LamellarModel**
[1c03e14]2371
[1127c32]2372This model provides the scattering intensity, *I(q)*, for a lyotropic lamellar phase where a uniform SLD and random
2373distribution in solution are assumed. Polydispersity in the bilayer thickness can be applied from the GUI.
[1c03e14]2374
[1127c32]2375*2.1.29.1. Definition*
[1c03e14]2376
[1127c32]2377The scattering intensity *I(q)* is
[1c03e14]2378
[1127c32]2379.. image:: img/image133.PNG
[1c03e14]2380
[1127c32]2381The form factor is
[1c03e14]2382
[1127c32]2383.. image:: img/image134.PNG
[1c03e14]2384
[1127c32]2385where |delta| = bilayer thickness.
[1c03e14]2386
[1127c32]2387The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]2388
[7f42aad]2389.. image:: img/image040.gif
[1c03e14]2390
[1127c32]2391The returned value is in units of |cm^-1|, on absolute scale. In the parameters, *sld_bi* = SLD of the bilayer,
2392*sld_sol* = SLD of the solvent, and *bi_thick* = thickness of the bilayer.
[1c03e14]2393
2394==============  ========  =============
2395Parameter name  Units     Default value
2396==============  ========  =============
2397background      |cm^-1|   0.0
2398sld_bi          |Ang^-2|  1e-06
2399bi_thick        |Ang|     50
2400sld_sol         |Ang^-2|  6e-06
2401scale           None      1
2402==============  ========  =============
2403
[7f42aad]2404.. image:: img/image135.jpg
[1c03e14]2405
2406*Figure. 1D plot using the default values (w/1000 data point).*
2407
[1127c32]2408Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
2409(Kline, 2006).
[1c03e14]2410
2411REFERENCE
2412
[93b6fcc]2413F Nallet, R Laversanne, and D Roux, J. Phys. II France, 3, (1993) 487-502
[1c03e14]2414
[bf8c07b]2415also in J. Phys. Chem. B, 105, (2001) 11081-11088
[1c03e14]2416
2417
2418
2419.. _LamellarFFHGModel:
2420
[77cfcf0]2421**2.1.30. LamellarFFHGModel**
[1c03e14]2422
[1127c32]2423This model provides the scattering intensity, *I(q)*, for a lyotropic lamellar phase where a random distribution in
2424solution are assumed. The SLD of the head region is taken to be different from the SLD of the tail region.
[1c03e14]2425
[1127c32]2426*2.1.31.1. Definition*
[1c03e14]2427
[1127c32]2428The scattering intensity *I(q)* is
[1c03e14]2429
[1127c32]2430.. image:: img/image136.PNG
[1c03e14]2431
[1127c32]2432The form factor is
[1c03e14]2433
[7f42aad]2434.. image:: img/image137.jpg
[1c03e14]2435
[1127c32]2436where |delta|\ T = tail length (or *t_length*), |delta|\ H = head thickness (or *h_thickness*),
[3342eb3]2437|drho|\ H = SLD(headgroup) - SLD(solvent), and |drho|\ T = SLD(tail) - SLD(solvent). The total thickness is 2(H+T).
[1c03e14]2438
[1127c32]2439The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]2440
[7f42aad]2441.. image:: img/image040.gif
[1c03e14]2442
[1127c32]2443The returned value is in units of |cm^-1|, on absolute scale. In the parameters, *sld_tail* = SLD of the tail group,
2444and *sld_head* = SLD of the head group.
[1c03e14]2445
2446==============  ========  =============
2447Parameter name  Units     Default value
2448==============  ========  =============
2449background      |cm^-1|   0.0
2450sld_head        |Ang^-2|  3e-06
2451scale           None      1
2452sld_solvent     |Ang^-2|  6e-06
2453h_thickness     |Ang|     10
2454t_length        |Ang|     15
2455sld_tail        |Ang^-2|  0
2456==============  ========  =============
2457
[7f42aad]2458.. image:: img/image138.jpg
[1c03e14]2459
2460*Figure. 1D plot using the default values (w/1000 data point).*
2461
[1127c32]2462Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
2463(Kline, 2006).
[1c03e14]2464
2465REFERENCE
2466
[93b6fcc]2467F Nallet, R Laversanne, and D Roux, J. Phys. II France, 3, (1993) 487-502
[1c03e14]2468
[bf8c07b]2469also in J. Phys. Chem. B, 105, (2001) 11081-11088
[1c03e14]2470
[93b6fcc]2471*2014/04/17 - Description reviewed by S King and P Butler.*
[4ed2d0a1]2472
[1c03e14]2473
2474
2475.. _LamellarPSModel:
2476
[77cfcf0]2477**2.1.31. LamellarPSModel**
[1c03e14]2478
[1127c32]2479This model provides the scattering intensity, *I(q)* = *P(q)* \* *S(q)*, for a lyotropic lamellar phase where a random
2480distribution in solution are assumed.
[1c03e14]2481
[1127c32]2482*2.1.31.1. Definition*
[1c03e14]2483
[1127c32]2484The scattering intensity *I(q)* is
[1c03e14]2485
[1127c32]2486.. image:: img/image139.PNG
[1c03e14]2487
2488The form factor is
2489
[1127c32]2490.. image:: img/image134.PNG
[1c03e14]2491
[1127c32]2492and the structure factor is
[1c03e14]2493
[1127c32]2494.. image:: img/image140.PNG
[1c03e14]2495
2496where
2497
[1127c32]2498.. image:: img/image141.PNG
[1c03e14]2499
[58eccf6]2500Here *d* = (repeat) spacing, |delta| = bilayer thickness, the contrast |drho| = SLD(headgroup) - SLD(solvent),
[1127c32]2501K = smectic bending elasticity, B = compression modulus, and N = number of lamellar plates (*n_plates*).
[1c03e14]2502
[1127c32]2503NB: **When the Caille parameter is greater than approximately 0.8 to 1.0, the assumptions of the model are incorrect.**
2504And due to a complication of the model function, users are responsible for making sure that all the assumptions are
2505handled accurately (see the original reference below for more details).
[1c03e14]2506
[1127c32]2507The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]2508
[7f42aad]2509.. image:: img/image040.gif
[1c03e14]2510
2511The returned value is in units of |cm^-1|, on absolute scale.
2512
2513==============  ========  =============
2514Parameter name  Units     Default value
2515==============  ========  =============
2516background      |cm^-1|   0.0
2517contrast        |Ang^-2|  5e-06
2518scale           None      1
2519delta           |Ang|     30
2520n_plates        None      20
2521spacing         |Ang|     400
2522caille          |Ang^-2|  0.1
2523==============  ========  =============
2524
[7f42aad]2525.. image:: img/image142.jpg
[1c03e14]2526
2527*Figure. 1D plot using the default values (w/6000 data point).*
2528
[1127c32]2529Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
2530(Kline, 2006).
[1c03e14]2531
2532REFERENCE
2533
[93b6fcc]2534F Nallet, R Laversanne, and D Roux, J. Phys. II France, 3, (1993) 487-502
[1c03e14]2535
[bf8c07b]2536also in J. Phys. Chem. B, 105, (2001) 11081-11088
[1c03e14]2537
2538
2539
2540.. _LamellarPSHGModel:
2541
[77cfcf0]2542**2.1.32. LamellarPSHGModel**
[1c03e14]2543
[1127c32]2544This model provides the scattering intensity, *I(q)* = *P(q)* \* *S(q)*, for a lyotropic lamellar phase where a random
2545distribution in solution are assumed. The SLD of the head region is taken to be different from the SLD of the tail
2546region.
[1c03e14]2547
[1127c32]2548*2.1.32.1. Definition*
[1c03e14]2549
[1127c32]2550The scattering intensity *I(q)* is
[1c03e14]2551
[1127c32]2552.. image:: img/image139.PNG
[1c03e14]2553
[1127c32]2554The form factor is
[1c03e14]2555
[1127c32]2556.. image:: img/image143.PNG
[1c03e14]2557
2558The structure factor is
2559
[1127c32]2560.. image:: img/image140.PNG
[1c03e14]2561
2562where
2563
[1127c32]2564.. image:: img/image141.PNG
[1c03e14]2565
[1127c32]2566where |delta|\ T = tail length (or *t_length*), |delta|\ H = head thickness (or *h_thickness*),
[58eccf6]2567|drho|\ H = SLD(headgroup) - SLD(solvent), and |drho|\ T = SLD(tail) - SLD(headgroup).
[1127c32]2568Here *d* = (repeat) spacing, *K* = smectic bending elasticity, *B* = compression modulus, and N = number of lamellar
2569plates (*n_plates*).
[1c03e14]2570
[1127c32]2571NB: **When the Caille parameter is greater than approximately 0.8 to 1.0, the assumptions of the model are incorrect.**
2572And due to a complication of the model function, users are responsible for making sure that all the assumptions are
2573handled accurately (see the original reference below for more details).
[1c03e14]2574
[1127c32]2575The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]2576
[7f42aad]2577.. image:: img/image040.gif
[1c03e14]2578
[1127c32]2579The returned value is in units of |cm^-1|, on absolute scale. In the parameters, *sld_tail* = SLD of the tail group,
2580*sld_head* = SLD of the head group, and *sld_solvent* = SLD of the solvent.
[1c03e14]2581
2582==============  ========  =============
2583Parameter name  Units     Default value
2584==============  ========  =============
2585background      |cm^-1|   0.001
2586sld_head        |Ang^-2|  2e-06
2587scale           None      1
2588sld_solvent     |Ang^-2|  6e-06
2589deltaH          |Ang|     2
2590deltaT          |Ang|     10
2591sld_tail        |Ang^-2|  0
2592n_plates        None      30
2593spacing         |Ang|     40
2594caille          |Ang^-2|  0.001
2595==============  ========  =============
2596
[7f42aad]2597.. image:: img/image144.jpg
[1c03e14]2598
2599*Figure. 1D plot using the default values (w/6000 data point).*
2600
[1127c32]2601Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
2602(Kline, 2006).
[1c03e14]2603
2604REFERENCE
2605
[93b6fcc]2606F Nallet, R Laversanne, and D Roux, J. Phys. II France, 3, (1993) 487-502
[1c03e14]2607
[bf8c07b]2608also in J. Phys. Chem. B, 105, (2001) 11081-11088
[1c03e14]2609
2610
2611
2612.. _LamellarPCrystalModel:
2613
[77cfcf0]2614**2.1.33. LamellarPCrystalModel**
[1c03e14]2615
[1127c32]2616This model calculates the scattering from a stack of repeating lamellar structures. The stacks of lamellae (infinite
2617in lateral dimension) are treated as a paracrystal to account for the repeating spacing. The repeat distance is further
2618characterized by a Gaussian polydispersity. **This model can be used for large multilamellar vesicles.**
[1c03e14]2619
[1127c32]2620*2.1.33.1. Definition*
[1c03e14]2621
[1127c32]2622The scattering intensity *I(q)* is calculated as
[1c03e14]2623
[7f42aad]2624.. image:: img/image145.jpg
[1c03e14]2625
[1127c32]2626The form factor of the bilayer is approximated as the cross section of an infinite, planar bilayer of thickness *t*
[1c03e14]2627
[7f42aad]2628.. image:: img/image146.jpg
[1c03e14]2629
[1127c32]2630Here, the scale factor is used instead of the mass per area of the bilayer (*G*). The scale factor is the volume
[d4117ccb]2631fraction of the material in the bilayer, *not* the total excluded volume of the paracrystal. *Z*\ :sub:`N`\ *(q)*
2632describes the interference effects for aggregates consisting of more than one bilayer. The equations used are (3-5)
2633from the Bergstrom reference below.
[1c03e14]2634
[1127c32]2635Non-integer numbers of stacks are calculated as a linear combination of the lower and higher values
[1c03e14]2636
[7f42aad]2637.. image:: img/image147.jpg
[1c03e14]2638
[1127c32]2639The 2D scattering intensity is the same as 1D, regardless of the orientation of the *q* vector which is defined as
[1c03e14]2640
[7f42aad]2641.. image:: img/image040.gif
[1c03e14]2642
[1127c32]2643The parameters of the model are *Nlayers* = no. of layers, and *pd_spacing* = polydispersity of spacing.
[1c03e14]2644
2645==============  ========  =============
2646Parameter name  Units     Default value
2647==============  ========  =============
2648background      |cm^-1|   0
2649scale           None      1
2650Nlayers         None      20
2651pd_spacing      None      0.2
2652sld_layer       |Ang^-2|  1e-6
2653sld_solvent     |Ang^-2|  6.34e-6
2654spacing         |Ang|     250
2655thickness       |Ang|     33
2656==============  ========  =============
2657
[7f42aad]2658.. image:: img/image148.jpg
[1c03e14]2659
[1127c32]2660*Figure. 1D plot using the default values above (w/20000 data point).*
[1c03e14]2661
[1127c32]2662Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
2663(Kline, 2006).
[1c03e14]2664
2665REFERENCE
2666
[93b6fcc]2667M Bergstrom, J S Pedersen, P Schurtenberger, S U Egelhaaf, *J. Phys. Chem. B*, 103 (1999) 9888-9897
[1c03e14]2668
2669
2670
2671.. _SCCrystalModel:
2672
[77cfcf0]2673**2.1.34. SCCrystalModel**
[1c03e14]2674
[d4117ccb]2675Calculates the scattering from a **simple cubic lattice** with paracrystalline distortion. Thermal vibrations are
2676considered to be negligible, and the size of the paracrystal is infinitely large. Paracrystalline distortion is assumed
2677to be isotropic and characterized by a Gaussian distribution.
[1c03e14]2678
[77cfcf0]2679The returned value is scaled to units of |cm^-1|\ |sr^-1|, absolute scale.
[1c03e14]2680
[d4117ccb]2681*2.1.34.1. Definition*
[1c03e14]2682
[4ed2d0a1]2683The scattering intensity *I(q)* is calculated as
[1c03e14]2684
[7f42aad]2685.. image:: img/image149.jpg
[1c03e14]2686
[d4117ccb]2687where *scale* is the volume fraction of spheres, *Vp* is the volume of the primary particle, *V(lattice)* is a volume
2688correction for the crystal structure, *P(q)* is the form factor of the sphere (normalized), and *Z(q)* is the
2689paracrystalline structure factor for a simple cubic structure.
[1c03e14]2690
[d4117ccb]2691Equation (16) of the 1987 reference is used to calculate *Z(q)*, using equations (13)-(15) from the 1987 paper for
2692*Z1*\ , *Z2*\ , and *Z3*\ .
[1c03e14]2693
[d4117ccb]2694The lattice correction (the occupied volume of the lattice) for a simple cubic structure of particles of radius *R*
2695and nearest neighbor separation *D* is
[1c03e14]2696
[7f42aad]2697.. image:: img/image150.jpg
[1c03e14]2698
[d4117ccb]2699The distortion factor (one standard deviation) of the paracrystal is included in the calculation of *Z(q)*
[1c03e14]2700
[7f42aad]2701.. image:: img/image151.jpg
[1c03e14]2702
[d4117ccb]2703where *g* is a fractional distortion based on the nearest neighbor distance.
[1c03e14]2704
[d4117ccb]2705The simple cubic lattice is
[1c03e14]2706
[7f42aad]2707.. image:: img/image152.jpg
[1c03e14]2708
[d4117ccb]2709For a crystal, diffraction peaks appear at reduced *q*\ -values given by
[1c03e14]2710
[7f42aad]2711.. image:: img/image153.jpg
[1c03e14]2712
[d4117ccb]2713where for a simple cubic lattice any *h*\ , *k*\ , *l* are allowed and none are forbidden. Thus the peak positions
2714correspond to (just the first 5)
[1c03e14]2715
[7f42aad]2716.. image:: img/image154.jpg
[1c03e14]2717
[d4117ccb]2718**NB: The calculation of** *Z(q)* **is a double numerical integral that must be carried out with a high density of**
2719**points to properly capture the sharp peaks of the paracrystalline scattering.** So be warned that the calculation is
2720SLOW. Go get some coffee. Fitting of any experimental data must be resolution smeared for any meaningful fit. This
2721makes a triple integral. Very, very slow. Go get lunch!
[1c03e14]2722
2723==============  ========  =============
2724Parameter name  Units     Default value
2725==============  ========  =============
2726background      |cm^-1|   0
2727dnn             |Ang|     220
2728scale           None      1
2729sldSolv         |Ang^-2|  6.3e-06
2730radius          |Ang|     40
2731sld_Sph         |Ang^-2|  3e-06
2732d_factor        None      0.06
2733==============  ========  =============
2734
[d4117ccb]2735This example dataset is produced using 200 data points, *qmin* = 0.01 |Ang^-1|, *qmax* = 0.1 |Ang^-1| and the above
2736default values.
[bf8c07b]2737
[7f42aad]2738.. image:: img/image155.jpg
[1c03e14]2739
[d4117ccb]2740*Figure. 1D plot in the linear scale using the default values (w/200 data point).*
[1c03e14]2741
[d4117ccb]2742The 2D (Anisotropic model) is based on the reference below where *I(q)* is approximated for 1d scattering. Thus the
2743scattering pattern for 2D may not be accurate. Note that we are not responsible for any incorrectness of the 2D model
2744computation.
[1c03e14]2745
[7f42aad]2746.. image:: img/image156.jpg
[1c03e14]2747
[7f42aad]2748.. image:: img/image157.jpg
[1c03e14]2749
[d4117ccb]2750*Figure. 2D plot using the default values (w/200X200 pixels).*
[1c03e14]2751
[d4117ccb]2752REFERENCE
[1c03e14]2753
[d4117ccb]2754Hideki Matsuoka et. al. *Physical Review B*, 36 (1987) 1754-1765
2755(Original Paper)
[1c03e14]2756
[d4117ccb]2757Hideki Matsuoka et. al. *Physical Review B*, 41 (1990) 3854 -3856
2758(Corrections to FCC and BCC lattice structure calculation)
[1c03e14]2759
2760
2761
2762.. _FCCrystalModel:
2763
[77cfcf0]2764**2.1.35. FCCrystalModel**
[1c03e14]2765
[d4117ccb]2766Calculates the scattering from a **face-centered cubic lattice** with paracrystalline distortion. Thermal vibrations
2767are considered to be negligible, and the size of the paracrystal is infinitely large. Paracrystalline distortion is
2768assumed to be isotropic and characterized by a Gaussian distribution.
[1c03e14]2769
[77cfcf0]2770The returned value is scaled to units of |cm^-1|\ |sr^-1|, absolute scale.
[1c03e14]2771
[d4117ccb]2772*2.1.35.1. Definition*
[1c03e14]2773
[d4117ccb]2774The scattering intensity *I(q)* is calculated as
[1c03e14]2775
[7f42aad]2776.. image:: img/image158.jpg
[1c03e14]2777
[d4117ccb]2778where *scale* is the volume fraction of spheres, *Vp* is the volume of the primary particle, *V(lattice)* is a volume
2779correction for the crystal structure, *P(q)* is the form factor of the sphere (normalized), and *Z(q)* is the
2780paracrystalline structure factor for a face-centered cubic structure.
[1c03e14]2781
[d4117ccb]2782Equation (1) of the 1990 reference is used to calculate *Z(q)*, using equations (23)-(25) from the 1987 paper for
2783*Z1*\ , *Z2*\ , and *Z3*\ .
[1c03e14]2784
[d4117ccb]2785The lattice correction (the occupied volume of the lattice) for a face-centered cubic structure of particles of radius
2786*R* and nearest neighbor separation *D* is
[1c03e14]2787
[7f42aad]2788.. image:: img/image159.jpg
[1c03e14]2789
[d4117ccb]2790The distortion factor (one standard deviation) of the paracrystal is included in the calculation of *Z(q)*
[1c03e14]2791
[7f42aad]2792.. image:: img/image160.jpg
[1c03e14]2793
[d4117ccb]2794where *g* is a fractional distortion based on the nearest neighbor distance.
[1c03e14]2795
[d4117ccb]2796The face-centered cubic lattice is
[1c03e14]2797
[7f42aad]2798.. image:: img/image161.jpg
[1c03e14]2799
[d4117ccb]2800For a crystal, diffraction peaks appear at reduced q-values given by
[1c03e14]2801
[7f42aad]2802.. image:: img/image162.jpg
[1c03e14]2803
[d4117ccb]2804where for a face-centered cubic lattice *h*\ , *k*\ , *l* all odd or all even are allowed and reflections where
2805*h*\ , *k*\ , *l* are mixed odd/even are forbidden. Thus the peak positions correspond to (just the first 5)
[1c03e14]2806
[7f42aad]2807.. image:: img/image163.jpg
[1c03e14]2808
[d4117ccb]2809**NB: The calculation of** *Z(q)* **is a double numerical integral that must be carried out with a high density of**
2810**points to properly capture the sharp peaks of the paracrystalline scattering.** So be warned that the calculation is
2811SLOW. Go get some coffee. Fitting of any experimental data must be resolution smeared for any meaningful fit. This
2812makes a triple integral. Very, very slow. Go get lunch!
[1c03e14]2813
2814==============  ========  =============
2815Parameter name  Units     Default value
2816==============  ========  =============
2817background      |cm^-1|   0
2818dnn             |Ang|     220
2819scale           None      1
2820sldSolv         |Ang^-2|  6.3e-06
2821radius          |Ang|     40
2822sld_Sph         |Ang^-2|  3e-06
2823d_factor        None      0.06
2824==============  ========  =============
2825
[d4117ccb]2826This example dataset is produced using 200 data points, *qmin* = 0.01 |Ang^-1|, *qmax* = 0.1 |Ang^-1| and the above
2827default values.
[1c03e14]2828
[7f42aad]2829.. image:: img/image164.jpg
[1c03e14]2830
[d4117ccb]2831*Figure. 1D plot in the linear scale using the default values (w/200 data point).*
[1c03e14]2832
[d4117ccb]2833The 2D (Anisotropic model) is based on the reference below where *I(q)* is approximated for 1d scattering. Thus the
2834scattering pattern for 2D may not be accurate. Note that we are not responsible for any incorrectness of the 2D model
2835computation.
[1c03e14]2836
[7f42aad]2837.. image:: img/image165.gif
[1c03e14]2838
[7f42aad]2839.. image:: img/image166.jpg
[1c03e14]2840
2841*Figure. 2D plot using the default values (w/200X200 pixels).*
2842
[d4117ccb]2843REFERENCE
[1c03e14]2844
[d4117ccb]2845Hideki Matsuoka et. al. *Physical Review B*, 36 (1987) 1754-1765
2846(Original Paper)
[1c03e14]2847
[d4117ccb]2848Hideki Matsuoka et. al. *Physical Review B*, 41 (1990) 3854 -3856
2849(Corrections to FCC and BCC lattice structure calculation)
[1c03e14]2850
2851
2852
[d4117ccb]2853.. _BCCrystalModel:
[1c03e14]2854
[d4117ccb]2855**2.1.36. BCCrystalModel**
[1c03e14]2856
[d4117ccb]2857Calculates the scattering from a **body-centered cubic lattice** with paracrystalline distortion. Thermal vibrations
2858are considered to be negligible, and the size of the paracrystal is infinitely large. Paracrystalline distortion is
2859assumed to be isotropic and characterized by a Gaussian distribution.
[1c03e14]2860
[d4117ccb]2861The returned value is scaled to units of |cm^-1|\ |sr^-1|, absolute scale.
[1c03e14]2862
[d4117ccb]2863*2.1.36.1. Definition**
[1c03e14]2864
[d4117ccb]2865The scattering intensity *I(q)* is calculated as
[1c03e14]2866
[7f42aad]2867.. image:: img/image167.jpg
[1c03e14]2868
[d4117ccb]2869where *scale* is the volume fraction of spheres, *Vp* is the volume of the primary particle, *V(lattice)* is a volume
2870correction for the crystal structure, *P(q)* is the form factor of the sphere (normalized), and *Z(q)* is the
2871paracrystalline structure factor for a body-centered cubic structure.
[1c03e14]2872
[d4117ccb]2873Equation (1) of the 1990 reference is used to calculate *Z(q)*, using equations (29)-(31) from the 1987 paper for
2874*Z1*\ , *Z2*\ , and *Z3*\ .
[1c03e14]2875
[d4117ccb]2876The lattice correction (the occupied volume of the lattice) for a body-centered cubic structure of particles of radius
2877*R* and nearest neighbor separation *D* is
[1c03e14]2878
[7f42aad]2879.. image:: img/image159.jpg
[1c03e14]2880
[d4117ccb]2881The distortion factor (one standard deviation) of the paracrystal is included in the calculation of *Z(q)*
[1c03e14]2882
[7f42aad]2883.. image:: img/image160.jpg
[1c03e14]2884
[d4117ccb]2885where *g* is a fractional distortion based on the nearest neighbor distance.
[1c03e14]2886
[d4117ccb]2887The body-centered cubic lattice is
[1c03e14]2888
[7f42aad]2889.. image:: img/image168.jpg
[1c03e14]2890
[d4117ccb]2891For a crystal, diffraction peaks appear at reduced q-values given by
[1c03e14]2892
[7f42aad]2893.. image:: img/image162.jpg
[1c03e14]2894
[d4117ccb]2895where for a body-centered cubic lattice, only reflections where (\ *h* + *k* + *l*\ ) = even are allowed and
2896reflections where (\ *h* + *k* + *l*\ ) = odd are forbidden. Thus the peak positions correspond to (just the first 5)
[1c03e14]2897
[7f42aad]2898.. image:: img/image169.jpg
[1c03e14]2899
[d4117ccb]2900**NB: The calculation of** *Z(q)* **is a double numerical integral that must be carried out with a high density of**
2901**points to properly capture the sharp peaks of the paracrystalline scattering.** So be warned that the calculation is
2902SLOW. Go get some coffee. Fitting of any experimental data must be resolution smeared for any meaningful fit. This
2903makes a triple integral. Very, very slow. Go get lunch!
[1c03e14]2904
2905==============  ========  =============
2906Parameter name  Units     Default value
2907==============  ========  =============
2908background      |cm^-1|   0
2909dnn             |Ang|     220
2910scale           None      1
2911sldSolv         |Ang^-2|  6.3e-006
2912radius          |Ang|     40
2913sld_Sph         |Ang^-2|  3e-006
2914d_factor        None      0.06
2915==============  ========  =============
2916
[d4117ccb]2917This example dataset is produced using 200 data points, *qmin* = 0.001 |Ang^-1|, *qmax* = 0.1 |Ang^-1| and the above
2918default values.
[bf8c07b]2919
[7f42aad]2920.. image:: img/image170.jpg
[1c03e14]2921
[d4117ccb]2922*Figure. 1D plot in the linear scale using the default values (w/200 data point).*
[1c03e14]2923
[d4117ccb]2924The 2D (Anisotropic model) is based on the reference below where *I(q)* is approximated for 1d scattering. Thus the
2925scattering pattern for 2D may not be accurate. Note that we are not responsible for any incorrectness of the 2D model
2926computation.
[1c03e14]2927
[7f42aad]2928.. image:: img/image165.gif
[1c03e14]2929
[7f42aad]2930.. image:: img/image171.jpg
[1c03e14]2931
[d4117ccb]2932*Figure. 2D plot using the default values (w/200X200 pixels).*
[1c03e14]2933
[d4117ccb]2934REFERENCE
[1c03e14]2935
[d4117ccb]2936Hideki Matsuoka et. al. *Physical Review B*, 36 (1987) 1754-1765
2937(Original Paper)
[1c03e14]2938
[d4117ccb]2939Hideki Matsuoka et. al. *Physical Review B*, 41 (1990) 3854 -3856
2940(Corrections to FCC and BCC lattice structure calculation)
[1c03e14]2941
2942
2943
2944.. _ParallelepipedModel:
2945
[77cfcf0]2946**2.1.37. ParallelepipedModel**
[1c03e14]2947
[bf8c07b]2948This model provides the form factor, *P(q)*, for a rectangular cylinder (below) where the form factor is normalized by
[6386cd8]2949the volume of the cylinder. If you need to apply polydispersity, see the RectangularPrismModel_.
[1c03e14]2950
[bf8c07b]2951*P(q)* = *scale* \* <*f*\ :sup:`2`> / *V* + *background*
[1c03e14]2952
[bf8c07b]2953where the volume *V* = *A B C* and the averaging < > is applied over all orientations for 1D.
[1c03e14]2954
[bf8c07b]2955For information about polarised and magnetic scattering, click here_.
[1c03e14]2956
[7f42aad]2957.. image:: img/image087.jpg
[1c03e14]2958
[bf8c07b]2959*2.1.37.1. Definition*
[1c03e14]2960
[bf8c07b]2961**The edge of the solid must satisfy the condition that** *A* < *B*. Then, assuming *a* = *A* / *B* < 1,
2962*b* = *B* / *B* = 1, and *c* = *C* / *B* > 1, the form factor is
[1c03e14]2963
[bf8c07b]2964.. image:: img/image088.PNG
[1c03e14]2965
[bf8c07b]2966and the contrast is defined as
[1c03e14]2967
[bf8c07b]2968.. image:: img/image089.PNG
[1c03e14]2969
[bf8c07b]2970The scattering intensity per unit volume is returned in units of |cm^-1|; ie, *I(q)* = |phi| *P(q)*\ .
[1c03e14]2971
[bf8c07b]2972NB: The 2nd virial coefficient of the parallelpiped is calculated based on the the averaged effective radius
2973(= sqrt(*short_a* \* *short_b* / |pi|)) and length(= *long_c*) values, and used as the effective radius for
2974*S(Q)* when *P(Q)* \* *S(Q)* is applied.
[1c03e14]2975
[bf8c07b]2976To provide easy access to the orientation of the parallelepiped, we define the axis of the cylinder using three angles
2977|theta|, |phi| and |bigpsi|. These angles are defined on Figure 2 of the CylinderModel_. The angle |bigpsi| is the
2978rotational angle around the *long_c* axis against the *q* plane. For example, |bigpsi| = 0 when the *short_b* axis is
2979parallel to the *x*-axis of the detector.
[1c03e14]2980
[7f42aad]2981.. image:: img/image090.jpg
[1c03e14]2982
2983*Figure. Definition of angles for 2D*.
2984
[7f42aad]2985.. image:: img/image091.jpg
[1c03e14]2986
[bf8c07b]2987*Figure. Examples of the angles for oriented pp against the detector plane.*
[1c03e14]2988
2989==============  ========  =============
2990Parameter name  Units     Default value
2991==============  ========  =============
2992background      |cm^-1|   0.0
2993contrast        |Ang^-2|  5e-06
2994long_c          |Ang|     400
2995short_a         |Ang^-2|  35
2996short_b         |Ang|     75
2997scale           None      1
2998==============  ========  =============
2999
[7f42aad]3000.. image:: img/image092.jpg
[1c03e14]3001
3002*Figure. 1D plot using the default values (w/1000 data point).*
3003
[bf8c07b]3004*2.1.37.2. Validation of the parallelepiped 2D model*
[1c03e14]3005
[bf8c07b]3006Validation of our code was done by comparing the output of the 1D calculation to the angular average of the output of
3007a 2D calculation over all possible angles. The Figure below shows the comparison where the solid dot refers to averaged
30082D while the line represents the result of the 1D calculation (for the averaging, 76, 180, 76 points are taken for the
3009angles of |theta|, |phi|, and |psi| respectively).
[1c03e14]3010
[7f42aad]3011.. image:: img/image093.gif
[1c03e14]3012
3013*Figure. Comparison between 1D and averaged 2D.*
3014
[bf8c07b]3015Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
3016(Kline, 2006).
[1c03e14]3017
3018REFERENCE
3019
[93b6fcc]3020P Mittelbach and G Porod, *Acta Physica Austriaca*, 14 (1961) 185-211
[1c03e14]3021Equations (1), (13-14). (in German)
3022
3023
3024
3025.. _CSParallelepipedModel:
3026
[77cfcf0]3027**2.1.38. CSParallelepipedModel**
[1c03e14]3028
[bf8c07b]3029Calculates the form factor for a rectangular solid with a core-shell structure. **The thickness and the scattering**
3030**length density of the shell or "rim" can be different on all three (pairs) of faces.**
3031
3032The form factor is normalized by the particle volume *V* such that
[1c03e14]3033
[bf8c07b]3034*P(q)* = *scale* \* <*f*\ :sup:`2`> / *V* + *background*
[1c03e14]3035
[bf8c07b]3036where < > is an average over all possible orientations of the rectangular solid.
[1c03e14]3037
[bf8c07b]3038An instrument resolution smeared version of the model is also provided.
[1c03e14]3039
[bf8c07b]3040*2.1.38.1. Definition*
[1c03e14]3041
[bf8c07b]3042The function calculated is the form factor of the rectangular solid below. The core of the solid is defined by the
3043dimensions *A*, *B*, *C* such that *A* < *B* < *C*.
[1c03e14]3044
[7f42aad]3045.. image:: img/image087.jpg
[1c03e14]3046
[bf8c07b]3047There are rectangular "slabs" of thickness *tA* that add to the *A* dimension (on the *BC* faces). There are similar
3048slabs on the *AC* (= *tB*) and *AB* (= *tC*) faces. The projection in the *AB* plane is then
[1c03e14]3049
[7f42aad]3050.. image:: img/image094.jpg
[1c03e14]3051
[bf8c07b]3052The volume of the solid is
[1c03e14]3053
[bf8c07b]3054.. image:: img/image095.PNG
[1c03e14]3055
[bf8c07b]3056**meaning that there are "gaps" at the corners of the solid.**
[1c03e14]3057
[bf8c07b]3058The intensity calculated follows the ParallelepipedModel_, with the core-shell intensity being calculated as the
3059square of the sum of the amplitudes of the core and shell, in the same manner as a CoreShellModel_.
[1c03e14]3060
[bf8c07b]3061**For the calculation of the form factor to be valid, the sides of the solid MUST be chosen such that** *A* < *B* < *C*.
3062**If this inequality is not satisfied, the model will not report an error, and the calculation will not be correct.**
[1c03e14]3063
[bf8c07b]3064FITTING NOTES
3065If the scale is set equal to the particle volume fraction, |phi|, the returned value is the scattered intensity per
3066unit volume; ie, *I(q)* = |phi| *P(q)*\ . However, **no interparticle interference effects are included in this**
3067**calculation.**
[1c03e14]3068
[bf8c07b]3069There are many parameters in this model. Hold as many fixed as possible with known values, or you will certainly end
3070up at a solution that is unphysical.
[1c03e14]3071
[bf8c07b]3072Constraints must be applied during fitting to ensure that the inequality *A* < *B* < *C* is not violated. The
3073calculation will not report an error, but the results will not be correct.
[1c03e14]3074
3075The returned value is in units of |cm^-1|, on absolute scale.
3076
[bf8c07b]3077NB: The 2nd virial coefficient of the CSParallelpiped is calculated based on the the averaged effective radius
3078(= sqrt((*short_a* + 2 *rim_a*) \* (*short_b* + 2 *rim_b*) / |pi|)) and length(= *long_c* + 2 *rim_c*) values, and
3079used as the effective radius for *S(Q)* when *P(Q)* \* *S(Q)* is applied.
[1c03e14]3080
[bf8c07b]3081To provide easy access to the orientation of the parallelepiped, we define the axis of the cylinder using three angles
3082|theta|, |phi| and |bigpsi|. These angles are defined on Figure 2 of the CylinderModel_. The angle |bigpsi| is the
3083rotational angle around the *long_c* axis against the *q* plane. For example, |bigpsi| = 0 when the *short_b* axis is
3084parallel to the *x*-axis of the detector.
[1c03e14]3085
[7f42aad]3086.. image:: img/image090.jpg
[1c03e14]3087
3088*Figure. Definition of angles for 2D*.
3089
[7f42aad]3090.. image:: img/image091.jpg
[1c03e14]3091
[bf8c07b]3092*Figure. Examples of the angles for oriented cspp against the detector plane.*
[1c03e14]3093
[bf8c07b]3094This example dataset was produced by running the Macro Plot_CSParallelepiped(), using 100 data points,
3095*qmin* = 0.001 |Ang^-1|, *qmax* = 0.7 |Ang^-1| and the default values
[1c03e14]3096
3097==============  ========  =============
3098Parameter name  Units     Default value
3099==============  ========  =============
3100background      |cm^-1|   0.06
3101sld_pcore       |Ang^-2|  1e-06
3102sld_rimA        |Ang^-2|  2e-06
3103sld_rimB        |Ang^-2|  4e-06
3104sld_rimC        |Ang^-2|  2e-06
3105sld_solv        |Ang^-2|  6e-06
3106rimA            |Ang|     10
3107rimB            |Ang|     10
3108rimC            |Ang|     10
3109longC           |Ang|     400
3110shortA          |Ang|     35
3111midB            |Ang|     75
3112scale           None      1
3113==============  ========  =============
3114
[7f42aad]3115.. image:: img/image096.jpg
[1c03e14]3116
3117*Figure. 1D plot using the default values (w/256 data points).*
3118
[7f42aad]3119.. image:: img/image097.jpg
[1c03e14]3120
[bf8c07b]3121*Figure. 2D plot using the default values (w/(256X265) data points).*
[1c03e14]3122
[bf8c07b]3123Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
3124(Kline, 2006).
[1c03e14]3125
3126REFERENCE
3127
[93b6fcc]3128P Mittelbach and G Porod, *Acta Physica Austriaca*, 14 (1961) 185-211
[bf8c07b]3129Equations (1), (13-14). (in German)
[1c03e14]3130
3131
3132
[6386cd8]3133.. _RectangularPrismModel:
3134
3135**2.1.39. RectangularPrismModel**
3136
3137This model provides the form factor, *P(q)*, for a rectangular prism.
3138
3139Note that this model is almost totally equivalent to the existing ParallelepipedModel_. The only difference is that the
3140way the relevant parameters are defined here (*a*, *b/a*, *c/a* instead of *a*, *b*, *c*) allows to use polydispersity
3141with this model while keeping the shape of the prism (e.g. setting *b/a* = 1 and *c/a* = 1 and applying polydispersity
3142to *a* will generate a distribution of cubes of different sizes).
3143
3144*2.1.39.1. Definition*
3145
3146The 1D scattering intensity for this model was calculated by Mittelbach and Porod (Mittelbach, 1961), but the
3147implementation here is closer to the equations given by Nayuk and Huber (Nayuk, 2012).
3148
3149The scattering from a massive parallelepiped with an orientation with respect to the scattering vector given by |theta|
3150and |phi| is given by
3151
3152.. math::
3153  A_P\,(q) =  \frac{\sin \bigl( q \frac{C}{2} \cos\theta \bigr)}{q \frac{C}{2} \cos\theta} \, \times \,
3154  \frac{\sin \bigl( q \frac{A}{2} \sin\theta \sin\phi \bigr)}{q \frac{A}{2} \sin\theta \sin\phi} \, \times \,
3155  \frac{\sin \bigl( q \frac{B}{2} \sin\theta \cos\phi \bigr)}{q \frac{B}{2} \sin\theta \cos\phi}
3156
3157where *A*, *B* and *C* are the sides of the parallelepiped and must fulfill :math:`A \le B \le C`, |theta| is the angle
3158between the *z* axis and the longest axis of the parallelepiped *C*, and |phi| is the angle between the scattering
3159vector (lying in the *xy* plane) and the *y* axis.
3160
3161The normalized form factor in 1D is obtained averaging over all possible orientations
3162
3163.. math::
3164  P(q) =  \frac{2}{\pi} \times \, \int_0^{\frac{\pi}{2}} \, \int_0^{\frac{\pi}{2}} A_P^2(q) \, \sin\theta \, d\theta \, d\phi
3165
3166The 1D scattering intensity is then calculated as
3167
3168.. math::
3169  I(q) = \mbox{scale} \times V \times (\rho_{\mbox{pipe}} - \rho_{\mbox{solvent}})^2 \times P(q)
3170
3171where *V* is the volume of the rectangular prism, :math:`\rho_{\mbox{pipe}}` is the scattering length of the
3172parallelepiped, :math:`\rho_{\mbox{solvent}}` is the scattering length of the solvent, and (if the data are in absolute
3173units) *scale* represents the volume fraction (which is unitless).
3174
3175**The 2D scattering intensity is not computed by this model.**
3176
3177The returned value is scaled to units of |cm^-1| and the parameters of the RectangularPrismModel are the following
3178
3179==============  ========  =============
3180Parameter name  Units     Default value
3181==============  ========  =============
3182scale           None      1
3183short_side      |Ang|     35
3184b2a_ratio       None      1
3185c2a_ratio       None      1
3186sldPipe         |Ang^-2|  6.3e-6
3187sldSolv         |Ang^-2|  1.0e-6
3188background      |cm^-1|   0
3189==============  ========  =============
3190
3191*2.1.39.2. Validation of the RectangularPrismModel*
3192
3193Validation of the code was conducted by comparing the output of the 1D model to the output of the existing
3194parallelepiped model.
3195
3196REFERENCES
3197
3198P Mittelbach and G Porod, *Acta Physica Austriaca*, 14 (1961) 185-211
3199
3200R Nayuk and K Huber, *Z. Phys. Chem.*, 226 (2012) 837-854
3201
3202
3203
3204.. _RectangularHollowPrismModel:
3205
3206**2.1.40. RectangularHollowPrismModel**
3207
3208This model provides the form factor, *P(q)*, for a hollow rectangular parallelepiped with a wall thickness |bigdelta|.
3209
3210*2.1.40.1. Definition*
3211
3212The 1D scattering intensity for this model is calculated by forming the difference of the amplitudes of two massive
3213parallelepipeds differing in their outermost dimensions in each direction by the same length increment 2 |bigdelta|
3214(Nayuk, 2012).
3215
3216As in the case of the massive parallelepiped, the scattering amplitude is computed for a particular orientation of the
3217parallelepiped with respect to the scattering vector and then averaged over all possible orientations, giving
3218
3219.. math::
3220  P(q) =  \frac{1}{V^2} \frac{2}{\pi} \times \, \int_0^{\frac{\pi}{2}} \, \int_0^{\frac{\pi}{2}} A_{P\Delta}^2(q) \,
3221  \sin\theta \, d\theta \, d\phi
3222
3223where |theta| is the angle between the *z* axis and the longest axis of the parallelepiped, |phi| is the angle between
3224the scattering vector (lying in the *xy* plane) and the *y* axis, and
3225
3226.. math::
3227  A_{P\Delta}\,(q) =  A \, B \, C \, \times
3228                      \frac{\sin \bigl( q \frac{C}{2} \cos\theta \bigr)}{q \frac{C}{2} \cos\theta} \,
3229                      \frac{\sin \bigl( q \frac{A}{2} \sin\theta \sin\phi \bigr)}{q \frac{A}{2} \sin\theta \sin\phi} \,
3230                      \frac{\sin \bigl( q \frac{B}{2} \sin\theta \cos\phi \bigr)}{q \frac{B}{2} \sin\theta \cos\phi} -
3231                      8 \, \bigl( \frac{A}{2} - \Delta \bigr) \, \bigl( \frac{B}{2} - \Delta \bigr) \,
3232                      \bigl( \frac{C}{2} - \Delta \bigr) \, \times
3233                      \frac{\sin \bigl[ q \bigl(\frac{C}{2}-\Delta\bigr) \cos\theta \bigr]}
3234                      {q \bigl(\frac{C}{2}-\Delta\bigr) \cos\theta} \,
3235                      \frac{\sin \bigl[ q \bigl(\frac{A}{2}-\Delta\bigr) \sin\theta \sin\phi \bigr]}
3236                      {q \bigl(\frac{A}{2}-\Delta\bigr) \sin\theta \sin\phi} \,
3237                      \frac{\sin \bigl[ q \bigl(\frac{B}{2}-\Delta\bigr) \sin\theta \cos\phi \bigr]}
3238                      {q \bigl(\frac{B}{2}-\Delta\bigr) \sin\theta \cos\phi} \,
3239
3240where *A*, *B* and *C* are the external sides of the parallelepiped fulfilling :math:`A \le B \le C`, and the volume *V*
3241of the parallelepiped is
3242
3243.. math::
3244  V = A B C \, - \, (A - 2\Delta) (B - 2\Delta) (C - 2\Delta)
3245
3246The 1D scattering intensity is then calculated as
3247
3248.. math::
3249  I(q) = \mbox{scale} \times V \times (\rho_{\mbox{pipe}} - \rho_{\mbox{solvent}})^2 \times P(q)
3250
3251where :math:`\rho_{\mbox{pipe}}` is the scattering length of the parallelepiped, :math:`\rho_{\mbox{solvent}}` is the
3252scattering length of the solvent, and (if the data are in absolute units) *scale* represents the volume fraction (which
3253is unitless).
3254
3255**The 2D scattering intensity is not computed by this model.**
3256
3257The returned value is scaled to units of |cm^-1| and the parameters of the RectangularHollowPrismModel are the
3258following
3259
3260==============  ========  =============
3261Parameter name  Units     Default value
3262==============  ========  =============
3263scale           None      1
3264short_side      |Ang|     35
3265b2a_ratio       None      1
3266c2a_ratio       None      1
3267thickness       |Ang|     1
3268sldPipe         |Ang^-2|  6.3e-6
3269sldSolv         |Ang^-2|  1.0e-6
3270background      |cm^-1|   0
3271==============  ========  =============
3272
3273*2.1.40.2. Validation of the RectangularHollowPrismModel*
3274
3275Validation of the code was conducted by qualitatively comparing the output of the 1D model to the curves shown in
3276(Nayuk, 2012).
3277
3278REFERENCES
3279
3280R Nayuk and K Huber, *Z. Phys. Chem.*, 226 (2012) 837-854
3281
3282
3283
3284.. _RectangularHollowPrismInfThinWallsModel:
3285
3286**2.1.41. RectangularHollowPrismInfThinWallsModel**
3287
3288This model provides the form factor, *P(q)*, for a hollow rectangular prism with infinitely thin walls.
3289
3290*2.1.41.1. Definition*
3291
3292The 1D scattering intensity for this model is calculated according to the equations given by Nayuk and Huber
3293(Nayuk, 2012).
3294
3295Assuming a hollow parallelepiped with infinitely thin walls, edge lengths :math:`A \le B \le C` and presenting an
3296orientation with respect to the scattering vector given by |theta| and |phi|, where |theta| is the angle between the
3297*z* axis and the longest axis of the parallelepiped *C*, and |phi| is the angle between the scattering vector
3298(lying in the *xy* plane) and the *y* axis, the form factor is given by
3299
3300.. math::
3301  P(q) =  \frac{1}{V^2} \frac{2}{\pi} \times \, \int_0^{\frac{\pi}{2}} \, \int_0^{\frac{\pi}{2}} [A_L(q)+A_T(q)]^2
3302  \, \sin\theta \, d\theta \, d\phi
3303
3304where
3305
3306.. math::
3307  V = 2AB + 2AC + 2BC
3308
3309.. math::
3310  A_L\,(q) =  8 \times \frac{ \sin \bigl( q \frac{A}{2} \sin\phi \sin\theta \bigr)
3311                              \sin \bigl( q \frac{B}{2} \cos\phi \sin\theta \bigr)
3312                              \cos \bigl( q \frac{C}{2} \cos\theta \bigr) }
3313                            {q^2 \, \sin^2\theta \, \sin\phi \cos\phi}
3314
3315.. math::
3316  A_T\,(q) =  A_F\,(q) \times \frac{2 \, \sin \bigl( q \frac{C}{2} \cos\theta \bigr)}{q \, \cos\theta}
3317
3318and
3319
3320.. math::
3321  A_F\,(q) =  4 \frac{ \cos \bigl( q \frac{A}{2} \sin\phi \sin\theta \bigr)
3322                       \sin \bigl( q \frac{B}{2} \cos\phi \sin\theta \bigr) }
3323                     {q \, \cos\phi \, \sin\theta} +
3324              4 \frac{ \sin \bigl( q \frac{A}{2} \sin\phi \sin\theta \bigr)
3325                       \cos \bigl( q \frac{B}{2} \cos\phi \sin\theta \bigr) }
3326                     {q \, \sin\phi \, \sin\theta}
3327
3328The 1D scattering intensity is then calculated as
3329
3330.. math::
3331  I(q) = \mbox{scale} \times V \times (\rho_{\mbox{pipe}} - \rho_{\mbox{solvent}})^2 \times P(q)
3332
3333where *V* is the volume of the rectangular prism, :math:`\rho_{\mbox{pipe}}` is the scattering length of the
3334parallelepiped, :math:`\rho_{\mbox{solvent}}` is the scattering length of the solvent, and (if the data are in absolute
3335units) *scale* represents the volume fraction (which is unitless).
3336
3337**The 2D scattering intensity is not computed by this model.**
3338
3339The returned value is scaled to units of |cm^-1| and the parameters of the RectangularHollowPrismInfThinWallModel
3340are the following
3341
3342==============  ========  =============
3343Parameter name  Units     Default value
3344==============  ========  =============
3345scale           None      1
3346short_side      |Ang|     35
3347b2a_ratio       None      1
3348c2a_ratio       None      1
3349sldPipe         |Ang^-2|  6.3e-6
3350sldSolv         |Ang^-2|  1.0e-6
3351background      |cm^-1|   0
3352==============  ========  =============
3353
3354*2.1.41.2. Validation of the RectangularHollowPrismInfThinWallsModel*
3355
3356Validation of the code was conducted  by qualitatively comparing the output of the 1D model to the curves shown in
3357(Nayuk, 2012).
3358
3359REFERENCES
3360
3361R Nayuk and K Huber, *Z. Phys. Chem.*, 226 (2012) 837-854
3362
3363
3364
[7072ce6]3365.. _MicelleSphCoreModel:
3366
3367**2.1.42. MicelleSphCoreModel**
3368
3369This model provides the form factor, *P(q)*, for a micelle with a spherical core
3370and Gaussian polymer chains attached to the surface.
3371
3372*2.1.42.1. Definition*
3373
3374The 1D scattering intensity for this model is calculated according to the equations given by Pedersen
3375(Pedersen, 2000).
3376
3377*2.1.42.2. Validation of the MicelleSphCoreModel*
3378
3379This model has not yet been validated. Feb2015
3380
3381REFERENCES
3382
3383J Pedersen, *J. Appl. Cryst.*, 33 (2000) 637-640
3384
3385
3386
[1c03e14]33872.2 Shape-independent Functions
3388-------------------------------
3389
[6386cd8]3390The following are models used for shape-independent SAS analysis.
[1c03e14]3391
[4ed2d0a1]3392.. _Debye:
[1c03e14]3393
[58eccf6]3394**2.2.1. Debye (Gaussian Coil Model)**
[1c03e14]3395
[6386cd8]3396The Debye model is a form factor for a linear polymer chain obeying Gaussian statistics (ie, it is in the theta state).
3397In addition to the radius-of-gyration, *Rg*, a scale factor *scale*, and a constant background term are included in the
3398calculation. **NB: No size polydispersity is included in this model, use the** Poly_GaussCoil_ **Model instead**
[1c03e14]3399
[4ed2d0a1]3400.. image:: img/image172.PNG
[1c03e14]3401
[93b6fcc]3402For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3403
[7f42aad]3404.. image:: img/image040.gif
[1c03e14]3405
[4ed2d0a1]3406==============  ========  =============
3407Parameter name  Units     Default value
3408==============  ========  =============
[58eccf6]3409scale           None      1.0
3410rg              |Ang|     50.0
3411background      |cm^-1|   0.0
[4ed2d0a1]3412==============  ========  =============
[1c03e14]3413
[7f42aad]3414.. image:: img/image173.jpg
[1c03e14]3415
[4ed2d0a1]3416*Figure. 1D plot using the default values (w/200 data point).*
[1c03e14]3417
[4ed2d0a1]3418REFERENCE
[1c03e14]3419
[93b6fcc]3420R J Roe, *Methods of X-Ray and Neutron Scattering in Polymer Science*, Oxford University Press, New York (2000)
[1c03e14]3421
3422
3423
[4ed2d0a1]3424.. _BroadPeakModel:
[1c03e14]3425
[58eccf6]3426**2.2.2. BroadPeakModel**
[1c03e14]3427
[6386cd8]3428This model calculates an empirical functional form for SAS data characterized by a broad scattering peak. Many SAS
[93b6fcc]3429spectra are characterized by a broad peak even though they are from amorphous soft materials. For example, soft systems
[6386cd8]3430that show a SAS peak include copolymers, polyelectrolytes, multiphase systems, layered structures, etc.
[93b6fcc]3431
3432The d-spacing corresponding to the broad peak is a characteristic distance between the scattering inhomogeneities (such
3433as in lamellar, cylindrical, or spherical morphologies, or for bicontinuous structures).
[1c03e14]3434
[4ed2d0a1]3435The returned value is scaled to units of |cm^-1|, absolute scale.
[1c03e14]3436
[93b6fcc]3437*2.2.2.1. Definition*
3438
3439The scattering intensity *I(q)* is calculated as
[1c03e14]3440
[7f42aad]3441.. image:: img/image174.jpg
[1c03e14]3442
[93b6fcc]3443Here the peak position is related to the d-spacing as *Q0* = 2|pi| / *d0*.
[1c03e14]3444
[93b6fcc]3445For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3446
[7f42aad]3447.. image:: img/image040.gif
[1c03e14]3448
[93b6fcc]3449==================  ========  =============
3450Parameter name      Units     Default value
3451==================  ========  =============
3452scale_l    (=C)     None      10
3453scale_p    (=A)     None      1e-05
3454length_l (= |xi| )  |Ang|     50
3455q_peak    (=Q0)     |Ang^-1|  0.1
3456exponent_p (=n)     None      2
3457exponent_l (=m)     None      3
3458Background (=B)     |cm^-1|   0.1
3459==================  ========  =============
[1c03e14]3460
[7f42aad]3461.. image:: img/image175.jpg
[1c03e14]3462
[4ed2d0a1]3463*Figure. 1D plot using the default values (w/200 data point).*
[1c03e14]3464
[4ed2d0a1]3465REFERENCE
[1c03e14]3466
[4ed2d0a1]3467None.
[1c03e14]3468
[93b6fcc]3469*2013/09/09 - Description reviewed by King, S and Parker, P.*
[1c03e14]3470
3471
3472
[4ed2d0a1]3473.. _CorrLength:
[1c03e14]3474
[58eccf6]3475**2.2.3. CorrLength (Correlation Length Model)**
[1c03e14]3476
[6386cd8]3477Calculates an empirical functional form for SAS data characterized by a low-Q signal and a high-Q signal.
[1c03e14]3478
[4ed2d0a1]3479The returned value is scaled to units of |cm^-1|, absolute scale.
[1c03e14]3480
[93b6fcc]3481*2.2.3. Definition*
3482
3483The scattering intensity *I(q)* is calculated as
[1c03e14]3484
[7f42aad]3485.. image:: img/image176.jpg
[1c03e14]3486
[93b6fcc]3487The first term describes Porod scattering from clusters (exponent = n) and the second term is a Lorentzian function
3488describing scattering from polymer chains (exponent = *m*). This second term characterizes the polymer/solvent
3489interactions and therefore the thermodynamics. The two multiplicative factors *A* and *C*, the incoherent
3490background *B* and the two exponents *n* and *m* are used as fitting parameters. The final parameter |xi| is a
3491correlation length for the polymer chains. Note that when *m*\ =2 this functional form becomes the familiar Lorentzian
3492function. 
[1c03e14]3493
[93b6fcc]3494For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3495
[7f42aad]3496.. image:: img/image040.gif
[1c03e14]3497
[93b6fcc]3498====================  ========  =============
3499Parameter name        Units     Default value
3500====================  ========  =============
3501scale_l    (=C)       None      10
3502scale_p    (=A)       None      1e-06
3503length_l   (= |xi| )  |Ang|     50
3504exponent_p (=n)       None      2
3505exponent_l (=m)       None      3
3506Background (=B)       |cm^-1|   0.1
3507====================  ========  =============
[1c03e14]3508
[7f42aad]3509.. image:: img/image177.jpg
[1c03e14]3510
[4ed2d0a1]3511*Figure. 1D plot using the default values (w/500 data points).*
[1c03e14]3512
[4ed2d0a1]3513REFERENCE
[1c03e14]3514
[93b6fcc]3515B Hammouda, D L Ho and S R Kline, *Insight into Clustering in Poly(ethylene oxide) Solutions*, *Macromolecules*, 37
3516(2004) 6932-6937
[1c03e14]3517
[93b6fcc]3518*2013/09/09 - Description reviewed by King, S and Parker, P.*
[1c03e14]3519
3520
3521
[4ed2d0a1]3522.. _Lorentz:
[1c03e14]3523
[58eccf6]3524**2.2.4. Lorentz (Ornstein-Zernicke Model)**
[1c03e14]3525
[93b6fcc]3526*2.2.4.1. Definition*
3527
3528The Ornstein-Zernicke model is defined by
[1c03e14]3529
[4ed2d0a1]3530.. image:: img/image178.PNG
[1c03e14]3531
[93b6fcc]3532The parameter *L* is the screening length.
[1c03e14]3533
[93b6fcc]3534For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3535
[7f42aad]3536.. image:: img/image040.gif
[bf8c07b]3537
[4ed2d0a1]3538==============  ========  =============
3539Parameter name  Units     Default value
3540==============  ========  =============
[58eccf6]3541scale           None      1.0
3542length          |Ang|     50.0
3543background      |cm^-1|   0.0
[4ed2d0a1]3544==============  ========  =============
[1c03e14]3545
[7f42aad]3546.. image:: img/image179.jpg
[1c03e14]3547
[93b6fcc]3548* Figure. 1D plot using the default values (w/200 data point).*
3549
3550REFERENCE
3551
3552None.
[1c03e14]3553
3554
3555
[4ed2d0a1]3556.. _DABModel:
[1c03e14]3557
[58eccf6]3558**2.2.5. DABModel (Debye-Anderson-Brumberger Model)**
[1c03e14]3559
[93b6fcc]3560Calculates the scattering from a randomly distributed, two-phase system based on the Debye-Anderson-Brumberger (DAB)
3561model for such systems. The two-phase system is characterized by a single length scale, the correlation length, which
3562is a measure of the average spacing between regions of phase 1 and phase 2. **The model also assumes smooth interfaces**
3563**between the phases** and hence exhibits Porod behavior (I ~ *q*\ :sup:`-4`) at large *q* (*QL* >> 1).
3564
3565The DAB model is ostensibly a development of the earlier Debye-Bueche model.
3566
3567*2.2.5.1. Definition*
[1c03e14]3568
[916501b]3569.. image:: img/image180_corrected.PNG
[1c03e14]3570
[93b6fcc]3571The parameter *L* is the correlation length.
[1c03e14]3572
[93b6fcc]3573For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3574
[7f42aad]3575.. image:: img/image040.gif
[1c03e14]3576
[4ed2d0a1]3577==============  ========  =============
3578Parameter name  Units     Default value
3579==============  ========  =============
[58eccf6]3580scale           None      1.0
3581length          |Ang|     50.0
3582background      |cm^-1|   0.0
[4ed2d0a1]3583==============  ========  =============
[1c03e14]3584
[7f42aad]3585.. image:: img/image181.jpg
[1c03e14]3586
[93b6fcc]3587* Figure. 1D plot using the default values (w/200 data point).*
[1c03e14]3588
[4ed2d0a1]3589REFERENCE
[1c03e14]3590
[93b6fcc]3591P Debye, H R Anderson, H Brumberger, *Scattering by an Inhomogeneous Solid. II. The Correlation Function*
3592*and its Application*, *J. Appl. Phys.*, 28(6) (1957) 679
[1c03e14]3593
[93b6fcc]3594P Debye, A M Bueche, *Scattering by an Inhomogeneous Solid*, *J. Appl. Phys.*, 20 (1949) 518
[1c03e14]3595
[93b6fcc]3596*2013/09/09 - Description reviewed by King, S and Parker, P.*
[1c03e14]3597
3598
3599
[4ed2d0a1]3600.. _AbsolutePower_Law:
[1c03e14]3601
[58eccf6]3602**2.2.6. AbsolutePower_Law**
[1c03e14]3603
[93b6fcc]3604This model describes a simple power law with background.
[1c03e14]3605
[4ed2d0a1]3606.. image:: img/image182.PNG
[1c03e14]3607
[93b6fcc]3608Note the minus sign in front of the exponent. The parameter *m* should therefore be entered as a **positive** number.
[1c03e14]3609
[4ed2d0a1]3610==============  ========  =============
3611Parameter name  Units     Default value
3612==============  ========  =============
[58eccf6]3613Scale           None      1.0
3614m               None      4
3615Background      |cm^-1|   0.0
[4ed2d0a1]3616==============  ========  =============
[1c03e14]3617
[7f42aad]3618.. image:: img/image183.jpg
[1c03e14]3619
[4ed2d0a1]3620*Figure. 1D plot using the default values (w/200 data point).*
[1c03e14]3621
[93b6fcc]3622REFERENCE
3623
3624None.
3625
[1c03e14]3626
3627
[93b6fcc]3628.. _TeubnerStrey:
[1c03e14]3629
[93b6fcc]3630**2.2.7. TeubnerStrey (Model)**
[1c03e14]3631
[93b6fcc]3632This function calculates the scattered intensity of a two-component system using the Teubner-Strey model. Unlike the
3633DABModel_ this function generates a peak.
3634
3635*2.2.7.1. Definition*
[1c03e14]3636
[4ed2d0a1]3637.. image:: img/image184.PNG
[1c03e14]3638
[93b6fcc]3639For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3640
[7f42aad]3641.. image:: img/image040.gif
[1c03e14]3642
[4ed2d0a1]3643==============  ========  =============
3644Parameter name  Units     Default value
3645==============  ========  =============
[58eccf6]3646scale           None      0.1
3647c1              None      -30.0
3648c2              None      5000.0
3649background      |cm^-1|   0.0
[4ed2d0a1]3650==============  ========  =============
[1c03e14]3651
[7f42aad]3652.. image:: img/image185.jpg
[1c03e14]3653
[4ed2d0a1]3654*Figure. 1D plot using the default values (w/200 data point).*
[1c03e14]3655
[4ed2d0a1]3656REFERENCE
[1c03e14]3657
[93b6fcc]3658M Teubner, R Strey, *J. Chem. Phys.*, 87 (1987) 3195
[1c03e14]3659
[93b6fcc]3660K V Schubert, R Strey, S R Kline and E W Kaler, *J. Chem. Phys.*, 101 (1994) 5343
[1c03e14]3661
3662
3663
[4ed2d0a1]3664.. _FractalModel:
[1c03e14]3665
[58eccf6]3666**2.2.8. FractalModel**
[1c03e14]3667
[93b6fcc]3668Calculates the scattering from fractal-like aggregates built from spherical building blocks following the Texiera
3669reference.
3670
3671The value returned is in |cm^-1|\ .
3672
3673*2.2.8.1. Definition*
[1c03e14]3674
[4ed2d0a1]3675.. image:: img/image186.PNG
[1c03e14]3676
[93b6fcc]3677The *scale* parameter is the volume fraction of the building blocks, *R0* is the radius of the building block, *Df* is
3678the fractal dimension, |xi| is the correlation length, |rho|\ *solvent* is the scattering length density of the
3679solvent, and |rho|\ *block* is the scattering length density of the building blocks.
[1c03e14]3680
[93b6fcc]3681**Polydispersity on the radius is provided for.**
[1c03e14]3682
[93b6fcc]3683For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3684
[7f42aad]3685.. image:: img/image040.gif
[1c03e14]3686
[4ed2d0a1]3687==============  ========  =============
3688Parameter name  Units     Default value
3689==============  ========  =============
[58eccf6]3690scale           None      0.05
3691radius          |Ang|     5.0
3692fractal_dim     None      2
3693corr_length     |Ang|     100.0
3694block_sld       |Ang^-2|  2e-6
3695solvent_sld     |Ang^-2|  6e-6
3696background      |cm^-1|   0.0
[4ed2d0a1]3697==============  ========  =============
[1c03e14]3698
[7f42aad]3699.. image:: img/image187.jpg
[1c03e14]3700
3701*Figure. 1D plot using the default values (w/200 data point).*
3702
[4ed2d0a1]3703REFERENCE
[1c03e14]3704
[93b6fcc]3705J Teixeira, *J. Appl. Cryst.*, 21 (1988) 781-785
[1c03e14]3706
3707
3708
[4ed2d0a1]3709.. _MassFractalModel:
[1c03e14]3710
[4ed2d0a1]3711**2.2.9. MassFractalModel**
[1c03e14]3712
[93b6fcc]3713Calculates the scattering from fractal-like aggregates based on the Mildner reference.
3714
3715*2.2.9.1. Definition*
[1c03e14]3716
[7f42aad]3717.. image:: img/mass_fractal_eq1.jpg
[1c03e14]3718
[93b6fcc]3719where *R* is the radius of the building block, *Dm* is the **mass** fractal dimension, |zeta| is the cut-off length,
3720|rho|\ *solvent* is the scattering length density of the solvent, and |rho|\ *particle* is the scattering length
3721density of particles.
[1c03e14]3722
[93b6fcc]3723Note:  The mass fractal dimension *Dm* is only valid if 1 < mass_dim < 6. It is also only valid over a limited
3724*q* range (see the reference for details).
[1c03e14]3725
[4ed2d0a1]3726==============  ========  =============
3727Parameter name  Units     Default value
3728==============  ========  =============
[58eccf6]3729scale           None      1
3730radius          |Ang|     10.0
3731mass_dim        None      1.9
3732co_length       |Ang|     100.0
3733background      |cm^-1|   0.0
[4ed2d0a1]3734==============  ========  =============
[1c03e14]3735
[7f42aad]3736.. image:: img/mass_fractal_fig1.jpg
[1c03e14]3737
[93b6fcc]3738*Figure. 1D plot using default values.*
[1c03e14]3739
[4ed2d0a1]3740REFERENCE
[1c03e14]3741
[93b6fcc]3742D Mildner and P Hall, *J. Phys. D: Appl. Phys.*,  19 (1986) 1535-1545
3743Equation(9)
[1c03e14]3744
[93b6fcc]3745*2013/09/09 - Description reviewed by King, S and Parker, P.*
[1c03e14]3746
3747
3748
[4ed2d0a1]3749.. _SurfaceFractalModel:
[1c03e14]3750
[4ed2d0a1]3751**2.2.10. SurfaceFractalModel**
[1c03e14]3752
[93b6fcc]3753Calculates the scattering from fractal-like aggregates based on the Mildner reference.
3754
3755*2.2.10.1. Definition*
[1c03e14]3756
[f8063bf]3757.. image:: img/surface_fractal_eq1.gif
[1c03e14]3758
[93b6fcc]3759where *R* is the radius of the building block, *Ds* is the **surface** fractal dimension, |zeta| is the cut-off length,
3760|rho|\ *solvent* is the scattering length density of the solvent, and |rho|\ *particle* is the scattering length
3761density of particles.
[1c03e14]3762
[93b6fcc]3763Note:  The surface fractal dimension *Ds* is only valid if 1 < surface_dim < 3. It is also only valid over a limited
3764*q* range (see the reference for details).
[1c03e14]3765
[4ed2d0a1]3766==============  ========  =============
3767Parameter name  Units     Default value
3768==============  ========  =============
[58eccf6]3769scale           None      1
3770radius          |Ang|     10.0
3771surface_dim     None      2.0
3772co_length       |Ang|     500.0
3773background      |cm^-1|   0.0
[4ed2d0a1]3774==============  ========  =============
[1c03e14]3775
[7f42aad]3776.. image:: img/surface_fractal_fig1.jpg
[1c03e14]3777
[93b6fcc]3778*Figure. 1D plot using default values.*
[1c03e14]3779
[4ed2d0a1]3780REFERENCE
[1c03e14]3781
[93b6fcc]3782D Mildner and P Hall, *J. Phys. D: Appl. Phys.*,  19 (1986) 1535-1545
3783Equation(13)
[1c03e14]3784
3785
3786
[4ed2d0a1]3787.. _MassSurfaceFractal:
[1c03e14]3788
[58eccf6]3789**2.2.11. MassSurfaceFractal (Model)**
[1c03e14]3790
[93b6fcc]3791A number of natural and commercial processes form high-surface area materials as a result of the vapour-phase
3792aggregation of primary particles. Examples of such materials include soots, aerosols, and fume or pyrogenic silicas.
3793These are all characterised by cluster mass distributions (sometimes also cluster size distributions) and internal
3794surfaces that are fractal in nature. The scattering from such materials displays two distinct breaks in log-log
3795representation, corresponding to the radius-of-gyration of the primary particles, *rg*, and the radius-of-gyration of
3796the clusters (aggregates), *Rg*. Between these boundaries the scattering follows a power law related to the mass
3797fractal dimension, *Dm*, whilst above the high-Q boundary the scattering follows a power law related to the surface
3798fractal dimension of the primary particles, *Ds*.
3799
3800*2.2.11.1. Definition*
3801
3802The scattered intensity *I(q)* is  calculated using a modified Ornstein-Zernicke equation
[1c03e14]3803
[f8063bf]3804.. image:: img/masssurface_fractal_eq1.jpg
[1c03e14]3805
[93b6fcc]3806where *Rg* is the size of the cluster, *rg* is the size of the primary particle, *Ds* is the surface fractal dimension,
3807*Dm* is the mass fractal dimension, |rho|\ *solvent* is the scattering length density of the solvent, and |rho|\ *p* is
3808the scattering length density of particles.
[1c03e14]3809
[93b6fcc]3810Note:  The surface (*Ds*) and mass (*Dm*) fractal dimensions are only valid if 0 < *surface_dim* < 6,
38110 < *mass_dim* < 6, and (*surface_dim*+*mass_dim*) < 6. 
[1c03e14]3812
[4ed2d0a1]3813==============  ========  =============
3814Parameter name  Units     Default value
3815==============  ========  =============
[58eccf6]3816scale           None      1
3817primary_rg      |Ang|     4000.0
3818cluster_rg      |Ang|     86.7
3819surface_dim     None      2.3
3820mass_dim        None      1.8
3821background      |cm^-1|   0.0
[4ed2d0a1]3822==============  ========  =============
[1c03e14]3823
[7f42aad]3824.. image:: img/masssurface_fractal_fig1.jpg
[1c03e14]3825
[93b6fcc]3826*Figure. 1D plot using default values.*
[1c03e14]3827
[4ed2d0a1]3828REFERENCE
[1c03e14]3829
[93b6fcc]3830P Schmidt, *J Appl. Cryst.*, 24 (1991) 414-435
3831Equation(19)
[1c03e14]3832
[93b6fcc]3833A J Hurd, D W Schaefer, J E Martin, *Phys. Rev. A*, 35 (1987) 2361-2364
3834Equation(2)
[1c03e14]3835
3836
3837
[4ed2d0a1]3838.. _FractalCoreShell:
[1c03e14]3839
[58eccf6]3840**2.2.12. FractalCoreShell (Model)**
[1c03e14]3841
[93b6fcc]3842Calculates the scattering from a fractal structure with a primary building block of core-shell spheres, as opposed to
3843just homogeneous spheres in the FractalModel_. This model could find use for aggregates of coated particles, or
3844aggregates of vesicles.
3845
3846The returned value is scaled to units of |cm^-1|, absolute scale.
3847
3848*2.2.12.1. Definition*
[1c03e14]3849
[7f42aad]3850.. image:: img/fractcore_eq1.gif
[1c03e14]3851
[93b6fcc]3852The form factor *P(q)* is that from CoreShellModel_ with *bkg* = 0
[1c03e14]3853
[4ed2d0a1]3854.. image:: img/image013.PNG
[1c03e14]3855
[93b6fcc]3856while the fractal structure factor S(q) is
[1c03e14]3857
[4ed2d0a1]3858.. image:: img/fractcore_eq3.gif
[1c03e14]3859
[93b6fcc]3860where *Df* = frac_dim, |xi| = cor_length, *rc* = (core) radius, and *scale* = volume fraction.
[1c03e14]3861
[93b6fcc]3862The fractal structure is as documented in the FractalModel_. Polydispersity of radius and thickness is provided for.
[1c03e14]3863
[93b6fcc]3864For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3865
[7f42aad]3866.. image:: img/image040.gif
[1c03e14]3867
[4ed2d0a1]3868==============  ========  =============
3869Parameter name  Units     Default value
3870==============  ========  =============
[58eccf6]3871volfraction     None      0.05
3872frac_dim        None      2
3873thickness       |Ang|     5.0
3874radius          |Ang|     20.0
3875cor_length      |Ang|     100.0
3876core_sld        |Ang^-2|  3.5e-6
3877shell_sld       |Ang^-2|  1e-6
3878solvent_sld     |Ang^-2|  6.35e-6
3879background      |cm^-1|   0.0
[4ed2d0a1]3880==============  ========  =============
[1c03e14]3881
[7f42aad]3882.. image:: img/image188.jpg
[1c03e14]3883
[4ed2d0a1]3884*Figure. 1D plot using the default values (w/500 data points).*
[1c03e14]3885
[4ed2d0a1]3886REFERENCE
[1c03e14]3887
[93b6fcc]3888See the CoreShellModel_ and FractalModel_ descriptions.
[1c03e14]3889
3890
3891
[4ed2d0a1]3892.. _GaussLorentzGel:
[1c03e14]3893
[58eccf6]3894**2.2.13. GaussLorentzGel(Model)**
[1c03e14]3895
[93b6fcc]3896Calculates the scattering from a gel structure, but typically a physical rather than chemical network. It is modeled as
3897a sum of a low-*q* exponential decay plus a lorentzian at higher *q*-values.
[1c03e14]3898
[6386cd8]3899Also see the GelFitModel_.
3900
[4ed2d0a1]3901The returned value is scaled to units of |cm^-1|, absolute scale.
[1c03e14]3902
[93b6fcc]3903*2.2.13.1. Definition*
3904
3905The scattering intensity *I(q)* is calculated as (eqn 5 from the reference)
[1c03e14]3906
[7f42aad]3907.. image:: img/image189.jpg
[1c03e14]3908
[93b6fcc]3909|bigzeta| is the length scale of the static correlations in the gel, which can be attributed to the "frozen-in"
3910crosslinks. |xi| is the dynamic correlation length, which can be attributed to the fluctuating polymer chains between
3911crosslinks. *I*\ :sub:`G`\ *(0)* and *I*\ :sub:`L`\ *(0)* are the scaling factors for each of these structures. **Think carefully about how**
3912**these map to your particular system!**
[1c03e14]3913
[93b6fcc]3914NB: The peaked structure at higher *q* values (Figure 2 from the reference) is not reproduced by the model. Peaks can
3915be introduced into the model by summing this model with the PeakGaussModel_ function.
[1c03e14]3916
[93b6fcc]3917For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3918
[7f42aad]3919.. image:: img/image040.gif
[1c03e14]3920
[58eccf6]3921===================================  ========  =============
3922Parameter name                       Units     Default value
3923===================================  ========  =============
3924dyn_colength (=dynamic corr length)  |Ang|     20.0
3925scale_g       (=Gauss scale factor)  None      100
3926scale_l  (=Lorentzian scale factor)  None      50
3927stat_colength (=static corr length)  |Ang|     100.0
3928background                           |cm^-1|   0.0
3929===================================  ========  =============
[1c03e14]3930
[7f42aad]3931.. image:: img/image190.jpg
[1c03e14]3932
[4ed2d0a1]3933*Figure. 1D plot using the default values (w/500 data points).*
[1c03e14]3934
[4ed2d0a1]3935REFERENCE
[1c03e14]3936
[93b6fcc]3937G Evmenenko, E Theunissen, K Mortensen, H Reynaers, *Polymer*, 42 (2001) 2907-2913
[1c03e14]3938
3939
3940
[4ed2d0a1]3941.. _BEPolyelectrolyte:
[1c03e14]3942
[58eccf6]3943**2.2.14. BEPolyelectrolyte (Model)**
[1c03e14]3944
[93b6fcc]3945Calculates the structure factor of a polyelectrolyte solution with the RPA expression derived by Borue and Erukhimovich.
3946
3947The value returned is in |cm^-1|.
3948
3949*2.2.14.1. Definition*
[1c03e14]3950
[4ed2d0a1]3951.. image:: img/image191.PNG
[1c03e14]3952
[93b6fcc]3953where *K* is the contrast factor for the polymer, *Lb* is the Bjerrum length, *h* is the virial parameter, *b* is the
3954monomer length, *Cs* is the concentration of monovalent salt, |alpha| is the ionization degree, *Ca* is the polymer
3955molar concentration, and *background* is the incoherent background.
[1c03e14]3956
[93b6fcc]3957For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3958
[7f42aad]3959.. image:: img/image040.gif
[1c03e14]3960
[4ed2d0a1]3961==============  ========  =============
3962Parameter name  Units     Default value
3963==============  ========  =============
[58eccf6]3964K               barns     10
3965Lb              |Ang|     7.1
3966h               |Ang^-3|  12
3967b               |Ang|     10
3968Cs              mol/L     0
3969alpha           None      0.05
3970Ca              mol/L     0.7
3971background      |cm^-1|   0.0
[4ed2d0a1]3972==============  ========  =============
[1c03e14]3973
[58eccf6]3974NB: 1 barn = 10\ :sup:`-24` |cm^2|
3975
[4ed2d0a1]3976REFERENCE
[1c03e14]3977
[93b6fcc]3978V Y Borue, I Y Erukhimovich, *Macromolecules*, 21 (1988) 3240
[1c03e14]3979
[93b6fcc]3980J F Joanny, L Leibler, *Journal de Physique*, 51 (1990) 545
[1c03e14]3981
[93b6fcc]3982A Moussaid, F Schosseler, J P Munch, S Candau, *J. Journal de Physique II France*, 3 (1993) 573
[1c03e14]3983
[93b6fcc]3984E Raphael, J F Joanny, *Europhysics Letters*, 11 (1990) 179
[1c03e14]3985
3986
3987
[4ed2d0a1]3988.. _Guinier:
[1c03e14]3989
[4ed2d0a1]3990**2.2.15. Guinier (Model)**
[1c03e14]3991
[93b6fcc]3992This model fits the Guinier function
[1c03e14]3993
[4ed2d0a1]3994.. image:: img/image192.PNG
[1c03e14]3995
[93b6fcc]3996to the data directly without any need for linearisation (*cf*. Ln *I(q)* vs *q*\ :sup:`2`).
3997
3998For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]3999
[7f42aad]4000.. image:: img/image040.gif
[1c03e14]4001
[4ed2d0a1]4002==============  ========  =============
4003Parameter name  Units     Default value
4004==============  ========  =============
[58eccf6]4005scale           |cm^-1|   1.0
4006Rg              |Ang|     0.1
[4ed2d0a1]4007==============  ========  =============
[1c03e14]4008
[93b6fcc]4009REFERENCE
4010
4011A Guinier and G Fournet, *Small-Angle Scattering of X-Rays*, John Wiley & Sons, New York (1955)
4012
[1c03e14]4013
4014
[4ed2d0a1]4015.. _GuinierPorod:
[1c03e14]4016
[4ed2d0a1]4017**2.2.16. GuinierPorod (Model)**
[1c03e14]4018
[93b6fcc]4019Calculates the scattering for a generalized Guinier/power law object. This is an empirical model that can be used to
4020determine the size and dimensionality of scattering objects, including asymmetric objects such as rods or platelets, and
4021shapes intermediate between spheres and rods or between rods and platelets.
[1c03e14]4022
[93b6fcc]4023The result is in the units of |cm^-1|, absolute scale.
[1c03e14]4024
[93b6fcc]4025*2.2.16.1 Definition*
[1c03e14]4026
[93b6fcc]4027The following functional form is used
[1c03e14]4028
[7f42aad]4029.. image:: img/image193.jpg
[1c03e14]4030
[93b6fcc]4031This is based on the generalized Guinier law for such elongated objects (see the Glatter reference below). For 3D
4032globular objects (such as spheres), *s* = 0 and one recovers the standard Guinier_ formula. For 2D symmetry (such as
4033for rods) *s* = 1, and for 1D symmetry (such as for lamellae or platelets) *s* = 2. A dimensionality parameter (3-*s*)
4034is thus defined, and is 3 for spherical objects, 2 for rods, and 1 for plates.
4035
4036Enforcing the continuity of the Guinier and Porod functions and their derivatives yields
[1c03e14]4037
[7f42aad]4038.. image:: img/image194.jpg
[1c03e14]4039
[4ed2d0a1]4040and
[1c03e14]4041
[7f42aad]4042.. image:: img/image195.jpg
[1c03e14]4043
[93b6fcc]4044Note that
[1c03e14]4045
[6386cd8]4046 the radius-of-gyration for a sphere of radius *R* is given by *Rg* = *R* sqrt(3/5)
[1c03e14]4047
[6386cd8]4048 the cross-sectional radius-of-gyration for a randomly oriented cylinder of radius *R* is given by *Rg* = *R* / sqrt(2)
[1c03e14]4049
[6386cd8]4050 the cross-sectional radius-of-gyration of a randomly oriented lamella of thickness *T* is given by *Rg* = *T* / sqrt(12)
[1c03e14]4051
[93b6fcc]4052For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4053
[4ed2d0a1]4054.. image:: img/image008.PNG
[1c03e14]4055
[58eccf6]4056==============================  ========  =============
4057Parameter name                  Units     Default value
4058==============================  ========  =============
4059scale      (=Guinier scale, G)  |cm^-1|   1.0
4060rg                              |Ang|     100
4061dim (=dimensional variable, s)  None      1
4062m            (=Porod exponent)  None      3
4063background                      |cm^-1|   0.1
4064==============================  ========  =============
[1c03e14]4065
[7f42aad]4066.. image:: img/image196.jpg
[1c03e14]4067
[4ed2d0a1]4068*Figure. 1D plot using the default values (w/500 data points).*
[1c03e14]4069
[93b6fcc]4070REFERENCE
4071
4072A Guinier, G Fournet, *Small-Angle Scattering of X-Rays*, John Wiley and Sons, New York, (1955)
4073
4074O Glatter, O Kratky, *Small-Angle X-Ray Scattering*, Academic Press (1982)
4075Check out Chapter 4 on Data Treatment, pages 155-156.
4076
[1c03e14]4077
4078
[4ed2d0a1]4079.. _PorodModel:
[1c03e14]4080
[4ed2d0a1]4081**2.2.17. PorodModel**
[1c03e14]4082
[6386cd8]4083This model fits the Porod function
[1c03e14]4084
[916501b]4085.. image:: img/image197_corrected.PNG
[1c03e14]4086
[6386cd8]4087to the data directly without any need for linearisation (*cf*. Log *I(q)* vs Log *q*).
[1c03e14]4088
[6386cd8]4089Here *C* is the scale factor and *Sv* is the specific surface area (ie, surface area / volume) of the sample, and
4090|drho| is the contrast factor.
[1c03e14]4091
[93b6fcc]4092For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4093
[7f42aad]4094.. image:: img/image040.gif
[1c03e14]4095
[4ed2d0a1]4096==============  ========  =============
4097Parameter name  Units     Default value
4098==============  ========  =============
[58eccf6]4099scale           |Ang^-4|  0.1
4100background      |cm^-1|   0
[4ed2d0a1]4101==============  ========  =============
[1c03e14]4102
[6386cd8]4103REFERENCE
4104
4105None.
4106
[1c03e14]4107
4108
[4ed2d0a1]4109.. _PeakGaussModel:
[1c03e14]4110
[4ed2d0a1]4111**2.2.18. PeakGaussModel**
[1c03e14]4112
[6386cd8]4113This model describes a Gaussian shaped peak on a flat background
[1c03e14]4114
[4ed2d0a1]4115.. image:: img/image198.PNG
[1c03e14]4116
[6386cd8]4117with the peak having height of *I0* centered at *q0* and having a standard deviation of *B*.  The FWHM (full-width
4118half-maximum) is 2.354 B.  
[1c03e14]4119
[93b6fcc]4120For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4121
[7f42aad]4122.. image:: img/image040.gif
[1c03e14]4123
[4ed2d0a1]4124==============  ========  =============
4125Parameter name  Units     Default value
4126==============  ========  =============
[58eccf6]4127scale           |cm^-1|   100
4128q0              |Ang^-1|  0.05
4129B               |Ang^-1|  0.005
4130background      |cm^-1|   1
[4ed2d0a1]4131==============  ========  =============
[1c03e14]4132
[7f42aad]4133.. image:: img/image199.jpg
[1c03e14]4134
[4ed2d0a1]4135*Figure. 1D plot using the default values (w/500 data points).*
[1c03e14]4136
[6386cd8]4137REFERENCE
4138
4139None.
4140
[1c03e14]4141
4142
[4ed2d0a1]4143.. _PeakLorentzModel:
[1c03e14]4144
[4ed2d0a1]4145**2.2.19. PeakLorentzModel**
[1c03e14]4146
[6386cd8]4147This model describes a Lorentzian shaped peak on a flat background
[1c03e14]4148
[4ed2d0a1]4149.. image:: img/image200.PNG
[1c03e14]4150
[6386cd8]4151with the peak having height of *I0* centered at *q0* and having a HWHM (half-width half-maximum) of B. 
[1c03e14]4152
[93b6fcc]4153For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4154
[7f42aad]4155.. image:: img/image040.gif
[1c03e14]4156
[4ed2d0a1]4157==============  ========  =============
4158Parameter name  Units     Default value
4159==============  ========  =============
[58eccf6]4160scale           |cm^-1|   100
4161q0              |Ang^-1|  0.05
4162B               |Ang^-1|  0.005
4163background      |cm^-1|     1
[4ed2d0a1]4164==============  ========  =============
[1c03e14]4165
[7f42aad]4166.. image:: img/image201.jpg
[1c03e14]4167
[4ed2d0a1]4168*Figure. 1D plot using the default values (w/500 data points).*
[1c03e14]4169
[6386cd8]4170REFERENCE
4171
4172None.
4173
[1c03e14]4174
4175
[4ed2d0a1]4176.. _Poly_GaussCoil:
[1c03e14]4177
[4ed2d0a1]4178**2.2.20. Poly_GaussCoil (Model)**
[1c03e14]4179
[6386cd8]4180This model calculates an empirical functional form for the scattering from a **polydisperse** polymer chain in the
4181theta state assuming a Schulz-Zimm type molecular weight distribution. Polydispersity on the radius-of-gyration is also
4182provided for.
[1c03e14]4183
[4ed2d0a1]4184The returned value is scaled to units of |cm^-1|, absolute scale.
[1c03e14]4185
[6386cd8]4186*2.2.20.1. Definition*
4187
4188The scattering intensity *I(q)* is calculated as
4189
[4ed2d0a1]4190.. image:: img/image202.PNG
[1c03e14]4191
[6386cd8]4192where the dimensionless chain dimension is
[1c03e14]4193
[4ed2d0a1]4194.. image:: img/image203.PNG
[1c03e14]4195
[6386cd8]4196and the polydispersity is
[1c03e14]4197
[4ed2d0a1]4198.. image:: img/image204.PNG
[1c03e14]4199
[93b6fcc]4200For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4201
[7f42aad]4202.. image:: img/image040.gif
[1c03e14]4203
[6386cd8]4204This example dataset is produced using 200 data points, using 200 data points,
4205*qmin* = 0.001 |Ang^-1|, *qmax* = 0.7 |Ang^-1| and the default values
[1c03e14]4206
[4ed2d0a1]4207==============  ========  =============
4208Parameter name  Units     Default value
4209==============  ========  =============
[58eccf6]4210scale           None      1.0
4211rg              |Ang|     60.0
4212poly_m (Mw/Mn)  None      2
4213background      |cm^-1|   0.001
[4ed2d0a1]4214==============  ========  =============
[1c03e14]4215
[7f42aad]4216.. image:: img/image205.jpg
[1c03e14]4217
4218*Figure. 1D plot using the default values (w/200 data point).*
4219
[bf8c07b]4220REFERENCE
[1c03e14]4221
[6386cd8]4222O Glatter and O Kratky (editors), *Small Angle X-ray Scattering*, Academic Press, (1982)
4223Page 404
[1c03e14]4224
[93b6fcc]4225J S Higgins, and H C Benoit, Polymers and Neutron Scattering, Oxford Science Publications (1996)
[4ed2d0a1]4226
[1c03e14]4227
[4ed2d0a1]4228
4229.. _PolyExclVolume:
4230
4231**2.2.21. PolymerExclVolume (Model)**
[1c03e14]4232
[6386cd8]4233This model describes the scattering from polymer chains subject to excluded volume effects, and has been used as a
4234template for describing mass fractals.
[1c03e14]4235
[4ed2d0a1]4236The returned value is scaled to units of |cm^-1|, absolute scale.
[1c03e14]4237
[6386cd8]4238*2.2.21.1 Definition*
[1c03e14]4239
[6386cd8]4240The form factor  was originally presented in the following integral form (Benoit, 1957)
[1c03e14]4241
[7f42aad]4242.. image:: img/image206.jpg
[1c03e14]4243
[6386cd8]4244where |nu| is the excluded volume parameter (which is related to the Porod exponent *m* as |nu| = 1 / *m*), *a* is the
4245statistical segment length of the polymer chain, and *n* is the degree of polymerization. This integral was later put
4246into an almost analytical form as follows (Hammouda, 1993)
[1c03e14]4247
[7f42aad]4248.. image:: img/image207.jpg
[1c03e14]4249
[6386cd8]4250where |gamma|\ *(x,U)* is the incomplete gamma function
[1c03e14]4251
[7f42aad]4252.. image:: img/image208.jpg
[1c03e14]4253
[6386cd8]4254and the variable *U* is given in terms of the scattering vector *Q* as
[1c03e14]4255
[7f42aad]4256.. image:: img/image209.jpg
[1c03e14]4257
[6386cd8]4258The square of the radius-of-gyration is defined as
[1c03e14]4259
[7f42aad]4260.. image:: img/image210.jpg
[1c03e14]4261
[6386cd8]4262Note that this model applies only in the mass fractal range (ie, 5/3 <= *m* <= 3) and **does not** apply to surface
4263fractals (3 < *m* <= 4). It also does not reproduce the rigid rod limit (*m* = 1) because it assumes chain flexibility
4264from the outset. It may cover a portion of the semi-flexible chain range (1 < *m* < 5/3).
[1c03e14]4265
[6386cd8]4266A low-*Q* expansion yields the Guinier form and a high-*Q* expansion yields the Porod form which is given by
[1c03e14]4267
[7f42aad]4268.. image:: img/image211.jpg
[1c03e14]4269
[6386cd8]4270Here |biggamma|\ *(x)* = |gamma|\ *(x,inf)* is the gamma function.
4271
4272The asymptotic limit is dominated by the first term
[1c03e14]4273
[7f42aad]4274.. image:: img/image212.jpg
[1c03e14]4275
[6386cd8]4276The special case when |nu| = 0.5 (or *m* = 1/|nu| = 2) corresponds to Gaussian chains for which the form factor is given
4277by the familiar Debye_ function.
[1c03e14]4278
[7f42aad]4279.. image:: img/image213.jpg
[1c03e14]4280
[93b6fcc]4281For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4282
[7f42aad]4283.. image:: img/image040.gif
[1c03e14]4284
[6386cd8]4285This example dataset is produced using 200 data points, *qmin* = 0.001 |Ang^-1|, *qmax* = 0.2 |Ang^-1| and the default
4286values
[1c03e14]4287
[58eccf6]4288===================  ========  =============
4289Parameter name       Units     Default value
4290===================  ========  =============
4291scale                None      1.0
4292rg                   |Ang|     60.0
4293m (=Porod exponent)  None      3
4294background           |cm^-1|   0.0
4295===================  ========  =============
[1c03e14]4296
[7f42aad]4297.. image:: img/image214.jpg
[1c03e14]4298
4299*Figure. 1D plot using the default values (w/500 data points).*
4300
[6386cd8]4301REFERENCE
[1c03e14]4302
[6386cd8]4303H Benoit, *Comptes Rendus*, 245 (1957) 2244-2247
[1c03e14]4304
[6386cd8]4305B Hammouda, *SANS from Homogeneous Polymer Mixtures ­ A Unified Overview*, *Advances in Polym. Sci.*, 106 (1993) 87-133
[4ed2d0a1]4306
[1c03e14]4307
4308
[6386cd8]4309.. _RPA10Model:
[1c03e14]4310
[6386cd8]4311**2.2.22. RPA10Model**
[1c03e14]4312
[6386cd8]4313Calculates the macroscopic scattering intensity (units of |cm^-1|) for a multicomponent homogeneous mixture of polymers
4314using the Random Phase Approximation. This general formalism contains 10 specific cases
[1c03e14]4315
[6386cd8]4316Case 0: C/D binary mixture of homopolymers
[1c03e14]4317
[6386cd8]4318Case 1: C-D diblock copolymer
[1c03e14]4319
[6386cd8]4320Case 2: B/C/D ternary mixture of homopolymers
[1c03e14]4321
[6386cd8]4322Case 3: C/C-D mixture of a homopolymer B and a diblock copolymer C-D
[1c03e14]4323
[6386cd8]4324Case 4: B-C-D triblock copolymer
[1c03e14]4325
[6386cd8]4326Case 5: A/B/C/D quaternary mixture of homopolymers
[1c03e14]4327
[6386cd8]4328Case 6: A/B/C-D mixture of two homopolymers A/B and a diblock C-D
[1c03e14]4329
[6386cd8]4330Case 7: A/B-C-D mixture of a homopolymer A and a triblock B-C-D
[1c03e14]4331
[6386cd8]4332Case 8: A-B/C-D mixture of two diblock copolymers A-B and C-D
[1c03e14]4333
[6386cd8]4334Case 9: A-B-C-D tetra-block copolymer
[1c03e14]4335
[6386cd8]4336**NB: these case numbers are different from those in the NIST SANS package!**
[1c03e14]4337
[6386cd8]4338Only one case can be used at any one time.
[1c03e14]4339
[6386cd8]4340The returned value is scaled to units of |cm^-1|, absolute scale.
[1c03e14]4341
[6386cd8]4342The RPA (mean field) formalism only applies only when the multicomponent polymer mixture is in the homogeneous
4343mixed-phase region.
[1c03e14]4344
[6386cd8]4345**Component D is assumed to be the "background" component (ie, all contrasts are calculated with respect to**
4346**component D).** So the scattering contrast for a C/D blend = [SLD(component C) - SLD(component D)]\ :sup:`2`.
[1c03e14]4347
[6386cd8]4348Depending on which case is being used, the number of fitting parameters - the segment lengths (ba, bb, etc) and |chi|
4349parameters (Kab, Kac, etc) - vary. The *scale* parameter should be held equal to unity.
[1c03e14]4350
[6386cd8]4351The input parameters are the degrees of polymerization, the volume fractions, the specific volumes, and the neutron
4352scattering length densities for each component.
[1c03e14]4353
[6386cd8]4354Fitting parameters for a Case 0 Model
[1c03e14]4355
[58eccf6]4356=======================  ========  =============
4357Parameter name           Units     Default value
4358=======================  ========  =============
4359background               |cm^-1|   0.0
4360scale                    None      1
4361bc (=segment Length_bc)  **unit**  5
4362bd (=segment length_bd)  **unit**  5
4363Kcd (=chi_cd)            **unit**  -0.0004
4364=======================  ========  =============
[1c03e14]4365
[6386cd8]4366Fixed parameters for a Case 0 Model
[1c03e14]4367
[58eccf6]4368=======================  ========  =============
4369Parameter name           Units     Default value
4370=======================  ========  =============
4371Lc (=scatter. length_c)  **unit**  1e-12
4372Ld (=scatter. length_d)  **unit**  0
4373Nc    (=degree polym_c)  None      1000
4374Nd    (=degree polym_d)  None      1000
4375Phic (=vol. fraction_c)  None      0.25
4376Phid (=vol. fraction_d)  None      0.25
4377vc (=specific volume_c)  **unit**  100
4378vd (=specific volume_d)  **unit**  100
4379=======================  ========  =============
[1c03e14]4380
[7f42aad]4381.. image:: img/image215.jpg
[1c03e14]4382
4383*Figure. 1D plot using the default values (w/500 data points).*
4384
[6386cd8]4385REFERENCE
4386
4387A Z Akcasu, R Klein and B Hammouda, *Macromolecules*, 26 (1993) 4136
[1c03e14]4388
4389
4390
[4ed2d0a1]4391.. _TwoLorentzian:
[1c03e14]4392
[58eccf6]4393**2.2.23. TwoLorentzian (Model)**
[1c03e14]4394
[6386cd8]4395This model calculates an empirical functional form for SAS data characterized by two Lorentzian-type functions.
[1c03e14]4396
[4ed2d0a1]4397The returned value is scaled to units of |cm^-1|, absolute scale.
[1c03e14]4398
[6386cd8]4399*2.2.23.1. Definition*
[1c03e14]4400
[6386cd8]4401The scattering intensity *I(q)* is calculated as
[1c03e14]4402
[f8063bf]4403.. image:: img/image216.jpg 
[1c03e14]4404
[6386cd8]4405where *A* = Lorentzian scale factor #1, *C* = Lorentzian scale #2, |xi|\ :sub:`1` and |xi|\ :sub:`2` are the
4406corresponding correlation lengths, and *n* and *m* are the respective power law exponents (set *n* = *m* = 2 for
4407Ornstein-Zernicke behaviour).
[1c03e14]4408
[93b6fcc]4409For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4410
[7f42aad]4411.. image:: img/image040.gif
[1c03e14]4412
[58eccf6]4413===============================  ========  =============
4414Parameter name                   Units     Default value
4415===============================  ========  =============
4416scale_1 (=A)                     None      10
4417scale_2 (=C)                     None      1
44181ength_1 (=correlation length1)  |Ang|     100
44191ength_2 (=correlation length2)  |Ang|     10
4420exponent_1 (=n)                  None      3
4421exponent_2 (=m)                  None      2
4422background (=B)                  |cm^-1|   0.1
4423===============================  ========  =============
[1c03e14]4424
[7f42aad]4425.. image:: img/image217.jpg
[1c03e14]4426
4427*Figure. 1D plot using the default values (w/500 data points).*
4428
[bf8c07b]4429REFERENCE
4430
[6386cd8]4431None.
[1c03e14]4432
4433
4434
[4ed2d0a1]4435.. _TwoPowerLaw:
[1c03e14]4436
[58eccf6]4437**2.2.24. TwoPowerLaw (Model)**
[1c03e14]4438
[6386cd8]4439This model calculates an empirical functional form for SAS data characterized by two power laws.
[1c03e14]4440
[4ed2d0a1]4441The returned value is scaled to units of |cm^-1|, absolute scale.
[1c03e14]4442
[6386cd8]4443*2.2.24.1. Definition*
4444
4445The scattering intensity *I(q)* is calculated as
[1c03e14]4446
[7f42aad]4447.. image:: img/image218.jpg
[1c03e14]4448
[6386cd8]4449where *qc* is the location of the crossover from one slope to the other. The scaling *coef_A* sets the overall
4450intensity of the lower *q* power law region. The scaling of the second power law region is then automatically scaled to
4451match the first.
4452
4453**NB: Be sure to enter the power law exponents as positive values!**
[1c03e14]4454
[93b6fcc]4455For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4456
[7f42aad]4457.. image:: img/image040.gif
[1c03e14]4458
[4ed2d0a1]4459==============  ========  =============
4460Parameter name  Units     Default value
4461==============  ========  =============
[58eccf6]4462coef_A          None      1.0
4463qc              |Ang^-1|  0.04
4464power_1 (=m1)   None      4
4465power_2 (=m2)   None      4
4466background      |cm^-1|   0.0
[4ed2d0a1]4467==============  ========  =============
[1c03e14]4468
[7f42aad]4469.. image:: img/image219.jpg
[1c03e14]4470
4471*Figure. 1D plot using the default values (w/500 data points).*
4472
[6386cd8]4473REFERENCE
4474
4475None.
4476
[1c03e14]4477
4478
[4ed2d0a1]4479.. _UnifiedPowerRg:
[1c03e14]4480
[58eccf6]4481**2.2.25. UnifiedPowerRg (Beaucage Model)**
[1c03e14]4482
[6386cd8]4483This model deploys the empirical multiple level unified Exponential/Power-law fit method developed by G Beaucage. Four
4484functions are included so that 1, 2, 3, or 4 levels can be used. In addition a 0 level has been added which simply
4485calculates
4486
4487*I(q)* = *scale* / *q* + *background*
4488
[4ed2d0a1]4489The returned value is scaled to units of |cm^-1|, absolute scale. 
4490
[6386cd8]4491The Beaucage method is able to reasonably approximate the scattering from many different types of particles, including
4492fractal clusters, random coils (Debye equation), ellipsoidal particles, etc. 
[1c03e14]4493
[6386cd8]4494*2.2.25.1 Definition*
[1c03e14]4495
[4ed2d0a1]4496The empirical fit function is 
[1c03e14]4497
[7f42aad]4498.. image:: img/image220.jpg
[1c03e14]4499
[6386cd8]4500For each level, the four parameters *Gi*, *Rg,i*, *Bi* and *Pi* must be chosen. 
[1c03e14]4501
[6386cd8]4502For example, to approximate the scattering from random coils (Debye_ equation), set *Rg,i* as the Guinier radius,
4503*Pi* = 2, and *Bi* = 2 *Gi* / *Rg,i* 
[1c03e14]4504
[6386cd8]4505See the references for further information on choosing the parameters.
[1c03e14]4506
[93b6fcc]4507For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4508
[7f42aad]4509.. image:: img/image040.gif
[1c03e14]4510
[4ed2d0a1]4511==============  ========  =============
4512Parameter name  Units     Default value
4513==============  ========  =============
[58eccf6]4514scale           None      1.0
4515Rg2             |Ang|     21
4516power2          None      2
4517G2              |cm^-1|   3
4518B2              |cm^-1|   0.0006
4519Rg1             |Ang|     15.8
4520power1          None      4
4521G1              |cm^-1|   400
4522B1              |cm^-1|   4.5e-6                |
4523background      |cm^-1|   0.0
[4ed2d0a1]4524==============  ========  =============
[1c03e14]4525
[7f42aad]4526.. image:: img/image221.jpg
[1c03e14]4527
4528*Figure. 1D plot using the default values (w/500 data points).*
4529
4530REFERENCE
4531
[6386cd8]4532G Beaucage, *J. Appl. Cryst.*, 28 (1995) 717-728
[1c03e14]4533
[6386cd8]4534G Beaucage, *J. Appl. Cryst.*, 29 (1996) 134-146
[1c03e14]4535
4536
4537
[4ed2d0a1]4538.. _LineModel:
[1c03e14]4539
[4ed2d0a1]4540**2.2.26. LineModel**
[1c03e14]4541
[6386cd8]4542This calculates the simple linear function
[1c03e14]4543
[4ed2d0a1]4544.. image:: img/image222.PNG
[1c03e14]4545
[6386cd8]4546**NB: For 2D plots,** *I(q)* = *I(qx)*\ *\ *I(qy)*, **which is a different definition to other shape independent models.**
[1c03e14]4547
[6386cd8]4548==============  ==============  =============
4549Parameter name  Units           Default value
4550==============  ==============  =============
4551A               |cm^-1|         1.0
4552B               |Ang|\ |cm^-1|  1.0
4553==============  ==============  =============
[1c03e14]4554
[6386cd8]4555REFERENCE
[1c03e14]4556
[6386cd8]4557None.
[1c03e14]4558
4559
4560
[6386cd8]4561.. _GelFitModel:
[1c03e14]4562
[6386cd8]4563**2.2.27. GelFitModel**
[1c03e14]4564
[6386cd8]4565*This model was implemented by an interested user!*
[1c03e14]4566
[6386cd8]4567Unlike a concentrated polymer solution, the fine-scale polymer distribution in a gel involves at least two
4568characteristic length scales, a shorter correlation length (*a1*) to describe the rapid fluctuations in the position
4569of the polymer chains that ensure thermodynamic equilibrium, and a longer distance (denoted here as *a2*) needed to
4570account for the static accumulations of polymer pinned down by junction points or clusters of such points. The latter
4571is derived from a simple Guinier function.
[1c03e14]4572
[6386cd8]4573Also see the GaussLorentzGel_ Model.
[1c03e14]4574
[6386cd8]4575*2.2.27.1. Definition*
4576
4577The scattered intensity *I(q)* is calculated as
[1c03e14]4578
[7f42aad]4579.. image:: img/image233.gif
[1c03e14]4580
[6386cd8]4581where
[1c03e14]4582
[7f42aad]4583.. image:: img/image234.gif
[1c03e14]4584
[6386cd8]4585Note that the first term reduces to the Ornstein-Zernicke equation when *D* = 2; ie, when the Flory exponent is 0.5
4586(theta conditions). In gels with significant hydrogen bonding *D* has been reported to be ~2.6 to 2.8.
[1c03e14]4587
[6386cd8]4588============================  ========  =============
4589Parameter name                Units     Default value
4590============================  ========  =============
4591Background                    |cm^-1|   0.01
4592Guinier scale    (= *I(0)G*)  |cm^-1|   1.7
4593Lorentzian scale (= *I(0)L*)  |cm^-1|   3.5
4594Radius of gyration  (= *Rg*)  |Ang|     104
4595Fractal exponent     (= *D*)  None      2
4596Correlation length  (= *a1*)  |Ang|     16
4597============================  ========  =============
[1c03e14]4598
[7f42aad]4599.. image:: img/image235.gif
[1c03e14]4600
[6386cd8]4601*Figure. 1D plot using the default values (w/300 data points).*
[1c03e14]4602
[6386cd8]4603REFERENCE
[1c03e14]4604
[6386cd8]4605Mitsuhiro Shibayama, Toyoichi Tanaka, Charles C Han, J. Chem. Phys. 1992, 97 (9), 6829-6841
[1c03e14]4606
[6386cd8]4607Simon Mallam, Ferenc Horkay, Anne-Marie Hecht, Adrian R Rennie, Erik Geissler, Macromolecules 1991, 24, 543-548
[1c03e14]4608
4609
4610
[6386cd8]4611.. _StarPolymer:
[1c03e14]4612
[6386cd8]4613**2.2.28. Star Polymer with Gaussian Statistics**
[1c03e14]4614
[6386cd8]4615This model is also known as the Benoit Star model.
[1c03e14]4616
[6386cd8]4617*2.2.28.1. Definition*
4618
4619For a star with *f* arms:
[1c03e14]4620
[7f42aad]4621.. image:: img/star1.png
[1c03e14]4622
[6386cd8]4623where
[1c03e14]4624
[7f42aad]4625.. image:: img/star2.png
[1c03e14]4626
[6386cd8]4627and
4628
[7f42aad]4629.. image:: img/star3.png
[1c03e14]4630
[6386cd8]4631is the square of the ensemble average radius-of-gyration of an arm.
[1c03e14]4632
[6386cd8]4633REFERENCE
[1c03e14]4634
[6386cd8]4635H Benoit,   J. Polymer Science.,  11, 596-599  (1953)
[1c03e14]4636
4637
4638
[6386cd8]4639.. _ReflectivityModel:
[1c03e14]4640
[6386cd8]4641**2.2.29. ReflectivityModel**
[1c03e14]4642
[6386cd8]4643*This model was contributed by an interested user!*
4644
4645This model calculates **reflectivity** using the Parrett algorithm.
4646
4647Up to nine film layers are supported between Bottom(substrate) and Medium(Superstrate) where the neutron enters the
4648first top film. Each of the layers are composed of
4649
4650[œ of the interface (from the previous layer or substrate) + flat portion + œ of the interface (to the next layer or medium)]
4651
4652Two simple functions are provided to describe the interfacial density distribution; a linear function and an error
4653function. The interfacial thickness is equivalent to (-2.5 |sigma| to +2.5 |sigma| for the error function, where
4654|sigma| = roughness).
4655
4656Also see ReflectivityIIModel_.
4657
[7f42aad]4658.. image:: img/image231.bmp
[6386cd8]4659
4660*Figure. Comparison (using the SLD profile below) with the NIST web calculation (circles)*
4661http://www.ncnr.nist.gov/resources/reflcalc.html
4662
[7f42aad]4663.. image:: img/image232.gif
[6386cd8]4664
4665*Figure. SLD profile used for the calculation (above).*
[1c03e14]4666
4667REFERENCE
4668
[6386cd8]4669None.
[1c03e14]4670
4671
4672
[6386cd8]4673.. _ReflectivityIIModel:
[1c03e14]4674
[6386cd8]4675**2.2.30. ReflectivityIIModel**
[1c03e14]4676
[6386cd8]4677*This model was contributed by an interested user!*
[1c03e14]4678
[6386cd8]4679This **reflectivity** model is a more flexible version of ReflectivityModel_. More interfacial density
4680functions are supported, and the number of points (*npts_inter*) for each interface can be chosen.
[1c03e14]4681
[6386cd8]4682The SLD at the interface between layers, |rho|\ *inter_i*, is calculated with a function chosen by a user, where the
4683available functions are
[1c03e14]4684
[6386cd8]46851) Erf
[1c03e14]4686
[7f42aad]4687.. image:: img/image051.gif
[1c03e14]4688
[6386cd8]46892) Power-Law
4690
[7f42aad]4691.. image:: img/image050.gif
[6386cd8]4692
46933) Exp
4694
[7f42aad]4695.. image:: img/image049.gif
[6386cd8]4696
4697The constant *A* in the expressions above (but the parameter *nu* in the model!) is an input.
[1c03e14]4698
4699REFERENCE
[bf8c07b]4700
[6386cd8]4701None.
[1c03e14]4702
4703
4704
47052.3 Structure-factor Functions
4706------------------------------
4707
[6386cd8]4708The information in this section originated from NIST SANS package.
[1c03e14]4709
4710.. _HardSphereStructure:
4711
4712**2.3.1. HardSphereStructure Factor**
4713
4714This calculates the interparticle structure factor for monodisperse spherical particles interacting through hard
4715sphere (excluded volume) interactions.
4716
4717The calculation uses the Percus-Yevick closure where the interparticle potential is
4718
4719.. image:: img/image223.PNG
4720
4721where *r* is the distance from the center of the sphere of a radius *R*.
4722
4723For a 2D plot, the wave transfer is defined as
4724
[7f42aad]4725.. image:: img/image040.gif
[1c03e14]4726
4727==============  ========  =============
4728Parameter name  Units     Default value
4729==============  ========  =============
4730effect_radius   |Ang|     50.0
4731volfraction     None      0.2
4732==============  ========  =============
4733
[7f42aad]4734.. image:: img/image224.jpg
[1c03e14]4735
4736*Figure. 1D plot using the default values (in linear scale).*
4737
4738REFERENCE
[bf8c07b]4739
[93b6fcc]4740J K Percus, J Yevick, *J. Phys. Rev.*, 110, (1958) 1
[1c03e14]4741
4742
4743
4744.. _SquareWellStructure:
4745
4746**2.3.2. SquareWellStructure Factor**
4747
4748This calculates the interparticle structure factor for a square well fluid spherical particles. The mean spherical
4749approximation (MSA) closure was used for this calculation, and is not the most appropriate closure for an attractive
4750interparticle potential. This solution has been compared to Monte Carlo simulations for a square well fluid, showing
4751this calculation to be limited in applicability to well depths |epsilon| < 1.5 kT and volume fractions |phi| < 0.08.
4752
4753Positive well depths correspond to an attractive potential well. Negative well depths correspond to a potential
4754"shoulder", which may or may not be physically reasonable.
4755
4756The well width (*l*\ ) is defined as multiples of the particle diameter (2\*\ *R*\ )
4757
4758The interaction potential is:
4759
4760.. image:: img/image225.PNG
4761
4762where *r* is the distance from the center of the sphere of a radius *R*.
4763
[93b6fcc]4764For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4765
[7f42aad]4766.. image:: img/image040.gif
[1c03e14]4767
4768==============  =========  =============
4769Parameter name  Units      Default value
4770==============  =========  =============
4771effect_radius   |Ang|      50.0
4772volfraction     None       0.04
4773welldepth       kT         1.5
4774wellwidth       diameters  1.2
4775==============  =========  =============
4776
[7f42aad]4777.. image:: img/image226.jpg
[1c03e14]4778
4779*Figure. 1D plot using the default values (in linear scale).*
4780
4781REFERENCE
[bf8c07b]4782
[93b6fcc]4783R V Sharma, K C Sharma, *Physica*, 89A (1977) 213
[1c03e14]4784
4785
4786
4787.. _HayterMSAStructure:
4788
4789**2.3.3. HayterMSAStructure Factor**
4790
[906a325]4791This is an implementation of the Rescaled Mean Spherical Approximation which calculates the structure factor (the
4792Fourier transform of the pair correlation function *g(r)*) for a system of charged, spheroidal objects in a
4793dielectric medium. When combined with an appropriate form factor (such as sphere,core+shell, ellipsoid, etc), this
4794allows for inclusion of the interparticle interference effects due to screened coulomb repulsion between charged particles.
[1c03e14]4795
4796**This routine only works for charged particles**. If the charge is set to zero the routine will self-destruct!
4797For non-charged particles use a hard sphere potential.
4798
4799The salt concentration is used to compute the ionic strength of the solution which in turn is used to compute the Debye
4800screening length. At present there is no provision for entering the ionic strength directly nor for use of any
4801multivalent salts. The counterions are also assumed to be monovalent.
4802
[93b6fcc]4803For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4804
4805.. image:: img/image040.gif
4806
4807==============  ========  =============
4808Parameter name  Units     Default value
4809==============  ========  =============
4810effect_radius   |Ang|     20.8
4811charge          *e*       19
4812volfraction     None      0.2
4813temperature     K         318
4814salt conc       M         0
4815dielectconst    None      71.1
4816==============  ========  =============
4817
[7f42aad]4818.. image:: img/image227.jpg
[1c03e14]4819
4820*Figure. 1D plot using the default values (in linear scale).*
4821
4822REFERENCE
[bf8c07b]4823
[93b6fcc]4824J B Hayter and J Penfold, *Molecular Physics*, 42 (1981) 109-118
[bf8c07b]4825
[93b6fcc]4826J P Hansen and J B Hayter, *Molecular Physics*, 46 (1982) 651-656
[1c03e14]4827
4828
4829.. _StickyHSStructure:
4830
4831**2.3.4. StickyHSStructure Factor**
4832
4833This calculates the interparticle structure factor for a hard sphere fluid with a narrow attractive well. A perturbative
4834solution of the Percus-Yevick closure is used. The strength of the attractive well is described in terms of "stickiness"
4835as defined below. The returned value is a dimensionless structure factor, *S(q)*.
4836
4837The perturb (perturbation parameter), |epsilon|, should be held between 0.01 and 0.1. It is best to hold the
4838perturbation parameter fixed and let the "stickiness" vary to adjust the interaction strength. The stickiness, |tau|,
4839is defined in the equation below and is a function of both the perturbation parameter and the interaction strength.
4840|tau| and |epsilon| are defined in terms of the hard sphere diameter (|sigma| = 2\*\ *R*\ ), the width of the square
4841well, |bigdelta| (same units as *R*), and the depth of the well, *Uo*, in units of kT. From the definition, it is clear
4842that smaller |tau| means stronger attraction.
4843
4844.. image:: img/image228.PNG
4845
4846where the interaction potential is
4847
4848.. image:: img/image229.PNG
4849
4850The Percus-Yevick (PY) closure was used for this calculation, and is an adequate closure for an attractive interparticle
4851potential. This solution has been compared to Monte Carlo simulations for a square well fluid, with good agreement.
4852
4853The true particle volume fraction, |phi|, is not equal to *h*, which appears in most of the reference. The two are
4854related in equation (24) of the reference. The reference also describes the relationship between this perturbation
4855solution and the original sticky hard sphere (or adhesive sphere) model by Baxter.
4856
4857NB: The calculation can go haywire for certain combinations of the input parameters, producing unphysical solutions - in
4858this case errors are reported to the command window and the *S(q)* is set to -1 (so it will disappear on a log-log
4859plot). Use tight bounds to keep the parameters to values that you know are physical (test them) and keep nudging them
4860until the optimization does not hit the constraints.
4861
[93b6fcc]4862For 2D data: The 2D scattering intensity is calculated in the same way as 1D, where the *q* vector is defined as
[1c03e14]4863
[7f42aad]4864.. image:: img/image040.gif
[1c03e14]4865
4866==============  ========  =============
4867Parameter name  Units     Default value
4868==============  ========  =============
4869effect_radius   |Ang|     50
4870perturb         None      0.05
4871volfraction     None      0.1
4872stickiness      K         0.2
4873==============  ========  =============
4874
[7f42aad]4875.. image:: img/image230.jpg
[1c03e14]4876
4877*Figure. 1D plot using the default values (in linear scale).*
4878
4879REFERENCE
[bf8c07b]4880
[93b6fcc]4881S V G Menon, C Manohar, and K S Rao, *J. Chem. Phys.*, 95(12) (1991) 9186-9190
[1c03e14]4882
4883
4884
48852.4 Customised Functions
4886------------------------------
4887
4888
4889Customized model functions can be redefined or added to by users (See SansView tutorial for details).
4890
4891.. _testmodel:
4892
4893**2.4.1. testmodel**
4894
4895This function, as an example of a user defined function, calculates
4896
4897*I(q)* = *A* + *B* cos(2\ *q*\ ) + *C* sin(2\ *q*\ )
4898
4899
4900
4901.. _testmodel_2:
4902
4903**2.4.2. testmodel_2**
4904
4905This function, as an example of a user defined function, calculates
4906
4907*I(q)* = *scale* * sin(*f*\ )/*f*
4908
4909where
4910
4911*f* = *A* + *Bq* + *Cq*\ :sup:`2` + *Dq*\ :sup:`3` + *Eq*\ :sup:`4` + *Fq*\ :sup:`5`
4912
4913
4914
4915.. _sum_p1_p2:
4916
4917**2.4.3. sum_p1_p2**
4918
4919This function, as an example of a user defined function, calculates
4920
4921*I(q)* = *scale_factor* \* (CylinderModel + PolymerExclVolumeModel)
4922
4923To make your own (*p1 + p2*) model, select 'Easy Custom Sum' from the Fitting menu, or modify and compile the file
4924named 'sum_p1_p2.py' from 'Edit Custom Model' in the 'Fitting' menu.
4925
4926NB: Summing models only works only for single functional models (ie, single shell models, two-component RPA models, etc).
4927
4928
4929
4930.. _sum_Ap1_1_Ap2:
4931
4932**2.4.4. sum_Ap1_1_Ap2**
4933
4934This function, as an example of a user defined function, calculates
4935
4936*I(q)* = (*scale_factor* \* CylinderModel + (1 - *scale_factor*\ ) \* PolymerExclVolume model)
4937
4938To make your own (*A*\ * *p1* + (1-*A*) \* *p2*) model, modify and compile the file named 'sum_Ap1_1_Ap2.py' from
4939'Edit Custom Model' in the 'Fitting' menu.
4940
4941NB: Summing models only works only for single functional models (ie, single shell models, two-component RPA models, etc).
4942
4943
4944
4945.. _polynomial5:
4946
4947**2.4.5. polynomial5**
4948
4949This function, as an example of a user defined function, calculates
4950
4951*I(q)* = *A* + *Bq* + *Cq*\ :sup:`2` + *Dq*\ :sup:`3` + *Eq*\ :sup:`4` + *Fq*\ :sup:`5`
4952
4953This model can be modified and compiled from 'Edit Custom Model' in the 'Fitting' menu.
4954
4955
4956
4957.. _sph_bessel_jn:
4958
4959**2.4.6. sph_bessel_jn**
4960
4961This function, as an example of a user defined function, calculates
4962
4963*I(q)* = *C* \* *sph_jn(Ax+B)+D*
4964
4965where *sph_jn* is a spherical Bessel function of order *n*.
4966
4967This model can be modified and compiled from 'Edit Custom Model' in the 'Fitting' menu.
Note: See TracBrowser for help on using the repository browser.