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 13463 for NEMO/branches/2019/dev_r11351_fldread_with_XIOS/tests/ICE_ADV2D – NEMO

Ignore:
Timestamp:
2020-09-14T17:40:34+02:00 (4 years ago)
Author:
andmirek
Message:

Ticket #2195:update to trunk 13461

Location:
NEMO/branches/2019/dev_r11351_fldread_with_XIOS
Files:
7 edited
1 copied

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/dev_r11351_fldread_with_XIOS

    • Property svn:externals
      •  

        old new  
        33^/utils/build/mk@HEAD         mk 
        44^/utils/tools@HEAD            tools 
        5 ^/vendors/AGRIF/dev@HEAD      ext/AGRIF 
         5^/vendors/AGRIF/dev_r12970_AGRIF_CMEMS      ext/AGRIF 
        66^/vendors/FCM@HEAD            ext/FCM 
        77^/vendors/IOIPSL@HEAD         ext/IOIPSL 
         8 
         9# SETTE 
         10^/utils/CI/sette@13382        sette 
  • NEMO/branches/2019/dev_r11351_fldread_with_XIOS/tests/ICE_ADV2D/EXPREF/context_nemo.xml

    r10515 r13463  
    55--> 
    66<context id="nemo"> 
    7 <!-- $id$ --> 
     7    <!-- $id$ --> 
    88    <variable_definition> 
    9     <!-- Year of time origin for NetCDF files; defaults to 1800 --> 
    10        <variable id="ref_year" type="int"   > 1800 </variable> 
    11        <variable id="rau0"     type="float" > 1026.0 </variable> 
    12        <variable id="cpocean"  type="float" > 3991.86795711963 </variable> 
    13        <variable id="convSpsu" type="float" > 0.99530670233846  </variable> 
    14        <variable id="rhoic"    type="float" > 917.0 </variable> 
    15        <variable id="rhosn"    type="float" > 330.0 </variable> 
    16        <variable id="missval"  type="float" > 1.e20 </variable> 
     9       <!-- Year/Month/Day of time origin for NetCDF files; defaults to 1800-01-01 --> 
     10       <variable id="ref_year"  type="int"> 1900 </variable> 
     11       <variable id="ref_month" type="int"> 01 </variable> 
     12       <variable id="ref_day"   type="int"> 01 </variable> 
     13       <variable id="rau0"      type="float" > 1026.0 </variable> 
     14       <variable id="cpocean"   type="float" > 3991.86795711963 </variable> 
     15       <variable id="convSpsu"  type="float" > 0.99530670233846  </variable> 
     16       <variable id="rhoic"     type="float" > 917.0 </variable> 
     17       <variable id="rhosn"     type="float" > 330.0 </variable> 
     18       <variable id="missval"   type="float" > 1.e20 </variable> 
    1719    </variable_definition> 
     20 
    1821<!-- Fields definition --> 
    1922    <field_definition src="./field_def_nemo-oce.xml"/>    <!--  NEMO ocean dynamics     --> 
     
    2326    <file_definition src="./file_def_nemo-oce.xml"/>     <!--  NEMO ocean dynamics      --> 
    2427    <file_definition src="./file_def_nemo-ice.xml"/>     <!--  NEMO sea-ice model       --> 
    25     <!--  
    26 ============================================================================================================ 
    27 = grid definition = = DO NOT CHANGE = 
    28 ============================================================================================================ 
    29     --> 
    30      
    31     <axis_definition> 
    32       <axis id="deptht"  long_name="Vertical T levels"  unit="m" positive="down" /> 
    33       <axis id="depthu"  long_name="Vertical U levels"  unit="m" positive="down" /> 
    34       <axis id="depthv"  long_name="Vertical V levels"  unit="m" positive="down" /> 
    35       <axis id="depthw"  long_name="Vertical W levels"  unit="m" positive="down" /> 
    36       <axis id="nfloat"  long_name="Float number"       unit="-"                 /> 
    37       <axis id="icbcla"  long_name="Iceberg class"      unit="1"                 /> 
    38       <axis id="ncatice" long_name="Ice category"       unit="1"                 /> 
    39       <axis id="iax_20C" long_name="20 degC isotherm"   unit="degC"              /> 
    40       <axis id="iax_28C" long_name="28 degC isotherm"   unit="degC"              /> 
    41     </axis_definition> 
     28 
     29 
     30<!-- Axis definition --> 
     31    <axis_definition src="./axis_def_nemo.xml"/> 
    4232  
     33<!-- Domain definition --> 
    4334    <domain_definition src="./domain_def_nemo.xml"/> 
     35 
     36<!-- Grids definition --> 
     37    <grid_definition   src="./grid_def_nemo.xml"/> 
    4438   
    45     <grid_definition src="./grid_def_nemo.xml"/> 
    4639 
    4740</context> 
  • NEMO/branches/2019/dev_r11351_fldread_with_XIOS/tests/ICE_ADV2D/EXPREF/namelist_cfg

    r10520 r13463  
    3939   ln_linssh   = .true.    !  =T  linear free surface  ==>>  model level are fixed in time 
    4040   ! 
    41    rn_rdt      = 1200.     !  time step for the dynamics (and tracer if nn_acc=0) 
     41   rn_Dt      = 1200.     !  time step for the dynamics (and tracer if nn_acc=0) 
    4242   ! 
    4343   ln_meshmask = .true.   !  =T  create a mesh file 
     
    106106!!                                                                    !! 
    107107!!   namdrg        top/bottom drag coefficient                          (default: NO selection) 
    108 !!   namdrg_top    top    friction                                      (ln_OFF=F & ln_isfcav=T) 
    109 !!   namdrg_bot    bottom friction                                      (ln_OFF=F) 
     108!!   namdrg_top    top    friction                                      (ln_drg_OFF=F & ln_isfcav=T) 
     109!!   namdrg_bot    bottom friction                                      (ln_drg_OFF=F) 
    110110!!   nambbc        bottom temperature boundary condition                (default: OFF) 
    111111!!   nambbl        bottom boundary layer scheme                         (default: OFF) 
     
    115115&namdrg        !   top/bottom drag coefficient                          (default: NO selection) 
    116116!----------------------------------------------------------------------- 
    117    ln_OFF     = .true.     !  free-slip       : Cd = 0                   
     117   ln_drg_OFF = .true.     !  free-slip       : Cd = 0                  (F => fill namdrg_bot 
    118118/ 
    119119!!====================================================================== 
     
    201201!!   namdiu       Cool skin and warm layer models                       (default: OFF) 
    202202!!   namdiu       Cool skin and warm layer models                       (default: OFF) 
    203 !!   namflo       float parameters                                      ("key_float") 
    204 !!   nam_diaharm  Harmonic analysis of tidal constituents               ("key_diaharm") 
    205 !!   namdct       transports through some sections                      ("key_diadct") 
    206 !!   nam_diatmb   Top Middle Bottom Output                              (default: OFF) 
     203!!   namflo       float parameters                                      (default: OFF) 
     204!!   nam_diadct   transports through some sections                      (default: OFF) 
    207205!!   nam_dia25h   25h Mean Output                                       (default: OFF) 
    208206!!   namnc4       netcdf4 chunking and compression settings             ("key_netcdf4") 
  • NEMO/branches/2019/dev_r11351_fldread_with_XIOS/tests/ICE_ADV2D/MY_SRC/usrdef_hgr.F90

    r10515 r13463  
    2626   PUBLIC   usr_def_hgr   ! called by domhgr.F90 
    2727 
     28   !! * Substitutions 
     29#  include "do_loop_substitute.h90" 
    2830   !!---------------------------------------------------------------------- 
    2931   !! NEMO/OCE 4.0 , NEMO Consortium (2018) 
     
    6264      REAL(wp), DIMENSION(:,:), INTENT(out) ::   pe1e2u, pe1e2v               ! u- & v-surfaces (if reduction in strait)   [m2] 
    6365      ! 
    64       INTEGER  ::   ji, jj   ! dummy loop indices 
     66      INTEGER  ::   ji, jj     ! dummy loop indices 
    6567      REAL(wp) ::   zphi0, zlam0, zbeta, zf0 
    66       REAL(wp) ::   zti, zui, ztj, zvj   ! local scalars 
     68      REAL(wp) ::   zti, ztj   ! local scalars 
    6769      !!------------------------------------------------------------------------------- 
    6870      ! 
     
    7476 
    7577      !                          ========== 
    76       zlam0 = -(jpiglo-1)/2 * 1.e-3 * rn_dx 
    77       zphi0 = -(jpjglo-1)/2 * 1.e-3 * rn_dy 
     78      zlam0 = -REAL( (Ni0glo-2)/2, wp) * 1.e-3 * rn_dx 
     79      zphi0 = -REAL( (Nj0glo-2)/2, wp) * 1.e-3 * rn_dy  
    7880 
    7981#if defined key_agrif  
     
    8183!clem         zlam0  = Agrif_Parent(zlam0) + (Agrif_ix())*Agrif_Parent(rn_dx) * 1.e-5 
    8284!clem         zphi0  = Agrif_Parent(zphi0) + (Agrif_iy())*Agrif_Parent(rn_dy) * 1.e-5 
    83          zlam0 = ( 0.5_wp - ( Agrif_parent(jpiglo) - 1 ) / 2 ) * 1.e-3 * Agrif_irhox() * rn_dx  & 
     85         zlam0 = ( 0.5_wp - REAL( (Agrif_parent(Ni0glo) - 2 ) / 2, wp ) ) * 1.e-3 * Agrif_irhox() * rn_dx  & 
    8486            &  + ( Agrif_Ix() + nbghostcells - 1 ) * Agrif_irhox() * rn_dx * 1.e-3 - ( 0.5_wp + nbghostcells ) * rn_dx * 1.e-3 
    85          zphi0 = ( 0.5_wp - ( Agrif_parent(jpjglo) - 1 ) / 2 ) * 1.e-3 * Agrif_irhoy() * rn_dy  & 
     87         zphi0 = ( 0.5_wp - REAL( (Agrif_parent(Nj0glo) - 2 ) / 2, wp ) ) * 1.e-3 * Agrif_irhoy() * rn_dy  & 
    8688            &  + ( Agrif_Iy() + nbghostcells - 1 ) * Agrif_irhoy() * rn_dy * 1.e-3 - ( 0.5_wp + nbghostcells ) * rn_dy * 1.e-3 
    8789      ENDIF 
    8890#endif          
    8991 
    90       DO jj = 1, jpj 
    91          DO ji = 1, jpi 
    92             zti = FLOAT( ji - 1 + nimpp - 1 )          ;  ztj = FLOAT( jj - 1 + njmpp - 1 ) 
    93             zui = FLOAT( ji - 1 + nimpp - 1 ) + 0.5_wp ;  zvj = FLOAT( jj - 1 + njmpp - 1 ) + 0.5_wp 
    94  
    95             plamt(ji,jj) = zlam0 + rn_dx * 1.e-3 * zti 
    96             plamu(ji,jj) = zlam0 + rn_dx * 1.e-3 * zui 
    97             plamv(ji,jj) = plamt(ji,jj)  
    98             plamf(ji,jj) = plamu(ji,jj)  
    99     
    100             pphit(ji,jj) = zphi0 + rn_dy * 1.e-3 * ztj 
    101             pphiv(ji,jj) = zphi0 + rn_dy * 1.e-3 * zvj 
    102             pphiu(ji,jj) = pphit(ji,jj)  
    103             pphif(ji,jj) = pphiv(ji,jj)  
    104          END DO 
    105       END DO 
     92      DO_2D( 1, 1, 1, 1 ) 
     93         zti = REAL( mig0_oldcmp(ji) - 1, wp )   ! start at i=0 in the global grid without halos 
     94         ztj = REAL( mjg0_oldcmp(jj) - 1, wp )   ! start at j=0 in the global grid without halos 
     95          
     96         plamt(ji,jj) = zlam0 + rn_dx * 1.e-3 *   zti 
     97         plamu(ji,jj) = zlam0 + rn_dx * 1.e-3 * ( zti + 0.5_wp ) 
     98         plamv(ji,jj) = plamt(ji,jj)  
     99         plamf(ji,jj) = plamu(ji,jj)  
     100          
     101         pphit(ji,jj) = zphi0 + rn_dy * 1.e-3 *   ztj 
     102         pphiv(ji,jj) = zphi0 + rn_dy * 1.e-3 * ( ztj + 0.5_wp ) 
     103         pphiu(ji,jj) = pphit(ji,jj)  
     104         pphif(ji,jj) = pphiv(ji,jj)  
     105      END_2D 
    106106          
    107107         ! Horizontal scale factors (in meters) 
  • NEMO/branches/2019/dev_r11351_fldread_with_XIOS/tests/ICE_ADV2D/MY_SRC/usrdef_nam.F90

    r10515 r13463  
    1414   !!   usr_def_hgr   : initialize the horizontal mesh  
    1515   !!---------------------------------------------------------------------- 
    16    USE dom_oce  , ONLY: nimpp , njmpp            ! i- & j-indices of the local domain 
     16   USE dom_oce 
    1717   USE par_oce        ! ocean space and time domain 
    1818   USE phycst         ! physical constants 
     
    4040CONTAINS 
    4141 
    42    SUBROUTINE usr_def_nam( ldtxt, ldnam, cd_cfg, kk_cfg, kpi, kpj, kpk, kperio ) 
     42   SUBROUTINE usr_def_nam( cd_cfg, kk_cfg, kpi, kpj, kpk, kperio ) 
    4343      !!---------------------------------------------------------------------- 
    4444      !!                     ***  ROUTINE dom_nam  *** 
     
    5252      !! ** input   : - namusr_def namelist found in namelist_cfg 
    5353      !!---------------------------------------------------------------------- 
    54       CHARACTER(len=*), DIMENSION(:), INTENT(out) ::   ldtxt, ldnam    ! stored print information 
    5554      CHARACTER(len=*)              , INTENT(out) ::   cd_cfg          ! configuration name 
    5655      INTEGER                       , INTENT(out) ::   kk_cfg          ! configuration resolution 
     
    5857      INTEGER                       , INTENT(out) ::   kperio          ! lateral global domain b.c.  
    5958      ! 
    60       INTEGER ::   ios, ii   ! Local integer 
     59      INTEGER ::   ios       ! Local integer 
    6160      REAL(wp)::   zlx, zly  ! Local scalars 
    6261      !! 
     
    6463      !!---------------------------------------------------------------------- 
    6564      ! 
    66       ii = 1 
     65      READ  ( numnam_cfg, namusr_def, IOSTAT = ios, ERR = 902 ) 
     66902   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namusr_def in configuration namelist' ) 
    6767      ! 
    68       REWIND( numnam_cfg )          ! Namelist namusr_def (exist in namelist_cfg only) 
    69       READ  ( numnam_cfg, namusr_def, IOSTAT = ios, ERR = 902 ) 
    70 902   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namusr_def in configuration namelist', .TRUE. ) 
     68      IF(lwm)   WRITE( numond, namusr_def ) 
    7169      ! 
    7270#if defined key_agrif  
     
    7977#endif 
    8078      ! 
    81       WRITE( ldnam(:), namusr_def ) 
     79      IF(lwm)   WRITE( numond, namusr_def ) 
    8280      ! 
    8381      cd_cfg = 'ICE_ADV2D'           ! name & resolution (not used) 
    84       kk_cfg = INT( rn_dx ) 
     82      kk_cfg = NINT( rn_dx ) 
    8583      ! 
    86       ! Global Domain size:  ICE_ADV2D domain is  300 km x 300 Km x 10 m 
    87       kpi = INT( 300.e3 / rn_dx ) -1 
    88       kpj = INT( 300.e3 / rn_dy ) -1 
    89 #if defined key_agrif 
    90       IF( .NOT. Agrif_Root() ) THEN 
    91          kpi = nbcellsx + 2 + 2*nbghostcells 
    92          kpj = nbcellsy + 2 + 2*nbghostcells 
     84      IF( Agrif_Root() ) THEN        ! Global Domain size: ICE_AGRIF domain is  300 km x 300 Km x 10 m 
     85         kpi = NINT( 300.e3 / rn_dx ) - 1 
     86         kpj = NINT( 300.e3 / rn_dy ) - 1 
     87      ELSE                           ! Global Domain size: add nbghostcells + 1 "land" point on each side 
     88         kpi  = nbcellsx + nbghostcells_x   + nbghostcells_x   + 2 
     89         kpj  = nbcellsy + nbghostcells_y_s + nbghostcells_y_n + 2 
    9390      ENDIF 
    94 #endif 
    95       kpk = 1 
     91      kpk = 2 
    9692      ! 
    9793!!      zlx = (kpi-2)*rn_dx*1.e-3 
     
    9995      zlx = kpi*rn_dx*1.e-3 
    10096      zly = kpj*rn_dy*1.e-3 
     97      ! 
     98      IF( Agrif_Root() ) THEN   ;   kperio = 7     ! ICE_AGRIF configuration : bi-periodic basin 
     99      ELSE                      ;   kperio = 0     ! closed periodicity for the zoom 
     100      ENDIF 
    101101      !                             ! control print 
    102       WRITE(ldtxt(ii),*) '   '                                                                          ;   ii = ii + 1 
    103       WRITE(ldtxt(ii),*) 'usr_def_nam  : read the user defined namelist (namusr_def) in namelist_cfg'   ;   ii = ii + 1 
    104       WRITE(ldtxt(ii),*) '~~~~~~~~~~~ '                                                                 ;   ii = ii + 1 
    105       WRITE(ldtxt(ii),*) '   Namelist namusr_def : ICE_ADV2D test case'                                 ;   ii = ii + 1 
    106       WRITE(ldtxt(ii),*) '      horizontal resolution                    rn_dx  = ', rn_dx, ' meters'   ;   ii = ii + 1 
    107       WRITE(ldtxt(ii),*) '      horizontal resolution                    rn_dy  = ', rn_dy, ' meters'   ;   ii = ii + 1 
    108       WRITE(ldtxt(ii),*) '      ICE_ADV2D domain = 300 km x 300Km x 1 grid-point '                      ;   ii = ii + 1 
    109       WRITE(ldtxt(ii),*) '         LX [km]: ', zlx                                                      ;   ii = ii + 1 
    110       WRITE(ldtxt(ii),*) '         LY [km]: ', zly                                                      ;   ii = ii + 1 
    111       WRITE(ldtxt(ii),*) '         resulting global domain size :        jpiglo = ', kpi                ;   ii = ii + 1 
    112       WRITE(ldtxt(ii),*) '                                               jpjglo = ', kpj                ;   ii = ii + 1 
    113       WRITE(ldtxt(ii),*) '                                               jpkglo = ', kpk                ;   ii = ii + 1 
    114       WRITE(ldtxt(ii),*) '         Coriolis:', ln_corio                                                 ;   ii = ii + 1 
    115       ! 
    116       !                             ! Set the lateral boundary condition of the global domain 
    117       kperio = 7                    ! ICE_ADV2D configuration : bi-periodic basin 
    118 #if defined key_agrif 
    119       IF( .NOT. Agrif_Root() ) THEN 
    120       kperio = 0 
     102      IF(lwp) THEN 
     103         WRITE(numout,*) '   ' 
     104         WRITE(numout,*) 'usr_def_nam  : read the user defined namelist (namusr_def) in namelist_cfg' 
     105         WRITE(numout,*) '~~~~~~~~~~~ ' 
     106         WRITE(numout,*) '   Namelist namusr_def : ICE_ADV2D test case' 
     107         WRITE(numout,*) '      horizontal resolution                    rn_dx  = ', rn_dx, ' meters' 
     108         WRITE(numout,*) '      horizontal resolution                    rn_dy  = ', rn_dy, ' meters' 
     109         WRITE(numout,*) '      ICE_ADV2D domain = 300 km x 300Km x 1 grid-point ' 
     110         WRITE(numout,*) '         LX [km]: ', zlx 
     111         WRITE(numout,*) '         LY [km]: ', zly 
     112         WRITE(numout,*) '         resulting global domain size :        Ni0glo = ', kpi 
     113         WRITE(numout,*) '                                               Nj0glo = ', kpj 
     114         WRITE(numout,*) '                                               jpkglo = ', kpk 
     115         WRITE(numout,*) '         Coriolis:', ln_corio 
     116         WRITE(numout,*) '   ' 
     117         WRITE(numout,*) '   Lateral boundary condition of the global domain' 
     118         WRITE(numout,*) '      ICE_ADV2D : bi-periodic basin            jperio = ', kperio 
    121119      ENDIF 
    122 #endif 
    123       ! 
    124       WRITE(ldtxt(ii),*) '   '                                                                          ;   ii = ii + 1 
    125       WRITE(ldtxt(ii),*) '   Lateral boundary condition of the global domain'                           ;   ii = ii + 1 
    126       WRITE(ldtxt(ii),*) '      ICE_ADV2D : bi-periodic basin               jperio = ', kperio          ;   ii = ii + 1 
    127120      ! 
    128121   END SUBROUTINE usr_def_nam 
  • NEMO/branches/2019/dev_r11351_fldread_with_XIOS/tests/ICE_ADV2D/MY_SRC/usrdef_sbc.F90

    r10515 r13463  
    3333   PUBLIC   usrdef_sbc_ice_flx  ! routine called by icestp.F90 for ice thermo 
    3434 
    35    !! * Substitutions 
    36 #  include "vectopt_loop_substitute.h90" 
    3735   !!---------------------------------------------------------------------- 
    3836   !! NEMO/OCE 4.0 , NEMO Consortium (2018) 
     
    4240CONTAINS 
    4341 
    44    SUBROUTINE usrdef_sbc_oce( kt ) 
     42   SUBROUTINE usrdef_sbc_oce( kt, Kbb ) 
    4543      !!--------------------------------------------------------------------- 
    4644      !!                    ***  ROUTINE usr_def_sbc  *** 
     
    5755      !!---------------------------------------------------------------------- 
    5856      INTEGER, INTENT(in) ::   kt   ! ocean time step 
     57      INTEGER, INTENT(in) ::   Kbb  ! ocean time index 
    5958      !!--------------------------------------------------------------------- 
    6059      ! 
  • NEMO/branches/2019/dev_r11351_fldread_with_XIOS/tests/ICE_ADV2D/MY_SRC/usrdef_zgr.F90

    r10515 r13463  
    2525   PUBLIC   usr_def_zgr   ! called by domzgr.F90 
    2626 
    27   !! * Substitutions 
    28 #  include "vectopt_loop_substitute.h90" 
    2927   !!---------------------------------------------------------------------- 
    3028   !! NEMO/OCE 4.0 , NEMO Consortium (2018) 
Note: See TracChangeset for help on using the changeset viewer.