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 3875 for branches/2013/dev_r3853_CNRS9_ConfSetting/NEMOGCM/NEMO/OFF_SRC – NEMO

Ignore:
Timestamp:
2013-04-18T16:38:06+02:00 (11 years ago)
Author:
clevy
Message:

Configuration Setting/Step? 1, see ticket:#1074

Location:
branches/2013/dev_r3853_CNRS9_ConfSetting/NEMOGCM/NEMO/OFF_SRC
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/2013/dev_r3853_CNRS9_ConfSetting/NEMOGCM/NEMO/OFF_SRC/domain.F90

    r3632 r3875  
    8888      !!---------------------------------------------------------------------- 
    8989      USE ioipsl 
     90      INTEGER  ::   ios                 ! Local integer output status for namelist read 
    9091      NAMELIST/namrun/ nn_no   , cn_exp    , cn_ocerst_in, cn_ocerst_out, ln_rstart , nn_rstctl,   & 
    9192         &             nn_it000, nn_itend  , nn_date0    , nn_leapy     , nn_istate , nn_stock ,   & 
     
    100101      !!---------------------------------------------------------------------- 
    101102 
    102       REWIND( numnam )              ! Namelist namrun : parameters of the run 
    103       READ  ( numnam, namrun ) 
     103      REWIND( numnam_ref )              ! Namelist namrun in reference namelist : Parameters of the run 
     104      READ  ( numnam_ref, namrun, IOSTAT = ios, ERR = 901) 
     105901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namrun in reference namelist', lwp ) 
     106 
     107      REWIND( numnam_cfg )              ! Namelist namrun in configuration namelist : Parameters of the run 
     108      READ  ( numnam_cfg, namrun, IOSTAT = ios, ERR = 902 ) 
     109902   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namrun in configuration namelist', lwp ) 
     110      WRITE ( numond, namrun ) 
    104111      ! 
    105112      IF(lwp) THEN                  ! control print 
     
    170177#endif 
    171178 
    172       REWIND( numnam )             ! Domain 
    173       READ  ( numnam, namdom ) 
     179      REWIND( numnam_ref )              ! Namelist namdom in reference namelist : space & time domain (bathymetry, mesh, timestep) 
     180      READ  ( numnam_ref, namdom, IOSTAT = ios, ERR = 903) 
     181903   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namdom in reference namelist', lwp ) 
     182 
     183      REWIND( numnam_cfg )              ! Namelist namdom in configuration namelist : space & time domain (bathymetry, mesh, timestep) 
     184      READ  ( numnam_cfg, namdom, IOSTAT = ios, ERR = 904 ) 
     185904   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namdom in configuration namelist', lwp ) 
     186      WRITE ( numond, namdom ) 
    174187 
    175188      IF(lwp) THEN 
     
    206219      rdth      = rn_rdth 
    207220 
    208       REWIND( numnam )             ! Namelist cross land advection 
    209       READ  ( numnam, namcla ) 
     221      REWIND( numnam_ref )              ! Namelist namcla in reference namelist : Cross land advection 
     222      READ  ( numnam_ref, namcla, IOSTAT = ios, ERR = 905) 
     223905   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namcla in reference namelist', lwp ) 
     224 
     225      REWIND( numnam_cfg )              ! Namelist namcla in configuration namelist : Cross land advection 
     226      READ  ( numnam_cfg, namcla, IOSTAT = ios, ERR = 906 ) 
     227906   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namcla in configuration namelist', lwp ) 
     228      WRITE( numond, namcla ) 
     229 
    210230      IF(lwp) THEN 
    211231         WRITE(numout,*) 
     
    216236#if defined key_netcdf4 
    217237      !                             ! NetCDF 4 case   ("key_netcdf4" defined) 
    218       REWIND( numnam )                    ! Namelist namnc4 : netcdf4 chunking parameters 
    219       READ  ( numnam, namnc4 ) 
     238      REWIND( numnam_ref )              ! Namelist namnc4 in reference namelist : NETCDF 
     239      READ  ( numnam_ref, namnc4, IOSTAT = ios, ERR = 907) 
     240907   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namnc4 in reference namelist', lwp ) 
     241 
     242      REWIND( numnam_cfg )              ! Namelist namnc4 in configuration namelist : NETCDF 
     243      READ  ( numnam_cfg, namnc4, IOSTAT = ios, ERR = 908 ) 
     244908   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namnc4 in configuration namelist', lwp ) 
     245      WRITE( numond, namnc4 ) 
    220246      IF(lwp) THEN                        ! control print 
    221247         WRITE(numout,*) 
     
    257283      !!---------------------------------------------------------------------- 
    258284      INTEGER ::   ioptio = 0   ! temporary integer 
     285      INTEGER ::   ios 
    259286      !! 
    260287      NAMELIST/namzgr/ ln_zco, ln_zps, ln_sco 
    261288      !!---------------------------------------------------------------------- 
    262289 
    263       REWIND ( numnam )                ! Read Namelist namzgr : vertical coordinate' 
    264       READ   ( numnam, namzgr ) 
     290      REWIND( numnam_ref )              ! Namelist namzgr in reference namelist : Vertical coordinate 
     291      READ  ( numnam_ref, namzgr, IOSTAT = ios, ERR = 901 ) 
     292901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namzgr in reference namelist', lwp ) 
     293 
     294      REWIND( numnam_cfg )              ! Namelist namzgr in configuration namelist : Vertical coordinate 
     295      READ  ( numnam_cfg, namzgr, IOSTAT = ios, ERR = 902 ) 
     296902   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namzgr in configuration namelist', lwp ) 
     297      WRITE ( numond, namzgr ) 
    265298 
    266299      IF(lwp) THEN                     ! Control print 
  • branches/2013/dev_r3853_CNRS9_ConfSetting/NEMOGCM/NEMO/OFF_SRC/dtadyn.F90

    r3827 r3875  
    326326      INTEGER  :: jfld                               ! dummy loop arguments 
    327327      INTEGER  :: inum, idv, idimv                   ! local integer 
     328      INTEGER  :: ios                                ! Local integer output status for namelist read 
    328329      !! 
    329330      CHARACTER(len=100)            ::  cn_dir   !   Root directory for location of core files 
     
    367368      sn_eiw  = FLD_N( 'dyna_grid_W' ,    120    , 'voveaeiw' ,  .true.    , .true. ,   'yearly'  , ''       , ''         ) 
    368369      ! 
    369       REWIND( numnam )                          ! read in namlist namdta_dyn 
    370       READ  ( numnam, namdta_dyn ) 
     370      REWIND( numnam_ref )              ! Namelist namdta_dyn in reference namelist : Offline: init. of dynamical data 
     371      READ  ( numnam_ref, namdta_dyn, IOSTAT = ios, ERR = 901) 
     372901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namdta_dyn in reference namelist', lwp ) 
     373 
     374      REWIND( numnam_cfg )              ! Namelist namdta_dyn in configuration namelist : Offline: init. of dynamical data 
     375      READ  ( numnam_cfg, namdta_dyn, IOSTAT = ios, ERR = 902 ) 
     376902   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namdta_dyn in configuration namelist', lwp ) 
     377      WRITE ( numond, namdta_dyn ) 
    371378      !                                         ! store namelist information in an array 
    372379      !                                         ! Control print 
  • branches/2013/dev_r3853_CNRS9_ConfSetting/NEMOGCM/NEMO/OFF_SRC/nemogcm.F90

    r3827 r3875  
    136136      INTEGER ::   ji            ! dummy loop indices 
    137137      INTEGER ::   ilocal_comm   ! local integer 
     138      INTEGER ::   ios 
    138139      CHARACTER(len=80), DIMENSION(16) ::   cltxt 
    139140      !! 
     
    145146      cltxt = '' 
    146147      ! 
    147       !                             ! open Namelist file 
    148       CALL ctl_opn( numnam, 'namelist', 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, 6, .FALSE. ) 
    149       ! 
    150       READ( numnam, namctl )        ! Namelist namctl : Control prints & Benchmark 
     148      !                             ! Open reference namelist and configuration namelist files 
     149      CALL ctl_opn( numnam_ref, 'namelist_ref', 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, 6, .FALSE. ) 
     150      CALL ctl_opn( numnam_cfg, 'namelist_cfg', 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, 6, .FALSE. ) 
     151      CALL ctl_opn( numond, 'output.namelist.dyn', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, 6, .FALSE., narea ) 
     152      ! 
     153      ! 
     154      REWIND( numnam_ref )              ! Namelist namctl in reference namelist : Control prints & Benchmark 
     155      READ  ( numnam_ref, namctl, IOSTAT = ios, ERR = 901 ) 
     156901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namctl in reference namelist', lwp ) 
     157 
     158      REWIND( numnam_cfg )              ! Namelist namctl in confguration namelist : Control prints & Benchmark 
     159      READ  ( numnam_cfg, namctl, IOSTAT = ios, ERR = 902 ) 
     160902   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namctl in configuration namelist', lwp ) 
     161      WRITE( numond, namctl ) 
    151162      ! 
    152163      !                             !--------------------------------------------! 
     
    155166#if defined key_iomput 
    156167         CALL  xios_initialize( "nemo",return_comm=ilocal_comm ) 
    157       narea = mynode( cltxt, numnam, nstop, ilocal_comm )   ! Nodes selection 
     168      narea = mynode( cltxt, numnam_ref, numnam_cfg, numond , nstop, ilocal_comm )   ! Nodes selection 
    158169#else 
    159170      ilocal_comm = 0 
    160       narea = mynode( cltxt, numnam, nstop )                 ! Nodes selection (control print return in cltxt) 
     171      narea = mynode( cltxt, numnam_ref, numnam_cfg, numond , nstop )                ! Nodes selection (control print return in cltxt) 
    161172#endif 
    162173 
     
    364375      ! 
    365376      IF( numstp     /= -1 )   CLOSE( numstp     )   ! time-step file 
    366       IF( numnam     /= -1 )   CLOSE( numnam     )   ! oce namelist 
     377      IF( numnam_ref /= -1 )   CLOSE( numnam_ref )   ! oce reference namelist 
     378      IF( numnam_cfg /= -1 )   CLOSE( numnam_cfg )   ! oce configuration namelist 
    367379      IF( numout     /=  6 )   CLOSE( numout     )   ! standard model output file 
    368380      numout = 6                                     ! redefine numout in case it is used after this point... 
Note: See TracChangeset for help on using the changeset viewer.