Changes in / [8678a34:a0ebc96] in sasmodels
- Location:
- sasmodels/models
- Files:
-
- 1 added
- 1 deleted
- 20 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/models/barbell.py
r0b56f38 r9802ab3 68 68 The 2D scattering intensity is calculated similar to the 2D cylinder model. 69 69 70 .. figure:: img/cylinder_angle_definition. jpg70 .. figure:: img/cylinder_angle_definition.png 71 71 72 72 Definition of the angles for oriented 2D barbells. … … 108 108 ["radius", "Ang", 20, [0, inf], "volume", "Cylindrical bar radius"], 109 109 ["length", "Ang", 400, [0, inf], "volume", "Cylinder bar length"], 110 ["theta", "degrees", 60, [- inf, inf], "orientation", "In planeangle"],111 ["phi", "degrees", 60, [- inf, inf], "orientation", "Out of plane angle"],110 ["theta", "degrees", 60, [-360, 360], "orientation", "Barbell axis to beam angle"], 111 ["phi", "degrees", 60, [-360, 360], "orientation", "Rotation about beam"], 112 112 ] 113 113 # pylint: enable=bad-whitespace, line-too-long -
sasmodels/models/bcc_paracrystal.py
r1f65db5 r69e1afc 123 123 ["sld", "1e-6/Ang^2", 4, [-inf, inf], "sld", "Particle scattering length density"], 124 124 ["sld_solvent", "1e-6/Ang^2", 1, [-inf, inf], "sld", "Solvent scattering length density"], 125 ["theta", "degrees", 60, [- inf, inf], "orientation", "In planeangle"],126 ["phi", "degrees", 60, [- inf, inf], "orientation", "Out of plane angle"],127 ["psi", "degrees", 60, [- inf, inf], "orientation", "Out of plane angle"]125 ["theta", "degrees", 60, [-360, 360], "orientation", "c axis to beam angle"], 126 ["phi", "degrees", 60, [-360, 360], "orientation", "rotation about beam"], 127 ["psi", "degrees", 60, [-360, 360], "orientation", "rotation about c axis"] 128 128 ] 129 129 # pylint: enable=bad-whitespace, line-too-long … … 148 148 [{ }, 149 149 [0.001, q, 0.215268], [1.46601394721, 2.85851284174, 0.00866710287078]], 150 ] 150 [{'theta':20.0,'phi':30,'psi':40.0},(-0.017,0.035),2082.20264399 ], 151 [{'theta':20.0,'phi':30,'psi':40.0},(-0.081,0.011),0.436323144781 ] 152 ] -
sasmodels/models/capped_cylinder.py
r0b56f38 r9802ab3 71 71 The 2D scattering intensity is calculated similar to the 2D cylinder model. 72 72 73 .. figure:: img/cylinder_angle_definition. jpg73 .. figure:: img/cylinder_angle_definition.png 74 74 75 75 Definition of the angles for oriented 2D cylinders. … … 129 129 ["radius_cap", "Ang", 20, [0, inf], "volume", "Cap radius"], 130 130 ["length", "Ang", 400, [0, inf], "volume", "Cylinder length"], 131 ["theta", "degrees", 60, [- inf, inf], "orientation", "inclinationangle"],132 ["phi", "degrees", 60, [- inf, inf], "orientation", "deflection angle"],131 ["theta", "degrees", 60, [-360, 360], "orientation", "cylinder axis to beam angle"], 132 ["phi", "degrees", 60, [-360, 360], "orientation", "rotation about beam"], 133 133 ] 134 134 # pylint: enable=bad-whitespace, line-too-long -
sasmodels/models/core_shell_bicelle.py
r0b56f38 r9802ab3 47 47 .. math:: 48 48 49 49 \begin{align} 50 50 F(Q,\alpha) = &\bigg[ 51 51 (\rho_c - \rho_f) V_c \frac{2J_1(QRsin \alpha)}{QRsin\alpha}\frac{sin(QLcos\alpha/2)}{Q(L/2)cos\alpha} \\ … … 63 63 cylinders is then given by integrating over all possible $\theta$ and $\phi$. 64 64 65 The *theta* and *phi* parameters are not used for the 1D output. 65 For oriented bicelles the *theta*, and *phi* orientation parameters will appear when fitting 2D data, 66 see the :ref:`cylinder` model for further information. 66 67 Our implementation of the scattering kernel and the 1D scattering intensity 67 68 use the c-library from NIST. 68 69 69 .. figure:: img/cylinder_angle_definition. jpg70 .. figure:: img/cylinder_angle_definition.png 70 71 71 Definition of the angles for the oriented core shell bicelle tmodel. 72 Definition of the angles for the oriented core shell bicelle model, 73 note that the cylinder axis of the bicelle starts along the beam direction 74 when $\theta = \phi = 0$. 72 75 73 76 … … 135 138 ["sld_rim", "1e-6/Ang^2", 4, [-inf, inf], "sld", "Cylinder rim scattering length density"], 136 139 ["sld_solvent", "1e-6/Ang^2", 1, [-inf, inf], "sld", "Solvent scattering length density"], 137 ["theta", "degrees", 90, [- inf, inf], "orientation", "In planeangle"],138 ["phi", "degrees", 0, [- inf, inf], "orientation", "Out of plane angle"],140 ["theta", "degrees", 90, [-360, 360], "orientation", "cylinder axis to beam angle"], 141 ["phi", "degrees", 0, [-360, 360], "orientation", "rotation about beam"] 139 142 ] 140 143 … … 160 163 qy = q*sin(pi/6.0) 161 164 tests = [[{}, 0.05, 7.4883545957], 162 [{'theta':80., 'phi':10.}, (qx, qy), 2.81048892474 ] ,165 [{'theta':80., 'phi':10.}, (qx, qy), 2.81048892474 ] 163 166 ] 164 167 del qx, qy # not necessary to delete, but cleaner -
sasmodels/models/core_shell_bicelle_elliptical.c
r44e8a93 rdedcf34 24 24 double si1,si2,be1,be2; 25 25 // core_shell_bicelle_elliptical, RKH Dec 2016, based on elliptical_cylinder and core_shell_bicelle 26 // tested against limiting cases of cylinder, elliptical_cylinder and core_shell_bicelle26 // tested against limiting cases of cylinder, elliptical_cylinder, stacked_discs, and core_shell_bicelle 27 27 // const double uplim = M_PI_4; 28 28 const double halfheight = 0.5*length; … … 34 34 35 35 const double r_major = r_minor * x_core; 36 const double r A = 0.5*(square(r_major) + square(r_minor));37 const double r B = 0.5*(square(r_major) - square(r_minor));36 const double r2A = 0.5*(square(r_major) + square(r_minor)); 37 const double r2B = 0.5*(square(r_major) - square(r_minor)); 38 38 const double dr1 = (rhoc-rhoh) *M_PI*r_minor*r_major*(2.0*halfheight);; 39 39 const double dr2 = (rhor-rhosolv)*M_PI*(r_minor+thick_rim)*(r_major+thick_rim)*2.0*(halfheight+thick_face); … … 60 60 //const double beta = ( Gauss76Z[j]*(vbj-vaj) + vaj + vbj )/2.0; 61 61 const double beta = ( Gauss76Z[j] +1.0)*M_PI_2; 62 const double rr = sqrt(r A - rB*cos(beta));62 const double rr = sqrt(r2A - r2B*cos(beta)); 63 63 double besarg1 = q*rr*sin_alpha; 64 64 double besarg2 = q*(rr+thick_rim)*sin_alpha; -
sasmodels/models/core_shell_bicelle_elliptical.py
r15a90c1 r9802ab3 76 76 bicelles is then given by integrating over all possible $\alpha$ and $\psi$. 77 77 78 For oriented bicell les the *theta*, *phi* and *psi* orientation parameters onlyappear when fitting 2D data,78 For oriented bicelles the *theta*, *phi* and *psi* orientation parameters will appear when fitting 2D data, 79 79 see the :ref:`elliptical-cylinder` model for further information. 80 80 … … 119 119 ["radius", "Ang", 30, [0, inf], "volume", "Cylinder core radius"], 120 120 ["x_core", "None", 3, [0, inf], "volume", "axial ratio of core, X = r_polar/r_equatorial"], 121 ["thick_rim", "Ang", 8, [0, inf], "volume", "Rim shell thickness"],122 ["thick_face", "Ang", 14, [0, inf], "volume", "Cylinder face thickness"],123 ["length", "Ang", 50, [0, inf], "volume", "Cylinder length"],121 ["thick_rim", "Ang", 8, [0, inf], "volume", "Rim shell thickness"], 122 ["thick_face", "Ang", 14, [0, inf], "volume", "Cylinder face thickness"], 123 ["length", "Ang", 50, [0, inf], "volume", "Cylinder length"], 124 124 ["sld_core", "1e-6/Ang^2", 4, [-inf, inf], "sld", "Cylinder core scattering length density"], 125 125 ["sld_face", "1e-6/Ang^2", 7, [-inf, inf], "sld", "Cylinder face scattering length density"], 126 126 ["sld_rim", "1e-6/Ang^2", 1, [-inf, inf], "sld", "Cylinder rim scattering length density"], 127 127 ["sld_solvent", "1e-6/Ang^2", 6, [-inf, inf], "sld", "Solvent scattering length density"], 128 ["theta", "degrees", 90, [-360, 360], "orientation", "In planeangle"],129 ["phi", "degrees", 0, [-360, 360], "orientation", "Out of plane angle"],130 ["psi", "degrees", 0, [-360, 360], "orientation", "Major axis angle relative to Q"],128 ["theta", "degrees", 90.0, [-360, 360], "orientation", "cylinder axis to beam angle"], 129 ["phi", "degrees", 0, [-360, 360], "orientation", "rotation about beam"], 130 ["psi", "degrees", 0, [-360, 360], "orientation", "rotation about cylinder axis"] 131 131 ] 132 132 -
sasmodels/models/core_shell_cylinder.py
r0b56f38 r9b79f29 117 117 ["length", "Ang", 400, [0, inf], "volume", 118 118 "Cylinder length"], 119 ["theta", "degrees", 60, [- inf, inf], "orientation",120 " In planeangle"],121 ["phi", "degrees", 60, [-inf, inf], "orientation",122 " Out of plane angle"],119 ["theta", "degrees", 60, [-360, 360], "orientation", 120 "cylinder axis to beam angle"], 121 ["phi", "degrees", 60, [-360, 360], "orientation", 122 "rotation about beam"], 123 123 ] 124 124 -
sasmodels/models/core_shell_ellipsoid.py
r8e68ea0 r9802ab3 77 77 F^2(q)=\int_{0}^{\pi/2}{F^2(q,\alpha)\sin(\alpha)d\alpha} 78 78 79 For oriented ellipsoids the *theta*, *phi* and *psi* orientation parameters will appear when fitting 2D data, 80 see the :ref:`elliptical-cylinder` model for further information. 79 81 80 82 References … … 132 134 ["sld_shell", "1e-6/Ang^2", 1, [-inf, inf], "sld", "Shell scattering length density"], 133 135 ["sld_solvent", "1e-6/Ang^2", 6.3, [-inf, inf], "sld", "Solvent scattering length density"], 134 ["theta", "degrees", 0, [- inf, inf], "orientation", "Oblate orientation wrt incoming beam"],135 ["phi", "degrees", 0, [- inf, inf], "orientation", "Oblate orientation in the plane of the detector"],136 ["theta", "degrees", 0, [-360, 360], "orientation", "elipsoid axis to beam angle"], 137 ["phi", "degrees", 0, [-360, 360], "orientation", "rotation about beam"], 136 138 ] 137 139 # pylint: enable=bad-whitespace, line-too-long -
sasmodels/models/core_shell_parallelepiped.py
r1f65db5 r9b79f29 153 153 ["thick_rim_c", "Ang", 10, [0, inf], "volume", 154 154 "Thickness of C rim"], 155 ["theta", "degrees", 0, [- inf, inf], "orientation",156 " In planeangle"],157 ["phi", "degrees", 0, [- inf, inf], "orientation",158 " Out of plane angle"],159 ["psi", "degrees", 0, [- inf, inf], "orientation",160 " Rotation angle around its own c axis against q plane"],155 ["theta", "degrees", 0, [-360, 360], "orientation", 156 "c axis to beam angle"], 157 ["phi", "degrees", 0, [-360, 360], "orientation", 158 "rotation about beam"], 159 ["psi", "degrees", 0, [-360, 360], "orientation", 160 "rotation about c axis"], 161 161 ] 162 162 -
sasmodels/models/cylinder.py
r3330bb4 r9802ab3 61 61 .. _cylinder-angle-definition: 62 62 63 .. figure:: img/cylinder_angle_definition. jpg63 .. figure:: img/cylinder_angle_definition.png 64 64 65 Definition of the angles for oriented cylinders. 65 Definition of the $\theta$ and $\phi$ orientation angles for a cylinder relative 66 to the beam line coordinates, plus an indication of their orientation distributions 67 which are described as rotations about each of the perpendicular axes $\delta_1$ and $\delta_2$ 68 in the frame of the cylinder itself, which when $\theta = \phi = 0$ are parallel to the $Y$ and $X$ axes. 66 69 67 70 .. figure:: img/cylinder_angle_projection.png … … 69 72 Examples for oriented cylinders. 70 73 71 The $\theta$ and $\phi$ parameters only appear in the model when fitting 2d data. 74 The $\theta$ and $\phi$ parameters to orient the cylinder only appear in the model when fitting 2d data. 75 On introducing "Orientational Distribution" in the angles, "distribution of theta" and "distribution of phi" parameters will 76 appear. These are actually rotations about the axes $\delta_1$ and $\delta_2$ of the cylinder, which when $\theta = \phi = 0$ are parallel 77 to the $Y$ and $X$ axes of the instrument respectively. Some experimentation may be required to understand the 2d patterns fully. 78 (Earlier implementations had numerical integration issues in some circumstances when orientation distributions passed through 90 degrees, such 79 situations, with very broad distributions, should still be approached with care.) 72 80 73 81 Validation … … 127 135 ["length", "Ang", 400, [0, inf], "volume", 128 136 "Cylinder length"], 129 ["theta", "degrees", 60, [- inf, inf], "orientation",130 " latitude"],131 ["phi", "degrees", 60, [-inf, inf], "orientation",132 " longitude"],137 ["theta", "degrees", 60, [-360, 360], "orientation", 138 "cylinder axis to beam angle"], 139 ["phi", "degrees", 60, [-360, 360], "orientation", 140 "rotation about beam"], 133 141 ] 134 142 -
sasmodels/models/ellipsoid.py
r0b56f38 r9b79f29 151 151 ["radius_equatorial", "Ang", 400, [0, inf], "volume", 152 152 "Equatorial radius"], 153 ["theta", "degrees", 60, [- inf, inf], "orientation",154 " In planeangle"],155 ["phi", "degrees", 60, [- inf, inf], "orientation",156 " Out of plane angle"],153 ["theta", "degrees", 60, [-360, 360], "orientation", 154 "ellipsoid axis to beam angle"], 155 ["phi", "degrees", 60, [-360, 360], "orientation", 156 "rotation about beam"], 157 157 ] 158 158 -
sasmodels/models/elliptical_cylinder.py
r15a90c1 r9802ab3 57 57 define the axis of the cylinder using two angles $\theta$, $\phi$ and $\Psi$ 58 58 (see :ref:`cylinder orientation <cylinder-angle-definition>`). The angle 59 $\Psi$ is the rotational angle around its own long_c axis against the $q$ plane. 60 For example, $\Psi = 0$ when the $r_\text{minor}$ axis is parallel to the 61 $x$ axis of the detector. 59 $\Psi$ is the rotational angle around its own long_c axis. 62 60 63 61 All angle parameters are valid and given only for 2D calculation; ie, an … … 66 64 .. figure:: img/elliptical_cylinder_angle_definition.png 67 65 68 Definition of angles for oriented elliptical cylinder, where axis_ratio >1,69 and angle $\Psi$ is a rotation around the axis of the cylinder.66 Definition of angles for oriented elliptical cylinder, where axis_ratio is drawn >1, 67 and angle $\Psi$ is now a rotation around the axis of the cylinder. 70 68 71 69 .. figure:: img/elliptical_cylinder_angle_projection.png … … 73 71 Examples of the angles for oriented elliptical cylinders against the 74 72 detector plane, with $\Psi$ = 0. 73 74 The $\theta$ and $\phi$ parameters to orient the cylinder only appear in the model when fitting 2d data. 75 On introducing "Orientational Distribution" in the angles, "distribution of theta" and "distribution of phi" parameters will 76 appear. These are actually rotations about the axes $\delta_1$ and $\delta_2$ of the cylinder, the $b$ and $a$ axes of the 77 cylinder cross section. (When $\theta = \phi = 0$ these are parallel to the $Y$ and $X$ axes of the instrument.) 78 The third orientation distribution, in $\psi$, is about the $c$ axis of the particle. Some experimentation may be required to 79 understand the 2d patterns fully. (Earlier implementations had numerical integration issues in some circumstances when orientation 80 distributions passed through 90 degrees, such situations, with very broad distributions, should still be approached with care.) 75 81 76 82 NB: The 2nd virial coefficient of the cylinder is calculated based on the … … 126 132 ["sld", "1e-6/Ang^2", 4.0, [-inf, inf], "sld", "Cylinder scattering length density"], 127 133 ["sld_solvent", "1e-6/Ang^2", 1.0, [-inf, inf], "sld", "Solvent scattering length density"], 128 ["theta", "degrees", 90.0, [-360, 360], "orientation", " In planeangle"],129 ["phi", "degrees", 0, [-360, 360], "orientation", " Out of plane angle"],130 ["psi", "degrees", 0, [-360, 360], "orientation", " Major axis angle relative to Q"]]134 ["theta", "degrees", 90.0, [-360, 360], "orientation", "cylinder axis to beam angle"], 135 ["phi", "degrees", 0, [-360, 360], "orientation", "rotation about beam"], 136 ["psi", "degrees", 0, [-360, 360], "orientation", "rotation about cylinder axis"]] 131 137 132 138 # pylint: enable=bad-whitespace, line-too-long -
sasmodels/models/fcc_paracrystal.py
r1f65db5 r69e1afc 111 111 ["sld", "1e-6/Ang^2", 4, [-inf, inf], "sld", "Particle scattering length density"], 112 112 ["sld_solvent", "1e-6/Ang^2", 1, [-inf, inf], "sld", "Solvent scattering length density"], 113 ["theta", "degrees", 60, [-inf, inf], "orientation", "In planeangle"],114 ["phi", "degrees", 60, [-inf, inf], "orientation", "Out of plane angle"],115 ["psi", "degrees", 60, [-inf, inf], "orientation", "Out of plane angle"]113 ["theta", "degrees", 60, [-360, 360], "orientation", "c axis to beam angle"], 114 ["phi", "degrees", 60, [-360, 360], "orientation", "rotation about beam"], 115 ["psi", "degrees", 60, [-360, 360], "orientation", "rotation about c axis"] 116 116 ] 117 117 # pylint: enable=bad-whitespace, line-too-long … … 129 129 psi_pd=15, psi_pd_n=0, 130 130 ) 131 # april 6 2017, rkh add unit tests, NOT compared with any other calc method, assume correct! 132 # add 2d test later 131 # april 10 2017, rkh add unit tests, NOT compared with any other calc method, assume correct! 133 132 q =4.*pi/220. 134 133 tests = [ 135 134 [{ }, 136 135 [0.001, q, 0.215268], [0.275164706668, 5.7776842567, 0.00958167119232]], 136 [{}, (-0.047,-0.007), 238.103096286], 137 [{}, (0.053,0.063), 0.863609587796 ], 137 138 ] -
sasmodels/models/hollow_cylinder.py
r0b56f38 r9b79f29 82 82 ["sld", "1/Ang^2", 6.3, [-inf, inf], "sld", "Cylinder sld"], 83 83 ["sld_solvent", "1/Ang^2", 1, [-inf, inf], "sld", "Solvent sld"], 84 ["theta", "degrees", 90, [-360, 360], "orientation", " Thetaangle"],85 ["phi", "degrees", 0, [-360, 360], "orientation", " Phi angle"],84 ["theta", "degrees", 90, [-360, 360], "orientation", "Cylinder axis to beam angle"], 85 ["phi", "degrees", 0, [-360, 360], "orientation", "Rotation about beam"], 86 86 ] 87 87 # pylint: enable=bad-whitespace, line-too-long -
sasmodels/models/parallelepiped.py
rafd4692 r9802ab3 9 9 ---------- 10 10 11 |This model calculates the scattering from a rectangular parallelepiped12 |(\:numref:`parallelepiped-image`\).13 |If you need to apply polydispersity, see also :ref:`rectangular-prism`.11 This model calculates the scattering from a rectangular parallelepiped 12 (\:numref:`parallelepiped-image`\). 13 If you need to apply polydispersity, see also :ref:`rectangular-prism`. 14 14 15 15 .. _parallelepiped-image: … … 67 67 68 68 \mu &= qB 69 70 69 71 70 The scattering intensity per unit volume is returned in units of |cm^-1|. … … 113 112 detector plane. 114 113 114 On introducing "Orientational Distribution" in the angles, "distribution of theta" and "distribution of phi" parameters will 115 appear. These are actually rotations about axes $\delta_1$ and $\delta_2$ of the parallelepiped, perpendicular to the $a$ x $c$ and $b$ x $c$ faces. 116 (When $\theta = \phi = 0$ these are parallel to the $Y$ and $X$ axes of the instrument.) The third orientation distribution, in $\psi$, is 117 about the $c$ axis of the particle, perpendicular to the $a$ x $b$ face. Some experimentation may be required to 118 understand the 2d patterns fully. (Earlier implementations had numerical integration issues in some circumstances when orientation 119 distributions passed through 90 degrees, such situations, with very broad distributions, should still be approached with care.) 120 121 115 122 For a given orientation of the parallelepiped, the 2D form factor is 116 123 calculated as … … 168 175 169 176 * **Author:** This model is based on form factor calculations implemented 170 in a c-library provided by the NIST Center for Neutron Research (Kline, 2006).177 in a c-library provided by the NIST Center for Neutron Research (Kline, 2006). 171 178 * **Last Modified by:** Paul Kienzle **Date:** April 05, 2017 172 179 * **Last Reviewed by:** Richard Heenan **Date:** April 06, 2017 … … 205 212 ["length_c", "Ang", 400, [0, inf], "volume", 206 213 "Larger side of the parallelepiped"], 207 ["theta", "degrees", 60, [- inf, inf], "orientation",208 " In planeangle"],209 ["phi", "degrees", 60, [- inf, inf], "orientation",210 " Out of plane angle"],211 ["psi", "degrees", 60, [- inf, inf], "orientation",212 " Rotation angle around its own c axis against q plane"],214 ["theta", "degrees", 60, [-360, 360], "orientation", 215 "c axis to beam angle"], 216 ["phi", "degrees", 60, [-360, 360], "orientation", 217 "rotation about beam"], 218 ["psi", "degrees", 60, [-360, 360], "orientation", 219 "rotation about c axis"], 213 220 ] 214 221 -
sasmodels/models/sc_paracrystal.py
r0881f4e r69e1afc 130 130 ["sld", "1e-6/Ang^2", 3.0, [0.0, inf], "sld", "Sphere scattering length density"], 131 131 ["sld_solvent", "1e-6/Ang^2", 6.3, [0.0, inf], "sld", "Solvent scattering length density"], 132 ["theta", "degrees", 0.0, [-inf, inf], "orientation", "Orientation of the a1 axis w/respect incoming beam"],133 ["phi", "degrees", 0.0, [-inf, inf], "orientation", "Orientation of the a2 in the plane of the detector"],134 ["psi", "degrees", 0.0, [-inf, inf], "orientation", "Orientation of the a3 in the plane of the detector"],132 ["theta", "degrees", 0, [-360, 360], "orientation", "c axis to beam angle"], 133 ["phi", "degrees", 0, [-360, 360], "orientation", "rotation about beam"], 134 ["psi", "degrees", 0, [-360, 360], "orientation", "rotation about c axis"] 135 135 ] 136 136 # pylint: enable=bad-whitespace, line-too-long … … 149 149 150 150 tests = [ 151 # Accuracy tests based on content in test/utest_extra_models.py 151 # Accuracy tests based on content in test/utest_extra_models.py, 2d tests added April 10, 2017 152 152 [{}, 0.001, 10.3048], 153 153 [{}, 0.215268, 0.00814889], 154 [{}, (0.414467), 0.001313289] 154 [{}, (0.414467), 0.001313289], 155 [{'theta':10.0,'phi':20,'psi':30.0},(0.045,-0.035),18.0397138402 ], 156 [{'theta':10.0,'phi':20,'psi':30.0},(0.023,0.045),0.0177333171285 ] 155 157 ] 156 158 -
sasmodels/models/stacked_disks.py
rf3073b0 r9802ab3 77 77 the axis of the cylinder using two angles $\theta$ and $\varphi$. 78 78 79 .. figure:: img/cylinder_angle_definition. jpg79 .. figure:: img/cylinder_angle_definition.png 80 80 81 81 Examples of the angles against the detector plane. … … 131 131 ["sld_layer", "1e-6/Ang^2", 0.0, [-inf, inf], "sld", "Layer scattering length density"], 132 132 ["sld_solvent", "1e-6/Ang^2", 5.0, [-inf, inf], "sld", "Solvent scattering length density"], 133 ["theta", "degrees", 0, [- inf, inf], "orientation", "Orientation of the stacked disk axis w/respect incoming beam"],134 ["phi", "degrees", 0, [- inf, inf], "orientation", "Orientation of the stacked disk in the plane of the detector"],133 ["theta", "degrees", 0, [-360, 360], "orientation", "Orientation of the stacked disk axis w/respect incoming beam"], 134 ["phi", "degrees", 0, [-360, 360], "orientation", "Rotation about beam"], 135 135 ] 136 136 # pylint: enable=bad-whitespace, line-too-long -
sasmodels/models/triaxial_ellipsoid.py
r0881f4e re645373 76 76 of the particle. 77 77 78 The angle $\psi$ is the rotational angle around its own $c$ axis 79 against the $q$ plane. For example, $\psi = 0$ when the 80 $a$ axis is parallel to the $x$ axis of the detector. 78 For oriented ellipsoids the *theta*, *phi* and *psi* orientation parameters will appear when fitting 2D data, 79 see the :ref:`elliptical-cylinder` model for further information. 81 80 82 81 .. _triaxial-ellipsoid-angles: … … 126 125 127 126 description = """ 128 Note: During fitting ensure that the inequality ra<rb<rc is not 129 violated. Otherwise the calculation will 130 not be correct. 127 Note - fitting ensure that the inequality ra<rb<rc is not 128 violated. Otherwise the calculation may not be correct. 131 129 """ 132 130 category = "shape:ellipsoid" … … 143 141 ["radius_polar", "Ang", 10, [0, inf], "volume", 144 142 "Polar radius, Rc"], 145 ["theta", "degrees", 60, [- inf, inf], "orientation",146 " In planeangle"],147 ["phi", "degrees", 60, [- inf, inf], "orientation",148 " Out of plane angle"],149 ["psi", "degrees", 60, [- inf, inf], "orientation",150 " Out of plane angle"],143 ["theta", "degrees", 60, [-360, 360], "orientation", 144 "polar axis to beam angle"], 145 ["phi", "degrees", 60, [-360, 360], "orientation", 146 "rotation about beam"], 147 ["psi", "degrees", 60, [-360, 360], "orientation", 148 "rotation about polar axis"], 151 149 ] 152 150 … … 183 181 # april 6 2017, rkh add unit tests 184 182 # NOT compared with any other calc method, assume correct! 185 # add2d test after pull #890183 # check 2d test after pull #890 186 184 qx = q*cos(pi/6.0) 187 185 qy = q*sin(pi/6.0) 188 186 tests = [[{}, 0.05, 24.8839548033], 189 # [{'theta':80., 'phi':10.}, (qx, qy), 9999.],187 [{'theta':80., 'phi':10.}, (qx, qy), 166.712060266 ], 190 188 ] 191 189 del qx, qy # not necessary to delete, but cleaner
Note: See TracChangeset
for help on using the changeset viewer.