Last change
on this file since 251 was
231,
checked in by pinsard, 17 years ago
|
improvements/corrections of some *.pro headers
|
-
Property svn:eol-style set to
native
-
Property svn:keywords set to
Id
|
File size:
1.1 KB
|
Line | |
---|
1 | ;+ |
---|
2 | ; |
---|
3 | ; @file_comments |
---|
4 | ; calculate umask. Economize memory (we do not need to keep umask anymore) |
---|
5 | ; |
---|
6 | ; @categories |
---|
7 | ; Utilities |
---|
8 | ; |
---|
9 | ; @returns |
---|
10 | ; A 3d array corresponding to umask. |
---|
11 | ; |
---|
12 | ; @uses |
---|
13 | ; common.pro |
---|
14 | ; |
---|
15 | ; @examples |
---|
16 | ; Used like if umask was a known array by substituing umask by (umask()) |
---|
17 | ; For example: Instaed of write umask[domainef] we have to write (umask())[domainef] |
---|
18 | ; |
---|
19 | ; @history |
---|
20 | ; Sebastien Masson (smasson\@lodyc.jussieu.fr) |
---|
21 | ; 11/12/98 |
---|
22 | ; ??/6/99 introduction of the key_shift |
---|
23 | ; 20/9/99 cas jpk=1 (Thanks to jpblod\@ipsl.jussieu.fr) |
---|
24 | ; |
---|
25 | ; @version |
---|
26 | ; $Id$ |
---|
27 | ; |
---|
28 | ;- |
---|
29 | ; |
---|
30 | FUNCTION umask |
---|
31 | ; |
---|
32 | compile_opt idl2, strictarrsubs |
---|
33 | ; |
---|
34 | @cm_4mesh |
---|
35 | IF NOT keyword_set(key_forgetold) THEN BEGIN |
---|
36 | @updatenew |
---|
37 | ENDIF |
---|
38 | ;--------------------------------------------------------- |
---|
39 | tempsun = systime(1) ; For key_performance |
---|
40 | ; |
---|
41 | CASE size(tmask, /n_dimensions) OF |
---|
42 | 2:res = tmask*shift(tmask, -1, 0) |
---|
43 | 3:res = tmask*shift(tmask, -1, 0, 0) |
---|
44 | ENDCASE |
---|
45 | ; |
---|
46 | if NOT keyword_set(key_periodic) then res[jpi-1, *, *] = umaskred |
---|
47 | if keyword_set(key_performance) THEN print, 'temps umask', systime(1)-tempsun |
---|
48 | ; |
---|
49 | return, res |
---|
50 | end |
---|
Note: See
TracBrowser
for help on using the repository browser.