Changeset 2222134 in sasmodels for sasmodels/models/core_shell_ellipsoid_xt.py
- Timestamp:
- Sep 30, 2016 9:07:16 AM (7 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:
- a807206
- Parents:
- 6e5b2a7
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/models/core_shell_ellipsoid_xt.py
r40a87fa r2222134 14 14 The geometric parameters of this model are 15 15 16 * equat_core =* equatorial core radius *= R_minor_core*16 *radius_equat_core =* equatorial core radius *= R_minor_core* 17 17 18 *X_core = polar_core / equat_core = Rmajor_core / Rminor_core*18 *X_core = polar_core / radius_equat_core = Rmajor_core / Rminor_core* 19 19 20 *T _shell = equat_outer -equat_core = Rminor_outer - Rminor_core*20 *Thick_shell = equat_outer - radius_equat_core = Rminor_outer - Rminor_core* 21 21 22 *XpolarShell = Tpolar_shell / T _shell = (Rmajor_outer - Rmajor_core)/22 *XpolarShell = Tpolar_shell / Thick_shell = (Rmajor_outer - Rmajor_core)/ 23 23 (Rminor_outer - Rminor_core)* 24 24 25 25 In terms of the original radii 26 26 27 *polar_core = equat_core * X_core*27 *polar_core = radius_equat_core * X_core* 28 28 29 *equat_shell = equat_core + T_shell*29 *equat_shell = radius_equat_core + Thick_shell* 30 30 31 *polar_shell = equat_core * X_core + T_shell * XpolarShell*31 *polar_shell = radius_equat_core * X_core + Thick_shell * XpolarShell* 32 32 33 33 (where we note that "shell" perhaps confusingly, relates to the outer radius) … … 68 68 single particle scattering amplitude. 69 69 [Parameters]: 70 equat_core = equatorial radius of core,70 radius_equat_core = equatorial radius of core, 71 71 x_core = ratio of core polar/equatorial radii, 72 t _shell = equatorial radius of outer surface,72 thick_shell = equatorial radius of outer surface, 73 73 x_polar_shell = ratio of polar shell thickness to equatorial shell thickness, 74 74 sld_core = SLD_core … … 88 88 # ["name", "units", default, [lower, upper], "type", "description"], 89 89 parameters = [ 90 [" equat_core", "Ang",20, [0, inf], "volume", "Equatorial radius of core"],90 ["radius_equat_core","Ang", 20, [0, inf], "volume", "Equatorial radius of core"], 91 91 ["x_core", "None", 3, [0, inf], "volume", "axial ratio of core, X = r_polar/r_equatorial"], 92 ["t _shell","Ang", 30, [0, inf], "volume", "thickness of shell at equator"],92 ["thick_shell", "Ang", 30, [0, inf], "volume", "thickness of shell at equator"], 93 93 ["x_polar_shell", "", 1, [0, inf], "volume", "ratio of thickness of shell at pole to that at equator"], 94 94 ["sld_core", "1e-6/Ang^2", 2, [-inf, inf], "sld", "Core scattering length density"], … … 103 103 "core_shell_ellipsoid_xt.c"] 104 104 105 def ER( equat_core, x_core, t_shell, x_polar_shell):105 def ER(radius_equat_core, x_core, thick_shell, x_polar_shell): 106 106 """ 107 107 Returns the effective radius used in the S*P calculation 108 108 """ 109 109 from .ellipsoid import ER as ellipsoid_ER 110 polar_outer = equat_core*x_core + t_shell*x_polar_shell111 equat_outer = equat_core + t_shell110 polar_outer = radius_equat_core*x_core + thick_shell*x_polar_shell 111 equat_outer = radius_equat_core + thick_shell 112 112 return ellipsoid_ER(polar_outer, equat_outer) 113 113 114 114 115 115 demo = dict(scale=0.05, background=0.001, 116 equat_core=20.0,116 radius_equat_core=20.0, 117 117 x_core=3.0, 118 t _shell=30.0,118 thick_shell=30.0, 119 119 x_polar_shell=1.0, 120 120 sld_core=2.0, … … 131 131 tests = [ 132 132 # Accuracy tests based on content in test/utest_coreshellellipsoidXTmodel.py 133 [{' equat_core': 200.0,133 [{'radius_equat_core': 200.0, 134 134 'x_core': 0.1, 135 't _shell': 50.0,135 'thick_shell': 50.0, 136 136 'x_polar_shell': 0.2, 137 137 'sld_core': 2.0, … … 145 145 [{'background': 0.01}, 0.1, 11.6915], 146 146 147 [{' equat_core': 20.0,147 [{'radius_equat_core': 20.0, 148 148 'x_core': 200.0, 149 't _shell': 54.0,149 'thick_shell': 54.0, 150 150 'x_polar_shell': 3.0, 151 151 'sld_core': 20.0, … … 158 158 [{'background': 0.001}, (0.4, 0.5), 0.00690673], 159 159 160 [{' equat_core': 20.0,160 [{'radius_equat_core': 20.0, 161 161 'x_core': 200.0, 162 't _shell': 54.0,162 'thick_shell': 54.0, 163 163 'x_polar_shell': 3.0, 164 164 'sld_core': 20.0,
Note: See TracChangeset
for help on using the changeset viewer.