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 8731 for branches/UKMO/dev_r8183_GC_couple_pkg/NEMOGCM/NEMO/OPA_SRC/SBC/geo2ocean.F90 – NEMO

Ignore:
Timestamp:
2017-11-17T12:37:29+01:00 (6 years ago)
Author:
dancopsey
Message:

Merged in NEMO3.6 version of this branch (dev_r5518_GC3_couple_pkg)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/UKMO/dev_r8183_GC_couple_pkg/NEMOGCM/NEMO/OPA_SRC/SBC/geo2ocean.F90

    r8730 r8731  
    5151   !!---------------------------------------------------------------------- 
    5252CONTAINS 
     53 
     54   SUBROUTINE repcmo ( pxu1, pyu1, pxv1, pyv1,   & 
     55                       px2 , py2 , kchoix  ) 
     56      !!---------------------------------------------------------------------- 
     57      !!                  ***  ROUTINE repcmo  *** 
     58      !! 
     59      !! ** Purpose :   Change vector componantes from a geographic grid to a 
     60      !!      stretched coordinates grid. 
     61      !! 
     62      !! ** Method  :   Initialization of arrays at the first call. 
     63      !! 
     64      !! ** Action  : - px2 : first  componante (defined at u point) 
     65      !!              - py2 : second componante (defined at v point) 
     66      !!---------------------------------------------------------------------- 
     67      REAL(wp), INTENT(in   ), DIMENSION(jpi,jpj) ::   pxu1, pyu1   ! geographic vector componantes at u-point 
     68      REAL(wp), INTENT(in   ), DIMENSION(jpi,jpj) ::   pxv1, pyv1   ! geographic vector componantes at v-point 
     69      REAL(wp), INTENT(  out), DIMENSION(jpi,jpj) ::   px2          ! i-componante (defined at u-point) 
     70      REAL(wp), INTENT(  out), DIMENSION(jpi,jpj) ::   py2          ! j-componante (defined at v-point) 
     71      !!---------------------------------------------------------------------- 
     72      INTEGER, INTENT( IN ) ::   & 
     73         kchoix   ! type of transformation 
     74                  ! = 1 change from geographic to model grid. 
     75                  ! =-1 change from model to geographic grid 
     76      !!---------------------------------------------------------------------- 
     77  
     78      SELECT CASE (kchoix) 
     79      CASE ( 1) 
     80        ! Change from geographic to stretched coordinate 
     81        ! ---------------------------------------------- 
     82      
     83        CALL rot_rep( pxu1, pyu1, 'U', 'en->i',px2 ) 
     84        CALL rot_rep( pxv1, pyv1, 'V', 'en->j',py2 ) 
     85      CASE (-1) 
     86       ! Change from stretched to geographic coordinate 
     87       ! ---------------------------------------------- 
     88      
     89       CALL rot_rep( pxu1, pyu1, 'U', 'ij->e',px2 ) 
     90       CALL rot_rep( pxv1, pyv1, 'V', 'ij->n',py2 ) 
     91     END SELECT 
     92      
     93   END SUBROUTINE repcmo 
    5394 
    5495   SUBROUTINE rot_rep ( pxin, pyin, cd_type, cdtodo, prot ) 
Note: See TracChangeset for help on using the changeset viewer.