Changeset 6914 for branches/2016/dev_r6409_SIMPLIF_2_usrdef
- Timestamp:
- 2016-09-06T13:27:38+02:00 (8 years ago)
- Location:
- branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/LOCK_EXCHANGE/EXP00/namelist_cfg
r6906 r6914 2 2 !! NEMO/OPA Configuration namelist : used to overwrite defaults values defined in SHARED/namelist_ref 3 3 !!>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 4 ! 4 5 !----------------------------------------------------------------------- 5 6 &namusr_def ! LOCK_EXCHANGE user defined namelist 6 7 !----------------------------------------------------------------------- 7 ln_zco = .true. ! z-coordinate flag8 8 rn_dx = 500. ! horizontal resolution in meters 9 9 rn_dz = 1. ! vertical resolution in meters 10 10 / 11 ! 11 12 !----------------------------------------------------------------------- 12 13 &namrun ! parameters of the run 13 14 !----------------------------------------------------------------------- 14 15 nn_no = 0 ! job number (no more used...) 15 cn_exp = "LOCK -FCT2-flux-ubs-ens" ! experience name16 cn_exp = "LOCK_FCT2_flux_ubs" ! experience name 16 17 nn_it000 = 1 ! first time step 17 nn_itend = 12240 ! for 34h of simulation18 nn_itend = 61200 ! for 17h of simulation (=61200 time-step) 18 19 nn_istate = 0 ! output the initial state (1) or not (0) 19 nn_stock = 12240 ! frequency of creation of a restart file (modulo referenced to 1)20 nn_write = 12240 ! frequency of write in the output file (modulo referenced to nn_it000)20 nn_stock = 61200 ! frequency of creation of a restart file (modulo referenced to 1) 21 nn_write = 61200 ! frequency of write in the output file (modulo referenced to nn_it000) 21 22 / 22 23 !----------------------------------------------------------------------- … … 27 28 ln_write_cfg= .false. ! (=T) create the domain configuration file 28 29 ! 29 cp_cfg = "lock" ! name of the configuration30 cp_cfg = "lock" ! name of the configuration 30 31 jp_cfg = 0 ! resolution of the configuration 31 32 ln_use_jattr = .false. ! use (T) the file attribute: open_ocean_jstart, if present … … 81 82 / 82 83 !----------------------------------------------------------------------- 83 &nambbl ! bottom boundary layer scheme 84 &nambbl ! bottom boundary layer scheme ("key_trabbl") 84 85 !----------------------------------------------------------------------- 85 86 / … … 124 125 !----------------------------------------------------------------------- 125 126 &namtra_ldf ! lateral diffusion scheme for tracers 126 !----------------------------------------------------------------------- -----------127 ! ! Operator type: 128 ln_traldf_lap = . true.! laplacian operator127 !----------------------------------------------------------------------- 128 ! ! Operator type: both false = No lateral diffusion 129 ln_traldf_lap = .false. ! laplacian operator 129 130 ln_traldf_blp = .false. ! bilaplacian operator 130 ! ! Direction of action:131 ln_traldf_lev = .false. ! iso-level132 ln_traldf_hor = .true. ! horizontal (geopotential)133 ln_traldf_iso = .false. ! iso-neutral (standard operator)134 ln_traldf_triad = .false. ! iso-neutral (triad operator)135 !136 ! ! iso-neutral options:137 ln_traldf_msc = .true. ! Method of Stabilizing Correction (both operators)138 rn_slpmax = 0.01 ! slope limit (both operators)139 ln_triad_iso = .false. ! pure horizontal mixing in ML (triad only)140 rn_sw_triad = 1 ! =1 switching triad ; =0 all 4 triads used (triad only)141 ln_botmix_triad = .false. ! lateral mixing on bottom (triad only)142 !143 ! ! Coefficients:144 nn_aht_ijk_t = 0 ! space/time variation of eddy coef145 ! ! =-20 (=-30) read in eddy_diffusivity_2D.nc (..._3D.nc) file146 ! ! = 0 constant147 ! ! = 10 F(k) =ldf_c1d148 ! ! = 20 F(i,j) =ldf_c2d149 ! ! = 21 F(i,j,t) =Treguier et al. JPO 1997 formulation150 ! ! = 30 F(i,j,k) =ldf_c2d + ldf_c1d151 ! ! = 31 F(i,j,k,t)=F(local velocity)152 rn_aht_0 = 0. ! lateral eddy diffusivity (lap. operator) [m2/s]153 rn_bht_0 = 0. ! lateral eddy diffusivity (bilap. operator) [m4/s]154 /155 !----------------------------------------------------------------------------------156 &namtra_ldfeiv ! eddy induced velocity param.157 !----------------------------------------------------------------------------------158 ln_ldfeiv =.false. ! use eddy induced velocity parameterization159 ln_ldfeiv_dia =.false. ! diagnose eiv stream function and velocities160 rn_aeiv_0 = 0. ! eddy induced velocity coefficient [m2/s]161 nn_aei_ijk_t = 0 ! space/time variation of the eiv coeficient162 ! ! =-20 (=-30) read in eddy_induced_velocity_2D.nc (..._3D.nc) file163 ! ! = 0 constant164 ! ! = 10 F(k) =ldf_c1d165 ! ! = 20 F(i,j) =ldf_c2d166 ! ! = 21 F(i,j,t) =Treguier et al. JPO 1997 formulation167 ! ! = 30 F(i,j,k) =ldf_c2d + ldf_c1d168 131 / 169 132 !----------------------------------------------------------------------- -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/LOCK_EXCHANGE/MY_SRC/usrdef_hgr.F90
r6906 r6914 10 10 !!---------------------------------------------------------------------- 11 11 12 !!---------------------------------------------------------------------- ------------12 !!---------------------------------------------------------------------- 13 13 !! usr_def_hgr : initialize the horizontal mesh for LOCK_EXCHANGE configuration 14 !!---------------------------------------------------------------------- ------------14 !!---------------------------------------------------------------------- 15 15 USE dom_oce , ONLY: nimpp, njmpp ! ocean space and time domain 16 16 USE par_oce ! ocean space and time domain … … 46 46 !! 47 47 !! ** Method : set all intent(out) argument to a proper value 48 !! LOCK_EXCHANGE configuration : uniform grid spacing ( 500m)48 !! LOCK_EXCHANGE configuration : uniform grid spacing (rn_dx) 49 49 !! without Coriolis force (f=0) 50 50 !! -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/LOCK_EXCHANGE/MY_SRC/usrdef_istate.F90
r6906 r6914 37 37 !! 38 38 !! ** Purpose : Initialization of the dynamics and tracers 39 !! Here LOCK_EXCHANGE configuration example39 !! Here LOCK_EXCHANGE configuration 40 40 !! 41 41 !! ** Method : - set temprature field … … 59 59 IF(lwp) WRITE(numout,*) ' (i.e. a temperature difference of 25 degrees with rn_a0 = 0.2' 60 60 ! 61 ! rn_a0 = 2.e-1! thermal expension coefficient (nn_eos= 1)61 ! rn_a0 = 0.2 ! thermal expension coefficient (nn_eos= 1) 62 62 ! rho = rau0 - rn_a0 * (T-10) 63 63 ! delta_T = 25 degrees ==>> delta_rho = 25 * rn_a0 = 5 kg/m3 … … 68 68 ! 69 69 ! ! T & S profiles 70 zdam = 32. ! in kilometers70 zdam = 32. ! density front position in kilometers 71 71 pts(:,:,:,jp_tem) = 30._wp * ptmask(:,:,:) 72 72 DO jk = 1, jpkm1 -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/LOCK_EXCHANGE/MY_SRC/usrdef_nam.F90
r6906 r6914 15 15 !!---------------------------------------------------------------------- 16 16 USE dom_oce , ONLY: nimpp , njmpp ! i- & j-indices of the local domain 17 USE dom_oce , ONLY: ln_zco, ln_zps, ln_sco ! flag of type of coordinate !!gm NOT SURE !18 17 USE par_oce ! ocean space and time domain 19 18 USE phycst ! physical constants … … 57 56 INTEGER :: ios, ii ! Local integer 58 57 !! 59 NAMELIST/namusr_def/ ln_zco, ln_zps, ln_sco,rn_dx, rn_dz58 NAMELIST/namusr_def/ rn_dx, rn_dz 60 59 !!---------------------------------------------------------------------- 61 60 ! … … 78 77 WRITE(ldtxt(ii),*) '~~~~~~~~~~~ ' ; ii = ii + 1 79 78 WRITE(ldtxt(ii),*) ' Namelist namusr_def : LOCK_EXCHANGE test case' ; ii = ii + 1 80 WRITE(ldtxt(ii),*) ' type of vertical coordinate : ' ; ii = ii + 181 WRITE(ldtxt(ii),*) ' z-coordinate flag ln_zco = ', ln_zco ; ii = ii + 182 WRITE(ldtxt(ii),*) ' z-partial-step coordinate flag ln_zps = ', ln_sco ; ii = ii + 183 WRITE(ldtxt(ii),*) ' s-coordinate flag ln_sco = ', ln_sco ; ii = ii + 184 79 WRITE(ldtxt(ii),*) ' horizontal resolution rn_dx = ', rn_dx, ' meters' ; ii = ii + 1 85 80 WRITE(ldtxt(ii),*) ' vertical resolution rn_dz = ', rn_dz, ' meters' ; ii = ii + 1 -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/LOCK_EXCHANGE/MY_SRC/usrdef_sbc.F90
r6901 r6914 6 6 !! 7 7 !! User defined : user defined momentum, heat and freshwater forcings 8 !!===================================================================== 8 !!====================================================================== 9 9 !! History : 4.0 ! 2016-03 (S. Flavoni, G. Madec) user defined interface 10 10 !!---------------------------------------------------------------------- -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/LOCK_EXCHANGE/MY_SRC/usrdef_zgr.F90
r6906 r6914 2 2 !!============================================================================== 3 3 !! *** MODULE usrdef_zgr *** 4 !! 5 !! === LOCK_EXCHANGE case === 6 !! 4 7 !! Ocean domain : user defined vertical coordinate system 5 !!6 !! === LOCK_EXCHANGE case ===7 !!8 8 !!============================================================================== 9 !! History : 4.0 ! 2016-08 (G. Madec ) Original code9 !! History : 4.0 ! 2016-08 (G. Madec, S. Flavoni) Original code 10 10 !!---------------------------------------------------------------------- 11 11 12 12 !!---------------------------------------------------------------------- 13 !! usr_def_zgr : user defined vertical coordinate system (required) 14 !! zgr_z1d : reference 1D z-coordinate 15 !! zgr_zps : 3D vertical coordinate in z-partial cell coordinate 13 !! usr_def_zgr : user defined vertical coordinate system (required) 14 !! zgr_z1d : reference 1D z-coordinate 16 15 !!--------------------------------------------------------------------- 17 USE oce ! ocean variables 18 USE dom_oce , ONLY: ln_zco, ln_zps, ln_sco ! ocean space and time domain 19 USE dom_oce , ONLY: nimpp, njmpp ! ocean space and time domain 20 USE dom_oce , ONLY: glamt ! ocean space and time domain 21 USE usrdef_nam ! User defined : namelist variables 16 USE oce ! ocean variables 17 USE dom_oce , ONLY: ln_zco, ln_zps, ln_sco ! ocean space and time domain 18 USE usrdef_nam ! User defined : namelist variables 22 19 ! 23 USE in_out_manager 24 USE lbclnk 25 USE lib_mpp 26 USE wrk_nemo 27 USE timing 20 USE in_out_manager ! I/O manager 21 USE lbclnk ! ocean lateral boundary conditions (or mpp link) 22 USE lib_mpp ! distributed memory computing library 23 USE wrk_nemo ! Memory allocation 24 USE timing ! Timing 28 25 29 26 IMPLICIT NONE … … 62 59 INTEGER , DIMENSION(:,:) , INTENT(out) :: k_top, k_bot ! first & last ocean level 63 60 ! 64 INTEGER :: ji, jj, jk ! dummy indices 65 INTEGER :: ik ! local integers 66 REAL(wp) :: zfact, z1_jpkm1 ! local scalar 67 REAL(wp) :: ze3min ! local scalar 68 REAL(wp), DIMENSION(jpi,jpj) :: zht, zhu, z2d ! 2D workspace 61 INTEGER :: jk ! dummy indices 62 REAL(wp), DIMENSION(jpi,jpj) :: z2d ! 2D workspace 69 63 !!---------------------------------------------------------------------- 70 64 ! … … 77 71 ! --------------------------- 78 72 ! set in usrdef_nam.F90 by reading the namusr_def namelist only ln_zco 73 ln_zco = .TRUE. ! z-partial-step coordinate 79 74 ln_zps = .FALSE. ! z-partial-step coordinate 80 75 ln_sco = .FALSE. ! s-coordinate … … 87 82 ! !== UNmasked meter bathymetry ==! 88 83 ! 89 ! flat bassin (20m deep and 64000m wide )84 ! flat bassin (20m deep and 64000m wide, set through the jpk and jpi (see userdef_nam.F90)) 90 85 CALL zgr_z1d( pdept_1d, pdepw_1d, pe3t_1d , pe3w_1d ) ! Reference z-coordinate system 91 86 ! … … 96 91 ! the ocean basin surrounded by land (1 grid-point) set through lbc_lnk call as jperio=0 97 92 z2d(:,:) = 1._wp ! surface ocean is the 1st level 98 CALL lbc_lnk( z2d, 'T', 1. ) ! closed basin 99 k_top(:,:) = z2d(:,:)93 CALL lbc_lnk( z2d, 'T', 1. ) ! closed basin since jperio = 0 (see userdef_nam.F90) 94 k_top(:,:) = NINT( z2d(:,:) ) 100 95 ! 101 96 ! 102 IF ( ln_zco ) THEN !== z-coordinate ==! (step-like topography) 103 ! 104 ! !* bottom ocean compute from the depth of grid-points 105 k_bot(:,:) = jpkm1 * k_top(:,:) ! here use k_top as a land mask 106 ! !* horizontally uniform coordinate (reference z-co everywhere) 107 DO jk = 1, jpk 108 pdept(:,:,jk) = pdept_1d(jk) 109 pdepw(:,:,jk) = pdepw_1d(jk) 110 pe3t (:,:,jk) = pe3t_1d (jk) 111 pe3u (:,:,jk) = pe3t_1d (jk) 112 pe3v (:,:,jk) = pe3t_1d (jk) 113 pe3f (:,:,jk) = pe3t_1d (jk) 114 pe3w (:,:,jk) = pe3w_1d (jk) 115 pe3uw(:,:,jk) = pe3w_1d (jk) 116 pe3vw(:,:,jk) = pe3w_1d (jk) 117 END DO 118 ENDIF 97 ! !== z-coordinate ==! (step-like topography) 119 98 ! 99 ! !* bottom ocean compute from the depth of grid-points 100 k_bot(:,:) = jpkm1 * k_top(:,:) ! here use k_top as a land mask 101 ! !* horizontally uniform coordinate (reference z-co everywhere) 102 DO jk = 1, jpk 103 pdept(:,:,jk) = pdept_1d(jk) 104 pdepw(:,:,jk) = pdepw_1d(jk) 105 pe3t (:,:,jk) = pe3t_1d (jk) 106 pe3u (:,:,jk) = pe3t_1d (jk) 107 pe3v (:,:,jk) = pe3t_1d (jk) 108 pe3f (:,:,jk) = pe3t_1d (jk) 109 pe3w (:,:,jk) = pe3w_1d (jk) 110 pe3uw(:,:,jk) = pe3w_1d (jk) 111 pe3vw(:,:,jk) = pe3w_1d (jk) 112 END DO 120 113 ! 121 114 END SUBROUTINE usr_def_zgr -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/OVERFLOW/EXP00/namelist_cfg
r6906 r6914 2 2 !! NEMO/OPA Configuration namelist : used to overwrite defaults values defined in SHARED/namelist_ref 3 3 !!>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 4 ! 4 5 !----------------------------------------------------------------------- 5 6 &namusr_def ! User defined : OVERFLOW configuration … … 7 8 ! ! type of vertical coordinate 8 9 ln_zco = .false. ! z-coordinate 9 ln_zps = . false.! z-partial-step coordinate10 ln_sco = . true.! s-coordinate11 rn_dx = 1000.! horizontal resolution [meters]12 rn_dz = 20.! vertical resolution [meters]10 ln_zps = .true. ! z-partial-step coordinate 11 ln_sco = .false. ! s-coordinate 12 rn_dx = 1000. ! horizontal resolution [meters] 13 rn_dz = 20. ! vertical resolution [meters] 13 14 / 14 15 ! … … 17 18 !----------------------------------------------------------------------- 18 19 nn_no = 0 ! job number (no more used...) 19 cn_exp = " overfl-FCT2-flux-ubs-ens" ! experience name20 cn_exp = "OVF_FCT2_flux_ubs" ! experience name 20 21 nn_it000 = 1 ! first time step 21 nn_itend = 12240 ! for 34h of simulation (=12240)22 nn_istate = 1! output the initial state (1) or not (0)23 nn_stock = 12240 ! frequency of creation of a restart file (modulo referenced to 1)24 nn_write = 12240 ! frequency of write in the output file (modulo referenced to nn_it000)22 nn_itend = 6120 ! here 17h of simulation (=6120 time-step) 23 nn_istate = 0 ! output the initial state (1) or not (0) 24 nn_stock = 6120 ! frequency of creation of a restart file (modulo referenced to 1) 25 nn_write = 6120 ! frequency of write in the output file (modulo referenced to nn_it000) 25 26 / 26 27 !----------------------------------------------------------------------- … … 85 86 / 86 87 !----------------------------------------------------------------------- 87 &nambbl ! bottom boundary layer scheme 88 &nambbl ! bottom boundary layer scheme ("key_trabbl") 88 89 !----------------------------------------------------------------------- 89 90 / -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/OVERFLOW/MY_SRC/usrdef_hgr.F90
r6904 r6914 46 46 !! 47 47 !! ** Method : set all intent(out) argument to a proper value 48 !! OVERFLOW configuration : uniform grid sp cing (1km)48 !! OVERFLOW configuration : uniform grid spacing (rn_dx) 49 49 !! without Coriolis force (f=0) 50 50 !! -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/OVERFLOW/MY_SRC/usrdef_istate.F90
r6906 r6914 37 37 !! 38 38 !! ** Purpose : Initialization of the dynamics and tracers 39 !! Here OVERFLOW configuration example39 !! Here OVERFLOW configuration 40 40 !! 41 41 !! ** Method : - set temprature field … … 59 59 IF(lwp) WRITE(numout,*) ' (i.e. a temperature difference of 10 degrees with rn_a0 = 0.2' 60 60 ! 61 ! rn_a0 = 2.e-1! thermal expension coefficient (nn_eos= 1)61 ! rn_a0 = 0.2 ! thermal expension coefficient (nn_eos= 1) 62 62 ! rho = rau0 - rn_a0 * (T-10) 63 63 ! delta_T = 10 degrees ==>> delta_rho = 10 * rn_a0 = 2 kg/m3 … … 68 68 ! 69 69 ! ! T & S profiles 70 zdam = 20. ! in kilometers70 zdam = 20. ! density front position in kilometers 71 71 pts(:,:,:,jp_tem) = 20._wp * ptmask(:,:,:) 72 72 DO jk = 1, jpkm1 -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/OVERFLOW/MY_SRC/usrdef_nam.F90
r6906 r6914 15 15 !!---------------------------------------------------------------------- 16 16 USE dom_oce , ONLY: nimpp , njmpp ! i- & j-indices of the local domain 17 USE dom_oce , ONLY: ln_zco, ln_zps, ln_sco ! flag of type of coordinate !!gm NOT SURE !17 USE dom_oce , ONLY: ln_zco, ln_zps, ln_sco ! flag of type of coordinate 18 18 USE par_oce ! ocean space and time domain 19 19 USE phycst ! physical constants … … 71 71 kpi = INT( 200.e3 / rn_dx ) + 2 72 72 kpj = 3 73 kpk = INT( 2.e3/ rn_dz ) + 173 kpk = INT( 2000. / rn_dz ) + 1 74 74 ! 75 75 ! ! control print -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/OVERFLOW/MY_SRC/usrdef_sbc.F90
r6900 r6914 6 6 !! 7 7 !! User defined : user defined momentum, heat and freshwater forcings 8 !!===================================================================== 8 !!====================================================================== 9 9 !! History : 4.0 ! 2016-03 (S. Flavoni, G. Madec) user defined interface 10 10 !!---------------------------------------------------------------------- -
branches/2016/dev_r6409_SIMPLIF_2_usrdef/NEMOGCM/CONFIG/OVERFLOW/MY_SRC/usrdef_zgr.F90
r6906 r6914 2 2 !!============================================================================== 3 3 !! *** MODULE usrdef_zgr *** 4 !! 5 !! === OVERFLOW case === 6 !! 4 7 !! Ocean domain : user defined vertical coordinate system 5 !!6 !! === OVERFLOW case ===7 !!8 8 !!============================================================================== 9 !! History : 4.0 ! 2016-08 (G. Madec) Original code 10 !!---------------------------------------------------------------------- 11 12 !!---------------------------------------------------------------------- 13 !! usr_def_zgr : user defined vertical coordinate system (required) 14 !! zgr_z1d : reference 1D z-coordinate 15 !! zgr_zps : 3D vertical coordinate in z-partial cell coordinate 9 !! History : 4.0 ! 2016-08 (G. Madec, S. Flavoni) Original code 10 !!---------------------------------------------------------------------- 11 12 !!---------------------------------------------------------------------- 13 !! usr_def_zgr : user defined vertical coordinate system (required) 14 !! zgr_z1d : reference 1D z-coordinate 16 15 !!--------------------------------------------------------------------- 17 USE oce 18 USE dom_oce 19 USE dom_oce , ONLY: nimpp, njmpp! ocean space and time domain20 USE dom_oce 21 USE usrdef_nam 16 USE oce ! ocean variables 17 USE dom_oce , ONLY: ln_zco, ln_zps, ln_sco ! ocean space and time domain 18 USE dom_oce , ONLY: mi0, mi1, nimpp, njmpp ! ocean space and time domain 19 USE dom_oce , ONLY: glamt ! ocean space and time domain 20 USE usrdef_nam ! User defined : namelist variables 22 21 ! 23 USE in_out_manager 24 USE lbclnk 25 USE lib_mpp 26 USE wrk_nemo 27 USE timing 22 USE in_out_manager ! I/O manager 23 USE lbclnk ! ocean lateral boundary conditions (or mpp link) 24 USE lib_mpp ! distributed memory computing library 25 USE wrk_nemo ! Memory allocation 26 USE timing ! Timing 28 27 29 28 IMPLICIT NONE … … 70 69 ! 71 70 IF(lwp) WRITE(numout,*) 72 IF(lwp) WRITE(numout,*) 'usr_def_zgr : OVERFLOW configuration (z -coordinate closed box ocean without cavities)'71 IF(lwp) WRITE(numout,*) 'usr_def_zgr : OVERFLOW configuration (z(ps)- or s-coordinate closed box ocean without cavities)' 73 72 IF(lwp) WRITE(numout,*) '~~~~~~~~~~~' 74 73 ! … … 86 85 ! 87 86 ! western continental shelf (500m deep) and eastern deep ocean (2000m deep) 87 ! (set through the jpk and jpi (see userdef_nam.F90)) 88 88 ! with a hyperbolic tangent transition centered at 40km 89 89 ! NB: here glamt is in kilometers … … 91 91 zht(:,:) = + ( 500. + 0.5 * 1500. * ( 1.0 + tanh( (glamt(:,:) - 40.) / 7. ) ) ) 92 92 ! 93 ! at u-point: recompute from glamu (see usrdef_hgr.F90) to avoid the masking when using lbc_lnk 94 zfact = rn_dx * 1.e-3 ! conversion in km 95 DO ji = 1, jpi 96 zhu(ji,:) = + ( 500. + 0.5 * 1500. * ( 1.0 + tanh( ( zfact * REAL( ji-1 + nimpp-1 , wp ) - 40.) / 7. ) ) ) 97 END DO 98 ! 93 ! at u-point: averaging zht 94 DO ji = 1, jpim1 95 zhu(ji,:) = 0.5_wp * ( zht(ji,:) + zht(ji+1,:) ) 96 END DO 97 CALL lbc_lnk( zhu, 'U', 1. ) ! boundary condition: this mask the surrouding grid-points 98 ! ! ==>>> set by hand non-zero value on first/last columns & rows 99 DO ji = mi0(1), mi1(1) ! first row of global domain only 100 zhu(ji,2) = zht(1,2) 101 END DO 102 DO ji = mi0(jpi), mi1(jpi) ! last row of global domain only 103 zhu(ji,2) = zht(jpi,2) 104 END DO 105 zhu(:,1) = zhu(:,2) 106 zhu(:,3) = zhu(:,2) 107 ! 99 108 CALL zgr_z1d( pdept_1d, pdepw_1d, pe3t_1d , pe3w_1d ) ! Reference z-coordinate system 100 109 ! … … 105 114 ! the ocean basin surrounded by land (1 grid-point) set through lbc_lnk call as jperio=0 106 115 z2d(:,:) = 1._wp ! surface ocean is the 1st level 107 CALL lbc_lnk( z2d, 'T', 1. ) ! closed basin 108 k_top(:,:) = z2d(:,:)116 CALL lbc_lnk( z2d, 'T', 1. ) ! closed basin since jperio = 0 (see userdef_nam.F90) 117 k_top(:,:) = NINT( z2d(:,:) ) 109 118 ! 110 119 ! … … 162 171 k_bot(:,:) = jpkm1 163 172 DO jk = jpkm1, 1, -1 164 WHERE( zht(:,:) < =pdepw_1d(jk) + ze3min ) k_bot(:,:) = jk-1173 WHERE( zht(:,:) < pdepw_1d(jk) + ze3min ) k_bot(:,:) = jk-1 165 174 END DO 166 175 ! … … 180 189 DO ji = 1, jpi 181 190 ik = k_bot(ji,jj) 182 IF( ik /= jpkm1 ) THEN ! last level ==> ref 1d z-coordinate183 191 pdepw(ji,jj,ik+1) = MIN( zht(ji,jj) , pdepw_1d(ik+1) ) 184 192 pe3t (ji,jj,ik ) = pdepw(ji,jj,ik+1) - pdepw(ji,jj,ik) 185 pe3t (ji,jj,ik+1) = pe3t (ji,jj,ik )193 pe3t (ji,jj,ik+1) = pe3t (ji,jj,ik ) 186 194 ! 187 pdept(ji,jj,ik ) = pdep t(ji,jj,ik-1) + pe3t(ji,jj,ik) * 0.5_wp188 p e3w (ji,jj,ik+1) = pdepw(ji,jj,ik+1) - pdepw(ji,jj,ik)189 ENDIF195 pdept(ji,jj,ik ) = pdepw(ji,jj,ik ) + pe3t (ji,jj,ik ) * 0.5_wp 196 pdept(ji,jj,ik+1) = pdepw(ji,jj,ik+1) + pe3t (ji,jj,ik+1) * 0.5_wp 197 pe3w (ji,jj,ik+1) = pdept(ji,jj,ik+1) - pdept(ji,jj,ik) ! = pe3t (ji,jj,ik ) 190 198 END DO 191 199 END DO … … 194 202 pe3u (:,:,:) = pe3t(:,:,:) ! HERE OVERFLOW configuration : 195 203 pe3v (:,:,:) = pe3t(:,:,:) ! e3 increases with i-index and identical with j-index 196 pe3f (:,:,:) = pe3t(:,:,:) ! so e3 minimum of (i,i+1) points is (i) point (idem in j-direction)197 pe3uw(:,:,:) = pe3w(:,:,:) ! 204 pe3f (:,:,:) = pe3t(:,:,:) ! so e3 minimum of (i,i+1) points is (i) point 205 pe3uw(:,:,:) = pe3w(:,:,:) ! in j-direction e3v=e3t and e3f=e3v 198 206 pe3vw(:,:,:) = pe3w(:,:,:) ! ==>> no need of lbc_lnk calls 199 207 !
Note: See TracChangeset
for help on using the changeset viewer.