Changeset 71b751d in sasmodels for sasmodels/models/rpa.c
- Timestamp:
- Aug 14, 2018 12:09:34 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:
- 86aa992
- Parents:
- 2f8cbb9
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/models/rpa.c
reb63414 r71b751d 39 39 double S31,S32,S33,S34,S41,S42,S43,S44; 40 40 double Lad,Lbd,Lcd,Nav,Intg; 41 41 42 42 // Set values for non existent parameters (eg. no A or B in case 0 and 1 etc) 43 43 //icase was shifted to N-1 from the original code … … 58 58 Kab = Kac = Kad = -0.0004; 59 59 } 60 60 61 61 // Set volume fraction of component D based on constraint that sum of vol frac =1 62 62 Phi[3]=1.0-Phi[0]-Phi[1]-Phi[2]; … … 84 84 Phicd=sqrt(Phi[2]*Phi[3]); 85 85 86 // Calculate Q^2 * Rg^2 for each homopolymer assuming random walk 86 // Calculate Q^2 * Rg^2 for each homopolymer assuming random walk 87 87 Xa=q*q*b[0]*b[0]*N[0]/6.0; 88 88 Xb=q*q*b[1]*b[1]*N[1]/6.0; … … 311 311 //Note that should multiply by Nav to get units of SLD which will become 312 312 // Nav*2 in the next line (SLD^2) but then normalization in that line would 313 //need to divide by Nav leaving only Nav or sqrt(Nav) before squaring. 313 //need to divide by Nav leaving only Nav or sqrt(Nav) before squaring. 314 314 Nav=6.022045e+23; 315 315 Lad=(L[0]/v[0]-L[3]/v[3])*sqrt(Nav); … … 320 320 321 321 //rescale for units of Lij^2 (fm^2 to cm^2) 322 Intg *= 1.0e-26; 322 Intg *= 1.0e-26; 323 323 324 324 return Intg;
Note: See TracChangeset
for help on using the changeset viewer.