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 6905 for branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM – NEMO

Ignore:
Timestamp:
2016-09-02T10:53:03+02:00 (8 years ago)
Author:
gm
Message:

#1692 - branch SIMPLIF_2_usrdef: OVERFLOW configuration (zps case) + dommsk bug correction

Location:
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/OVERFLOW/EXP00/namelist_cfg

    r6904 r6905  
    66!----------------------------------------------------------------------- 
    77   !                       !  type of vertical coordinate 
    8    ln_zco      = .true.       ! z-coordinate 
     8   ln_zco      = .false.       ! z-coordinate 
    99   ln_zps      = .false.      ! z-partial-step coordinate 
    10    ln_sco      = .false.      ! s-coordinate    
     10   ln_sco      = .true.      ! s-coordinate    
    1111   rn_dx       = 1000.     !  horizontal resolution   [meters] 
    1212   rn_dz       =   20.     !  vertical   resolution   [meters] 
     
    1919   cn_exp      =   "overfl-FCT2-flux-ubs-ens"  !  experience name 
    2020   nn_it000    =       1   !  first time step 
    21    nn_itend    =   10   ! for 34h of simulation  (=12240)  
    22    nn_istate   =       0   !  output the initial state (1) or not (0) 
     21   nn_itend    =   180   ! for 34h of simulation  (=12240)  
     22   nn_istate   =       1   !  output the initial state (1) or not (0) 
    2323   nn_stock    =   12240   !  frequency of creation of a restart file (modulo referenced to 1) 
    2424   nn_write    =   12240   !  frequency of write in the output file   (modulo referenced to nn_it000) 
     
    8080/ 
    8181!----------------------------------------------------------------------- 
    82 &namtra_qsr    !   penetrative solar radiation 
    83 !----------------------------------------------------------------------- 
    84 / 
    85 !----------------------------------------------------------------------- 
    86 &namsbc_rnf    !   runoffs namelist surface boundary condition 
    87 !----------------------------------------------------------------------- 
    88 / 
    89 !----------------------------------------------------------------------- 
    90 &namsbc_ssr    !   surface boundary condition : sea surface restoring 
    91 !----------------------------------------------------------------------- 
    92 / 
    93 !----------------------------------------------------------------------- 
    94 &namsbc_alb    !   albedo parameters 
    95 !----------------------------------------------------------------------- 
    96 / 
    97 !----------------------------------------------------------------------- 
    98 &namberg       !   iceberg parameters 
    99 !----------------------------------------------------------------------- 
    100 / 
    101 !----------------------------------------------------------------------- 
    10282&namlbc        !   lateral momentum boundary condition 
    10383!----------------------------------------------------------------------- 
     
    11494&nambbc        !   bottom temperature boundary condition                (default: NO) 
    11595!----------------------------------------------------------------------- 
    116    ln_trabbc   = .false.    !  Apply a geothermal heating at the ocean bottom 
    11796/ 
    11897!----------------------------------------------------------------------- 
     
    124103!----------------------------------------------------------------------- 
    125104    nn_eos      =  1     !  type of equation of state and Brunt-Vaisala frequency 
    126                                  !  =-1, TEOS-10 
    127                                  !  = 0, EOS-80 
    128                                  !  = 1, S-EOS   (simplified eos) 
    129    !                            ! S-EOS coefficients (ln_seos=T): 
    130    !                            !  rd(T,S,Z)*rau0 = -a0*(1+.5*lambda*dT+mu*Z+nu*dS)*dT+b0*dS 
    131    rn_a0       =  2.e-1      !  thermal expension coefficient (nn_eos= 1) 
    132    rn_b0       =  8.e-1      !  saline  expension coefficient (nn_eos= 1) 
    133    rn_lambda1  =  0.      !  cabbeling coeff in T^2  (=0 for linear eos) 
    134    rn_lambda2  =  0.      !  cabbeling coeff in S^2  (=0 for linear eos) 
    135    rn_mu1      =  0.      !  thermobaric coeff. in T (=0 for linear eos) 
    136    rn_mu2      =  0.      !  thermobaric coeff. in S (=0 for linear eos) 
    137    rn_nu       =  0.      !  cabbeling coeff in T*S  (=0 for linear eos) 
     105                              !  =-1, TEOS-10 
     106                              !  = 0, EOS-80 
     107                              !  = 1, S-EOS   (simplified eos) 
     108   !                     ! S-EOS coefficients (nn_eos=1): 
     109   !                          !  rd(T,S,Z)*rau0 = -a0*(1+.5*lambda*dT+mu*Z+nu*dS)*dT+b0*dS 
     110   rn_a0       =  0.2         !  thermal expension coefficient (nn_eos= 1) 
     111   rn_b0       =  0.          !  saline  expension coefficient (nn_eos= 1) 
     112   rn_lambda1  =  0.          !  cabbeling coeff in T^2  (=0 for linear eos) 
     113   rn_lambda2  =  0.          !  cabbeling coeff in S^2  (=0 for linear eos) 
     114   rn_mu1      =  0.          !  thermobaric coeff. in T (=0 for linear eos) 
     115   rn_mu2      =  0.          !  thermobaric coeff. in S (=0 for linear eos) 
     116   rn_nu       =  0.          !  cabbeling coeff in T*S  (=0 for linear eos) 
    138117/ 
    139118!----------------------------------------------------------------------- 
     
    155134/ 
    156135!----------------------------------------------------------------------- 
    157 &namtra_adv_mle !  mixed layer eddy parametrisation (Fox-Kemper param) 
    158 !----------------------------------------------------------------------- 
    159   ln_mle      = .false.   ! (T) use the Mixed Layer Eddy (MLE) parameterisation 
    160 / 
    161 !---------------------------------------------------------------------------------- 
     136&namtra_adv_mle !   mixed layer eddy parametrisation (Fox-Kemper param) (default: NO) 
     137!----------------------------------------------------------------------- 
     138/ 
     139!----------------------------------------------------------------------- 
    162140&namtra_ldf    !   lateral diffusion scheme for tracers 
    163 !---------------------------------------------------------------------------------- 
    164    !                       !  Operator type: 
    165    ln_traldf_lap   =  .true.   !    laplacian operator 
     141!----------------------------------------------------------------------- 
     142   !                       !  Operator type:    both false = No lateral diffusion 
     143   ln_traldf_lap   =  .false.  !    laplacian operator 
    166144   ln_traldf_blp   =  .false.  !  bilaplacian operator 
    167    !                       !  Direction of action: 
    168    ln_traldf_lev   =  .false.  !  iso-level 
    169    ln_traldf_hor   =  .true.  !  horizontal (geopotential) 
    170    ln_traldf_iso   =  .false.   !  iso-neutral (standard operator) 
    171    ln_traldf_triad =  .false.  !  iso-neutral (triad    operator) 
    172    ! 
    173    !                       !  iso-neutral options:         
    174    ln_traldf_msc   =  .true.   !  Method of Stabilizing Correction (both operators) 
    175    rn_slpmax       =   0.01    !  slope limit                      (both operators) 
    176    ln_triad_iso    =  .false.  !  pure horizontal mixing in ML              (triad only) 
    177    rn_sw_triad     =  1        !  =1 switching triad ; =0 all 4 triads used (triad only) 
    178    ln_botmix_triad =  .false.  !  lateral mixing on bottom                  (triad only) 
    179    ! 
    180    !                       !  Coefficients: 
    181    nn_aht_ijk_t    = 0        !  space/time variation of eddy coef 
    182    !                                !   =-20 (=-30)    read in eddy_diffusivity_2D.nc (..._3D.nc) file 
    183    !                                !   =  0           constant 
    184    !                                !   = 10 F(k)      =ldf_c1d 
    185    !                                !   = 20 F(i,j)    =ldf_c2d 
    186    !                                !   = 21 F(i,j,t)  =Treguier et al. JPO 1997 formulation 
    187    !                                !   = 30 F(i,j,k)  =ldf_c2d + ldf_c1d 
    188    !                                !   = 31 F(i,j,k,t)=F(local velocity) 
    189    rn_aht_0        = 0.    !  lateral eddy diffusivity   (lap. operator) [m2/s] 
    190    rn_bht_0        = 0.    !  lateral eddy diffusivity (bilap. operator) [m4/s] 
    191 / 
    192 !---------------------------------------------------------------------------------- 
    193 &namtra_ldfeiv !   eddy induced velocity param. 
    194 !---------------------------------------------------------------------------------- 
    195 / 
    196 !----------------------------------------------------------------------- 
    197 &namtra_dmp    !   tracer: T & S newtonian damping 
     145/ 
     146!----------------------------------------------------------------------- 
     147&namtra_ldfeiv !   eddy induced velocity param.                         (default: NO) 
     148!----------------------------------------------------------------------- 
     149/ 
     150!----------------------------------------------------------------------- 
     151&namtra_dmp    !   tracer: T & S newtonian damping                       (default: YES) 
    198152!----------------------------------------------------------------------- 
    199153   ln_tradmp   =  .false.   !  add a damping termn (T) or not (F) 
     
    214168/ 
    215169!----------------------------------------------------------------------- 
    216 &namdyn_vor    !   option of physics/algorithm (not control by CPP keys) 
     170&namdyn_vor    !   option of physics/algorithm 
    217171!----------------------------------------------------------------------- 
    218172   ln_dynvor_ene = .false. !  enstrophy conserving scheme 
     
    245199   !                       !  Type of the operator : 
    246200   !                           !  no diffusion: set ln_dynldf_lap=..._blp=F  
    247    ln_dynldf_lap =  .true.     !    laplacian operator 
     201   ln_dynldf_lap =  .false.    !    laplacian operator 
    248202   ln_dynldf_blp =  .false.    !  bilaplacian operator 
    249203   !                       !  Direction of action  : 
     
    269223   rn_avm0     =   1.e-4  !  vertical eddy viscosity   [m2/s]          (background Kz if not "key_zdfcst") 
    270224   rn_avt0     =   0.     !  vertical eddy diffusivity [m2/s]          (background Kz if not "key_zdfcst") 
    271    ln_zdfevd   = .false.  !  enhanced vertical diffusion (evd) (T) or not (F) 
    272    ln_zdfnpc   = .false.  !  Non-Penetrative Convective algorithm (T) or not (F) 
    273 / 
    274 !----------------------------------------------------------------------- 
    275 &namzdf_tke    !   turbulent eddy kinetic dependent vertical diffusion  ("key_zdftke") 
    276 !----------------------------------------------------------------------- 
    277 / 
    278 !----------------------------------------------------------------------- 
    279 &namzdf_ddm    !   double diffusive mixing parameterization             ("key_zdfddm") 
    280 !----------------------------------------------------------------------- 
    281 / 
    282 !----------------------------------------------------------------------- 
    283 &namzdf_tmx    !   tidal mixing parameterization                        ("key_zdftmx") 
    284 !----------------------------------------------------------------------- 
     225   ln_zdfevd   = .false.  !  enhanced vertical diffusion (evd) 
     226   ln_zdfnpc   = .false.  !  Non-Penetrative Convective algorithm 
    285227/ 
    286228!----------------------------------------------------------------------- 
     
    292234!----------------------------------------------------------------------- 
    293235/ 
    294 !----------------------------------------------------------------------- 
    295 &namptr       !   Poleward Transport Diagnostic 
    296 !----------------------------------------------------------------------- 
    297 / 
    298 !----------------------------------------------------------------------- 
    299 &namhsb       !  Heat and salt budgets 
    300 !----------------------------------------------------------------------- 
    301 / 
    302 !----------------------------------------------------------------------- 
    303 &namobs       !  observation usage 
    304 !----------------------------------------------------------------------- 
    305 / 
    306 !----------------------------------------------------------------------- 
    307 &nam_asminc   !   assimilation increments                               ('key_asminc') 
    308 !----------------------------------------------------------------------- 
    309 / 
  • branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/OVERFLOW/MY_SRC/usrdef_istate.F90

    r6904 r6905  
    1414   !!---------------------------------------------------------------------- 
    1515   USE par_oce        ! ocean space and time domain 
    16    USE dom_oce , ONLY : gphit  
     16   USE dom_oce , ONLY : glamt  
    1717   USE phycst         ! physical constants 
    1818   ! 
     
    5454      ! 
    5555      IF(lwp) WRITE(numout,*) 
    56       IF(lwp) WRITE(numout,*) 'usr_def_istate : OVERFLOW configuration, analytical definition of initial state ' 
    57       IF(lwp) WRITE(numout,*) '~~~~~~~~~~~~~~   Ocean at rest, with a dam on T profile, and uniform S profile' 
     56      IF(lwp) WRITE(numout,*) 'usr_def_istate : OVERFLOW configuration, analytical definition of initial state' 
     57      IF(lwp) WRITE(numout,*) '~~~~~~~~~~~~~~   Ocean at rest, with a constant salinity (not used as rho=F(T) ' 
     58      IF(lwp) WRITE(numout,*) '                 and a vertical density front with a 2 kg/m3 difference located' 
     59      IF(lwp) WRITE(numout,*) '                 and a vertical density front with a 2 kg/m3 difference located at glam=20km' 
     60      IF(lwp) WRITE(numout,*) '                 (i.e. a temperature difference of 10 degrees with rn_a0 = 0.2' 
     61      ! 
     62      !  rn_a0 =  2.e-1   !  thermal expension coefficient (nn_eos= 1) 
     63      !  rho = rau0 - rn_a0 * (T-10)  
     64      !  delta_T = 10 degrees  ==>>  delta_rho = 10 * rn_a0 = 2 kg/m3 
    5865      ! 
    5966      pu  (:,:,:) = 0._wp        ! ocean at rest 
     
    6572      pts(:,:,:,jp_tem) = 20._wp * ptmask(:,:,:) 
    6673      DO jk = 1, jpkm1 
    67          WHERE( gphit(:,:) <= zdam )   pts(:,:,jk,jp_tem) = 10._wp * ptmask(:,:,jk) 
     74         WHERE( glamt(:,:) <= zdam )   pts(:,:,jk,jp_tem) = 10._wp * ptmask(:,:,jk) 
    6875      END DO 
    6976      ! 
  • branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/OVERFLOW/MY_SRC/usrdef_nam.F90

    r6904 r6905  
    9494      WRITE(ldtxt(ii),*) '   '                                                                          ;   ii = ii + 1 
    9595      WRITE(ldtxt(ii),*) '   Lateral boundary condition of the global domain'                           ;   ii = ii + 1 
    96       WRITE(ldtxt(ii),*) '      east-west cyclic                         jperio = ', kperio             ;   ii = ii + 1 
     96      WRITE(ldtxt(ii),*) '      OVERFLOW : closed basin                  jperio = ', kperio             ;   ii = ii + 1 
    9797      ! 
    9898   END SUBROUTINE usr_def_nam 
  • branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/OVERFLOW/MY_SRC/usrdef_zgr.F90

    r6904 r6905  
    6363      ! 
    6464      INTEGER  ::   ji, jj, jk        ! dummy indices 
     65      INTEGER  ::   ik                ! local integers 
    6566      REAL(wp) ::   zfact, z1_jpkm1   ! local scalar 
    6667      REAL(wp) ::   ze3min            ! local scalar 
    6768      REAL(wp), DIMENSION(jpi,jpj) ::   zht, zhu, z2d   ! 2D workspace 
    68  
    69  
    70       INTEGER  ::   ik, it, ikb, ikt ! temporary integers 
    71       REAL(wp) ::   ze3tp , ze3wp    ! Last ocean level thickness at T- and W-points 
    72       REAL(wp) ::   zdepwp           ! Ajusted ocean depth to avoid too small e3t 
    73       REAL(wp) ::   zdiff            ! temporary scalar 
    74       REAL(wp) ::   zmax             ! temporary scalar 
    75  
    76  
    7769      !!---------------------------------------------------------------------- 
    7870      ! 
     
    123115         ! 
    124116         !                                !* terrain-following coordinate with e3.(k)=cst) 
     117         !                                !  OVERFLOW case : identical with j-index (T=V, U=F) 
    125118         z1_jpkm1 = 1._wp / REAL( jpkm1 , wp) 
    126119         DO jk = 1, jpk 
     
    161154      ! 
    162155      IF ( ln_zps ) THEN      !==  zps-coordinate  ==!   (partial bottom-steps) 
    163        
    164        
    165        
    166          CALL ctl_stop( 'STOP', ' zps coordinate not yet coded' ) 
    167  
    168  
    169  
    170        
    171       !!---------------------------------------------------------------------- 
    172       !!                  ***  ROUTINE zgr_zps  *** 
    173       !!                      
    174       !! ** Purpose :   the depth and vertical scale factor in partial step 
    175       !!              reference z-coordinate case 
    176       !! 
    177       !! ** Method  :   Partial steps : computes the 3D vertical scale factors 
    178       !!      of T-, U-, V-, W-, UW-, VW and F-points that are associated with 
    179       !!      a partial step representation of bottom topography. 
    180       !! 
    181       !!       
    182       !!  Reference :   Pacanowsky & Gnanadesikan 1997, Mon. Wea. Rev., 126, 3248-3270. 
    183       !!---------------------------------------------------------------------- 
    184       !!--------------------------------------------------------------------- 
     156         ! 
     157!         CALL ctl_stop( 'STOP', ' zps coordinate not yet coded' ) 
    185158         ! 
    186159         ze3min = 0.1_wp * rn_dz 
     
    193166            WHERE( zht(:,:) <= pdepw_1d(jk) + ze3min )   k_bot(:,:) = jk-1 
    194167         END DO 
    195  
     168         ! 
    196169         !                                !* vertical coordinate system 
    197          ! 
    198          DO jk = 1, jpk                         ! initialization to the reference z-coordinate 
     170         DO jk = 1, jpk                      ! initialization to the reference z-coordinate 
    199171            pdept(:,:,jk) = pdept_1d(jk) 
    200172            pdepw(:,:,jk) = pdepw_1d(jk) 
     
    207179            pe3vw(:,:,jk) = pe3w_1d (jk) 
    208180         END DO 
    209          ! 
    210          DO jj = 1, jpj                         ! bottom scale factors and depth at T- and W-points 
     181         DO jj = 1, jpj                      ! bottom scale factors and depth at T- and W-points 
    211182            DO ji = 1, jpi 
    212183               ik = k_bot(ji,jj) 
    213184               IF( ik /= jpkm1 ) THEN                 ! last level ==> ref 1d z-coordinate 
    214185                  pdepw(ji,jj,ik+1) = MIN( zht(ji,jj) , pdepw_1d(ik+1) ) 
    215                   pe3t (ji,jj,ik  ) = pdepw(ji,jj,ik) - pdepw(ji,jj,ik+1) 
     186                  pe3t (ji,jj,ik  ) = pdepw(ji,jj,ik+1) - pdepw(ji,jj,ik) 
    216187                  pe3t (ji,jj,ik+1) = pe3t (ji,jj,ik)  
    217                 
     188                  ! 
    218189                  pdept(ji,jj,ik  ) = pdept(ji,jj,ik-1) + pe3t(ji,jj,ik) * 0.5_wp 
    219                   pe3w (ji,jj,ik+1) = pdepw(ji,jj,ik) - pdepw(ji,jj,ik+1) 
     190                  pe3w (ji,jj,ik+1) = pdepw(ji,jj,ik+1) - pdepw(ji,jj,ik) 
    220191               ENDIF 
    221192            END DO 
    222193         END DO          
    223           
    224           
    225          ! 
    226          DO jj = 1, jpj                         ! bottom scale factors and depth at T- and W-points 
    227             DO ji = 1, jpi 
    228                ik = k_bot(ji,jj) 
    229                   ! 
    230                   IF( zht(ji,jj) <= pdepw_1d(ik+1) ) THEN  ;   pdepw(ji,jj,ik+1) = zht(ji,jj) 
    231                   ELSE                                     ;   pdepw(ji,jj,ik+1) = pdepw_1d(ik+1) 
    232                   ENDIF 
    233    !gm Bug?  check the gdepw_1d 
    234                   !       ... on ik 
    235                   pdept(ji,jj,ik) = pdepw_1d(ik) + ( pdepw   (ji,jj,ik+1) - pdepw_1d(ik) )   & 
    236                      &                           * ( pdept_1d(      ik  ) - pdepw_1d(ik) )   & 
    237                      &                           / ( pdepw_1d(      ik+1) - pdepw_1d(ik) ) 
    238                   pe3t (ji,jj,ik) = pe3t_1d (ik) * ( pdepw   (ji,jj,ik+1) - pdepw_1d(ik) )   &  
    239                      &                           / ( pdepw_1d(      ik+1) - pdepw_1d(ik) )  
    240                   pe3w (ji,jj,ik) = 0.5_wp * ( pdepw(ji,jj,ik+1) + pdepw_1d(ik+1) - 2._wp * pdepw_1d(ik) )   & 
    241                      &                     * ( pe3w_1d(ik) / ( pdepw_1d(ik+1) - pdepw_1d(ik) ) ) 
    242                   !       ... on ik+1 
    243                   pe3w (ji,jj,ik+1) = pe3t (ji,jj,ik) 
    244                   pe3t (ji,jj,ik+1) = pe3t (ji,jj,ik) 
    245                   pdept(ji,jj,ik+1) = pdept(ji,jj,ik) + pe3t(ji,jj,ik) 
    246             END DO 
    247          END DO 
    248          ! 
    249       ! 
    250       ! 
    251       !                                      ! bottom scale factors and depth at  U-, V-, UW and VW-points 
    252       ! 
    253       DO jk = 1,jpk                          ! Computed as the minimum of neighbooring scale factors 
    254          DO jj = 1, jpjm1 
    255             DO ji = 1, jpim1 
    256                pe3u (ji,jj,jk) = MIN( pe3t(ji,jj,jk), pe3t(ji+1,jj,jk) ) 
    257                pe3v (ji,jj,jk) = MIN( pe3t(ji,jj,jk), pe3t(ji,jj+1,jk) ) 
    258                pe3uw(ji,jj,jk) = MIN( pe3w(ji,jj,jk), pe3w(ji+1,jj,jk) ) 
    259                pe3vw(ji,jj,jk) = MIN( pe3w(ji,jj,jk), pe3w(ji,jj+1,jk) ) 
    260             END DO 
    261          END DO 
    262       END DO 
    263       !                                      ! lateral boundary conditions 
    264       CALL lbc_lnk( pe3u , 'U', 1._wp )   ;   CALL lbc_lnk( pe3uw, 'U', 1._wp )    
    265       CALL lbc_lnk( pe3v , 'V', 1._wp )   ;   CALL lbc_lnk( pe3vw, 'V', 1._wp ) 
    266       ! 
    267  
    268       DO jk = 1, jpk                         ! set to z-scale factor if zero (i.e. along closed boundaries) 
    269          WHERE( pe3u (:,:,jk) == 0._wp )   pe3u (:,:,jk) = pe3t_1d(jk) 
    270          WHERE( pe3v (:,:,jk) == 0._wp )   pe3v (:,:,jk) = pe3t_1d(jk) 
    271          WHERE( pe3uw(:,:,jk) == 0._wp )   pe3uw(:,:,jk) = pe3w_1d(jk) 
    272          WHERE( pe3vw(:,:,jk) == 0._wp )   pe3vw(:,:,jk) = pe3w_1d(jk) 
    273       END DO 
    274        
    275       ! Scale factor at F-point 
    276       DO jk = 1, jpk                        ! initialisation to z-scale factors 
    277          pe3f(:,:,jk) = pe3t_1d(jk) 
    278       END DO 
    279       DO jk = 1, jpk                        ! Computed as the minimum of neighbooring V-scale factors 
    280          DO jj = 1, jpjm1 
    281             DO ji = 1, fs_jpim1   ! vector opt. 
    282                pe3f(ji,jj,jk) = MIN( pe3v(ji,jj,jk), pe3v(ji+1,jj,jk) ) 
    283             END DO 
    284          END DO 
    285       END DO 
    286       CALL lbc_lnk( pe3f, 'F', 1._wp )       ! Lateral boundary conditions 
    287       ! 
    288       DO jk = 1, jpk                        ! set to z-scale factor if zero (i.e. along closed boundaries) 
    289          WHERE( pe3f(:,:,jk) == 0._wp )   pe3f(:,:,jk) = pe3t_1d(jk) 
    290       END DO 
    291 !!gm  bug ? :  must be a do loop with mj0,mj1 
    292       !  
    293        
    294 !!gm  DO it differently ! 
    295 !      pe3t(:,mj0(1),:) = e3t(:,mj0(2),:)     ! we duplicate factor scales for jj = 1 and jj = 2 
    296 !      pe3w(:,mj0(1),:) = e3w(:,mj0(2),:)  
    297 !      pe3u(:,mj0(1),:) = e3u(:,mj0(2),:)  
    298 !      pe3v(:,mj0(1),:) = e3v(:,mj0(2),:)  
    299 !      pe3f(:,mj0(1),:) = e3f(:,mj0(2),:)  
    300  
    301       ! Control of the sign 
    302       IF( MINVAL( pe3t (:,:,:) ) <= 0._wp )   CALL ctl_stop( '    zgr_zps :   e r r o r   e3t_0 <= 0' ) 
    303       IF( MINVAL( pe3w (:,:,:) ) <= 0._wp )   CALL ctl_stop( '    zgr_zps :   e r r o r   e3w_0 <= 0' ) 
    304       IF( MINVAL( pdept(:,:,:) ) <  0._wp )   CALL ctl_stop( '    zgr_zps :   e r r o r   gdept_0 <  0' ) 
    305       IF( MINVAL( pdepw(:,:,:) ) <  0._wp )   CALL ctl_stop( '    zgr_zps :   e r r o r   gdepw_0 <  0' ) 
    306       
    307       ! Compute gde3w_0 (vertical sum of e3w) 
    308 !      IF ( ln_isfcav ) THEN ! if cavity 
    309 !         WHERE( misfdep == 0 )   misfdep = 1 
    310 !         DO jj = 1,jpj 
    311 !            DO ji = 1,jpi 
    312 !               gde3w_0(ji,jj,1) = 0.5_wp * e3w_0(ji,jj,1) 
    313 !               DO jk = 2, misfdep(ji,jj) 
    314 !                  gde3w_0(ji,jj,jk) = gde3w_0(ji,jj,jk-1) + e3w_0(ji,jj,jk)  
    315 !               END DO 
    316 !               IF( misfdep(ji,jj) >= 2 )   gde3w_0(ji,jj,misfdep(ji,jj)) = risfdep(ji,jj) + 0.5_wp * e3w_0(ji,jj,misfdep(ji,jj)) 
    317 !               DO jk = misfdep(ji,jj) + 1, jpk 
    318 !                  gde3w_0(ji,jj,jk) = gde3w_0(ji,jj,jk-1) + e3w_0(ji,jj,jk)  
    319 !               END DO 
    320 !            END DO 
    321 !         END DO 
    322 !      ELSE ! no cavity 
    323 !         gde3w_0(:,:,1) = 0.5_wp * e3w_0(:,:,1) 
    324 !         DO jk = 2, jpk 
    325 !            gde3w_0(:,:,jk) = gde3w_0(:,:,jk-1) + e3w_0(:,:,jk) 
    326 !         END DO 
    327 !      END IF 
    328       ! 
    329       ! 
    330        
    331        
    332        
    333        
     194         !                                   ! bottom scale factors and depth at  U-, V-, UW and VW-points 
     195         !                                   ! usually Computed as the minimum of neighbooring scale factors 
     196         pe3u (:,:,:) = pe3t(:,:,:)          ! HERE OVERFLOW configuration :  
     197         pe3v (:,:,:) = pe3t(:,:,:)          !    e3 increases with i-index and identical with j-index 
     198         pe3f (:,:,:) = pe3t(:,:,:)          !    so e3 minimum of (i,i+1) points is (i) point (idem in j-direction) 
     199         pe3uw(:,:,:) = pe3w(:,:,:)          !     
     200         pe3vw(:,:,:) = pe3w(:,:,:)          !    ==>>  no need of lbc_lnk calls 
     201         !       
    334202      ENDIF 
    335203      ! 
  • branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/NEMO/OPA_SRC/DOM/dommsk.F90

    r6904 r6905  
    130130      ! ---------------------------- 
    131131      ! 
     132      tmask(:,:,:) = 0._wp 
    132133      DO jj = 1, jpj 
    133134         DO ji = 1, jpi 
    134             iktop = MAX( k_top(ji,jj) , 1 ) 
    135             ikbot =      k_bot(ji,jj) 
    136             tmask(ji,jj,      1:iktop-1) = 0._wp      ! mask the iceshelves 
    137             tmask(ji,jj,iktop  :ikbot  ) = 1._wp 
    138             tmask(ji,jj,ikbot+1:jpk    ) = 0._wp      ! mask the ocean topography 
     135            iktop = k_top(ji,jj) 
     136            ikbot = k_bot(ji,jj) 
     137            IF( iktop /= 0 ) THEN       ! water in the column 
     138               tmask(ji,jj,iktop:ikbot  ) = 1._wp 
     139            ENDIF 
    139140         END DO   
    140141      END DO   
Note: See TracChangeset for help on using the changeset viewer.