Changeset 127 for sans/Analysis/branches/ajj_23APR07/IGOR_Package_Files/Put in User Procedures/SANS_Models_v3.00/HPMSA.ipf
- Timestamp:
- Jul 24, 2007 3:23:44 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sans/Analysis/branches/ajj_23APR07/IGOR_Package_Files/Put in User Procedures/SANS_Models_v3.00/HPMSA.ipf
r42 r127 1 1 #pragma rtGlobals=1 // Use modern global access method. 2 2 #pragma IgorVersion = 6.0 3 4 // converted to Igor code by Paul Butler 5 // 3 6 Proc PlotHayterPenfoldMSA(num,qmin,qmax) 4 7 Variable num=128, qmin=.001, qmax=.3 … … 23 26 make/o/t parameters_hpmsa = {"Diameter (A)","Charge","Volume Fraction","Temperature(K)","monovalent salt conc. (M)","dielectric constant of solvent"} 24 27 Edit parameters_hpmsa,coef_hpmsa 25 ywave_hpmsa := HayterPenfoldMSA(coef_hpmsa,xwave_hpmsa) 28 Variable/G root:g_HPMSA 29 g_hpmsa := HayterPenfoldMSA(coef_hpmsa,ywave_hpmsa,xwave_hpmsa) 30 // ywave_hpmsa := HayterPenfoldMSA(coef_hpmsa,xwave_hpmsa) 26 31 xdiamwave_hpmsa:=xwave_hpmsa*coef_hpmsa[0] 27 32 //Display ywave_hpmsa vs xdiamwave_hpmsa … … 33 38 End 34 39 40 //AAO version 41 Function HayterPenfoldMSA(cw,yw,xw) : FitFunc 42 Wave cw,yw,xw 43 44 #if exists("HayterPenfoldMSAX") 45 yw = HayterPenfoldMSAX(cw,xw) 46 #else 47 yw = fHayterPenfoldMSA(cw,xw) 48 #endif 49 return(0) 50 End 51 35 52 ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// 36 53 // … … 44 61 // A POWER OF 2 45 62 // 46 47 Function HayterPenfoldMSA(w,x) : FitFunc 63 Function fHayterPenfoldMSA(w,x) : FitFunc 48 64 wave w 49 65 variable x … … 769 785 qcosk = qk*cosk 770 786 aqk = gMSAWave[0]*(sink-qcosk) 771 772 773 774 775 776 777 787 aqk=aqk+gMSAWave[1]*((2.0*qk2-1.0)*qcosk+2.0*sink-2.0/qk) 788 inter=24.0*qk3+4.0*(1.0-6.0*qk2)*sink 789 aqk=(aqk+0.5*etaz*gMSAWave[0]*(inter-(1.0-12.0*qk2+24.0*qk2*qk2)*qcosk))*qk3 790 aqk=aqk +gMSAWave[2]*(ck*asink-sk*qcosk)*qqk 791 aqk=aqk +gMSAWave[3]*(sk*asink-qk*(ck*cosk-1.0))*qqk 792 aqk=aqk +gMSAWave[3]*(cosk-1.0)*qk2 793 aqk=aqk -gekz*(asink+qcosk)*qqk 778 794 SofQ = 1.0/(1.0-e24*aqk) 779 795 endif
Note: See TracChangeset
for help on using the changeset viewer.