Changeset 1222 for sans/Dev/trunk/NCNR_User_Procedures/Analysis
- Timestamp:
- Oct 18, 2019 1:08:35 PM (3 years ago)
- Location:
- sans/Dev/trunk/NCNR_User_Procedures/Analysis
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
sans/Dev/trunk/NCNR_User_Procedures/Analysis/Packages/Wrapper_v40.ipf
r1001 r1222 345 345 // make the necessary waves if they don't exist already 346 346 if(exists("Hold_"+suffix) == 0) 347 Make/O/D/N=(num) $("epsilon_"+suffix),$("Hold_"+suffix) 348 Make/O/T/N=(num) $("LoLim_"+suffix),$("HiLim_"+suffix) 349 Wave eps = $("epsilon_"+suffix) 350 Wave coef=$popStr 351 if(eps[0] == 0) //if eps already if filled, don't change it 352 eps = abs(coef*1e-4) + 1e-10 //default eps is proportional to the coefficients 353 endif 354 endif 347 Make/O/D/N=(num) $("Hold_"+suffix) 348 endif 349 if(exists("epsilon_"+suffix) == 0) 350 Make/O/D/N=(num) $("epsilon_"+suffix) 351 endif 352 if(exists("LoLim_"+suffix) == 0) 353 Make/O/T/N=(num) $("LoLim_"+suffix) 354 endif 355 if(exists("HiLim_"+suffix) == 0) 356 Make/O/T/N=(num) $("HiLim_"+suffix) 357 endif 358 359 Wave eps = $("epsilon_"+suffix) 360 Wave coef=$popStr 361 if(eps[0] == 0) //if eps already if filled, don't change it 362 eps = abs(coef*1e-4) + 1e-10 //default eps is proportional to the coefficients 363 endif 364 355 365 // default epsilon values, sometimes needed for the fit 356 366 … … 1169 1179 1170 1180 // insert graphs 1181 // extra flag "2" (Igor >=7.00) is 2x screen resolution 1171 1182 if(WaveExists(dataXw)) 1172 1183 // Notebook $nb picture={$topGraph(0, 0, 400, 300), -5, 1}, text="\r" 1173 Notebook $nb scaling={50, 50}, picture={$topGraph(0, 0, 800, 600), -5, 1 }, text="\r"1184 Notebook $nb scaling={50, 50}, picture={$topGraph(0, 0, 800, 600), -5, 1,2}, text="\r" 1174 1185 // 1175 1186 else //must be 2D Gizmo 1176 1187 Execute "ExportGizmo Clip" //this ALWAYS is a PICT or BMP. Gizmo windows are different... 1177 1188 LoadPict/Q/O "Clipboard",tmp_Gizmo 1178 Notebook $nb picture={tmp_Gizmo(0, 0, 800, 600), 0, 1 }, text="\r"1189 Notebook $nb picture={tmp_Gizmo(0, 0, 800, 600), 0, 1,2}, text="\r" 1179 1190 endif 1180 1191 … … 1211 1222 /// SavePICT /E=-5/O/P=home /I/W=(0,0,3,3) as pictStr 1212 1223 if(WaveExists(dataXw)) 1213 SavePICT /E=-5/O/ P=home/WIN=$topGraph /W=(0,0,800,600) as pictStr1224 SavePICT /E=-5/O/B=144/P=home/WIN=$topGraph /W=(0,0,800,600) as pictStr 1214 1225 else 1215 1226 Execute "ExportGizmo /P=home as \""+pictStr+"\"" //this won't be of very high quality -
sans/Dev/trunk/NCNR_User_Procedures/Analysis/VSANS/V_SWB_Beaucage.ipf
r1220 r1222 278 278 // define limits based on lo/mean, hi/mean of the wavelength distribution 279 279 // using the empirical definition, "middle" of the peaks 280 loLim = 3.37/ 5.3281 upLim = 20/ 5.3280 loLim = 3.37/kSuperWhiteBeam_Mean 281 upLim = 20/kSuperWhiteBeam_Mean 282 282 283 283 inten = V_IntegrOneLevelSWB_mid(w,loLim,upLim,x) … … 285 285 // why do I need this? Is this because this is defined as the mean of the distribution 286 286 // and is needed to normalize the integral? verify this on paper. 287 inten *= 5.3287 inten *= kSuperWhiteBeam_Mean 288 288 289 289 // normalize the integral 290 inten /= 30955// "middle" of peaks290 inten /= kSuperWhiteBeam_Normalization // "middle" of peaks 291 291 292 292 // additional normalization??? … … 321 321 // FUNCREF SANSModel_proto func = $funcStr 322 322 323 val = V_SuperWhiteBeamDist_mid(dum* 5.3)*OneLevelX(cw,qq/dum)323 val = V_SuperWhiteBeamDist_mid(dum*kSuperWhiteBeam_Mean)*OneLevelX(cw,qq/dum) 324 324 325 325 return (val) … … 350 350 // define limits based on lo/mean, hi/mean of the wavelength distribution 351 351 // using the empirical definition, "middle" of the peaks 352 loLim = 3.37/ 5.3353 upLim = 20/ 5.3352 loLim = 3.37/kSuperWhiteBeam_Mean 353 upLim = 20/kSuperWhiteBeam_Mean 354 354 355 355 inten = V_IntegrTwoLevelSWB_mid(w,loLim,upLim,x) … … 357 357 // why do I need this? Is this because this is defined as the mean of the distribution 358 358 // and is needed to normalize the integral? verify this on paper. 359 inten *= 5.3359 inten *= kSuperWhiteBeam_Mean 360 360 361 361 // normalize the integral 362 inten /= 30955// "middle" of peaks362 inten /= kSuperWhiteBeam_Normalization // "middle" of peaks 363 363 364 364 // additional normalization??? … … 393 393 // FUNCREF SANSModel_proto func = $funcStr 394 394 395 val = V_SuperWhiteBeamDist_mid(dum* 5.3)*TwoLevelX(cw,qq/dum)395 val = V_SuperWhiteBeamDist_mid(dum*kSuperWhiteBeam_Mean)*TwoLevelX(cw,qq/dum) 396 396 397 397 return (val) … … 422 422 // define limits based on lo/mean, hi/mean of the wavelength distribution 423 423 // using the empirical definition, "middle" of the peaks 424 loLim = 3.37/ 5.3425 upLim = 20/ 5.3424 loLim = 3.37/kSuperWhiteBeam_Mean 425 upLim = 20/kSuperWhiteBeam_Mean 426 426 427 427 inten = V_IntegrThreeLevelSWB_mid(w,loLim,upLim,x) … … 429 429 // why do I need this? Is this because this is defined as the mean of the distribution 430 430 // and is needed to normalize the integral? verify this on paper. 431 inten *= 5.3431 inten *= kSuperWhiteBeam_Mean 432 432 433 433 // normalize the integral 434 inten /= 30955// "middle" of peaks434 inten /= kSuperWhiteBeam_Normalization // "middle" of peaks 435 435 436 436 // additional normalization??? … … 465 465 // FUNCREF SANSModel_proto func = $funcStr 466 466 467 val = V_SuperWhiteBeamDist_mid(dum* 5.3)*ThreeLevelX(cw,qq/dum)467 val = V_SuperWhiteBeamDist_mid(dum*kSuperWhiteBeam_Mean)*ThreeLevelX(cw,qq/dum) 468 468 469 469 return (val) … … 496 496 // define limits based on lo/mean, hi/mean of the wavelength distribution 497 497 // using the empirical definition, "middle" of the peaks 498 loLim = 3.37/ 5.3499 upLim = 20/ 5.3498 loLim = 3.37/kSuperWhiteBeam_Mean 499 upLim = 20/kSuperWhiteBeam_Mean 500 500 501 501 inten = V_IntegrFourLevelSWB_mid(w,loLim,upLim,x) … … 503 503 // why do I need this? Is this because this is defined as the mean of the distribution 504 504 // and is needed to normalize the integral? verify this on paper. 505 inten *= 5.3505 inten *= kSuperWhiteBeam_Mean 506 506 507 507 // normalize the integral 508 inten /= 30955// "middle" of peaks508 inten /= kSuperWhiteBeam_Normalization // "middle" of peaks 509 509 510 510 // additional normalization??? … … 539 539 // FUNCREF SANSModel_proto func = $funcStr 540 540 541 val = V_SuperWhiteBeamDist_mid(dum* 5.3)*FourLevelX(cw,qq/dum)541 val = V_SuperWhiteBeamDist_mid(dum*kSuperWhiteBeam_Mean)*FourLevelX(cw,qq/dum) 542 542 543 543 return (val) -
sans/Dev/trunk/NCNR_User_Procedures/Analysis/VSANS/V_SWB_BroadPeak.ipf
r1209 r1222 124 124 // define limits based on lo/mean, hi/mean of the wavelength distribution 125 125 // using the empirical definition, "middle" of the peaks 126 loLim = 3.37/ 5.3127 upLim = 20/ 5.3126 loLim = 3.37/kSuperWhiteBeam_Mean 127 upLim = 20/kSuperWhiteBeam_Mean 128 128 129 129 inten = V_IntegrBroadPeakSWB_mid(w,loLim,upLim,x) … … 133 133 // why do I need this? Is this because this is defined as the mean of the distribution 134 134 // and is needed to normalize the integral? verify this on paper. 135 inten *= 5.3135 inten *= kSuperWhiteBeam_Mean 136 136 137 137 // normalize the integral 138 inten /= 30955// "middle" of peaks138 inten /= kSuperWhiteBeam_Normalization // "middle" of peaks 139 139 140 140 inten -= w[6] … … 176 176 // FUNCREF SANSModel_proto func = $funcStr 177 177 178 val = V_SuperWhiteBeamDist_mid(dum* 5.3)*BroadPeakX(cw,qq/dum)178 val = V_SuperWhiteBeamDist_mid(dum*kSuperWhiteBeam_Mean)*BroadPeakX(cw,qq/dum) 179 179 180 180 return (val) -
sans/Dev/trunk/NCNR_User_Procedures/Analysis/VSANS/V_SWB_GaussSpheres.ipf
r1209 r1222 121 121 // define limits based on lo/mean, hi/mean of the wavelength distribution 122 122 // using the empirical definition, "middle" of the peaks 123 loLim = 3.37/ 5.3124 upLim = 20/ 5.3123 loLim = 3.37/kSuperWhiteBeam_Mean 124 upLim = 20/kSuperWhiteBeam_Mean 125 125 126 126 inten = V_IntegrGaussSphereSWB_mid(w,loLim,upLim,xx) … … 128 128 // why do I need this? Is this because this is defined as the mean of the distribution 129 129 // and is needed to normalize the integral? verify this on paper. 130 inten *= 5.3130 inten *= kSuperWhiteBeam_Mean 131 131 132 132 // normalize the integral 133 inten /= 30955// "middle" of peaks133 inten /= kSuperWhiteBeam_Normalization // "middle" of peaks 134 134 135 135 inten -= w[5] … … 169 169 // FUNCREF SANSModel_proto func = $funcStr 170 170 171 val = V_SuperWhiteBeamDist_mid(dum* 5.3)*GaussSpheresX(cw,qq/dum)171 val = V_SuperWhiteBeamDist_mid(dum*kSuperWhiteBeam_Mean)*GaussSpheresX(cw,qq/dum) 172 172 173 173 return (val) -
sans/Dev/trunk/NCNR_User_Procedures/Analysis/VSANS/V_WB_Beaucage.ipf
r1099 r1222 278 278 // define limits based on lo/mean, hi/mean of the wavelength distribution 279 279 // using the empirical definition, "middle" of the peaks 280 loLim = 3.37/ 5.3281 upLim = 8.37/ 5.3280 loLim = 3.37/kWhiteBeam_Mean 281 upLim = 8.37/kWhiteBeam_Mean 282 282 283 283 inten = V_IntegrOneLevelWB_mid(w,loLim,upLim,x) … … 285 285 // why do I need this? Is this because this is defined as the mean of the distribution 286 286 // and is needed to normalize the integral? verify this on paper. 287 inten *= 5.3287 inten *= kWhiteBeam_Mean 288 288 289 289 // normalize the integral 290 inten /= 19933// "middle" of peaks290 inten /= kWhiteBeam_Normalization // "middle" of peaks 291 291 292 292 // additional normalization??? … … 321 321 // FUNCREF SANSModel_proto func = $funcStr 322 322 323 val = V_WhiteBeamDist_mid(dum* 5.3)*OneLevelX(cw,qq/dum)323 val = V_WhiteBeamDist_mid(dum*kWhiteBeam_Mean)*OneLevelX(cw,qq/dum) 324 324 325 325 return (val) … … 350 350 // define limits based on lo/mean, hi/mean of the wavelength distribution 351 351 // using the empirical definition, "middle" of the peaks 352 loLim = 3.37/ 5.3353 upLim = 8.37/ 5.3352 loLim = 3.37/kWhiteBeam_Mean 353 upLim = 8.37/kWhiteBeam_Mean 354 354 355 355 inten = V_IntegrTwoLevelWB_mid(w,loLim,upLim,x) … … 357 357 // why do I need this? Is this because this is defined as the mean of the distribution 358 358 // and is needed to normalize the integral? verify this on paper. 359 inten *= 5.3359 inten *= kWhiteBeam_Mean 360 360 361 361 // normalize the integral 362 inten /= 19933// "middle" of peaks362 inten /= kWhiteBeam_Normalization // "middle" of peaks 363 363 364 364 // additional normalization??? … … 393 393 // FUNCREF SANSModel_proto func = $funcStr 394 394 395 val = V_WhiteBeamDist_mid(dum* 5.3)*TwoLevelX(cw,qq/dum)395 val = V_WhiteBeamDist_mid(dum*kWhiteBeam_Mean)*TwoLevelX(cw,qq/dum) 396 396 397 397 return (val) … … 422 422 // define limits based on lo/mean, hi/mean of the wavelength distribution 423 423 // using the empirical definition, "middle" of the peaks 424 loLim = 3.37/ 5.3425 upLim = 8.37/ 5.3424 loLim = 3.37/kWhiteBeam_Mean 425 upLim = 8.37/kWhiteBeam_Mean 426 426 427 427 inten = V_IntegrThreeLevelWB_mid(w,loLim,upLim,x) … … 429 429 // why do I need this? Is this because this is defined as the mean of the distribution 430 430 // and is needed to normalize the integral? verify this on paper. 431 inten *= 5.3431 inten *= kWhiteBeam_Mean 432 432 433 433 // normalize the integral 434 inten /= 19933// "middle" of peaks434 inten /= kWhiteBeam_Normalization // "middle" of peaks 435 435 436 436 // additional normalization??? … … 465 465 // FUNCREF SANSModel_proto func = $funcStr 466 466 467 val = V_WhiteBeamDist_mid(dum* 5.3)*ThreeLevelX(cw,qq/dum)467 val = V_WhiteBeamDist_mid(dum*kWhiteBeam_Mean)*ThreeLevelX(cw,qq/dum) 468 468 469 469 return (val) … … 496 496 // define limits based on lo/mean, hi/mean of the wavelength distribution 497 497 // using the empirical definition, "middle" of the peaks 498 loLim = 3.37/ 5.3499 upLim = 8.37/ 5.3498 loLim = 3.37/kWhiteBeam_Mean 499 upLim = 8.37/kWhiteBeam_Mean 500 500 501 501 inten = V_IntegrFourLevelWB_mid(w,loLim,upLim,x) … … 503 503 // why do I need this? Is this because this is defined as the mean of the distribution 504 504 // and is needed to normalize the integral? verify this on paper. 505 inten *= 5.3505 inten *= kWhiteBeam_Mean 506 506 507 507 // normalize the integral 508 inten /= 19933// "middle" of peaks508 inten /= kWhiteBeam_Normalization // "middle" of peaks 509 509 510 510 // additional normalization??? … … 539 539 // FUNCREF SANSModel_proto func = $funcStr 540 540 541 val = V_WhiteBeamDist_mid(dum* 5.3)*FourLevelX(cw,qq/dum)541 val = V_WhiteBeamDist_mid(dum*kWhiteBeam_Mean)*FourLevelX(cw,qq/dum) 542 542 543 543 return (val) -
sans/Dev/trunk/NCNR_User_Procedures/Analysis/VSANS/V_WB_BroadPeak.ipf
r1099 r1222 121 121 // define limits based on lo/mean, hi/mean of the wavelength distribution 122 122 // using the empirical definition, "middle" of the peaks 123 loLim = 3.37/ 5.3124 upLim = 8.37/ 5.3123 loLim = 3.37/kWhiteBeam_Mean 124 upLim = 8.37/kWhiteBeam_Mean 125 125 126 126 inten = V_IntegrBroadPeakWB_mid(w,loLim,upLim,x) … … 128 128 // why do I need this? Is this because this is defined as the mean of the distribution 129 129 // and is needed to normalize the integral? verify this on paper. 130 inten *= 5.3130 inten *= kWhiteBeam_Mean 131 131 132 132 // normalize the integral 133 inten /= 19933// "middle" of peaks133 inten /= kWhiteBeam_Normalization // "middle" of peaks 134 134 135 135 // additional normalization??? … … 164 164 // FUNCREF SANSModel_proto func = $funcStr 165 165 166 val = V_WhiteBeamDist_mid(dum* 5.3)*BroadPeakX(cw,qq/dum)166 val = V_WhiteBeamDist_mid(dum*kWhiteBeam_Mean)*BroadPeakX(cw,qq/dum) 167 167 168 168 return (val) -
sans/Dev/trunk/NCNR_User_Procedures/Analysis/VSANS/V_WB_GaussSpheres.ipf
r1209 r1222 121 121 // define limits based on lo/mean, hi/mean of the wavelength distribution 122 122 // using the empirical definition, "middle" of the peaks 123 loLim = 3.37/ 5.3124 upLim = 8.37/ 5.3123 loLim = 3.37/kWhiteBeam_Mean 124 upLim = 8.37/kWhiteBeam_Mean 125 125 126 126 inten = V_IntegrGaussSphereWB_mid(w,loLim,upLim,xx) … … 128 128 // why do I need this? Is this because this is defined as the mean of the distribution 129 129 // and is needed to normalize the integral? verify this on paper. 130 inten *= 5.3130 inten *= kWhiteBeam_Mean 131 131 132 132 // normalize the integral 133 inten /= 19933// "middle" of peaks133 inten /= kWhiteBeam_Normalization // "middle" of peaks 134 134 135 135 inten -= w[5] … … 167 167 // FUNCREF SANSModel_proto func = $funcStr 168 168 169 val = V_WhiteBeamDist_mid(dum* 5.3)*GaussSpheresX(cw,qq/dum)169 val = V_WhiteBeamDist_mid(dum*kWhiteBeam_Mean)*GaussSpheresX(cw,qq/dum) 170 170 171 171 return (val)
Note: See TracChangeset
for help on using the changeset viewer.