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 11317 for NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/tests/ICE_ADV1D – NEMO

Ignore:
Timestamp:
2019-07-22T10:32:59+02:00 (5 years ago)
Author:
smasson
Message:

dev_r10984_HPC-13 : improve error handling, see #2307 and #2285

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/tests/ICE_ADV1D/MY_SRC/usrdef_nam.F90

    r10513 r11317  
    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 
    67       ! 
    6865      REWIND( numnam_cfg )          ! Namelist namusr_def (exist in namelist_cfg only) 
    6966      READ  ( numnam_cfg, namusr_def, IOSTAT = ios, ERR = 902 ) 
    70 902   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namusr_def in configuration namelist', .TRUE. ) 
     67902   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namusr_def in configuration namelist' ) 
    7168      ! 
    72       WRITE( ldnam(:), namusr_def ) 
     69      WRITE( numond, namusr_def ) 
    7370      ! 
    7471      cd_cfg = 'ICE_ADV1D'           ! name & resolution (not used) 
     
    8380      zly = kpj*rn_dy*1.e-3 
    8481      !                             ! control print 
    85       WRITE(ldtxt(ii),*) '   '                                                                          ;   ii = ii + 1 
    86       WRITE(ldtxt(ii),*) 'usr_def_nam  : read the user defined namelist (namusr_def) in namelist_cfg'   ;   ii = ii + 1 
    87       WRITE(ldtxt(ii),*) '~~~~~~~~~~~ '                                                                 ;   ii = ii + 1 
    88       WRITE(ldtxt(ii),*) '   Namelist namusr_def : ICE_ADV1D test case'                                 ;   ii = ii + 1 
    89       WRITE(ldtxt(ii),*) '      horizontal resolution                    rn_dx  = ', rn_dx, ' meters'   ;   ii = ii + 1 
    90       WRITE(ldtxt(ii),*) '      horizontal resolution                    rn_dy  = ', rn_dy, ' meters'   ;   ii = ii + 1 
    91       WRITE(ldtxt(ii),*) '      ICE_ADV1D domain  '                                                     ;   ii = ii + 1 
    92       WRITE(ldtxt(ii),*) '         LX [km]: ', zlx                                                      ;   ii = ii + 1 
    93       WRITE(ldtxt(ii),*) '         LY [km]: ', zly                                                      ;   ii = ii + 1 
    94       WRITE(ldtxt(ii),*) '         resulting global domain size :        jpiglo = ', kpi                ;   ii = ii + 1 
    95       WRITE(ldtxt(ii),*) '                                               jpjglo = ', kpj                ;   ii = ii + 1 
    96       WRITE(ldtxt(ii),*) '                                               jpkglo = ', kpk                ;   ii = ii + 1 
    97       WRITE(ldtxt(ii),*) '         Coriolis:', ln_corio                                                 ;   ii = ii + 1 
     82      WRITE(numout,*) '   ' 
     83      WRITE(numout,*) 'usr_def_nam  : read the user defined namelist (namusr_def) in namelist_cfg' 
     84      WRITE(numout,*) '~~~~~~~~~~~ ' 
     85      WRITE(numout,*) '   Namelist namusr_def : ICE_ADV1D test case' 
     86      WRITE(numout,*) '      horizontal resolution                    rn_dx  = ', rn_dx, ' meters' 
     87      WRITE(numout,*) '      horizontal resolution                    rn_dy  = ', rn_dy, ' meters' 
     88      WRITE(numout,*) '      ICE_ADV1D domain  ' 
     89      WRITE(numout,*) '         LX [km]: ', zlx 
     90      WRITE(numout,*) '         LY [km]: ', zly 
     91      WRITE(numout,*) '         resulting global domain size :        jpiglo = ', kpi 
     92      WRITE(numout,*) '                                               jpjglo = ', kpj 
     93      WRITE(numout,*) '                                               jpkglo = ', kpk 
     94      WRITE(numout,*) '         Coriolis:', ln_corio 
    9895      ! 
    9996      !                             ! Set the lateral boundary condition of the global domain 
    10097      kperio = 0                    ! ICE_ADV1D configuration : bi-periodic basin 
    10198      ! 
    102       WRITE(ldtxt(ii),*) '   '                                                                          ;   ii = ii + 1 
    103       WRITE(ldtxt(ii),*) '   Lateral boundary condition of the global domain'                           ;   ii = ii + 1 
    104       WRITE(ldtxt(ii),*) '      ICE_ADV1D : closed basin                    jperio = ', kperio          ;   ii = ii + 1 
     99      WRITE(numout,*) '   ' 
     100      WRITE(numout,*) '   Lateral boundary condition of the global domain' 
     101      WRITE(numout,*) '      ICE_ADV1D : closed basin                    jperio = ', kperio 
    105102      ! 
    106103   END SUBROUTINE usr_def_nam 
Note: See TracChangeset for help on using the changeset viewer.