source: sasmodels/sasmodels/models/lamellar.py @ 19dcb933

core_shell_microgelscostrafo411magnetic_modelrelease_v0.94release_v0.95ticket-1257-vesicle-productticket_1156ticket_1265_superballticket_822_more_unit_tests
Last change on this file since 19dcb933 was 19dcb933, checked in by Paul Kienzle <pkienzle@…>, 10 years ago

build docs for models

  • Property mode set to 100644
File size: 2.1 KB
Line 
1r"""
2Polydispersity in the bilayer thickness can be applied from the GUI.
3
4Definition
5----------
6
7The scattering intensity *I(Q)* is
8
9.. math::
10
11    I(Q) = 2\pi{P(Q) \over \delta Q^2}
12
13
14The form factor is
15
16.. math::
17
18    P(Q) = {2\Delta\rho^2 \over Q^2}(1-cos(Q\delta))
19
20
21where |delta| = bilayer thickness.
22
23The 2D scattering intensity is calculated in the same way as 1D, where the $Q$ vector is defined as
24
25.. math::
26
27    Q = \sqrt{Q_x^2 + Q_y^2}
28
29
30
31Our model uses the form factor calculations implemented in a c-library provided by the NIST Center for Neutron Research
32(Kline, 2006).
33
34.. figure:: img/lamellar_1d.jpg
35
36    1D plot using the default values (w/1000 data point).
37
38
39Reference
40---------
41
42F Nallet, R Laversanne, and D Roux, J. Phys. II France, 3, (1993) 487-502
43
44also in J. Phys. Chem. B, 105, (2001) 11081-11088
45
46
47"""
48
49from numpy import pi, inf
50
51name = "lamellar"
52title = "Lyotropic lamellar phase with uniform SLD and random distribution"
53description = """\
54        [Dilute Lamellar Form Factor](from a lyotropic lamellar phase)
55                I(q)= 2*pi*P(q)/(delta *q^(2)), where
56                P(q)=2*(contrast/q)^(2)*(1-cos(q*delta))^(2))
57                thickness = layer thickness
58                sld = layer scattering length density
59                sld_solvent = solvent scattering length density
60                background = incoherent background
61                scale = scale factor
62"""
63
64parameters = [
65#   [ "name", "units", default, [lower, upper], "type",
66#     "description" ],
67    [ "sld", "1e-6/Ang^2", 1, [-inf,inf], "",
68      "Layer scattering length density" ],
69    [ "solvent_sld", "1e-6/Ang^2", 6, [-inf,inf], "",
70      "Solvent scattering length density" ],
71    [ "thickness", "Ang",  50, [0, inf], "volume",
72      "Bilayer thickness" ],
73    ]
74
75
76# No volume normalization despite having a volume parameter
77# This should perhaps be volume normalized?
78form_volume = """
79    return REAL(1.0);
80    """
81
82Iq = """
83    const real sub = sld - solvent_sld;
84    const real qsq = q*q;
85    return REAL(4.0e-4)*M_PI*sub*sub/qsq * (REAL(1.0)-cos(q*thickness))
86        / (thickness*qsq);
87    """
88
89Iqxy = """
90    // never called since no orientation or magnetic parameters.
91    return REAL(-1.0);
92    """
93
94# ER defaults to 0.0
95# VR defaults to 1.0
Note: See TracBrowser for help on using the repository browser.