Ignore:
Timestamp:
07/21/06 14:47:49 (18 years ago)
Author:
navarro
Message:

english and nicer header (2a)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/SRC/ToBeReviewed/GRILLE/grille.pro

    r134 r142  
    33;------------------------------------------------------------ 
    44;+ 
    5 ; NAME:grille 
    6 ; 
    7 ; PURPOSE: choisit la grille qui doit etre utilisee pour faire le graphe en 
    8 ; fonction de vargrid et renvoie les parametres correspondants calcules ds 
    9 ; domdef.pro et reduit au domaine definit par domdef (contrairement a 
    10 ; grandegrille.pro) 
    11 ; 
    12 ; CATEGORY: 
    13 ; 
    14 ; CALLING SEQUENCE: 
    15 ;  grille,mask,glam,gphi,gdep,nx,ny,nz,firstx,firsty,firstz,lastx,lasty,lastz,e1,e2,e3 
    16 ; 
    17 ; INPUTS:rien. ATTENTION les choix de la grille se fait a partir de la 
    18 ; valeur de la variable globale vargrid, qui peut etre egale a 'T', 
    19 ; 'U', 'V', 'W' ou 'F'. 
    20 ; 
    21 ; KEYWORD PARAMETERS: 
    22 ;         TRI si ce mot clef sert a obtenir grace a grille la 
    23 ;         triangulation qui se rapporte a la grille mais uniquement 
    24 ;         sur la partie du zoom. ce tableau de triangulation reduit 
    25 ;         est passe ds la variable que l''on a egalee a tri.par ex: 
    26 ;         grille,...,tri=triangulation_reduite. ne mot clef est 
    27 ;         utilise dans plt.pro 
    28 ; 
    29 ;         /FORPLT: ds plt on veut que sur les points terres, glam et 
    30 ;         gphi soit egale a glamt et gphit quelle que soit la grille. 
    31 ; 
    32 ;         /NOTRI: utile seulement qd TRI est active. dans ce cas 
    33 ;         grille retourne -1 ds la variable tri meme si la variable du 
    34 ;         common triangles_list est definie et differente de -1 
    35 ; 
    36 ;         /WDEPTH: to specify that the field is at W depth instad of T  
    37 ;         depth (automatically activated if vargrid eq 'W') 
    38 ; 
    39 ; OUTPUTS:mask,glam,gphi,gdep,nx,ny,nz,firstx,firsty,firstz, 
    40 ;         lastx,lasty,lastz,e1,e2,e3 
    41 ; 
    42 ;         pour leur definition cf domdef et la gestion des sous 
    43 ;         domaines sur le web 
    44 ; 
    45 ;         Rq: ces outputs sont optionnels, si je veux recuperer que 
    46 ;         mask, glam et gphi il suffit de taper grille, mask, glam, gphi 
    47 ; 
    48 ; COMMON BLOCKS: cm_4mesh and cm_4data 
    49 ; 
    50 ; SIDE EFFECTS: utilise la variable globale vargird 
    51 ; 
    52 ; RESTRICTIONS: vargrid doit etre 'T', 'W', 'U', 'V' ou 'F' 
    53 ; 
    54 ; EXAMPLE: 
    55 ; 
    56 ; MODIFICATION HISTORY: Sebastien Masson (smasson@lodyc.jussieu.fr) 
     5; 
     6; @file_comments 
     7; Choose the grid which must be used to do the graph in function of 
     8; vargrid and send back corresponding parameters calculated in 
     9; domdef.pro and reduced at the domain defined by domdef (contrarily 
     10; to grandegrille.pro) 
     11; BEWARE!! The choice of the grid is made from the value of the  
     12; global variable vargrid, which can be equal to 'T', 'U', 'V', 'W' ou 'F'. 
     13; 
     14; @categories 
     15; 
     16; @keyword TRI  
     17; This keyword serve to obtain, thanks to grille, the triangulation which 
     18; refer to the grid but only on the part of the zoom. This of triangulation 
     19; is passed in the variable we have equate at TRI. 
     20; For example: grille,...,tri=triangulation_reduite. 
     21; This keyword is used in plt.pro 
     22; 
     23; @keyword WDEPTH 
     24; To specify that the field is at W depth instad of T  
     25; depth (automatically activated if vargrid eq 'W') 
     26;  
     27; @keyword FORPLT 
     28; In plt, we want that land points, glam and gphi, be equal to glamt and  
     29; gphit regardless of the grid. 
     30; 
     31; @keyword NOTRI 
     32; Useful only when TRI is activated. In this case, grill send back -1 in the  
     33; variable tri even if the variable of the common triangles_list is defined  
     34; and different of-1 
     35;  
     36; @keyword _EXTRA  
     37; Used to pass your keywords 
     38; 
     39; @keyword TOUT 
     40; 
     41; @param MASK {out}{optional} 
     42; For the definition, see domdef and the management of subdomains on the web. 
     43;  
     44; @param  GLAM {out}{optional} 
     45; For the definition, see domdef and the management of subdomains on the web. 
     46;  
     47; @param  GPHI {out}{optional} 
     48; For the definition, see domdef and the management of subdomains on the web. 
     49;  
     50; @param  GDEP {out}{optional} 
     51; For the definition, see domdef and the management of subdomains on the web. 
     52;  
     53; @param  NX {out}{optional} 
     54; For the definition, see domdef and the management of subdomains on the web. 
     55;  
     56; @param  NY {out}{optional} 
     57; For the definition, see domdef and the management of subdomains on the web. 
     58;  
     59; @param  NZ {out}{optional} 
     60; For the definition, see domdef and the management of subdomains on the web. 
     61;  
     62; @param  FIRSTX {out}{optional} 
     63; For the definition, see domdef and the management of subdomains on the web. 
     64;  
     65; @param  FIRSTY {out}{optional} 
     66; For the definition, see domdef and the management of subdomains on the web. 
     67;  
     68; @param  FIRSTZ {out}{optional} 
     69; For the definition, see domdef and the management of subdomains on the web. 
     70;          
     71; @param LASTX {out}{optional} 
     72; For the definition, see domdef and the management of subdomains on the web. 
     73;  
     74; @param  LASTY {out}{optional} 
     75; For the definition, see domdef and the management of subdomains on the web. 
     76;  
     77; @param  LASTZ {out}{optional} 
     78; For the definition, see domdef and the management of subdomains on the web. 
     79;  
     80; @param  E1 {out}{optional} 
     81; For the definition, see domdef and the management of subdomains on the web. 
     82; 
     83; @param  E2 {out}{optional} 
     84; For the definition, see domdef and the management of subdomains on the web. 
     85;  
     86; @param  E3 {out}{optional} 
     87; For the definition, see domdef and the management of subdomains on the web. 
     88; 
     89; @uses 
     90; cm_4mesh  
     91; cm_4data 
     92; 
     93; @restrictions  
     94; Use the variable vargrid 
     95; 
     96; @restrictions 
     97; Vargrid must be 'T', 'W', 'U', 'V' ou 'F' 
     98; 
     99; @history 
     100;  Sebastien Masson (smasson@lodyc.jussieu.fr) 
    57101;                       12/2/1999 
    58102;                       10/11/1999 /forplt 
     103; 
     104; @version 
     105; $Id$  
     106; 
     107; @todo Comment ecrire la remarque sur les inputs? 
     108;  
    59109;- 
    60110;------------------------------------------------------------ 
     
    73123  ENDIF 
    74124;--------------------- 
    75   tempsun = systime(1)          ; pour key_performance 
     125  tempsun = systime(1)          ; For key_performance 
    76126;------------------------------------------------------------ 
    77127  vargrid = strupcase(strmid(vargrid,0,/reverse_offset)) 
     
    83133    domdef, gridtype = vargrid, _EXTRA = ex 
    84134  endif 
    85   tempdeux = systime(1)         ; pour key_performance =2 
     135  tempdeux = systime(1)         ; For key_performance =2 
    86136;------------------------------------------------------------ 
    87137;------------------------------------------------------------ 
     
    99149  CASE 1 OF  
    100150;------------------------------------------------------------ 
    101 ; grille T and W 
     151; grid T and W 
    102152;------------------------------------------------------------ 
    103153    vargrid eq 'T' OR vargrid eq 'W' : begin 
    104 ;scalaires 
     154;scalars 
    105155      nx = nxt 
    106156      ny = nyt 
     
    109159      lastx = lastxt 
    110160      lasty = lastyt 
    111 ;vecteurs 2d 
     161;2d vectors 
    112162      IF arg_present(glam) THEN glam = glamt[firstx:lastx, firsty:lasty] 
    113163      IF arg_present(gphi) THEN gphi = gphit[firstx:lastx, firsty:lasty] 
    114164      IF arg_present(e1) THEN e1 = e1t[firstx:lastx, firsty:lasty] 
    115165      IF arg_present(e2) THEN e2 = e2t[firstx:lastx, firsty:lasty] 
    116 ;vecteurs 3d 
     166;3d vectors  
    117167      IF keyword_set(forplt) THEN mask = tmask[firstx:lastx, firsty:lasty, firstz] $ 
    118168      ELSE IF arg_present(mask) THEN mask = tmask[firstx:lastx, firsty:lasty, firstz:lastz] 
    119169    end 
    120170;------------------------------------------------------------ 
    121 ; grille U 
     171; grid U 
    122172;------------------------------------------------------------ 
    123173    vargrid eq 'U': begin 
    124 ;scalaires 
     174;scalars 
    125175      nx = nxu 
    126176      ny = nyu 
     
    129179      lastx = lastxu 
    130180      lasty = lastyu 
    131 ;vecteurs 2d 
     181;2d vectors 
    132182      IF arg_present(glam) THEN glam = glamu[firstx:lastx, firsty:lasty] 
    133183      IF arg_present(gphi) THEN gphi = gphiu[firstx:lastx, firsty:lasty] 
     
    163213      IF arg_present(e1) THEN e1  = e1u[firstx:lastx, firsty:lasty] 
    164214      IF arg_present(e2) THEN e2  = e2u[firstx:lastx, firsty:lasty] 
    165 ;vecteurs 3d 
     215;3d vectors 
    166216      IF keyword_set(forplt) THEN mask = (umask())[firstx:lastx, firsty:lasty, firstz] $ 
    167217      ELSE IF arg_present(mask) THEN mask = (umask())[firstx:lastx, firsty:lasty, firstz:lastz] 
    168218    end 
    169219;------------------------------------------------------------ 
    170 ; grille V 
     220; grid V 
    171221;------------------------------------------------------------ 
    172222    vargrid eq 'OPAPTDHV' or vargrid eq 'OPAPT3DV' $ 
    173223      or vargrid eq 'V': begin 
    174 ;scalaires 
     224;scalars 
    175225      nx = nxv 
    176226      ny = nyv 
     
    179229      lastx = lastxv 
    180230      lasty = lastyv 
    181 ;vecteurs 2d 
     231;2d vectors 
    182232      IF arg_present(glam) THEN glam = glamv[firstx:lastx, firsty:lasty] 
    183233      IF arg_present(gphi) THEN gphi = gphiv[firstx:lastx, firsty:lasty] 
     
    213263      IF arg_present(e1) THEN e1  = e1v[firstx:lastx, firsty:lasty] 
    214264      IF arg_present(e2) THEN e2  = e2v[firstx:lastx, firsty:lasty] 
    215 ;vecteurs 3d 
     265;3d vecteurs 
    216266      IF keyword_set(forplt) THEN mask = (vmask())[firstx:lastx, firsty:lasty, firstz] $ 
    217267      ELSE IF arg_present(mask) THEN mask = (vmask())[firstx:lastx, firsty:lasty, firstz:lastz] 
    218268    end 
    219269;------------------------------------------------------------ 
    220 ; grille F 
     270; grid F 
    221271;------------------------------------------------------------ 
    222272    vargrid eq 'OPAPTDHF' or vargrid eq 'OPAPT3DF' $  
    223273      or vargrid eq 'F': begin 
    224 ;scalaires 
     274;scalars 
    225275      nx = nxf 
    226276      ny = nyf 
     
    229279      lastx = lastxf 
    230280      lasty = lastyf 
    231 ;vecteurs 2d 
     281;2d vectors 
    232282      IF arg_present(glam) THEN glam = glamf[firstx:lastx, firsty:lasty] 
    233283      IF arg_present(gphi) THEN gphi = gphif[firstx:lastx, firsty:lasty] 
     
    273323      IF arg_present(e1) THEN e1  = e1f[firstx:lastx, firsty:lasty] 
    274324      IF arg_present(e2) THEN e2  = e2f[firstx:lastx, firsty:lasty] 
    275 ;vecteurs 3d 
     325;3d vectors  
    276326      IF keyword_set(forplt) THEN mask = (fmask())[firstx:lastx, firsty:lasty, firstz] $ 
    277327      ELSE IF arg_present(mask) THEN mask = (fmask())[firstx:lastx, firsty:lasty, firstz:lastz] 
     
    289339;------------------------------------------------------------ 
    290340;------------------------------------------------------------ 
    291 ; Variables se rapportant a la dimension verticale 
    292 ;------------------------------------------------------------ 
    293 ;------------------------------------------------------------ 
    294 ;------------------------------------------------------------ 
    295 ; 
    296 ; 
    297   tempdeux = systime(1)         ; pour key_performance =2 
     341; Variables refering to the vertical dimension 
     342;------------------------------------------------------------ 
     343;------------------------------------------------------------ 
     344;------------------------------------------------------------ 
     345; 
     346; 
     347  tempdeux = systime(1)         ; For key_performance =2 
    298348  if keyword_set(wdepth) then begin 
    299349    gdep = gdepw[firstz:lastz] 
     
    340390    print, 'temps grille: Variables se rapportant a la dimension verticale ', systime(1)-tempdeux 
    341391;------------------------------------------------------------ 
    342 ; vecteur triangulation Qd TRI est active 
     392; Triangulation vector when TRI is activated. 
    343393;------------------------------------------------------------ 
    344394  if arg_present(TRI) then $ 
     
    356406  ENDELSE 
    357407;------------------------------------------------------------------ 
    358 ; pour s'assurer qu'il n'y a pas de dimension degenerees (=1) 
    359 ;------------------------------------------------------------------- 
     408; To make sure there is not any degenerated dimension (=1) 
     409;------------------------------------------------------------------ 
    360410;    mask=reform(mask, /over) 
    361411;    glam=reform(glam, /over) 
Note: See TracChangeset for help on using the changeset viewer.