Ignore:
Timestamp:
03/16/07 10:22:26 (17 years ago)
Author:
pinsard
Message:

corrections of some misspellings in some *.pro

File:
1 edited

Legend:

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

    r163 r226  
    44;+ 
    55; 
    6 ; @file_comments  
    7 ; Allows to extract a sub-domain of study by providing parameters  
     6; @file_comments 
     7; Allows to extract a sub-domain of study by providing parameters 
    88; needed for drawings (see outputs) 
    99; 
     
    1212; @param Z1 {in}{optional} 
    1313; For a 3d domain whose the horizontal part cover all glam 
    14 ;  
     14; 
    1515; @param Z2 {in}{optional} 
    1616; For a 3d domain whose the horizontal part cover all gphi 
     
    3838; 
    3939; @keyword FINDALWAYS 
    40 ; Force to redefine a box even when none point is find in the box.  
     40; Force to redefine a box even when none point is find in the box. 
    4141; In this case, we select all the grid. 
    4242; 
    4343; @keyword GRIDTYPE {type=string or vector} 
    44 ; It is a string or a vector of strings containing the grids's name  
    45 ; (Only determined by 'T','U','V','W','F') for which the calculation  
    46 ; must be done.  
     44; It is a string or a vector of strings containing the grids's name 
     45; (Only determined by 'T','U','V','W','F') for which the calculation 
     46; must be done. 
    4747;  For example: 'T' or ['T','U'] 
    4848; 
     
    5555; grids. 
    5656; 
    57 ; @keyword INDEX  
    58 ; We activate it if we want that all elements passed in input of domdef  
    59 ; refer to indexes of glam, gphi and gdep arrays rather than to values  
     57; @keyword INDEX 
     58; We activate it if we want that all elements passed in input of domdef 
     59; refer to indexes of glam, gphi and gdep arrays rather than to values 
    6060; of these arrays. 
    6161; 
    62 ; @keyword XINDEX  
    63 ; We activate it if we want that all elements passed in input of domdef  
    64 ; and concerning the X dimension refer to indexes of glam arrays rather  
     62; @keyword XINDEX 
     63; We activate it if we want that all elements passed in input of domdef 
     64; and concerning the X dimension refer to indexes of glam arrays rather 
    6565; than to values of these arrays. 
    6666; 
    67 ; @keyword YINDEX  
    68 ; We activate it if we want that all elements passed in input of domdef  
    69 ; and concerning the X dimension refer to indexes of gphi arrays rather  
     67; @keyword YINDEX 
     68; We activate it if we want that all elements passed in input of domdef 
     69; and concerning the X dimension refer to indexes of gphi arrays rather 
    7070; than to values of these arrays. 
    71 ;  
    72 ; @keyword ZINDEX  
    73 ; We activate it if we want that all elements passed in input of domdef  
    74 ; and concerning the X dimension refer to indexes of gdep arrays rather  
     71; 
     72; @keyword ZINDEX 
     73; We activate it if we want that all elements passed in input of domdef 
     74; and concerning the X dimension refer to indexes of gdep arrays rather 
    7575; than to values of these arrays. 
    7676; 
    7777; @uses 
    7878; common.pro 
    79 ; 
    8079; 
    8180; @history 
     
    123122; 
    124123  IF keyword_set(endpoints) THEN BEGIN 
    125     IF NOT keyword_set(type) THEN BEGIN  
     124    IF NOT keyword_set(type) THEN BEGIN 
    126125      dummy = report(['If domdef is used do find the box associated' $ 
    127126                      , 'to endpoints, you must also specify type keyword']) 
    128127      return 
    129     ENDIF  
     128    ENDIF 
    130129    CASE N_PARAMS() OF 
    131130      0: 
     
    137136    section, BOXZOOM = boxzoom, ENDPOINTS = endpoints, TYPE = type, /ONLYBOX 
    138137    return 
    139   ENDIF    
     138  ENDIF 
    140139 
    141140;------------------------------------------------------------------- 
     
    153152      END 
    154153    ENDCASE 
    155     RETURN   
     154    RETURN 
    156155  ENDIF 
    157156;------------------------------------------------------------------- 
     
    170169  vert1t = 99999. & vert2t = -99999. & vert1w = 99999. & vert2w = -99999. 
    171170; 
    172   IF jpj EQ 1 THEN BEGIN  
     171  IF jpj EQ 1 THEN BEGIN 
    173172    IF (where(gridtype eq 'T'))[0] NE -1 OR (where(gridtype EQ 'W'))[0] NE -1 THEN BEGIN 
    174173      glamt = reform(glamt, jpi, jpj, /over) 
    175174      gphit = reform(gphit, jpi, jpj, /over) 
    176     ENDIF  
     175    ENDIF 
    177176    IF (where(gridtype eq 'U'))[0] NE -1 THEN BEGIN 
    178177      glamu = reform(glamu, jpi, jpj, /over) 
    179178      gphiu = reform(gphiu, jpi, jpj, /over) 
    180     ENDIF   
     179    ENDIF 
    181180    IF (where(gridtype eq 'V'))[0] NE -1 THEN BEGIN 
    182181      glamv = reform(glamv, jpi, jpj, /over) 
    183182      gphiv = reform(gphiv, jpi, jpj, /over) 
    184     ENDIF   
     183    ENDIF 
    185184    IF (where(gridtype eq 'F'))[0] NE -1 THEN BEGIN 
    186185      glamf = reform(glamf, jpi, jpj, /over) 
    187186      gphif = reform(gphif, jpi, jpj, /over) 
    188     ENDIF   
     187    ENDIF 
    189188  ENDIF 
    190189; 
     
    229228         AND NOT keyword_set(xindex) AND NOT keyword_set(yindex) AND NOT keyword_set(index) ) THEN BEGIN 
    230229    IF N_PARAMS() EQ 0 THEN BEGIN 
    231 ; find lon1 and lon2 the longitudinal boudaries of the full domain 
     230; find lon1 and lon2 the longitudinal boundaries of the full domain 
    232231      IF (where(gridtype eq 'T'))[0] NE -1 THEN lon1t = min(glamt, max = lon2t) 
    233232      IF (where(gridtype eq 'W'))[0] NE -1 AND (where(gridtype eq 'T'))[0] EQ -1 THEN lon1t = min(glamt, max = lon2t) 
     
    237236      lon1 = min([lon1t, lon1u, lon1v, lon1f]) 
    238237      lon2 = max([lon2t, lon2u, lon2v, lon2f]) 
    239 ; find lat1 and lat2 the latitudinal boudaries of the full domain 
     238; find lat1 and lat2 the latitudinal boundaries of the full domain 
    240239      IF (where(gridtype eq 'T'))[0] NE -1 THEN lat1t = min(gphit, max = lat2t) 
    241240      IF (where(gridtype eq 'W'))[0] NE -1 AND (where(gridtype eq 'T'))[0] EQ -1 THEN lat1t = min(gphit, max = lat2t) 
     
    245244      lat1 = min([lat1t, lat1u, lat1v, lat1f]) 
    246245      lat2 = max([lat2t, lat2u, lat2v, lat2f]) 
    247     ENDIF ELSE BEGIN  
     246    ENDIF ELSE BEGIN 
    248247      lon1 = min([x1, x2], max = lon2) 
    249248      lat1 = min([y1, y2], max = lat2) 
     
    288287        IF (dom[0] EQ -1) THEN BEGIN 
    289288          IF keyword_set(findalways) THEN BEGIN 
    290 ; if t grid parameters alreday defined, we use them...  
     289; if t grid parameters alreday defined, we use them... 
    291290            CASE 1 OF 
    292291              (where(gridtype eq 'T'))[0] NE -1 OR (where(gridtype EQ 'W'))[0] NE -1:BEGIN 
     
    337336                firstxv = firstxt & lastxv = lastxt & nxv = nxt 
    338337                firstyv = firstyt & lastyv = lastyt & nyv = nyt 
    339               END  
     338              END 
    340339              (where(gridtype eq 'U'))[0] NE -1:BEGIN 
    341340                print, 'WARNING, empty V points box... we use the same index as U points...' 
    342341                firstxv = firstxu & lastxv = lastxu & nxv = nxu 
    343342                firstyv = firstyu & lastyv = lastyu & nyv = nyu 
    344               END  
     343              END 
    345344              ELSE:BEGIN 
    346345                print, 'WARNING, empty V points box... we get the neighnors to define a new box...' 
     
    385384                firstxf = firstxt & lastxf = lastxt & nxf = nxt 
    386385                firstyf = firstyt & lastyf = lastyt & nyf = nyt 
    387               END  
     386              END 
    388387              (where(gridtype eq 'U'))[0] NE -1:BEGIN 
    389388                print, 'WARNING, empty F points box... we use the same index as U points...' 
    390389                firstxf = firstxu & lastxf = lastxu & nxf = nxu 
    391390                firstyf = firstyu & lastyf = lastyu & nyf = nyu 
    392               END  
     391              END 
    393392              (where(gridtype eq 'V'))[0] NE -1:BEGIN 
    394393                print, 'WARNING, empty F points box... we use the same index as V points...' 
    395394                firstxf = firstxv & lastxf = lastxv & nxf = nxv 
    396395                firstyf = firstyv & lastyf = lastyv & nyf = nyv 
    397               END  
     396              END 
    398397              ELSE:BEGIN 
    399398                print, 'WARNING, empty F points box... we get the neighnors to define a new box...' 
     
    406405                RETURN 
    407406              END 
    408             ENDCASE   
     407            ENDCASE 
    409408          ENDIF ELSE BEGIN 
    410409            ras = report('WARNING, The box does not contain any F points...') 
     
    469468          firstyv = fsty & lastyv = lsty 
    470469          nxv = nx & nyv = ny 
    471         ENDIF          
     470        ENDIF 
    472471; find lon1f, lon2f, lat1f, lat2f, firstxf, firstxf, nxf and nyf 
    473472; according to x1, x2, y1, y2 
     
    537536                    print, 'WARNING, empty U points box... we use the same index as T points...' 
    538537                    firstyu = firstyt & lastyu = lastyt & nyu = nyt 
    539                   END  
     538                  END 
    540539                  ELSE:BEGIN 
    541540                    print, 'WARNING, empty U points box... we get the neighnors to define a new box...' 
     
    548547                    RETURN 
    549548                  END 
    550                 ENDCASE  
     549                ENDCASE 
    551550              ENDIF ELSE BEGIN 
    552551                ras = report('WARNING, The box does not contain any U points...') 
     
    575574                    print, 'WARNING, empty V points box... we use the same index as T points...' 
    576575                    firstyv = firstyt & lastyv = lastyt & nyv = nyt 
    577                   END  
     576                  END 
    578577                  (where(gridtype eq 'U'))[0] NE -1:BEGIN 
    579578                    print, 'WARNING, empty V points box... we use the same index as U points...' 
    580579                    firstyv = firstyu & lastyv = lastyu & nyv = nyu 
    581                   END  
     580                  END 
    582581                  ELSE:BEGIN 
    583582                    print, 'WARNING, empty V points box... we get the neighnors to define a new box...' 
     
    589588                    ENDCASE 
    590589                    RETURN 
    591                   END  
    592                 ENDCASE  
     590                  END 
     591                ENDCASE 
    593592              ENDIF ELSE BEGIN 
    594593                ras = report('WARNING, The box does not contain any V points...') 
     
    617616                    print, 'WARNING, empty F points box... we use the same index as T points...' 
    618617                    firstyf = firstyt & lastyf = lastyt & nyf = nyt 
    619                   END  
     618                  END 
    620619                  (where(gridtype eq 'U'))[0] NE -1:BEGIN 
    621620                    print, 'WARNING, empty F points box... we use the same index as U points...' 
    622621                    firstyf = firstyu & lastyf = lastyu & nyf = nyu 
    623                   END  
     622                  END 
    624623                  (where(gridtype eq 'V'))[0] NE -1:BEGIN 
    625624                    print, 'WARNING, empty F points box... we use the same index as V points...' 
    626625                    firstyf = firstyv & lastyf = lastyv & nyf = nyv 
    627                   END  
     626                  END 
    628627                  ELSE:BEGIN 
    629628                    print, 'WARNING, empty F points box... we get the neighnors to define a new box...' 
     
    636635                    RETURN 
    637636                  END 
    638                 ENDCASE  
     637                ENDCASE 
    639638              ENDIF ELSE BEGIN 
    640639                ras = report('WARNING, The box does not contain any F points...') 
     
    705704                    print, 'WARNING, empty U points box... we use the same index as T points...' 
    706705                    firstxu = firstxt & lastxu = lastxt & nxu = nxt 
    707                   END  
     706                  END 
    708707                  ELSE:BEGIN 
    709708                    print, 'WARNING, empty U points box... we get the neighnors to define a new box...' 
     
    716715                    RETURN 
    717716                  END 
    718                 ENDCASE  
     717                ENDCASE 
    719718              ENDIF ELSE BEGIN 
    720719                ras = report('WARNING, The box does not contain any U points...') 
     
    743742                    print, 'WARNING, empty V points box... we use the same index as T points...' 
    744743                    firstxv = firstxt & lastxv = lastxt & nxv = nxt 
    745                   END  
     744                  END 
    746745                  (where(gridtype eq 'U'))[0] NE -1:BEGIN 
    747746                    print, 'WARNING, empty V points box... we use the same index as U points...' 
    748747                    firstxv = firstxu & lastxv = lastxu & nxv = nxu 
    749                   END  
     748                  END 
    750749                  ELSE:BEGIN 
    751750                    print, 'WARNING, empty V points box... we get the neighnors to define a new box...' 
     
    757756                    ENDCASE 
    758757                    RETURN 
    759                   END  
    760                 ENDCASE  
     758                  END 
     759                ENDCASE 
    761760              ENDIF ELSE BEGIN 
    762761                ras = report('WARNING, The box does not contain any V points...') 
     
    785784                    print, 'WARNING, empty F points box... we use the same index as T points...' 
    786785                    firstxf = firstxt & lastxf = lastxt & nxf = nxt 
    787                   END  
     786                  END 
    788787                  (where(gridtype eq 'U'))[0] NE -1:BEGIN 
    789788                    print, 'WARNING, empty F points box... we use the same index as U points...' 
    790789                    firstxf = firstxu & lastxf = lastxu & nxf = nxu 
    791                   END  
     790                  END 
    792791                  (where(gridtype eq 'V'))[0] NE -1:BEGIN 
    793792                    print, 'WARNING, empty F points box... we use the same index as V points...' 
    794793                    firstxf = firstxv & lastxf = lastxv & nxf = nxv 
    795                   END  
     794                  END 
    796795                  ELSE:BEGIN 
    797796                    print, 'WARNING, empty F points box... we get the neighnors to define a new box...' 
     
    803802                    ENDCASE 
    804803                    RETURN 
    805                   END  
    806                 ENDCASE  
     804                  END 
     805                ENDCASE 
    807806              ENDIF ELSE BEGIN 
    808807                ras = report('WARNING, The box does not contain any F points...') 
     
    821820      END 
    822821    ENDCASE 
    823   ENDELSE  
    824 ;------------------------------------------------------------------- 
    825 ; The extracted domain is it regular or not?  
     822  ENDELSE 
     823;------------------------------------------------------------------- 
     824; The extracted domain is it regular or not? 
    826825;------------------------------------------------------------------- 
    827826  CASE 1 OF 
    828827    ((where(gridtype eq 'T'))[0] NE -1 OR (where(gridtype eq 'W'))[0] NE -1) AND nxt NE 0 AND nyt NE 0:BEGIN 
    829 ; to get faster, we first test the most basic cases befor testing the 
     828; to get faster, we first test the most basic cases before testing the 
    830829; full array. 
    831830      CASE 0 OF 
     
    908907        firstzt = domz[0] 
    909908        lastzt = domz[nzt-1] 
    910       ENDIF ELSE BEGIN  
     909      ENDIF ELSE BEGIN 
    911910        ras = report('WARNING, The box does not contain any T level...') 
    912911        firstzt = -1 
    913912        lastzt = -1 
    914       ENDELSE  
     913      ENDELSE 
    915914    ENDIF 
    916915; define firstzw, firstzw, nzw 
     
    920919        lastzw = lastzt 
    921920        nzw = nzt 
    922       ENDIF ELSE BEGIN  
     921      ENDIF ELSE BEGIN 
    923922        domz = where(gdepw ge vert1 and gdepw le vert2, nzw) 
    924923        IF nzw NE 0 THEN BEGIN 
    925924          firstzw = domz[0] 
    926925          lastzw = domz[nzw-1] 
    927         ENDIF ELSE BEGIN  
     926        ENDIF ELSE BEGIN 
    928927          ras = report('WARNING, The box does not contain any W level...') 
    929928          firstzw = -1 
    930929          lastzw = -1 
    931         ENDELSE  
    932       ENDELSE  
     930        ENDELSE 
     931      ENDELSE 
    933932    ENDIF 
    934933;------------------------------------------------------------------- 
    935934; vertical domain defined with the Z index 
    936935;------------------------------------------------------------------- 
    937   ENDIF ELSE BEGIN  
     936  ENDIF ELSE BEGIN 
    938937    CASE N_PARAMS() OF 
    939938      2:fstz = min([x1, x2], max = lstz) 
     
    951950      vert1t = min(gdept[fstz:lstz], max = vert2t) 
    952951      firstzt = fstz & lastzt = lstz & nzt = nz 
    953     ENDIF       
     952    ENDIF 
    954953; find vert1w, vert2w, firstzw, firstzw, nzw 
    955954; according to (x1, x2) or (z1, z2) 
     
    957956      vert1w = min(gdepw[fstz:lstz], max = vert2w) 
    958957      firstzw = fstz & lastzw = lstz & nzw = nz 
    959     ENDIF       
     958    ENDIF 
    960959    vert1 = min([vert1t, vert1w]) 
    961960    vert2 = max([vert2t, vert2w]) 
     
    965964  IF NOT keyword_set(key_forgetold) THEN BEGIN 
    966965@updateold 
    967   ENDIF  
    968 ;------------------------------------------------------------------- 
    969   if keyword_set(key_performance) THEN print, 'temps domdef', systime(1)-tempsun  
     966  ENDIF 
     967;------------------------------------------------------------------- 
     968  if keyword_set(key_performance) THEN print, 'temps domdef', systime(1)-tempsun 
    970969;------------------------------------------------------------------- 
    971970 
Note: See TracChangeset for help on using the changeset viewer.