Changeset 228 for trunk/SRC/Interpolation/fromirr.pro
- Timestamp:
- 03/16/07 15:12:31 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SRC/Interpolation/fromirr.pro
r205 r228 38 38 ; 39 39 ; @keyword ADDR {type=2d array} 40 ; 2D arrays, weig and addr are the weight and addresses used to 41 ; perform the interpolation: 40 ; 1) at the first call of fromirr: 41 ; This keyword can be set to a named variable (undefined or equal to 0) into which the 42 ; addresses used to perform the interpolation will be copied when the current routine exits. 43 ; 2) Next, once this keyword is set to a defined 2d array, it is used to bypass the computation 44 ; of the weights and addresses used to perform the interpolation. In this case, fromirr simply 45 ; compute the interpolated field as: 42 46 ; dataout = total(weig*datain[addr], 1) 43 47 ; dataout = reform(dataout, jpio, jpjo, /over) 44 ; Those keywords can be set to named variables (that are undefined or equal to 0) into which the 45 ; values will be copied when the current routine exits. Next, they can be used to perform 46 ; the interpolation without computing again those 2 parameters. This greatly 47 ; speed-up the interpolation! In that case, lonin, latin, lonout and latout are not necessary. 48 ; In that case, method, lonin, latin, are not used (but are necessary). 49 ; lonout, latout are used only to know the output domain size 48 50 ; 49 51 ; @returns … … 58 60 ; @examples 59 61 ; 62 ; To interpolate 1 field: 63 ; 60 64 ; IDL> tncep = fromirr('bilinear', topa, glamt, gphit, tmask[*,*,0], lonout, latout, mskout) 61 65 ; 62 ; or 66 ; or if you have several fields to interpolate from the same source and target grids 67 ; 68 ; 1) get back the weights and addresses in variables a and b 69 ; (that must be undefined or equal to 0 before calling fromirr) 63 70 ; 64 71 ; IDL> t1ncep = fromirr('bilinear', topa, glamt, gphit, tmask[*,*,0], lonout, latout, mskout $ 65 72 ; , WEIG = a, ADDR = b) 66 73 ; IDL> help, a, b 74 ; 75 ; 2) use a and b that are now defined to bypass the computation of the weights and addresses 76 ; and speed-up the computation! 77 ; 67 78 ; IDL> t2ncep = fromirr('bilinear', topa, WEIG = a, ADDR = b) 68 79 ;
Note: See TracChangeset
for help on using the changeset viewer.