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 6140 for trunk/NEMOGCM/NEMO/SAS_SRC – NEMO

Ignore:
Timestamp:
2015-12-21T12:35:23+01:00 (8 years ago)
Author:
timgraham
Message:

Merge of branches/2015/dev_merge_2015 back into trunk. Merge excludes NEMOGCM/TOOLS/OBSTOOLS/ for now due to issues with the change of file type. Will sort these manually with further commits.

Branch merged as follows:
In the working copy of branch ran:
svn merge svn+ssh://forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/trunk@HEAD
Small conflicts due to bug fixes applied to trunk since the dev_merge_2015 was copied. Bug fixes were applied to the branch as well so these were easy to resolve.
Branch committed at this stage

In working copy run:
svn switch svn+ssh://forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/trunk
to switch working copy

Run:
svn merge --reintegrate svn+ssh://forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/branches/2015/dev_merge_2015
to merge the branch into the trunk and then commit - no conflicts at this stage.

Location:
trunk/NEMOGCM/NEMO/SAS_SRC
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/NEMOGCM/NEMO/SAS_SRC/daymod.F90

    r5563 r6140  
    2020   !! 
    2121   !!   we suppose that the time step is deviding the number of second of in a day 
    22    !!             ---> MOD( rday, rdttra(1) ) == 0 
     22   !!             ---> MOD( rday, rdt ) == 0 
    2323   !! 
    2424   !!           ----------- WARNING ----------- 
     
    7676            &           'You must do a restart at higher frequency (or remove this stop and recompile the code in I8)' ) 
    7777      ENDIF 
    78       ! all calendar staff is based on the fact that MOD( rday, rdttra(1) ) == 0 
    79       IF( MOD( rday     , rdttra(1) ) /= 0. )   CALL ctl_stop( 'the time step must devide the number of second of in a day' ) 
    80       IF( MOD( rday     , 2.        ) /= 0. )   CALL ctl_stop( 'the number of second of in a day must be an even number'    ) 
    81       IF( MOD( rdttra(1), 2.        ) /= 0. )   CALL ctl_stop( 'the time step (in second) must be an even number'           ) 
    82       nsecd   = NINT(rday           ) 
    83       nsecd05 = NINT(0.5 * rday     ) 
    84       ndt     = NINT(      rdttra(1)) 
    85       ndt05   = NINT(0.5 * rdttra(1)) 
     78      ! all calendar staff is based on the fact that MOD( rday, rdt ) == 0 
     79      IF( MOD( rday , rdt ) /= 0. )   CALL ctl_stop( 'the time step must devide the number of second of in a day' ) 
     80      IF( MOD( rday , 2.  ) /= 0. )   CALL ctl_stop( 'the number of second of in a day must be an even number'    ) 
     81      IF( MOD( rdt  , 2.  ) /= 0. )   CALL ctl_stop( 'the time step (in second) must be an even number'           ) 
     82      nsecd   = NINT(rday         ) 
     83      nsecd05 = NINT(0.5 * rday   ) 
     84      ndt     = NINT(      rdt    ) 
     85      ndt05   = NINT(0.5 * rdt    ) 
    8686 
    8787      ! ==> clem: here we read the ocean restart for the date (only if it exists) 
     
    224224      nsec_week  = nsec_week  + ndt 
    225225      nsec_day   = nsec_day   + ndt                 
    226       adatrj  = adatrj  + rdttra(1) / rday 
    227       fjulday = fjulday + rdttra(1) / rday 
     226      adatrj  = adatrj  + rdt / rday 
     227      fjulday = fjulday + rdt / rday 
    228228      IF( ABS(fjulday - REAL(NINT(fjulday),wp)) < zprec )   fjulday = REAL(NINT(fjulday),wp)   ! avoid truncation error 
    229229      IF( ABS(adatrj  - REAL(NINT(adatrj ),wp)) < zprec )   adatrj  = REAL(NINT(adatrj ),wp)   ! avoid truncation error 
     
    340340               ! parameters correspondting to nit000 - 1 (as we start the step loop with a call to day) 
    341341               ndastp = ndate0 - 1     ! ndate0 read in the namelist in dom_nam, we assume that we start run at 00:00 
    342                adatrj = ( REAL( nit000-1, wp ) * rdttra(1) ) / rday 
     342               adatrj = ( REAL( nit000-1, wp ) * rdt ) / rday 
    343343               ! note this is wrong if time step has changed during run 
    344344            ENDIF 
     
    346346            ! parameters correspondting to nit000 - 1 (as we start the step loop with a call to day) 
    347347            ndastp = ndate0 - 1        ! ndate0 read in the namelist in dom_nam, we assume that we start run at 00:00 
    348             adatrj = ( REAL( nit000-1, wp ) * rdttra(1) ) / rday 
     348            adatrj = ( REAL( nit000-1, wp ) * rdt ) / rday 
    349349         ENDIF 
    350350         IF( ABS(adatrj  - REAL(NINT(adatrj),wp)) < 0.1 / rday )   adatrj = REAL(NINT(adatrj),wp)   ! avoid truncation error 
  • trunk/NEMOGCM/NEMO/SAS_SRC/diawri.F90

    r5930 r6140  
    3636   USE lbclnk          ! ocean lateral boundary conditions (or mpp link) 
    3737   USE in_out_manager  ! I/O manager 
    38    USE diadimg         ! dimg direct access file format output 
    3938   USE diaar5, ONLY :   lk_diaar5 
    4039   USE iom 
     
    6160 
    6261   !! * Substitutions 
    63 #  include "zdfddm_substitute.h90" 
    64 #  include "domzgr_substitute.h90" 
    6562#  include "vectopt_loop_substitute.h90" 
    6663   !!---------------------------------------------------------------------- 
     
    8178  END FUNCTION dia_wri_alloc 
    8279 
    83 #if defined key_dimgout 
    84    !!---------------------------------------------------------------------- 
    85    !!   'key_dimgout'                                      DIMG output file 
    86    !!---------------------------------------------------------------------- 
    87 #   include "diawri_dimg.h90" 
    88  
    89 #else 
    9080   !!---------------------------------------------------------------------- 
    9181   !!   Default option                                   NetCDF output file 
    9282   !!---------------------------------------------------------------------- 
    93 # if defined key_iomput 
     83#if defined key_iomput 
    9484   !!---------------------------------------------------------------------- 
    9585   !!   'key_iomput'                                        use IOM library 
     
    10696      !! ** Method  :  use iom_put 
    10797      !!---------------------------------------------------------------------- 
    108       !! 
    109       INTEGER, INTENT( in ) ::   kt      ! ocean time-step index 
     98      INTEGER, INTENT(in) ::   kt   ! ocean time-step index 
    11099      !!---------------------------------------------------------------------- 
    111100      !  
     
    140129      INTEGER  ::   ierr                                     ! error code return from allocation 
    141130      INTEGER  ::   iimi, iima, ipk, it, itmod, ijmi, ijma   ! local integers 
    142       REAL(wp) ::   zsto, zout, zmax, zjulian, zdt           ! local scalars 
     131      REAL(wp) ::   zsto, zout, zmax, zjulian                ! local scalars 
    143132      !!---------------------------------------------------------------------- 
    144133      !  
     
    159148 
    160149      ! Define frequency of output and means 
    161       zdt = rdt 
    162       IF( nacc == 1 ) zdt = rdtmin 
    163150      IF( ln_mskland )   THEN   ;   clop = "only(x)"   ! put 1.e+20 on land (very expensive!!) 
    164151      ELSE                      ;   clop = "x"         ! no use of the mask value (require less cpu time) 
    165152      ENDIF 
    166153#if defined key_diainstant 
    167       zsto = nwrite * zdt 
     154      zsto = nwrite * rdt 
    168155      clop = "inst("//TRIM(clop)//")" 
    169156#else 
    170       zsto=zdt 
     157      zsto=rdt 
    171158      clop = "ave("//TRIM(clop)//")" 
    172159#endif 
    173       zout = nwrite * zdt 
    174       zmax = ( nitend - nit000 + 1 ) * zdt 
     160      zout = nwrite * rdt 
     161      zmax = ( nitend - nit000 + 1 ) * rdt 
    175162 
    176163      ! Define indices of the horizontal output zoom and vertical limit storage 
     
    214201         CALL histbeg( clhstnam, jpi, glamt, jpj, gphit,           &  ! Horizontal grid: glamt and gphit 
    215202            &          iimi, iima-iimi+1, ijmi, ijma-ijmi+1,       & 
    216             &          nit000-1, zjulian, zdt, nh_T, nid_T, domain_id=nidom, snc4chunks=snc4set ) 
     203            &          nit000-1, zjulian, rdt, nh_T, nid_T, domain_id=nidom, snc4chunks=snc4set ) 
    217204         CALL histvert( nid_T, "deptht", "Vertical T levels",      &  ! Vertical grid: gdept 
    218205            &           "m", ipk, gdept_1d, nz_T, "down" ) 
     
    226213         CALL histbeg( clhstnam, jpi, glamu, jpj, gphiu,           &  ! Horizontal grid: glamu and gphiu 
    227214            &          iimi, iima-iimi+1, ijmi, ijma-ijmi+1,       & 
    228             &          nit000-1, zjulian, zdt, nh_U, nid_U, domain_id=nidom, snc4chunks=snc4set ) 
     215            &          nit000-1, zjulian, rdt, nh_U, nid_U, domain_id=nidom, snc4chunks=snc4set ) 
    229216         CALL histvert( nid_U, "depthu", "Vertical U levels",      &  ! Vertical grid: gdept 
    230217            &           "m", ipk, gdept_1d, nz_U, "down" ) 
     
    238225         CALL histbeg( clhstnam, jpi, glamv, jpj, gphiv,           &  ! Horizontal grid: glamv and gphiv 
    239226            &          iimi, iima-iimi+1, ijmi, ijma-ijmi+1,       & 
    240             &          nit000-1, zjulian, zdt, nh_V, nid_V, domain_id=nidom, snc4chunks=snc4set ) 
     227            &          nit000-1, zjulian, rdt, nh_V, nid_V, domain_id=nidom, snc4chunks=snc4set ) 
    241228         CALL histvert( nid_V, "depthv", "Vertical V levels",      &  ! Vertical grid : gdept 
    242229            &          "m", ipk, gdept_1d, nz_V, "down" ) 
     
    334321      ! 
    335322   END SUBROUTINE dia_wri 
    336 # endif 
    337  
    338323#endif 
    339324 
     
    358343      INTEGER  ::   id_i , nz_i, nh_i        
    359344      INTEGER, DIMENSION(1) ::   idex             ! local workspace 
    360       REAL(wp) ::   zsto, zout, zmax, zjulian, zdt 
     345      REAL(wp) ::   zsto, zout, zmax, zjulian 
    361346      !!---------------------------------------------------------------------- 
    362347      !  
     
    369354      clname = cdfile_name 
    370355      IF( .NOT. Agrif_Root() ) clname = TRIM(Agrif_CFixed())//'_'//TRIM(clname) 
    371       zdt  = rdt 
    372356      zsto = rdt 
    373357      clop = "inst(x)"           ! no use of the mask value (require less cpu time) 
    374358      zout = rdt 
    375       zmax = ( nitend - nit000 + 1 ) * zdt 
     359      zmax = ( nitend - nit000 + 1 ) * rdt 
    376360 
    377361      IF(lwp) WRITE(numout,*) 
     
    388372      zjulian = zjulian - adatrj   !   set calendar origin to the beginning of the experiment 
    389373      CALL histbeg( clname, jpi, glamt, jpj, gphit,   & 
    390           1, jpi, 1, jpj, nit000-1, zjulian, zdt, nh_i, id_i, domain_id=nidom, snc4chunks=snc4set ) ! Horizontal grid : glamt and gphit 
     374          1, jpi, 1, jpj, nit000-1, zjulian, rdt, nh_i, id_i, domain_id=nidom, snc4chunks=snc4set ) ! Horizontal grid : glamt and gphit 
    391375      CALL histvert( id_i, "deptht", "Vertical T levels",   &    ! Vertical grid : gdept 
    392376          "m", jpk, gdept_1d, nz_i, "down") 
     
    431415      ! ----------------- 
    432416      CALL histclo( id_i ) 
    433 #if ! defined key_iomput && ! defined key_dimgout 
     417#if ! defined key_iomput 
    434418      IF( ninist /= 1  ) THEN 
    435419         CALL histclo( nid_T ) 
  • trunk/NEMOGCM/NEMO/SAS_SRC/nemogcm.F90

    r5510 r6140  
    184184      NAMELIST/namctl/ ln_ctl  , nn_print, nn_ictls, nn_ictle,   & 
    185185         &             nn_isplt, nn_jsplt, nn_jctls, nn_jctle,   & 
    186          &             nn_bench, nn_timing 
     186         &             nn_bench, nn_timing, nn_diacfl 
    187187      NAMELIST/namcfg/ cp_cfg, cp_cfz, jp_cfg, jpidta, jpjdta, jpkdta, jpiglo, jpjglo, & 
    188188         &             jpizoom, jpjzoom, jperio, ln_use_jattr 
  • trunk/NEMOGCM/NEMO/SAS_SRC/sbcssm.F90

    r5407 r6140  
    8888         ssu_m(:,:) = sf_ssm_3d(jf_usp)%fnow(:,:,1) * umask(:,:,1)    ! u-velocity 
    8989         ssv_m(:,:) = sf_ssm_3d(jf_vsp)%fnow(:,:,1) * vmask(:,:,1)    ! v-velocity  
    90          IF( lk_vvl )   e3t_m(:,:) = sf_ssm_3d(jf_e3t)%fnow(:,:,1) * tmask(:,:,1)    ! v-velocity  
     90         IF( .NOT.ln_linssh )   e3t_m(:,:) = sf_ssm_3d(jf_e3t)%fnow(:,:,1) * tmask(:,:,1)    ! v-velocity  
    9191      ELSE 
    9292         ssu_m(:,:) = sf_ssm_2d(jf_usp)%fnow(:,:,1) * umask(:,:,1)    ! u-velocity 
    9393         ssv_m(:,:) = sf_ssm_2d(jf_vsp)%fnow(:,:,1) * vmask(:,:,1)    ! v-velocity  
    94          IF( lk_vvl )   e3t_m(:,:) = sf_ssm_2d(jf_e3t)%fnow(:,:,1) * tmask(:,:,1)    ! v-velocity  
     94         IF( .NOT.ln_linssh )   e3t_m(:,:) = sf_ssm_2d(jf_e3t)%fnow(:,:,1) * tmask(:,:,1)    ! v-velocity  
    9595      ENDIF 
    9696      ! 
     
    115115         CALL prt_ctl(tab2d_1=ssv_m, clinfo1=' ssv_m   - : ', mask1=vmask, ovlap=1   ) 
    116116         CALL prt_ctl(tab2d_1=ssh_m, clinfo1=' ssh_m   - : ', mask1=tmask, ovlap=1   ) 
    117          IF( lk_vvl      )   CALL prt_ctl(tab2d_1=ssh_m, clinfo1=' e3t_m   - : ', mask1=tmask, ovlap=1   ) 
    118          IF( ln_read_frq )   CALL prt_ctl(tab2d_1=frq_m, clinfo1=' frq_m   - : ', mask1=tmask, ovlap=1   ) 
     117         IF( .NOT.ln_linssh )   CALL prt_ctl(tab2d_1=ssh_m, clinfo1=' e3t_m   - : ', mask1=tmask, ovlap=1   ) 
     118         IF( ln_read_frq    )   CALL prt_ctl(tab2d_1=frq_m, clinfo1=' frq_m   - : ', mask1=tmask, ovlap=1   ) 
    119119      ENDIF 
    120120      ! 
     
    125125         CALL iom_put( 'sss_m', sss_m ) 
    126126         CALL iom_put( 'ssh_m', ssh_m ) 
    127          IF( lk_vvl      )   CALL iom_put( 'e3t_m', e3t_m ) 
    128          IF( ln_read_frq )   CALL iom_put( 'frq_m', frq_m ) 
     127         IF( .NOT.ln_linssh )   CALL iom_put( 'e3t_m', e3t_m ) 
     128         IF( ln_read_frq    )   CALL iom_put( 'frq_m', frq_m ) 
    129129      ENDIF 
    130130      ! 
     
    216216      IF( ln_3d_uve ) THEN 
    217217         jf_usp = 1 ; jf_vsp = 2 ; jf_e3t = 3      ! define 3D fields index 
    218          nfld_3d  = 2 + COUNT( (/lk_vvl/) )        ! number of 3D fields to read 
     218         nfld_3d  = 2 + COUNT( (/.NOT.ln_linssh/) )        ! number of 3D fields to read 
    219219         nfld_2d  = 3 + COUNT( (/ln_read_frq/) )   ! number of 2D fields to read 
    220220      ELSE 
    221          jf_usp = 4 ; jf_vsp = 5 ; jf_e3t = 6 ; jf_frq = 6 + COUNT( (/lk_vvl/) )   ! update 2D fields index 
     221         jf_usp = 4 ; jf_vsp = 5 ; jf_e3t = 6 ; jf_frq = 6 + COUNT( (/.NOT.ln_linssh/) )   ! update 2D fields index 
    222222         nfld_3d  = 0                                                              ! no 3D fields to read 
    223          nfld_2d  = 5 + COUNT( (/lk_vvl/) ) + COUNT( (/ln_read_frq/) )             ! number of 2D fields to read 
     223         nfld_2d  = 5 + COUNT( (/.NOT.ln_linssh/) ) + COUNT( (/ln_read_frq/) )             ! number of 2D fields to read 
    224224      ENDIF 
    225225 
     
    231231         slf_3d(jf_usp) = sn_usp 
    232232         slf_3d(jf_vsp) = sn_vsp 
    233          IF( lk_vvl )   slf_3d(jf_e3t) = sn_e3t 
     233         IF( .NOT.ln_linssh )   slf_3d(jf_e3t) = sn_e3t 
    234234      ENDIF 
    235235 
     
    243243         IF( .NOT. ln_3d_uve ) THEN 
    244244            slf_2d(jf_usp) = sn_usp ; slf_2d(jf_vsp) = sn_vsp 
    245             IF( lk_vvl )   slf_2d(jf_e3t) = sn_e3t 
     245            IF( .NOT.ln_linssh )   slf_2d(jf_e3t) = sn_e3t 
    246246         ENDIF 
    247247      ENDIF 
  • trunk/NEMOGCM/NEMO/SAS_SRC/step.F90

    r5510 r6140  
    1616   USE oce              ! ocean dynamics and tracers variables 
    1717   USE dom_oce          ! ocean space and time domain variables  
    18    USE in_out_manager   ! I/O manager 
    19    USE sbc_oce 
    20    USE sbccpl 
    21    USE iom              ! 
    22    USE lbclnk 
    23 #if defined key_iomput 
    24    USE xios 
    25 #endif 
    26  
    2718   USE daymod           ! calendar                         (day     routine) 
    28  
     19   USE sbc_oce          ! surface boundary condition: fields 
    2920   USE sbcmod           ! surface boundary condition       (sbc     routine) 
    3021   USE sbcrnf           ! surface boundary condition: runoff variables 
    31  
     22   USE sbccpl           ! surface boundary condition: coupled interface 
    3223   USE eosbn2           ! equation of state                (eos_bn2 routine) 
    33  
    3424   USE diawri           ! Standard run outputs             (dia_wri routine) 
    35    USE stpctl           ! time stepping control            (stp_ctl routine) 
    36    USE prtctl           ! Print control                    (prt_ctl routine) 
    37  
    38    USE timing           ! Timing             
    39  
    4025   USE bdy_par          ! clem: mandatory for LIM3 
    4126#if defined key_bdy 
    4227   USE bdydta           ! clem: mandatory for LIM3 
     28#endif 
     29   USE stpctl           ! time stepping control            (stp_ctl routine) 
     30   ! 
     31   USE in_out_manager   ! I/O manager 
     32   USE prtctl           ! Print control                    (prt_ctl routine) 
     33   USE iom              ! 
     34   USE lbclnk           ! 
     35   USE timing           ! Timing             
     36#if defined key_iomput 
     37   USE xios 
    4338#endif 
    4439 
     
    4641   PRIVATE 
    4742 
    48    PUBLIC   stp   ! called by opa.F90 
     43   PUBLIC   stp   ! called by nemogcm.F90 
    4944 
    50    !! * Substitutions 
    51 #  include "domzgr_substitute.h90" 
    52 #  include "zdfddm_substitute.h90" 
    5345   !!---------------------------------------------------------------------- 
    5446   !! NEMO/OPA 3.3 , NEMO Consortium (2010) 
Note: See TracChangeset for help on using the changeset viewer.