New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 2358 for branches/nemo_v3_3_beta/NEMOGCM/NEMO/OPA_SRC/OBS/obs_grid.F90 – NEMO

Ignore:
Timestamp:
2010-11-04T19:14:01+01:00 (13 years ago)
Author:
rblod
Message:

Changes to be able to compile v3_3_beta with key_agrif,see ticket #753 ; just compilation fixes, I was to scared to try to run AGRIF

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/nemo_v3_3_beta/NEMOGCM/NEMO/OPA_SRC/OBS/obs_grid.F90

    r2287 r2358  
    4444   PRIVATE linquad,                    & ! Determine whether a point lies within a cell 
    4545      &    maxdist,                    & ! Find the maximum distance between 2 pts in a cell 
    46       &    obs_grid_search_bruteforce, & ! Find i, j on the ORCA grid from lat, lon 
    47       &    obs_grid_search_lookup        ! Find i, j on the ORCA grid from lat, lon quicker 
     46      &    obs_grd_bruteforce, & ! Find i, j on the ORCA grid from lat, lon 
     47      &    obs_grd_lookup        ! Find i, j on the ORCA grid from lat, lon quicker 
    4848 
    4949   !!* Module variables 
     
    7575      & ixpos, & 
    7676      & iypos, & 
    77       & iproc     
     77      & iprocn     
    7878 
    7979   ! Switches 
     
    9898      !! ** Purpose : Search local gridpoints to find the grid box containing 
    9999      !!              the observations calls either 
    100       !!              obs_grid_search_bruteforce - the original brute force search 
     100      !!              obs_grd_bruteforce - the original brute force search 
    101101      !!                     or 
    102       !!              obs_grid_search_lookup - uses a lookup table to do a fast  
     102      !!              obs_grd_lookup - uses a lookup table to do a fast  
    103103      !!search 
    104104      !!History : 
     
    122122 
    123123         IF ( ln_grid_search_lookup .AND. ( cdgrid == 'T' ) ) THEN 
    124             CALL obs_grid_search_lookup( kobsin, plam, pphi, & 
     124            CALL obs_grd_lookup( kobsin, plam, pphi, & 
    125125               &                         kobsi, kobsj, kproc ) 
    126126         ELSE 
    127127            IF ( cdgrid == 'T' ) THEN 
    128                CALL obs_grid_search_bruteforce( jpi, jpj, jpiglo, jpjglo, & 
     128               CALL obs_grd_bruteforce( jpi, jpj, jpiglo, jpjglo, & 
    129129                  &                             nldi, nlei,nldj,  nlej,   & 
    130130                  &                             nproc, jpnij,             & 
     
    133133                  &                             kobsi, kobsj, kproc ) 
    134134            ELSEIF ( cdgrid == 'U' ) THEN 
    135                CALL obs_grid_search_bruteforce( jpi, jpj, jpiglo, jpjglo, & 
     135               CALL obs_grd_bruteforce( jpi, jpj, jpiglo, jpjglo, & 
    136136                  &                             nldi, nlei,nldj,  nlej,   & 
    137137                  &                             nproc, jpnij,             & 
     
    140140                  &                             kobsi, kobsj, kproc ) 
    141141            ELSEIF ( cdgrid == 'V' ) THEN 
    142                CALL obs_grid_search_bruteforce( jpi, jpj, jpiglo, jpjglo, & 
     142               CALL obs_grd_bruteforce( jpi, jpj, jpiglo, jpjglo, & 
    143143                  &                             nldi, nlei,nldj,  nlej,   & 
    144144                  &                             nproc, jpnij,             & 
     
    147147                  &                             kobsi, kobsj, kproc ) 
    148148            ELSEIF ( cdgrid == 'F' ) THEN 
    149                CALL obs_grid_search_bruteforce( jpi, jpj, jpiglo, jpjglo, & 
     149               CALL obs_grd_bruteforce( jpi, jpj, jpiglo, jpjglo, & 
    150150                  &                             nldi, nlei,nldj,  nlej,   & 
    151151                  &                             nproc, jpnij,             & 
     
    162162   END SUBROUTINE obs_grid_search 
    163163 
    164 #include "obs_grid_search_bruteforce.h90" 
     164#include "obs_grd_bruteforce.h90" 
    165165    
    166    SUBROUTINE obs_grid_search_lookup( kobs, plam, pphi, kobsi, kobsj, kproc ) 
     166   SUBROUTINE obs_grd_lookup( kobs, plam, pphi, kobsi, kobsj, kproc ) 
    167167      !!---------------------------------------------------------------------- 
    168       !!                ***  ROUTINE obs_grid_search_lookup *** 
     168      !!                ***  ROUTINE obs_grid_lookup *** 
    169169      !! 
    170170      !! ** Purpose : Search local gridpoints to find the grid box containing 
    171       !!              the observations (much faster then obs_grid_search_bruteforce) 
     171      !!              the observations (much faster then obs_grd_bruteforce) 
    172172      !! 
    173173      !! ** Method  : Call to linquad 
     
    361361      END DO 
    362362 
    363       if(lwp) WRITE(numout,*) 'obs_grid_search_lookup do coordinate search using lookup table' 
     363      if(lwp) WRITE(numout,*) 'obs_grid_lookup do coordinate search using lookup table' 
    364364 
    365365      !----------------------------------------------------------------------- 
     
    630630         & ) 
    631631       
    632    END SUBROUTINE obs_grid_search_lookup 
     632   END SUBROUTINE obs_grd_lookup 
    633633 
    634634 
     
    758758               & ixpos(nlons,nlats), & 
    759759               & iypos(nlons,nlats), & 
    760                & iproc(nlons,nlats)  & 
     760               & iprocn(nlons,nlats)  & 
    761761               & ) 
    762762             
     
    818818            END DO 
    819819             
    820             CALL obs_grid_search_bruteforce( jpi, jpj, jpiglo, jpjglo,  & 
    821                &                             nldi, nlei,nldj,  nlej,    & 
    822                &                             nproc, jpnij,              & 
    823                &                             glamt, gphit, tmask,       & 
    824                &                             nlons*nlats, lonsi, latsi, & 
    825                &                             ixposi, iyposi, iproci ) 
     820            CALL obs_grd_bruteforce( jpi, jpj, jpiglo, jpjglo,  & 
     821               &                     nldi, nlei,nldj,  nlej,    & 
     822               &                     nproc, jpnij,              & 
     823               &                     glamt, gphit, tmask,       & 
     824               &                     nlons*nlats, lonsi, latsi, & 
     825               &                     ixposi, iyposi, iproci ) 
    826826             
    827827            ! minimise file size by removing regions with no data from xypos file 
     
    873873               & ixpos(nlons,nlats),   & 
    874874               & iypos(nlons,nlats),   & 
    875                & iproc(nlons,nlats)    & 
     875               & iprocn(nlons,nlats)    & 
    876876               & ) 
    877877 
     
    880880            ixpos(:,:) = ixposi(jimin:jimax,jjmin:jjmax) 
    881881            iypos(:,:) = iyposi(jimin:jimax,jjmin:jjmax) 
    882             iproc(:,:) = iproci(jimin:jimax,jjmin:jjmax) 
     882            iprocn(:,:) = iproci(jimin:jimax,jjmin:jjmax) 
    883883 
    884884            DEALLOCATE(lonsi,latsi,ixposi,iyposi,iproci) 
     
    11691169 
    11701170      IF (ln_grid_search_lookup) THEN 
    1171          DEALLOCATE( lons, lats, ixpos, iypos, iproc ) 
     1171         DEALLOCATE( lons, lats, ixpos, iypos, iprocn ) 
    11721172      ENDIF 
    11731173       
Note: See TracChangeset for help on using the changeset viewer.