Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • sasmodels/models/bcc_paracrystal.py

    re7e9231 rda7b26b  
    11r""" 
     2.. warning:: This model and this model description are under review following  
     3             concerns raised by SasView users. If you need to use this model,  
     4             please email help@sasview.org for the latest situation. *The  
     5             SasView Developers. September 2018.* 
     6 
    27Definition 
    38---------- 
     
    1318 
    1419    I(q) = \frac{\text{scale}}{V_p} V_\text{lattice} P(q) Z(q) 
    15  
    1620 
    1721where *scale* is the volume fraction of spheres, $V_p$ is the volume of the 
     
    3034.. math:: 
    3135 
    32     V_\text{lattice} = \frac{8\pi}{3} \frac{R^3}{\left(2D/\sqrt{3}\right)^3} 
     36    V_\text{lattice} = \frac{16\pi}{3} \frac{R^3}{\left(D\sqrt{2}\right)^3} 
    3337 
    3438 
     
    97101 
    98102Authorship and Verification 
    99 ---------------------------- 
     103--------------------------- 
    100104 
    101105* **Author:** NIST IGOR/DANSE **Date:** pre 2010 
    102 * **Last Modified by:** Paul Butler **Date:** September 16, 2018 
    103 * **Last Reviewed by:** Paul Butler **Date:** September 16, 2018 
     106* **Last Modified by:** Paul Butler **Date:** September 29, 2016 
     107* **Last Reviewed by:** Richard Heenan **Date:** March 21, 2016 
    104108""" 
    105109 
     
    123127# pylint: disable=bad-whitespace, line-too-long 
    124128#             ["name", "units", default, [lower, upper], "type","description" ], 
    125 parameters = [["lattice_spacing",         "Ang",       220,    [-inf, inf], "",            "Lattice spacing"], 
    126               ["lattice_distortion",    "",            0.06, [-inf, inf], "",            "Paracrystal distortion factor"], 
     129parameters = [["dnn",         "Ang",       220,    [-inf, inf], "",            "Nearest neighbour distance"], 
     130              ["d_factor",    "",            0.06, [-inf, inf], "",            "Paracrystal distortion factor"], 
    127131              ["radius",      "Ang",        40,    [0, inf],    "volume",      "Particle radius"], 
    128132              ["sld",         "1e-6/Ang^2",  4,    [-inf, inf], "sld",         "Particle scattering length density"], 
     
    145149    # in this range 'cuz its easy. 
    146150    radius = 10**np.random.uniform(1.3, 4) 
    147     lattice_distortion = 10**np.random.uniform(-2, -0.7)  # sigma_d in 0.01-0.7 
    148     lattice_spacing_fraction = np.random.beta(a=10, b=1) 
    149     lattice_spacing = radius*4/np.sqrt(3)/lattice_spacing_fraction 
     151    d_factor = 10**np.random.uniform(-2, -0.7)  # sigma_d in 0.01-0.7 
     152    dnn_fraction = np.random.beta(a=10, b=1) 
     153    dnn = radius*4/np.sqrt(3)/dnn_fraction 
    150154    pars = dict( 
    151155        #sld=1, sld_solvent=0, scale=1, background=1e-32, 
    152         lattice_spacing=lattice_spacing, 
    153         lattice_distortion=lattice_distortion, 
     156        dnn=dnn, 
     157        d_factor=d_factor, 
    154158        radius=radius, 
    155159    ) 
Note: See TracChangeset for help on using the changeset viewer.