Ignore:
Timestamp:
Jan 24, 2020 1:59:51 PM (3 years ago)
Author:
srkline
Message:

additions to the reduction for new corrections to the tube detectors for the angle dependent efficiency and the angle dependent tube shadowing. Calculations have been added, new folder for the efficiency has been added, and preference checkboxes have been updated.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_WorkFolderUtils.ipf

    r1235 r1236  
    778778         
    779779                 
    780         // (5) angle-dependent tube shadowing 
     780        // (5) angle-dependent tube shadowing + detection efficiency 
     781        //  done together as one correction 
     782        // 
    781783        // TODO: 
    782         // -- not sure about this correction yet... 
     784        // -- this correction accounts for the efficiency of the tubes 
     785        //              (depends on angle and wavelength) 
     786        //    and the shadowing, only happens at large angles (> 23.7 deg, lateral to tubes) 
     787        // 
     788        // V_TubeEfficiencyShadowCorr(w,w_err,fname,detStr,destPath) 
    783789        // 
    784790        NVAR gDoTubeShadowCor = root:Packages:NIST:VSANS:Globals:gDoTubeShadowCor 
    785791        if (gDoTubeShadowCor == 1) 
    786                 Print "(stub)Tube Shadow correction" 
     792                Print "Doing Tube Efficiency+Shadow correction" 
     793                 
     794                for(ii=0;ii<ItemsInList(ksDetectorListAll);ii+=1) 
     795                        detStr = StringFromList(ii, ksDetectorListAll, ";") 
     796                         
     797                        if(cmpstr(detStr,"B") == 0) 
     798                                // always ignore "B" 
     799                        else 
     800                                Wave w = V_getDetectorDataW(fname,detStr) 
     801                                Wave w_err = V_getDetectorDataErrW(fname,detStr) 
     802                                 
     803                                V_TubeEfficiencyShadowCorr(w,w_err,fname,detStr,destPath) 
     804                        endif 
     805 
     806//                      Print "Eff for panel ",detStr 
     807                endfor 
     808 
    787809        else 
    788                 Print "Tube shadowing correction NOT DONE" 
     810                Print "Tube efficiency+shadowing correction NOT DONE" 
    789811        endif    
    790812                 
     
    874896         
    875897        // (not done) angle dependent efficiency correction 
     898        // -- efficiency and shadowing are now done together (step 5) 
    876899        NVAR doEfficiency = root:Packages:NIST:VSANS:Globals:gDoDetectorEffCor 
    877900 
Note: See TracChangeset for help on using the changeset viewer.