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 11960 for NEMO/branches/2019/dev_r11943_MERGE_2019/src/TOP/PISCES/SED/sedini.F90 – NEMO

Ignore:
Timestamp:
2019-11-25T18:19:39+01:00 (4 years ago)
Author:
acc
Message:

Branch 2019/dev_r11943_MERGE_2019. Merge in changes from 2019/dev_r11613_ENHANCE-04_namelists_as_internalfiles. (svn merge -r 11614:11954). Resolved tree conflicts and one actual conflict. Sette tested(these changes alter the ext/AGRIF reference; remember to update). See ticket #2341

Location:
NEMO/branches/2019/dev_r11943_MERGE_2019
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/dev_r11943_MERGE_2019

    • 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_r11615_ENHANCE-04_namelists_as_internalfiles_agrif@HEAD      ext/AGRIF 
        66^/vendors/FCM@HEAD            ext/FCM 
        77^/vendors/IOIPSL@HEAD         ext/IOIPSL 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/TOP/PISCES/SED/sedini.F90

    r11949 r11960  
    405405      !!---------------------------------------------------------------------- 
    406406 
    407       INTEGER ::   numnamsed_ref = -1           !! Logical units for namelist sediment 
    408       INTEGER ::   numnamsed_cfg = -1           !! Logical units for namelist sediment 
     407      CHARACTER(:), ALLOCATABLE ::   numnamsed_ref           !! Character buffer for reference namelist sediment 
     408      CHARACTER(:), ALLOCATABLE ::   numnamsed_cfg           !! Character buffer for configuration namelist sediment 
    409409      INTEGER :: ios                 ! Local integer output status for namelist read 
    410410      CHARACTER(LEN=20)   ::   clname 
     
    451451      IF(lwp) WRITE(numsed,*) ' sed_init_nam : read SEDIMENT namelist' 
    452452      IF(lwp) WRITE(numsed,*) ' ~~~~~~~~~~~~~~' 
    453       CALL ctl_opn( numnamsed_ref, TRIM( clname )//'_ref', 'OLD'    , 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) 
    454       CALL ctl_opn( numnamsed_cfg, TRIM( clname )//'_cfg', 'OLD'    , 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) 
     453      CALL load_nml( numnamsed_ref, TRIM( clname )//'_ref', numout, lwm ) 
     454      CALL load_nml( numnamsed_cfg, TRIM( clname )//'_cfg', numout, lwm ) 
    455455 
    456456      nitsed000 = nittrc000 
    457457      nitsedend = nitend 
    458458      ! Namelist nam_run 
    459       REWIND( numnamsed_ref )              ! Namelist nam_run in reference namelist : Pisces variables 
    460459      READ  ( numnamsed_ref, nam_run, IOSTAT = ios, ERR = 901) 
    461460901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_run in reference namelist' ) 
    462461 
    463       REWIND( numnamsed_cfg )              ! Namelist nam_run in reference namelist : Pisces variables 
    464462      READ  ( numnamsed_cfg, nam_run, IOSTAT = ios, ERR = 902) 
    465463902   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_run in configuration namelist' ) 
     
    473471      IF ( ln_p5z .AND. ln_sed_2way ) CALL ctl_stop( '2 ways coupling with sediment cannot be activated with PISCES-QUOTA' ) 
    474472 
    475       REWIND( numnamsed_ref )              ! Namelist nam_geom in reference namelist : Pisces variables 
    476473      READ  ( numnamsed_ref, nam_geom, IOSTAT = ios, ERR = 903) 
    477474903   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_geom in reference namelist' ) 
    478475 
    479       REWIND( numnamsed_cfg )              ! Namelist nam_geom in reference namelist : Pisces variables 
    480476      READ  ( numnamsed_cfg, nam_geom, IOSTAT = ios, ERR = 904) 
    481477904   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_geom in configuration namelist' ) 
     
    496492      dtsed = r2dttrc 
    497493 
    498       REWIND( numnamsed_ref )              ! Namelist nam_trased in reference namelist : Pisces variables 
    499494      READ  ( numnamsed_ref, nam_trased, IOSTAT = ios, ERR = 905) 
    500495905   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_trased in reference namelist' ) 
    501496 
    502       REWIND( numnamsed_cfg )              ! Namelist nam_trased in reference namelist : Pisces variables 
    503497      READ  ( numnamsed_cfg, nam_trased, IOSTAT = ios, ERR = 906) 
    504498906   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_trased in configuration namelist' ) 
     
    529523      ENDIF 
    530524 
    531       REWIND( numnamsed_ref )              ! Namelist nam_diased in reference namelist : Pisces variables 
    532525      READ  ( numnamsed_ref, nam_diased, IOSTAT = ios, ERR = 907) 
    533526907   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_diased in reference namelist' ) 
    534527 
    535       REWIND( numnamsed_cfg )              ! Namelist nam_diased in reference namelist : Pisces variables 
    536528      READ  ( numnamsed_cfg, nam_diased, IOSTAT = ios, ERR = 908) 
    537529908   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_diased in configuration namelist' ) 
     
    571563      ! Inorganic chemistry parameters 
    572564      !---------------------------------- 
    573       REWIND( numnamsed_ref )              ! Namelist nam_inorg in reference namelist : Pisces variables 
    574565      READ  ( numnamsed_ref, nam_inorg, IOSTAT = ios, ERR = 909) 
    575566909   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_inorg in reference namelist' ) 
    576567 
    577       REWIND( numnamsed_cfg )              ! Namelist nam_inorg in reference namelist : Pisces variables 
    578568      READ  ( numnamsed_cfg, nam_inorg, IOSTAT = ios, ERR = 910) 
    579569910   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_inorg in configuration namelist' ) 
     
    597587      ! Additional parameter linked to POC/O2/No3/Po4 
    598588      !---------------------------------------------- 
    599       REWIND( numnamsed_ref )              ! Namelist nam_poc in reference namelist : Pisces variables 
    600589      READ  ( numnamsed_ref, nam_poc, IOSTAT = ios, ERR = 911) 
    601590911   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_poc in reference namelist' ) 
    602591 
    603       REWIND( numnamsed_cfg )              ! Namelist nam_poc in reference namelist : Pisces variables 
    604592      READ  ( numnamsed_cfg, nam_poc, IOSTAT = ios, ERR = 912) 
    605593912   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_poc in configuration namelist' ) 
     
    649637      ! Bioturbation parameter 
    650638      !------------------------ 
    651       REWIND( numnamsed_ref )              ! Namelist nam_btb in reference namelist : Pisces variables 
    652639      READ  ( numnamsed_ref, nam_btb, IOSTAT = ios, ERR = 913) 
    653640913   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_btb in reference namelist' ) 
    654641 
    655       REWIND( numnamsed_cfg )              ! Namelist nam_btb in reference namelist : Pisces variables 
    656642      READ  ( numnamsed_cfg, nam_btb, IOSTAT = ios, ERR = 914) 
    657643914   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_btb in configuration namelist' ) 
     
    670656      ! Initial value (t=0) for sediment pore water and solid components 
    671657      !---------------------------------------------------------------- 
    672       REWIND( numnamsed_ref )              ! Namelist nam_rst in reference namelist : Pisces variables 
    673658      READ  ( numnamsed_ref, nam_rst, IOSTAT = ios, ERR = 915) 
    674659915   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_rst in reference namelist' ) 
    675660 
    676       REWIND( numnamsed_cfg )              ! Namelist nam_rst in reference namelist : Pisces variables 
    677661      READ  ( numnamsed_cfg, nam_rst, IOSTAT = ios, ERR = 916) 
    678662916   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_rst in configuration namelist' ) 
     
    685669      nn_dtsed = 1 
    686670 
    687       CLOSE( numnamsed_cfg ) 
    688       CLOSE( numnamsed_ref ) 
    689671 
    690672   END SUBROUTINE sed_init_nam 
Note: See TracChangeset for help on using the changeset viewer.