Changeset 0e55afe in sasmodels for sasmodels/models/core_shell_parallelepiped.py
- Timestamp:
- Nov 29, 2017 8:55:21 PM (6 years ago)
- Branches:
- master, core_shell_microgels, magnetic_model, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
- Children:
- 4493288
- Parents:
- 688d315 (diff), b669b49 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/models/core_shell_parallelepiped.py
r688d315 r0e55afe 7 7 "rim" can be different on each (pair) of faces. 8 8 9 10 9 The form factor is normalized by the particle volume $V$ such that 11 10 … … 16 15 where $\langle \ldots \rangle$ is an average over all possible orientations 17 16 of the rectangular solid. 18 19 17 20 18 The function calculated is the form factor of the rectangular solid below. … … 96 94 97 95 Definition of the angles for oriented core-shell parallelepipeds. 98 Note that rotation $\theta$, initially in the $xz$ plane, is carried out first, then 99 rotation $\phi$ about the $z$ axis, finally rotation $\Psi$ is now around the axis of the parallelepiped. 100 The neutron or X-ray beam is along the $z$ axis. 96 Note that rotation $\theta$, initially in the $xz$ plane, is carried 97 out first, then rotation $\phi$ about the $z$ axis, finally rotation 98 $\Psi$ is now around the axis of the cylinder. The neutron or X-ray 99 beam is along the $z$ axis. 101 100 102 101 .. figure:: img/parallelepiped_angle_projection.png … … 184 183 185 184 def random(): 186 import numpy as np187 185 outer = 10**np.random.uniform(1, 4.7, size=3) 188 186 thick = np.random.beta(0.5, 0.5, size=3)*(outer-2) + 1 … … 218 216 qx, qy = 0.2 * cos(pi/6.), 0.2 * sin(pi/6.) 219 217 tests = [[{}, 0.2, 0.533149288477], 220 [{}, [0.2], [0.533149288477]],221 [{'theta':10.0, 'phi':20.0}, (qx, qy), 0.0853299803222],222 [{'theta':10.0, 'phi':20.0}, [(qx, qy)], [0.0853299803222]],218 [{}, [0.2], [0.533149288477]], 219 [{'theta':10.0, 'phi':20.0}, (qx, qy), 0.0853299803222], 220 [{'theta':10.0, 'phi':20.0}, [(qx, qy)], [0.0853299803222]], 223 221 ] 224 222 del qx, qy # not necessary to delete, but cleaner
Note: See TracChangeset
for help on using the changeset viewer.