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 8866 for branches/2017/dev_r7881_ENHANCE09_RK3/NEMOGCM/NEMO/OPA_SRC – NEMO

Ignore:
Timestamp:
2017-12-01T07:22:09+01:00 (6 years ago)
Author:
gm
Message:

#1911 (ENHANCE-09): Agrif: remove Agrif_update_tke + style cleaning

Location:
branches/2017/dev_r7881_ENHANCE09_RK3/NEMOGCM/NEMO/OPA_SRC/ZDF
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/2017/dev_r7881_ENHANCE09_RK3/NEMOGCM/NEMO/OPA_SRC/ZDF/zdfphy.F90

    r8863 r8866  
    2828   USE sbcrnf         ! surface boundary condition: runoff variables 
    2929#if defined key_agrif 
    30    USE agrif_opa_interp 
     30   USE agrif_opa_interp   ! interpavm 
    3131#endif 
    3232   ! 
     
    279279 
    280280#if defined key_agrif  
    281       ! interpolation parent grid => child grid for avm_k ( ex : at west border: 
    282       ! update column 1 and 2) 
    283       CALL Agrif_tke 
     281      ! interpolation parent grid => child grid for avm_k ( ex : at west border: update column 1 and 2) 
     282      IF( l_zdfsh2 )   CALL Agrif_avm 
    284283#endif 
    285284 
    286285      !                                         !* Lateral boundary conditions (sign unchanged) 
    287       CALL lbc_lnk( avm_k, 'W', 1. )                  ! needed to compute the shear production term 
    288       CALL lbc_lnk( avt_k, 'W', 1. )                  !!gm a priori useless ==>> to be tested 
     286      IF( l_zdfsh2 ) THEN 
     287         CALL lbc_lnk( avm_k, 'W', 1. )               ! needed to compute the shear production term 
     288         CALL lbc_lnk( avt_k, 'W', 1. )               !!gm a priori useless ==>> to be tested 
     289      ENDIF 
    289290      CALL lbc_lnk( avm  , 'W', 1. )                  ! needed to compute avm at u- and v-points 
    290291      CALL lbc_lnk( avt  , 'W', 1. )                  !!gm  a priori only avm_k and avm are required 
    291       CALL lbc_lnk( avs  , 'W', 1. )                  !!gm  To be tested 
     292      CALL lbc_lnk( avs  , 'W', 1. )                  !!gm  for calculation, keeped here for output only 
    292293      ! 
    293294      IF( l_zdfdrg ) THEN     ! drag  have been updated (non-linear cases) 
     
    297298      ! 
    298299      CALL zdf_mxl( kt )                        !* mixed layer depth, and level 
    299  
     300      ! 
    300301      IF( lrst_oce ) THEN                       !* write TKE, GLS or RIC fields in the restart file 
    301302         IF( ln_zdftke )   CALL tke_rst( kt, 'WRITE' ) 
  • branches/2017/dev_r7881_ENHANCE09_RK3/NEMOGCM/NEMO/OPA_SRC/ZDF/zdftke.F90

    r8863 r8866  
    4646   USE zdfdrg         ! vertical physics: top/bottom drag coef. 
    4747   USE zdfmxl         ! vertical physics: mixed layer 
    48 #if defined key_agrif 
    49    USE agrif_opa_interp 
    50    USE agrif_opa_update 
    51 #endif 
    5248   ! 
    5349   USE in_out_manager ! I/O manager 
     
    107103      !!---------------------------------------------------------------------- 
    108104      ALLOCATE( htau(jpi,jpj) , dissl(jpi,jpj,jpk) , apdlr(jpi,jpj,jpk) ,   STAT= zdf_tke_alloc ) 
    109          ! 
     105      ! 
    110106      IF( lk_mpp             )   CALL mpp_sum ( zdf_tke_alloc ) 
    111107      IF( zdf_tke_alloc /= 0 )   CALL ctl_warn('zdf_tke_alloc: failed to allocate arrays') 
     
    171167 
    172168 
    173    SUBROUTINE tke_tke( pdepw, p_e3t, p_e3w, p_sh2    & 
    174       &                            , p_avm, p_avt ) 
     169   SUBROUTINE tke_tke( pdepw, p_e3t, p_e3w, p_sh2, p_avm, p_avt ) 
    175170      !!---------------------------------------------------------------------- 
    176171      !!                   ***  ROUTINE tke_tke  *** 
     
    217212      zfact3 = 0.5_wp       * rn_ediss 
    218213      ! 
    219       ! 
    220214      !                     !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 
    221215      !                     !  Surface/top/bottom boundary condition on tke 
     
    234228         END DO 
    235229      ENDIF 
    236        
     230      ! 
    237231      !                     !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 
    238232      !                     !  Bottom boundary condition on tke 
     
    395389         END DO 
    396390      END DO 
    397  
     391      ! 
    398392      !                            !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 
    399393      !                            !  TKE due to surface and internal wave breaking 
     
    483477      REAL(wp) ::   zdku,   zdkv, zsqen       !   -      - 
    484478      REAL(wp) ::   zemxl, zemlm, zemlp       !   -      - 
    485       REAL(wp), DIMENSION(jpi,jpj,jpk) ::   zmxlm, zmxld 
     479      REAL(wp), DIMENSION(jpi,jpj,jpk) ::   zmxlm, zmxld   ! 3D workspace 
    486480      !!-------------------------------------------------------------------- 
    487481      ! 
    488482      IF( ln_timing )   CALL timing_start('tke_avn') 
    489  
     483      ! 
    490484      !                     !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 
    491485      !                     !  Mixing length 
     
    597591      END SELECT 
    598592      ! 
    599  
    600593      !                     !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 
    601594      !                     !  Vertical eddy viscosity and diffusivity  (avm and avt) 
     
    623616         END DO 
    624617      ENDIF 
    625  
     618      ! 
    626619      IF(ln_ctl) THEN 
    627620         CALL prt_ctl( tab3d_1=en , clinfo1=' tke  - e: ', tab3d_2=avt, clinfo2=' t: ', ovlap=1, kdim=jpk) 
Note: See TracChangeset for help on using the changeset viewer.