Changeset eb69cce in sasmodels for sasmodels/models/sphere.py
- Timestamp:
- Nov 30, 2015 7: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/sphere.py
r0fa687d 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*, … … 63 60 title = "Spheres with uniform scattering length density" 64 61 description = """\ 65 P(q)=(scale/V)*[3V(sld-solvent_sld)*(sin(q R)-qRcos(qR))66 /(q R)^3]^2 + background67 R: radius of sphere62 P(q)=(scale/V)*[3V(sld-solvent_sld)*(sin(qr)-qr cos(qr)) 63 /(qr)^3]^2 + background 64 r: radius of sphere 68 65 V: The volume of the scatter 69 66 sld: the SLD of the sphere … … 93 90 double sn, cn; 94 91 SINCOS(qr, sn, cn); 95 // Use taylor series for low Qto avoid cancellation error. Tested against92 // Use taylor series for low q to avoid cancellation error. Tested against 96 93 // the following expression in quad precision: 97 94 // 3.0*(sn-qr*cn)/(qr*qr*qr);
Note: See TracChangeset
for help on using the changeset viewer.