Changeset eb69cce in sasmodels for sasmodels/models/spherepy.py
- Timestamp:
- Nov 30, 2015 9:18:41 PM (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:
- d18f8a8
- Parents:
- d138d43
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/models/spherepy.py
rd138d43 reb69cce 11 11 .. math:: 12 12 13 I( Q) = \frac{\text{scale}}{V} \cdot \left[ \14 3V(\Delta\rho) \cdot \frac{\sin( QR) - QR\cos(QR))}{(QR)^3} \13 I(q) = \frac{\text{scale}}{V} \cdot \left[ 14 3V(\Delta\rho) \cdot \frac{\sin(qr) - qr\cos(qr))}{(qr)^3} 15 15 \right]^2 + \text{background} 16 16 17 17 where *scale* is a volume fraction, $V$ is the volume of the scatterer, 18 $ R$ is the radius of the sphere, *background* is the background level and18 $r$ is the radius of the sphere, *background* is the background level and 19 19 *sld* and *solvent_sld* are the scattering length densities (SLDs) of the 20 20 scatterer and the solvent respectively. … … 27 27 The 2D scattering intensity is the same as above, regardless of the 28 28 orientation of $\vec q$. 29 30 Our model uses the form factor calculations as defined in the IGOR31 package provided by the NIST Center for Neutron Research (Kline, 2006).32 29 33 30 Validation … … 49 46 50 47 51 Reference 52 --------- 48 References 49 ---------- 53 50 54 51 A Guinier and G. Fournet, *Small-Angle Scattering of X-Rays*, … … 64 61 title = "Spheres with uniform scattering length density" 65 62 description = """\ 66 P(q)=(scale/V)*[3V(sld-solvent_sld)*(sin(q R)-qRcos(qR))67 /(q R)^3]^2 + background68 R: radius of sphere63 P(q)=(scale/V)*[3V(sld-solvent_sld)*(sin(qr)-qr cos(qr)) 64 /(qr)^3]^2 + background 65 r: radius of sphere 69 66 V: The volume of the scatter 70 67 sld: the SLD of the sphere … … 101 98 fq = bes * (sld - solvent_sld) * form_volume(radius) 102 99 return 1.0e-4 * fq ** 2 103 Iq.vectorized = True # Iq accepts an array of Qvalues100 Iq.vectorized = True # Iq accepts an array of q values 104 101 105 102 def Iqxy(qx, qy, sld, solvent_sld, radius): 106 103 return Iq(sqrt(qx ** 2 + qy ** 2), sld, solvent_sld, radius) 107 Iqxy.vectorized = True # Iqxy accepts arrays of Qx, Qy values104 Iqxy.vectorized = True # Iqxy accepts arrays of qx, qy values 108 105 109 106 def sesans(z, sld, solvent_sld, radius):
Note: See TracChangeset
for help on using the changeset viewer.