[325] | 1 | MODULE dom_oce |
---|
| 2 | !!---------------------------------------------------------------------- |
---|
| 3 | !! *** MODULE dom_oce *** |
---|
| 4 | !! |
---|
| 5 | !! ** Purpose : Define in memory all the ocean space domain variables |
---|
| 6 | !!---------------------------------------------------------------------- |
---|
[343] | 7 | !! OPA 9.0 , LOCEAN-IPSL (2005) |
---|
[719] | 8 | !! $Header$ |
---|
[343] | 9 | !! This software is governed by the CeCILL licence see modipsl/doc/NEMO_CeCILL.txt |
---|
[325] | 10 | !!---------------------------------------------------------------------- |
---|
| 11 | !! * Modules used |
---|
| 12 | USE par_oce ! ocean parameters |
---|
| 13 | |
---|
| 14 | IMPLICIT NONE |
---|
| 15 | PUBLIC ! allows the acces to par_oce when dom_oce is used |
---|
| 16 | ! ! exception to coding rules... to be suppressed ??? |
---|
| 17 | |
---|
| 18 | !!---------------------------------------------------------------------- |
---|
| 19 | !! space domain parameters |
---|
| 20 | !! ----------------------- |
---|
| 21 | LOGICAL, PUBLIC :: & !: |
---|
| 22 | lzoom = .FALSE. , & !: zoom flag |
---|
| 23 | lzoom_e = .FALSE. , & !: East zoom type flag |
---|
| 24 | lzoom_w = .FALSE. , & !: West zoom type flag |
---|
| 25 | lzoom_s = .FALSE. , & !: South zoom type flag |
---|
| 26 | lzoom_n = .FALSE. , & !: North zoom type flag |
---|
| 27 | lzoom_arct = .FALSE. , & !: ORCA arctic zoom flag |
---|
| 28 | lzoom_anta = .FALSE. !: ORCA antarctic zoom flag |
---|
| 29 | |
---|
| 30 | INTEGER, PUBLIC :: & !!: namdom : space domain (bathymetry, mesh) |
---|
| 31 | nmsh = 0 !: = 1 create a mesh-mask file |
---|
| 32 | |
---|
| 33 | INTEGER, PUBLIC :: & !: |
---|
| 34 | ! domain parameters linked to mpp |
---|
| 35 | nperio, & !: type of lateral boundary condition |
---|
| 36 | nimpp, njmpp, & !: i- & j-indexes for mpp-subdomain left bottom |
---|
| 37 | nreci, nrecj, & !: overlap region in i and j |
---|
| 38 | nproc, & !: number for local processor |
---|
| 39 | narea, & !: number for local area |
---|
| 40 | nbondi, nbondj, & !: mark of i- and j-direction local boundaries |
---|
| 41 | npolj, & !: north fold mark (0, 3 or 4) |
---|
| 42 | nlci, nlcj, & !: i- & j-dimensions of the local subdomain |
---|
| 43 | nldi, nlei, & !: first and last indoor i- and j-indexes |
---|
| 44 | nldj, nlej, & !: |
---|
| 45 | noea, nowe, & !: index of the local neighboring processors in |
---|
| 46 | noso, nono, & !: east, west, south and north directions |
---|
| 47 | npne, npnw, & !: index of north east and north west processor |
---|
| 48 | npse, npsw, & !: index of south east and south west processor |
---|
| 49 | nbne, nbnw, & !: logical of north east & north west processor |
---|
[361] | 50 | nbse, nbsw, & !: logical of south east & south west processor |
---|
| 51 | nidom |
---|
[325] | 52 | |
---|
| 53 | INTEGER, PUBLIC, DIMENSION(jpi) :: & !: |
---|
| 54 | mig !: local ==> global domain i-indice |
---|
| 55 | INTEGER, PUBLIC, DIMENSION(jpj) :: & !: |
---|
| 56 | mjg !: local ==> global domain j-indice |
---|
| 57 | INTEGER, PUBLIC, DIMENSION( jpidta ) :: & !: !!bug ==> other solution? |
---|
| 58 | mi0, mi1 !: global ==> local domain i-indice |
---|
| 59 | ! ! (mi0=1 and mi1=0 if the global indice is not in the local domain) |
---|
| 60 | INTEGER, PUBLIC, DIMENSION( jpjdta ) :: & !: |
---|
| 61 | mj0, mj1 !: global ==> local domain j-indice |
---|
| 62 | ! ! (mi0=1 and mi1=0 if the global indice is not in the local domain) |
---|
| 63 | |
---|
| 64 | INTEGER, PUBLIC, DIMENSION(jpnij) :: & !: |
---|
| 65 | nimppt, njmppt, & !: i-, j-indexes for each processor |
---|
| 66 | ibonit, ibonjt, & !: i-, j- processor neighbour existence |
---|
| 67 | nlcit, nlcjt, & !: dimensions of every subdomain |
---|
| 68 | nldit, nldjt, & !: first, last indoor index for each i-domain |
---|
| 69 | nleit, nlejt !: first, last indoor index for each j-domain |
---|
| 70 | |
---|
| 71 | !!---------------------------------------------------------------------- |
---|
| 72 | !! horizontal curvilinear coordinate and scale factors |
---|
| 73 | !! --------------------------------------------------------------------- |
---|
| 74 | |
---|
| 75 | REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: & !: |
---|
| 76 | glamt, glamu, & !: longitude of t-, u-, v- and f-points (degre) |
---|
| 77 | glamv, glamf, & !: |
---|
| 78 | gphit, gphiu, & !: latitude of t-, u-, v- and f-points (degre) |
---|
| 79 | gphiv, gphif, & !: |
---|
| 80 | e1t, e2t, & !: horizontal scale factors at t-point (m) |
---|
| 81 | e1u, e2u, & !: horizontal scale factors at u-point (m) |
---|
| 82 | e1v, e2v, & !: horizontal scale factors at v-point (m) |
---|
| 83 | ff !: coriolis factor (2.*omega*sin(yphi) ) (s-1) |
---|
| 84 | |
---|
[497] | 85 | |
---|
[325] | 86 | !!---------------------------------------------------------------------- |
---|
| 87 | !! vertical coordinate and scale factors |
---|
| 88 | !! -------------------------------------- |
---|
| 89 | |
---|
[497] | 90 | LOGICAL, PUBLIC :: & !!: namzgr : vertical coordinate |
---|
| 91 | ln_zco = .TRUE. , & !: z-coordinate - full step |
---|
| 92 | ln_zps = .FALSE. , & !: z-coordinate - partial step |
---|
| 93 | ln_sco = .FALSE. !: s-coordinate or hybrid z-s coordinate |
---|
[325] | 94 | |
---|
[497] | 95 | #if defined key_zco |
---|
| 96 | LOGICAL, PUBLIC, PARAMETER :: lk_zco = .TRUE. !: z-coordinate flag (1D arrays) |
---|
| 97 | #else |
---|
| 98 | LOGICAL, PUBLIC, PARAMETER :: lk_zco = .FALSE. !: z-coordinate flag (3D arrays) |
---|
[325] | 99 | |
---|
[497] | 100 | !! All coordinates |
---|
| 101 | !! --------------- |
---|
[325] | 102 | REAL(wp), PUBLIC, DIMENSION(jpi,jpj,jpk) :: & !: |
---|
[497] | 103 | gdep3w , & !: depth of T-points (sum of e3w) (m) |
---|
| 104 | gdept , gdepw , & !: analytical depth at T-W points (m) |
---|
| 105 | e3v , e3f , & !: analytical vertical scale factors at V--F |
---|
| 106 | e3t , e3u , & !: T--U points (m) |
---|
| 107 | e3vw , & !: analytical vertical scale factors at VW-- |
---|
| 108 | e3w , e3uw !: W--UW points (m) |
---|
| 109 | #endif |
---|
| 110 | REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: & !: |
---|
| 111 | hur, hvr, & !: inverse of u and v-points ocean depth (1/m) |
---|
| 112 | hu , hv !: depth at u- and v-points (meters) |
---|
[325] | 113 | |
---|
[497] | 114 | !! z-coordinate with full steps (also used in the other cases as reference z-coordinate) |
---|
| 115 | !! =-----------------====------ |
---|
| 116 | REAL(wp), PUBLIC, DIMENSION(jpk) :: & !: |
---|
| 117 | gdept_0, gdepw_0, & !: reference depth of t- and w-points (m) |
---|
| 118 | e3t_0 , e3w_0 !: reference vertical scale factors at T- and W-pts (m) |
---|
| 119 | |
---|
| 120 | !! z-coordinate with partial steps |
---|
| 121 | !! =-----------------=======------ |
---|
| 122 | REAL(wp), PUBLIC :: & !!: * namelist namdom * |
---|
| 123 | e3zps_min = 5.0_wp, & !: miminum thickness for partial steps (meters) |
---|
| 124 | e3zps_rat = 0.1_wp !: minimum thickness ration for partial steps |
---|
| 125 | |
---|
[325] | 126 | REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: & !: |
---|
| 127 | hdept, hdepw, e3tp, e3wp !: ??? |
---|
| 128 | |
---|
[497] | 129 | !! s-coordinate and hybrid z-s-coordinate |
---|
| 130 | !! =----------------======--------------- |
---|
[325] | 131 | REAL(wp), PUBLIC, DIMENSION(jpk) :: & !: |
---|
[497] | 132 | gsigt, gsigw , & !: model level depth coefficient at t-, w-levels (analytic) |
---|
| 133 | gsi3w , & !: model level depth coefficient at w-level (sum of gsigw) |
---|
[325] | 134 | esigt, esigw !: vertical scale factor coef. at t-, w-levels |
---|
| 135 | |
---|
[497] | 136 | REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: & !: |
---|
| 137 | hbatv , hbatf , & !: ocean depth at the vertical of V--F |
---|
| 138 | hbatt , hbatu , & !: T--U points (m) |
---|
| 139 | scosrf, scobot, & !: ocean surface and bottom topographies (if deviating from coordinate surfaces in HYBRID) |
---|
| 140 | hifv , hiff , & !: interface depth between stretching at V--F |
---|
| 141 | hift , hifu !: and quasi-uniform spacing T--U points (m) |
---|
| 142 | |
---|
| 143 | |
---|
[325] | 144 | !!---------------------------------------------------------------------- |
---|
| 145 | !! masks, bathymetry |
---|
| 146 | !! ----------------- |
---|
| 147 | |
---|
| 148 | INTEGER , PUBLIC, DIMENSION(jpi,jpj) :: & !: |
---|
| 149 | mbathy !: number of ocean level (=0, 1, ... , jpk-1) |
---|
| 150 | |
---|
| 151 | REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: & !: |
---|
| 152 | tmask_i !: interior domain T-point mask |
---|
| 153 | |
---|
| 154 | REAL(wp), PUBLIC, DIMENSION(jpi,jpj,jpk) :: & !: |
---|
| 155 | tmask, umask, & !: land/ocean mask at T-, U-, V- and F-points |
---|
| 156 | vmask, fmask !: |
---|
| 157 | |
---|
| 158 | REAL(wp), PUBLIC, DIMENSION(jpiglo) :: & !: |
---|
| 159 | tpol !: north fold mask (nperio= 3 or 4) |
---|
| 160 | |
---|
| 161 | !!---------------------------------------------------------------------- |
---|
| 162 | !! time domain |
---|
| 163 | !!---------------------------------------------------------------------- |
---|
| 164 | INTEGER, PUBLIC :: & !!: * Namelist * ??? |
---|
| 165 | nacc = 0 , & !: = 0/1 use of the acceleration of convergence technique |
---|
| 166 | neuler !: restart euler forward option (0=Euler) |
---|
| 167 | |
---|
| 168 | |
---|
| 169 | REAL(wp), PUBLIC :: & !!: * Namelist ??? * |
---|
| 170 | rdt = 3600._wp , & !: time step for the dynamics (and tracer if nacc=0) |
---|
| 171 | rdtmin = 3600._wp , & !: minimum time step on tracers |
---|
| 172 | rdtmax = 3600._wp , & !: maximum time step on tracers |
---|
| 173 | rdth = 800._wp , & !: depth variation of tracer step |
---|
| 174 | atfp = 0.1_wp , & !: asselin time filter parameter |
---|
| 175 | atfp1 !: asselin time filter coeff. (atfp1= 1-2*atfp) |
---|
| 176 | |
---|
| 177 | REAL(wp), PUBLIC, DIMENSION(jpk) :: & !: |
---|
| 178 | rdttra !: vertical profile of tracer time step |
---|
| 179 | |
---|
| 180 | !!---------------------------------------------------------------------- |
---|
| 181 | !! cross land advection |
---|
| 182 | !!---------------------------------------------------------------------- |
---|
| 183 | |
---|
| 184 | INTEGER, PUBLIC :: & !!: namelist ??? |
---|
| 185 | n_cla !: flag (0/1) for cross land advection to |
---|
| 186 | ! ! parameterize exchanges through straits |
---|
| 187 | |
---|
[497] | 188 | #if defined key_off_degrad |
---|
| 189 | !! ------------------------------------------------ |
---|
| 190 | !! Degradation method |
---|
| 191 | !! -------------------------------------------------- |
---|
| 192 | REAL(wp), PUBLIC, DIMENSION (jpi,jpj,jpk) :: & |
---|
| 193 | facvol !! volume for degraded regions |
---|
| 194 | #endif |
---|
| 195 | |
---|
[325] | 196 | !!---------------------------------------------------------------------- |
---|
| 197 | END MODULE dom_oce |
---|