# Changeset 8f04da4 in sasmodels for sasmodels/models/core_shell_parallelepiped.py

Ignore:
Timestamp:
Aug 2, 2017 12:53:56 AM (6 years ago)
Branches:
master, core_shell_microgels, costrafo411, magnetic_model, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
Children:
bd21b12
Parents:
1511c37c
Message:

tuned random model generation for more models

File:
1 edited

### Legend:

Unmodified
 r9b79f29 Calculates the form factor for a rectangular solid with a core-shell structure. The thickness and the scattering length density of the shell or The thickness and the scattering length density of the shell or "rim" can be different on each (pair) of faces. However at this time the 1D calculation does **NOT** actually calculate a c face rim despite the presence of **meaning that there are "gaps" at the corners of the solid.**  Again note that $t_C = 0$ currently. $t_C = 0$ currently. The intensity calculated follows the :ref:parallelepiped model, with the based on the the averaged effective radius $(=\sqrt{(A+2t_A)(B+2t_B)/\pi})$ and length $(C+2t_C)$ values, after appropriately sorting the three dimensions to give an oblate or prolate particle, to give an sorting the three dimensions to give an oblate or prolate particle, to give an effective radius, for $S(Q)$ when $P(Q) * S(Q)$ is applied. title = "Rectangular solid with a core-shell structure." description = """ P(q)= P(q)= """ category = "shape:parallelepiped" # VR defaults to 1.0 def random(): import numpy as np outer = 10**np.random.uniform(1, 4.7, size=3) thick = np.random.beta(0.5, 0.5, size=3)*(outer-2) + 1 length = outer - thick pars = dict( length_a=length[0], length_b=length[1], length_c=length[2], thick_rim_a=thick[0], thick_rim_b=thick[1], thick_rim_c=thick[2], ) return pars # parameters for demo demo = dict(scale=1, background=0.0,