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 9089 for branches – NEMO

Changeset 9089 for branches


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

dev_merge_2017: bug correction in zdfdrg + ISOMIP cfg

Location:
branches/2017/dev_merge_2017/NEMOGCM
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • branches/2017/dev_merge_2017/NEMOGCM/CONFIG/TEST_CASES/ISOMIP/EXP00/namelist_cfg

    r9019 r9089  
    22!! NEMO/OPA  : ISOMIP Configuration namelist to overwrite reference dynamical namelist 
    33!!>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     4!----------------------------------------------------------------------- 
     5&namusr_def    !   ISOMIP user defined namelist   
     6!----------------------------------------------------------------------- 
     7   ln_zps      = .true.    ! z-partial-step coordinate 
     8   rn_e1deg    =   0.3     !  zonal      grid-spacing (degrees) 
     9   rn_e2deg    =   0.1     !  meridional grid-spacing (degrees) 
     10   rn_e3       =   30.     !  vertical resolution 
     11/ 
    412!----------------------------------------------------------------------- 
    513&namrun        !   parameters of the run 
     
    1018   nn_leapy    =       0   !  Leap year calendar (1) or not (0) 
    1119   ln_clobber  = .true.    !  clobber (overwrite) an existing file 
     20   nn_istate   =       0   !  output the initial state (1) or not (0) 
    1221   nn_stock    =  99999999 !  frequency of creation of a restart file (modulo referenced to 1) 
    1322   nn_write    =      48   !  frequency of write in the output file   (modulo referenced to nn_it000) 
     
    1928   ln_read_cfg = .false.   !  (=T) read the domain configuration file 
    2029      !                    !  (=F) user defined configuration  ==>>>  see usrdef(_...) modules 
     30      cn_domcfg = "ISOMIP_zps_domcfg"         ! domain configuration filename 
     31      ! 
     32   ln_write_cfg= .false.   !  (=T) create the domain configuration file 
     33      cn_domcfg_out = "ISOMIP_cfg_out"    ! filename of the created file 
    2134/ 
    2235!----------------------------------------------------------------------- 
     
    4457&namsbc        !   Surface Boundary Condition (surface module) 
    4558!----------------------------------------------------------------------- 
    46    nn_fsbc     = 6         !  frequency of surface boundary condition computation 
     59   nn_fsbc     = 1         !  frequency of surface boundary condition computation 
    4760   !                       !     (also = the frequency of sea-ice model call) 
    4861   ln_blk      = .false.    !  Bulk formulation                          (T => fill namsbc_blk ) 
     
    168181&namdrg            !   top/bottom drag coefficient                      (default: NO selection) 
    169182!----------------------------------------------------------------------- 
    170    ln_non_lin = .true.    !  non-linear  drag: Cd = Cd0 |U| 
     183   ln_NONE    = .false.    !  free-slip       : Cd = 0                  (F => fill namdrg_bot 
     184   ln_lin     = .false.    !      linear  drag: Cd = Cd0 Uc0                   &   namdrg_top) 
     185   ln_non_lin = .true.     !  non-linear  drag: Cd = Cd0 |U| 
     186   ln_loglayer= .false.    !  logarithmic drag: Cd = vkarmn/log(z/z0) |U| 
     187   ! 
     188   ln_drgimp  = .false.    !  implicit top/bottom friction flag 
    171189/ 
    172190!----------------------------------------------------------------------- 
  • branches/2017/dev_merge_2017/NEMOGCM/CONFIG/TEST_CASES/ISOMIP/MY_SRC/usrdef_hgr.F90

    r9019 r9089  
    1717   USE par_oce         ! ocean space and time domain 
    1818   USE phycst          ! physical constants 
    19    USE usrdef_nam, ONLY: rn_lam0, rn_phi0, rn_e1deg, rn_e2deg   ! horizontal resolution in meters 
     19   USE usrdef_nam, ONLY: rn_e1deg, rn_e2deg   ! horizontal resolution in meters 
    2020   ! 
    2121   USE in_out_manager  ! I/O manager 
    2222   USE lib_mpp         ! MPP library 
    23    USE timing          ! Timing 
    2423    
    2524   IMPLICIT NONE 
     
    2928 
    3029   !!---------------------------------------------------------------------- 
    31    !! NEMO/OPA 4.0 , NEMO Consortium (2016) 
     30   !! NEMO/OPA 4.0 , NEMO Consortium (2017) 
    3231   !! $Id$  
    3332   !! Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt) 
     
    6665      !!------------------------------------------------------------------------------- 
    6766      ! 
    68       IF( nn_timing == 1 )  CALL timing_start('usr_def_hgr') 
    69       ! 
    7067      IF(lwp) THEN 
    7168         WRITE(numout,*) 
     
    7976      !                       !==  grid point position  ==!   (in degrees) 
    8077      DO jj = 1, jpj 
     78         DO ji = 1, jpi             ! longitude   (west coast at lon=0°) 
     79            plamt(ji,jj) = rn_e1deg * (  - 0.5 + REAL( ji-1 + nimpp-1 , wp )  )   
     80            plamu(ji,jj) = rn_e1deg * (          REAL( ji-1 + nimpp-1 , wp )  ) 
     81            plamv(ji,jj) = plamt(ji,jj) 
     82            plamf(ji,jj) = plamu(ji,jj) 
     83            !                       ! latitude   (south coast at lat= 81°) 
     84            pphit(ji,jj) = rn_e2deg * (  - 0.5 + REAL( jj-1 + njmpp-1 , wp )  ) - 80._wp 
     85            pphiu(ji,jj) = pphit(ji,jj) 
     86            pphiv(ji,jj) = rn_e2deg * (          REAL( jj-1 + njmpp-1 , wp )  ) - 80_wp 
     87            pphif(ji,jj) = pphiv(ji,jj) 
     88         END DO 
     89      END DO 
     90      ! 
     91      !                       !==  Horizontal scale factors  ==!   (in meters) 
     92      DO jj = 1, jpj 
    8193         DO ji = 1, jpi 
    82             zti = FLOAT( ji - 1 + nimpp - 1 )         ;   ztj = FLOAT( jj - 1 + njmpp - 1 ) 
    83             zui = FLOAT( ji - 1 + nimpp - 1 ) + 0.5   ;   zuj = FLOAT( jj - 1 + njmpp - 1 ) 
    84             zvi = FLOAT( ji - 1 + nimpp - 1 )         ;   zvj = FLOAT( jj - 1 + njmpp - 1 ) + 0.5 
    85             zfi = FLOAT( ji - 1 + nimpp - 1 ) + 0.5   ;   zfj = FLOAT( jj - 1 + njmpp - 1 ) + 0.5 
    86      ! Longitude 
    87             plamt(ji,jj) = rn_lam0 + rn_e1deg * zti 
    88             plamu(ji,jj) = rn_lam0 + rn_e1deg * zui 
    89             plamv(ji,jj) = rn_lam0 + rn_e1deg * zvi 
    90             plamf(ji,jj) = rn_lam0 + rn_e1deg * zfi 
    91      ! Latitude 
    92             pphit(ji,jj) = rn_phi0 + rn_e2deg * ztj 
    93             pphiu(ji,jj) = rn_phi0 + rn_e2deg * zuj 
    94             pphiv(ji,jj) = rn_phi0 + rn_e2deg * zvj 
    95             pphif(ji,jj) = rn_phi0 + rn_e2deg * zfj 
    96              
    97      !                       !==  Horizontal scale factors  ==!   (in meters) 
    98      ! e1 
     94            !                       ! e1   (zonal) 
    9995            pe1t(ji,jj) = ra * rad * COS( rad * pphit(ji,jj) ) * rn_e1deg 
    10096            pe1u(ji,jj) = ra * rad * COS( rad * pphiu(ji,jj) ) * rn_e1deg 
    10197            pe1v(ji,jj) = ra * rad * COS( rad * pphiv(ji,jj) ) * rn_e1deg 
    10298            pe1f(ji,jj) = ra * rad * COS( rad * pphif(ji,jj) ) * rn_e1deg 
    103      ! e2 
     99            !                       ! e2   (meridional) 
    104100            pe2t(ji,jj) = ra * rad * rn_e2deg 
    105101            pe2u(ji,jj) = ra * rad * rn_e2deg 
     
    109105      END DO 
    110106      !                             ! NO reduction of grid size in some straits  
    111       ke1e2u_v = 0                  !    ==>> u_ & v_surfaces will be computed in dom_ghr routine 
     107      ke1e2u_v    = 0               !    ==>> u_ & v_surfaces will be computed in dom_ghr routine 
    112108      pe1e2u(:,:) = 0._wp           !    CAUTION: set to zero to avoid error with some compilers that 
    113109      pe1e2v(:,:) = 0._wp           !             require an initialization of INTENT(out) arguments 
     
    116112      !                       !==  Coriolis parameter  ==! 
    117113      kff = 0                       ! Coriolis parameter calculated on the sphere 
    118       ! 
    119       ! 
    120114      pff_f(:,:) = 0._wp            ! CAUTION: set to zero to avoid error with some compilers that 
    121115      pff_t(:,:) = 0._wp            !             require an initialization of INTENT(out) arguments 
    122       ! 
    123       IF( nn_timing == 1 )  CALL timing_stop('usr_def_hgr') 
    124116      ! 
    125117   END SUBROUTINE usr_def_hgr 
  • branches/2017/dev_merge_2017/NEMOGCM/CONFIG/TEST_CASES/ISOMIP/MY_SRC/usrdef_nam.F90

    r7715 r9089  
    2929   PUBLIC   usr_def_nam   ! called by nemogcm.F90 
    3030 
    31    !                              !!* namusr_def namelist *!! 
    32    REAL(wp), PUBLIC ::   rn_lam0, rn_phi0      
    33    REAL(wp), PUBLIC ::   rn_e1deg, rn_e2deg, rn_e3 
    34    REAL(wp), PUBLIC ::   rbathy 
     31   !                                         !!* namusr_def namelist *!! 
     32   REAL(wp), PUBLIC ::   rn_e1deg, rn_e2deg   !: horizontal resolution   [degrees] 
     33   REAL(wp), PUBLIC ::   rn_e3                !: vertical   resolution         [m] 
     34    
     35   REAL(wp), PARAMETER, PUBLIC ::   rbathy = 900._wp   !: depth of the seafloor   [m] 
    3536 
    3637   !!---------------------------------------------------------------------- 
    37    !! NEMO/OPA 4.0 , NEMO Consortium (2016) 
     38   !! NEMO/OPA 4.0 , NEMO Consortium (2017) 
    3839   !! $Id$  
    3940   !! Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt) 
     
    6162      INTEGER ::   ios, ii   ! Local integer 
    6263      !! 
    63       NAMELIST/namusr_def/ ln_zco, ln_zps, ln_sco, rn_lam0, rn_phi0, rn_e1deg, rn_e2deg, rn_e3 
     64      NAMELIST/namusr_def/ ln_zco, ln_zps, ln_sco, rn_e1deg, rn_e2deg, rn_e3 
    6465      !!---------------------------------------------------------------------- 
    6566      ! 
     
    7475      cd_cfg = 'ISOMIP'           ! name & resolution (not used) 
    7576      kk_cfg = INT( rn_e3 ) 
    76       rbathy = 900.0   ! sea bed depth 
    7777      ! 
    78       ! Global Domain size:  ISOMIP domain is  200 km x 3 grid-points x 2000 m 
    79       kpi = INT( 15.0  / rn_e1deg ) + 1 
    80       kpj = INT( 10.0  / rn_e2deg ) + 1 
    81       kpk = INT( rbathy / rn_e3 ) + 1 
     78      ! Global Domain size:  ISOMIP domain is  15° x 10° x 900 m 
     79      kpi = INT(  15.0  / rn_e1deg ) + 2     ! add 2 for t-point in the east  & west  coasts 
     80      kpj = INT(  10.0  / rn_e2deg ) + 2     !     -        -           north & south   - 
     81      kpk = INT( rbathy / rn_e3    ) + 1     ! add 1 for t-point in the seafloor 
    8282      ! 
    8383      !                             ! control print 
    84       WRITE(ldtxt(ii),*) '   '                                                                          ;   ii = ii + 1 
    85       WRITE(ldtxt(ii),*) 'usr_def_nam  : read the user defined namelist (namusr_def) in namelist_cfg'   ;   ii = ii + 1 
    86       WRITE(ldtxt(ii),*) '~~~~~~~~~~~ '                                                                 ;   ii = ii + 1 
    87       WRITE(ldtxt(ii),*) '   Namelist namusr_def : ISOMIP test case'                                  ;   ii = ii + 1 
    88       WRITE(ldtxt(ii),*) '      type of vertical coordinate : '                                         ;   ii = ii + 1 
    89       WRITE(ldtxt(ii),*) '         z-coordinate flag                     ln_zco = ', ln_zco             ;   ii = ii + 1 
    90       WRITE(ldtxt(ii),*) '         z-partial-step coordinate flag        ln_zps = ', ln_zps             ;   ii = ii + 1 
    91       WRITE(ldtxt(ii),*) '         s-coordinate flag                     ln_sco = ', ln_sco             ;   ii = ii + 1 
    92       WRITE(ldtxt(ii),*) '         resulting global domain size :        jpiglo = ', kpi                ;   ii = ii + 1 
    93       WRITE(ldtxt(ii),*) '                                               jpjglo = ', kpj                ;   ii = ii + 1 
    94       WRITE(ldtxt(ii),*) '                                               jpkglo = ', kpk                ;   ii = ii + 1 
     84      WRITE(ldtxt(ii),*) '   '                                                                              ;   ii = ii + 1 
     85      WRITE(ldtxt(ii),*) 'usr_def_nam  : read the user defined namelist (namusr_def) in namelist_cfg'       ;   ii = ii + 1 
     86      WRITE(ldtxt(ii),*) '~~~~~~~~~~~ '                                                                     ;   ii = ii + 1 
     87      WRITE(ldtxt(ii),*) '   Namelist namusr_def : ISOMIP test case'                                        ;   ii = ii + 1 
     88      WRITE(ldtxt(ii),*) '      type of vertical coordinate : '                                             ;   ii = ii + 1 
     89      WRITE(ldtxt(ii),*) '         z-coordinate flag                     ln_zco   = ', ln_zco               ;   ii = ii + 1 
     90      WRITE(ldtxt(ii),*) '         z-partial-step coordinate flag        ln_zps   = ', ln_zps               ;   ii = ii + 1 
     91      WRITE(ldtxt(ii),*) '         s-coordinate flag                     ln_sco   = ', ln_sco               ;   ii = ii + 1 
     92      WRITE(ldtxt(ii),*) '      resolution'                                                                 ;   ii = ii + 1 
     93      WRITE(ldtxt(ii),*) '         zonal      resolution                 rn_e1deg = ', rn_e1deg, ' degrees' ;   ii = ii + 1 
     94      WRITE(ldtxt(ii),*) '         meridional resolution                 rn_e1deg = ', rn_e1deg, ' degrees' ;   ii = ii + 1 
     95      WRITE(ldtxt(ii),*) '         vertical   resolution                 rn_e3    = ', rn_e3   , ' meters'  ;   ii = ii + 1 
     96      WRITE(ldtxt(ii),*) '      ISOMIP domain = 15° x 10° x 900 m'                                          ;   ii = ii + 1 
     97      WRITE(ldtxt(ii),*) '         resulting global domain size :        jpiglo   = ', kpi                  ;   ii = ii + 1 
     98      WRITE(ldtxt(ii),*) '                                               jpjglo   = ', kpj                  ;   ii = ii + 1 
     99      WRITE(ldtxt(ii),*) '                                               jpkglo   = ', kpk                  ;   ii = ii + 1 
     100      ! 
    95101      ! 
    96102      !                             ! Set the lateral boundary condition of the global domain 
     
    99105      WRITE(ldtxt(ii),*) '   '                                                                          ;   ii = ii + 1 
    100106      WRITE(ldtxt(ii),*) '   Lateral boundary condition of the global domain'                           ;   ii = ii + 1 
    101       WRITE(ldtxt(ii),*) '      ISOMIP : closed basin                    jperio = ', kperio             ;   ii = ii + 1 
     107      WRITE(ldtxt(ii),*) '      ISOMIP : closed basin                    jperio   = ', kperio             ;   ii = ii + 1 
    102108      ! 
    103109   END SUBROUTINE usr_def_nam 
  • branches/2017/dev_merge_2017/NEMOGCM/CONFIG/TEST_CASES/ISOMIP/MY_SRC/usrdef_zgr.F90

    r8018 r9089  
    171171         END DO          
    172172         !                                   ! bottom scale factors and depth at  U-, V-, UW and VW-points 
    173          DO jk = 1,jpkm1                     ! Computed as the minimum of neighbooring scale factors 
     173         pe3u (:,:,:) = pe3t(:,:,:) 
     174         pe3uw(:,:,:) = pe3w(:,:,:) 
     175         DO jk = 1, jpk                      ! Computed as the minimum of neighbooring scale factors 
    174176            DO jj = 1, jpjm1 
    175                DO ji = 1, fs_jpim1   ! vector opt. 
    176                   pe3u (ji,jj,jk) = MIN( pe3t(ji,jj,jk), pe3t(ji+1,jj,jk) ) 
     177               DO ji = 1, jpi 
    177178                  pe3v (ji,jj,jk) = MIN( pe3t(ji,jj,jk), pe3t(ji,jj+1,jk) ) 
    178                   pe3uw(ji,jj,jk) = MIN( pe3w(ji,jj,jk), pe3w(ji+1,jj,jk) ) 
    179179                  pe3vw(ji,jj,jk) = MIN( pe3w(ji,jj,jk), pe3w(ji,jj+1,jk) ) 
     180                  pe3f (ji,jj,jk) = pe3v(ji,jj,jk) 
    180181               END DO 
    181182            END DO 
    182             DO jj = 1, jpjm1 
    183                DO ji = 1, fs_jpim1   ! vector opt. 
    184                  pe3f(ji,jj,jk) = MIN( pe3v(ji,jj,jk), pe3v(ji+1,jj,jk) ) 
    185                END DO 
    186             END DO 
    187          END DO 
    188          CALL lbc_lnk( pe3u , 'U', 1._wp )   ;   CALL lbc_lnk( pe3uw, 'U', 1._wp )   ! lateral boundary conditions 
     183         END DO 
    189184         CALL lbc_lnk( pe3v , 'V', 1._wp )   ;   CALL lbc_lnk( pe3vw, 'V', 1._wp ) 
    190185         CALL lbc_lnk( pe3f , 'F', 1._wp ) 
    191          DO jk = 1,jpkm1 
     186         DO jk = 1, jpk 
    192187            ! set to z-scale factor if zero (i.e. along closed boundaries) because of lbclnk 
    193188            WHERE( pe3u (:,:,jk) == 0._wp )   pe3u (:,:,jk) = pe3t_1d(jk) 
    194189            WHERE( pe3v (:,:,jk) == 0._wp )   pe3v (:,:,jk) = pe3t_1d(jk) 
     190            WHERE( pe3f (:,:,jk) == 0._wp )   pe3f (:,:,jk) = pe3t_1d(jk) 
    195191            WHERE( pe3uw(:,:,jk) == 0._wp )   pe3uw(:,:,jk) = pe3w_1d(jk) 
    196192            WHERE( pe3vw(:,:,jk) == 0._wp )   pe3vw(:,:,jk) = pe3w_1d(jk) 
  • branches/2017/dev_merge_2017/NEMOGCM/NEMO/OPA_SRC/ZDF/zdfdrg.F90

    r9019 r9089  
    2929   USE lib_mpp        ! distributed memory computing 
    3030   USE prtctl         ! Print control 
    31    USE timing         ! Timing 
    3231 
    3332   IMPLICIT NONE 
     
    7877CONTAINS 
    7978 
    80    SUBROUTINE zdf_drg( kt, k_mk, pCdmin, pCdmax, pz0, pke0, pCd0, pCdU ) 
     79   SUBROUTINE zdf_drg( kt, k_mk, pCdmin, pCdmax, pz0, pke0, pCd0,   &   ! <<== in  
     80      &                                                     pCdU )      ! ==>> out : bottom drag [m/s] 
    8181      !!---------------------------------------------------------------------- 
    8282      !!                   ***  ROUTINE zdf_drg  *** 
     
    108108      REAL(wp)::   zzz, zut, zvt, zcd   ! local scalars 
    109109      !!---------------------------------------------------------------------- 
    110       ! 
    111       IF( ln_timing )   CALL timing_start('zdf_drg') 
    112       ! 
    113110      ! 
    114111      IF( l_log_not_linssh ) THEN     !==  "log layer"  ==!   compute Cd and -Cd*|U| 
     
    123120               zcd = (  vkarmn / LOG( zzz / pz0 )  )**2 
    124121               zcd = pCd0(ji,jj) * MIN(  MAX( pCdmin , zcd ) , pCdmax  )   ! here pCd0 = mask*boost 
    125                pCdU(ji,jj) = - zcd * SQRT(  0.25 * ( zut*zvt + zvt*zvt ) + pke0  ) 
     122               pCdU(ji,jj) = - zcd * SQRT(  0.25 * ( zut*zut + zvt*zvt ) + pke0  ) 
    126123            END DO 
    127124         END DO 
     
    133130               zvt = vn(ji,jj,imk) + vn(ji,jj-1,imk) 
    134131               !                                                           ! here pCd0 = mask*boost * drag 
    135                pCdU(ji,jj) = - pCd0(ji,jj) * SQRT(  0.25 * ( zut*zvt + zvt*zvt ) + pke0  ) 
     132               pCdU(ji,jj) = - pCd0(ji,jj) * SQRT(  0.25 * ( zut*zut + zvt*zvt ) + pke0  ) 
    136133            END DO 
    137134         END DO 
     
    139136      ! 
    140137      IF(ln_ctl)   CALL prt_ctl( tab2d_1=pCdU, clinfo1=' Cd*U ') 
    141       ! 
    142       IF( ln_timing )   CALL timing_stop('zdf_drg') 
    143138      ! 
    144139   END SUBROUTINE zdf_drg 
     
    200195      !                     !==  TOP drag setting  ==!   (applied at the top of ocean cavities) 
    201196      ! 
    202       IF ( ln_isfcav ) THEN             ! Ocean cavities: top friction setting 
     197      IF( ln_isfcav ) THEN              ! Ocean cavities: top friction setting 
    203198         ALLOCATE( rCd0_top(jpi,jpj), rCdU_top(jpi,jpj) ) 
    204199         CALL drg_init( 'TOP   '   , mikt       ,                                         &   ! <== in 
    205             &           r_Cdmin_top, r_Cdmax_top, r_z0_top, r_ke0_top, rCd0_bot, rCdU_bot )   ! ==> out 
     200            &           r_Cdmin_top, r_Cdmax_top, r_z0_top, r_ke0_top, rCd0_top, rCdU_top )   ! ==> out 
    206201      ENDIF 
    207202      ! 
     
    223218      REAL(wp)                , INTENT(  out) ::   pke0            ! background KE          [m2/s2] 
    224219      REAL(wp), DIMENSION(:,:), INTENT(  out) ::   pCd0            ! masked precomputed part of the non-linear drag coefficient 
    225       REAL(wp), DIMENSION(:,:), INTENT(  out) ::   pCdU            ! linear drag*|U| at t-points  [m/s] 
     220      REAL(wp), DIMENSION(:,:), INTENT(  out) ::   pCdU            ! minus linear drag*|U| at t-points  [m/s] 
    226221      !! 
    227222      CHARACTER(len=40) ::   cl_namdrg, cl_file, cl_varname, cl_namref, cl_namcfg  ! local names  
     
    318313         l_zdfdrg = .FALSE.         ! no time variation of the drag: set it one for all 
    319314         ! 
    320          pCdU(:,:) = 0._wp          ! pCd0 never used 
     315         pCdU(:,:) = 0._wp 
     316         pCd0(:,:) = 0._wp 
    321317         ! 
    322318      CASE( np_lin )             !==  linear friction  ==!   (pCdU = Cd0 * Uc0) 
     
    326322         l_zdfdrg = .FALSE.         ! no time variation of the Cd*|U| : set it one for all 
    327323         !                       
    328          pCdU(:,:) = - rn_Cd0 * rn_Uc0 * zmsk_boost(:,:)   ! pCd0 never used: remain undefined 
     324         pCd0(:,:) = rn_Cd0 * zmsk_boost(:,:)  !* constant in time drag coefficient (= mask (and boost) Cd0) 
     325         pCdU(:,:) = - pCd0(:,:) * rn_Uc0      !  using a constant velocity 
    329326         ! 
    330327      CASE( np_non_lin )         !== non-linear friction  ==!   (pCd0 = Cd0 ) 
     
    337334         ! 
    338335         pCd0(:,:) = rn_Cd0 * zmsk_boost(:,:)  !* constant in time proportionality coefficient (= mask (and boost) Cd0) 
     336         pCdU(:,:) = 0._wp                     !   
    339337         ! 
    340338      CASE( np_loglayer )       !== logarithmic layer formulation of friction  ==!   (CdU = (vkarman log(z/z0))^2 |U| ) 
     
    349347         ! 
    350348         IF( ln_linssh ) THEN       !* pCd0 = (v log(z/z0))^2   as velocity points have a fixed z position 
    351          IF(lwp) WRITE(numout,*) 
    352          IF(lwp) WRITE(numout,*) '   N.B.   linear free surface case, Cd0 computed one for all' 
     349            IF(lwp) WRITE(numout,*) 
     350            IF(lwp) WRITE(numout,*) '   N.B.   linear free surface case, Cd0 computed one for all' 
    353351            ! 
    354352            l_log_not_linssh = .FALSE.    !- don't update Cd at each time step 
     
    369367            pCd0(:,:) = zmsk_boost(:,:) 
    370368         ENDIF 
     369         pCdU(:,:) = 0._wp          ! initialisation to zero (will be updated at each time step) 
    371370         ! 
    372371      CASE DEFAULT 
  • branches/2017/dev_merge_2017/NEMOGCM/NEMO/OPA_SRC/ZDF/zdfgls.F90

    r9023 r9089  
    3131   USE in_out_manager ! I/O manager 
    3232   USE iom            ! I/O manager library 
    33    USE timing         ! Timing 
    34    USE lib_fortran    ! Fortran utilities (allows no signed zero when 'key_nosignedzero' defined)  
     33   USE lib_fortran    ! Fortran utilities (allows no signed zero when 'key_nosignedzero' defined) 
    3534 
    3635   IMPLICIT NONE 
     
    160159      !!-------------------------------------------------------------------- 
    161160      ! 
    162       IF( ln_timing )   CALL timing_start('zdf_gls') 
    163       ! 
    164161      ! Preliminary computing 
    165162 
     
    822819         CALL prt_ctl( tab3d_1=p_avm, clinfo1=' gls  - m: ', ovlap=1, kdim=jpk ) 
    823820      ENDIF 
    824       ! 
    825       IF( ln_timing )   CALL timing_stop('zdf_gls') 
    826821      ! 
    827822   END SUBROUTINE zdf_gls 
     
    852847         &            nn_stab_func, nn_clos 
    853848      !!---------------------------------------------------------- 
    854       ! 
    855       IF( ln_timing )   CALL timing_start('zdf_gls_init') 
    856849      ! 
    857850      REWIND( numnam_ref )              ! Namelist namzdf_gls in reference namelist : Vertical eddy diffivity and viscosity using gls turbulent closure scheme 
     
    11291122      !                                !* read or initialize all required files   
    11301123      CALL gls_rst( nit000, 'READ' )      ! (en, avt_k, avm_k, hmxl_n) 
    1131       ! 
    1132       IF( ln_timing )   CALL timing_stop('zdf_gls_init') 
    11331124      ! 
    11341125   END SUBROUTINE zdf_gls_init 
  • branches/2017/dev_merge_2017/NEMOGCM/NEMO/OPA_SRC/ZDF/zdfosm.F90

    r9019 r9089  
    5959   USE lbclnk         ! ocean lateral boundary conditions (or mpp link) 
    6060   USE prtctl         ! Print control 
    61    USE timing         ! Timing 
    6261   USE lib_fortran    ! Fortran utilities (allows no signed zero when 'key_nosignedzero' defined) 
    6362 
     
    253252      !!-------------------------------------------------------------------- 
    254253      ! 
    255       IF( ln_timing )  CALL timing_start('zdf_osm') 
     254      IF( nn_timing == 1 )  CALL timing_start('zdf_osm') 
    256255      ! 
    257256      ALLOCATE( lconv(jpi,jpj),  STAT= i_lconv_alloc ) 
     
    13521351      CALL lbc_lnk( p_avt(:,:,:), 'W', 1. ) 
    13531352      ! 
    1354       IF( ln_timing )  CALL timing_stop('zdf_osm') 
    1355       ! 
    13561353   END SUBROUTINE zdf_osm 
    13571354 
     
    13761373          & ,ln_kpprimix, rn_riinfty, rn_difri, ln_convmix, rn_difconv 
    13771374     !!---------------------------------------------------------------------- 
    1378      ! 
    1379      IF( ln_timing )  CALL timing_start('zdf_osm_init') 
    13801375     ! 
    13811376     REWIND( numnam_ref )              ! Namelist namzdf_osm in reference namelist : Osmosis ML model 
     
    15031498     ghamu(:,:,:) = 0. 
    15041499     ghamv(:,:,:) = 0. 
    1505  
    1506      ! 
    1507      IF( ln_timing )  CALL timing_stop('zdf_osm_init') 
    15081500     ! 
    15091501   END SUBROUTINE zdf_osm_init 
     
    16161608      INTEGER :: ji, jj, jk 
    16171609      ! 
    1618       IF( ln_timing )  CALL timing_start('tra_osm') 
    1619       ! 
    16201610      IF( kt == nit000 ) THEN 
    16211611         IF(lwp) WRITE(numout,*) 
     
    16581648         &             tab3d_2=tsa(:,:,:,jp_sal), clinfo2=       ' Sa: ', mask2=tmask, clinfo3='tra' ) 
    16591649      ENDIF 
    1660       ! 
    1661       IF( ln_timing )  CALL timing_stop('tra_osm') 
    16621650      ! 
    16631651   END SUBROUTINE tra_osm 
     
    16951683      !!---------------------------------------------------------------------- 
    16961684      ! 
    1697       IF( ln_timing )  CALL timing_start('dyn_osm') 
    1698       ! 
    16991685      IF( kt == nit000 ) THEN 
    17001686         IF(lwp) WRITE(numout,*) 
     
    17161702         END DO 
    17171703      END DO 
    1718  
     1704      ! 
    17191705      ! code for saving tracer trends removed 
    17201706      ! 
    1721       IF( ln_timing )  CALL timing_stop('dyn_osm') 
    1722       ! 
    17231707   END SUBROUTINE dyn_osm 
    17241708 
Note: See TracChangeset for help on using the changeset viewer.