Changeset 40a87fa in sasmodels for sasmodels/models/core_shell_ellipsoid.py
- Timestamp:
- Aug 8, 2016 11:24:11 AM (8 years ago)
- Branches:
- master, core_shell_microgels, costrafo411, magnetic_model, release_v0.94, release_v0.95, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
- Children:
- 2472141
- Parents:
- 2d65d51
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/models/core_shell_ellipsoid.py
r7f1ee79 r40a87fa 5 5 .. math:: 6 6 7 P(q) = scale * \left<f^2\right>/V + background7 P(q) = \text{scale} * \left<f^2\right>/V + \text{background} 8 8 9 where the volume $V = (4/3)\pi( R_{major\_outer}R_{minor\_outer}^2)$ and the averaging $< >$ is10 a pplied over all orientations for 1D.9 where the volume $V = (4/3)\pi(r_\text{major outer} r_\text{minor outer}^2)$ 10 and the averaging $< >$ is applied over all orientations for 1D. 11 11 12 12 .. figure:: img/core_shell_ellipsoid_geometry.png 13 13 14 The returned value is in units of $cm^{-1}$, on absolute scale.14 The returned value is in units of |cm^-1|, on absolute scale. 15 15 16 16 Definition … … 21 21 .. math:: 22 22 23 P(q) = \frac{scale}{V}\int_0^1 24 \left|F(q,r_{minor\_core},r_{major\_core},\alpha) + F(q,r_{major\_outer},r_{major\_outer},\alpha)\right|^2d\alpha + background 23 P(q) &= \frac{\text{scale}}{V}\int_0^1 24 \left|F(q,r_\text{minor core},r_\text{major core},\alpha) 25 + F(q,r_\text{minor outer},r_\text{major outer},\alpha)\right|^2 26 d\alpha 27 + \text{background} 25 28 26 \left|F(q,r_{minor},r_{major},\alpha)\right|=(4\pi/3)r_{major}r_{minor}^2 \Delta \rho \cdot (3j_1(u)/u) 29 \left|F(q,r_\text{minor},r_\text{major},\alpha)\right| 30 &=(4\pi/3)r_\text{major}r_\text{minor}^2 \Delta \rho \cdot (3j_1(u)/u) 27 31 28 u = q\left[ r_{major}^2\alpha ^2 + r_{minor}^2(1-\alpha ^2)\right]^{1/2} 32 u &= q\left[ r_\text{major}^2\alpha ^2 33 + r_\text{minor}^2(1-\alpha ^2)\right]^{1/2} 29 34 30 35 where … … 40 45 The contrast is defined as SLD(core) - SLD(shell) and SLD(shell) - SLD(solvent). 41 46 42 In the parameters, *equat_core* = equatorial core radius, *polar_core* = 43 polar core radius, *equat_shell* = $r_{min}$ (or equatorial outer radius), 44 and *polar_shell* = $r_{maj}$ (or polar outer radius). 45 46 Note:It is the users' responsibility to ensure that shell radii are larger than 47 Note: It is the users' responsibility to ensure that shell radii are larger than 47 48 the core radii, especially if both are polydisperse, in which case the 48 49 core_shell_ellipsoid_xt model may be much better. … … 67 68 68 69 S J Berr, *Phys. Chem.*, 91 (1987) 4760 69 70 70 """ 71 71 … … 100 100 101 101 # pylint: disable=bad-whitespace, line-too-long 102 # 102 # ["name", "units", default, [lower, upper], "type", "description"], 103 103 parameters = [ 104 ["equat_core", "Ang", 200, [0, inf], "volume", "Equatorial radius of core, Rminor_core"],105 ["polar_core", "Ang", 10, [0, inf], "volume", "Polar radius of core, Rmajor_core"],106 ["equat_shell", "Ang", 250, [0, inf], "volume", "Equatorial radius of shell, Rminor_outer"],107 ["polar_shell", "Ang", 30, [0, inf], "volume", "Polar radius of shell, Rmajor_outer"],108 ["sld_core", "1e-6/Ang^2", 2, [-inf, inf], "sld", 109 ["sld_shell", "1e-6/Ang^2", 1, [-inf, inf], "sld", 110 ["sld_solvent", "1e-6/Ang^2", 6.3, [-inf, inf], "sld", 104 ["equat_core", "Ang", 200, [0, inf], "volume", "Equatorial radius of core, r minor core"], 105 ["polar_core", "Ang", 10, [0, inf], "volume", "Polar radius of core, r major core"], 106 ["equat_shell", "Ang", 250, [0, inf], "volume", "Equatorial radius of shell, r minor outer"], 107 ["polar_shell", "Ang", 30, [0, inf], "volume", "Polar radius of shell, r major outer"], 108 ["sld_core", "1e-6/Ang^2", 2, [-inf, inf], "sld", "Core scattering length density"], 109 ["sld_shell", "1e-6/Ang^2", 1, [-inf, inf], "sld", "Shell scattering length density"], 110 ["sld_solvent", "1e-6/Ang^2", 6.3, [-inf, inf], "sld", "Solvent scattering length density"], 111 111 ["theta", "degrees", 0, [-inf, inf], "orientation", "Oblate orientation wrt incoming beam"], 112 112 ["phi", "degrees", 0, [-inf, inf], "orientation", "Oblate orientation in the plane of the detector"], … … 120 120 Returns the effective radius used in the S*P calculation 121 121 """ 122 import numpy as np123 122 from .ellipsoid import ER as ellipsoid_ER 124 123 return ellipsoid_ER(polar_shell, equat_shell)
Note: See TracChangeset
for help on using the changeset viewer.