Changeset a2d8a67 in sasmodels for sasmodels/models/raspberry.c
- Timestamp:
- Mar 20, 2016 10:12:42 AM (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:
- 91d7ec4
- Parents:
- 3a66cf7
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/models/raspberry.c
r0433203 ra2d8a67 49 49 VS = M_4PI_3*rS*rS*rS; 50 50 51 //Number of small particles per large particle 51 52 Np = vfS*fSs*VL/vfL/VS; 52 53 54 //Total scattering length difference 53 55 slT = delrhoL*VL + Np*delrhoS*VS; 54 56 55 sfLS = sph_j1c(q*rL)*sph_j1c(q*rS)*sinc(q*(rL+deltaS*rS)); 56 sfSS = sph_j1c(q*rS)*sph_j1c(q*rS)*sinc(q*(rL+deltaS*rS))*sinc(q*(rL+deltaS*rS)); 57 58 f2 = delrhoL*delrhoL*VL*VL*sph_j1c(q*rL)*sph_j1c(q*rL); 59 f2 += Np*delrhoS*delrhoS*VS*VS*sph_j1c(q*rS)*sph_j1c(q*rS); 57 //Form factors for each particle 58 psiL = sph_j1c(q*rL); 59 psiS = sph_j1c(q*rS); 60 61 //Cross term between large and small particles 62 sfLS = psiL*psiS*sinc(q*(rL+deltaS*rS)); 63 //Cross term between small particles at the surface 64 sfSS = psiS*psiS*sinc(q*(rL+deltaS*rS))*sinc(q*(rL+deltaS*rS)); 65 66 //Large sphere form factor term 67 f2 = delrhoL*delrhoL*VL*VL*psiL*psiL; 68 //Small sphere form factor term 69 f2 += Np*delrhoS*delrhoS*VS*VS*psiS*psiS; 70 //Small particle - small particle cross term 60 71 f2 += Np*(Np-1)*delrhoS*delrhoS*VS*VS*sfSS; 72 //Large-small particle cross term 61 73 f2 += 2*Np*delrhoL*delrhoS*VL*VS*sfLS; 74 //Normalise by total scattering length difference 62 75 if (f2 != 0.0){ 63 76 f2 = f2/slT/slT; 64 77 } 65 78 79 //I(q) for large-small composite particles 66 80 f2 = f2*(vfL*delrhoL*delrhoL*VL + vfS*fSs*Np*delrhoS*delrhoS*VS); 67 68 f2+= vfS*(1.0-fSs)* pow(delrhoS, 2)*VS*sph_j1c(q*rS)*sph_j1c(q*rS);81 //I(q) for free small particles 82 f2+= vfS*(1.0-fSs)*delrhoS*delrhoS*VS*psiS*psiS; 69 83 70 84 // normalize to single particle volume and convert to 1/cm
Note: See TracChangeset
for help on using the changeset viewer.