[186] | 1 | MODULE oce_trc |
---|
| 2 | !!====================================================================== |
---|
| 3 | !! *** MODULE oce_trc *** |
---|
[945] | 4 | !! TOP : variables shared between ocean and passive tracers |
---|
[186] | 5 | !!====================================================================== |
---|
[945] | 6 | !! History : 1.0 ! 2004-03 (C. Ethe) original code |
---|
| 7 | !! 2.0 ! 2007-12 (C. Ethe, G. Madec) rewritting |
---|
[186] | 8 | !!---------------------------------------------------------------------- |
---|
[945] | 9 | !! NEMO/TOP 2.0, LOCEAN-IPSL (2007) |
---|
[1152] | 10 | !! $Id$ |
---|
[945] | 11 | !! Software governed by the CeCILL licence (modipsl/doc/NEMO_CeCILL.txt) |
---|
[186] | 12 | !!---------------------------------------------------------------------- |
---|
[945] | 13 | #if defined key_top |
---|
| 14 | !!---------------------------------------------------------------------- |
---|
| 15 | !! 'key_top' TOP models |
---|
| 16 | !!---------------------------------------------------------------------- |
---|
[186] | 17 | |
---|
[945] | 18 | !* Domain size * |
---|
| 19 | USE par_oce , ONLY : cp_cfg => cp_cfg !: name of the configuration |
---|
| 20 | USE par_oce , ONLY : jp_cfg => jp_cfg !: resolution of the configuration |
---|
| 21 | USE par_oce , ONLY : jpiglo => jpiglo !: first dimension of global domain --> i |
---|
| 22 | USE par_oce , ONLY : jpjglo => jpjglo !: second dimension of global domain --> j |
---|
| 23 | USE par_oce , ONLY : jpi => jpi !: first dimension of grid --> i |
---|
| 24 | USE par_oce , ONLY : jpj => jpj !: second dimension of grid --> j |
---|
| 25 | USE par_oce , ONLY : jpk => jpk !: number of levels |
---|
| 26 | USE par_oce , ONLY : jpim1 => jpim1 !: jpi - 1 |
---|
| 27 | USE par_oce , ONLY : jpjm1 => jpjm1 !: jpj - 1 |
---|
| 28 | USE par_oce , ONLY : jpkm1 => jpkm1 !: jpk - 1 |
---|
| 29 | USE par_oce , ONLY : jpij => jpij !: jpi x jpj |
---|
| 30 | USE par_oce , ONLY : jpidta => jpidta !: first horizontal dimension > or = jpi |
---|
| 31 | USE par_oce , ONLY : jpjdta => jpjdta !: second horizontal dimension > or = jpj |
---|
| 32 | USE par_oce , ONLY : jpkdta => jpkdta !: number of levels > or = jpk |
---|
| 33 | USE par_oce , ONLY : lk_esopa => lk_esopa !: flag to activate the all option |
---|
[186] | 34 | |
---|
[945] | 35 | !* IO manager * |
---|
| 36 | USE in_out_manager ! use all the variables |
---|
| 37 | !* physical constants * |
---|
| 38 | USE phycst ! use all the variables |
---|
[186] | 39 | |
---|
[945] | 40 | !* model domain * |
---|
| 41 | USE dom_oce , ONLY : lzoom => lzoom !: zoom flag |
---|
| 42 | USE dom_oce , ONLY : lzoom_e => lzoom_e !: East zoom type flag |
---|
| 43 | USE dom_oce , ONLY : lzoom_w => lzoom_w !: West zoom type flag |
---|
| 44 | USE dom_oce , ONLY : lzoom_s => lzoom_s !: South zoom type flag |
---|
| 45 | USE dom_oce , ONLY : lzoom_n => lzoom_n !: North zoom type flag |
---|
| 46 | USE dom_oce , ONLY : lzoom_arct => lzoom_arct !: ORCA arctic zoom flag |
---|
| 47 | USE dom_oce , ONLY : lzoom_anta => lzoom_anta !: ORCA antarctic zoom flag |
---|
| 48 | USE dom_oce , ONLY : nperio => nperio !: type of lateral boundary condition |
---|
| 49 | USE dom_oce , ONLY : nimpp => nimpp !: i index for mpp-subdomain left bottom |
---|
| 50 | USE dom_oce , ONLY : njmpp => njmpp !: j index for mpp-subdomain left bottom |
---|
| 51 | USE dom_oce , ONLY : nproc => nproc !: number for local processor |
---|
| 52 | USE dom_oce , ONLY : narea => narea !: number for local area |
---|
| 53 | USE dom_oce , ONLY : mig => mig !: local ==> global domain i-indice |
---|
| 54 | USE dom_oce , ONLY : mjg => mjg !: local ==> global domain i-indice |
---|
| 55 | USE dom_oce , ONLY : mi0 => mi0 !: global ==> local domain i-indice |
---|
| 56 | USE dom_oce , ONLY : mi1 => mi1 !: (mi0=1 and mi1=0 if the global indice is not in the local one) |
---|
| 57 | USE dom_oce , ONLY : mj0 => mj0 !: global ==> local domain j-indice |
---|
| 58 | USE dom_oce , ONLY : mj1 => mj1 !: (mj0=1 and mj1=0 if the global indice is not in the local one) |
---|
| 59 | USE dom_oce , ONLY : nidom => nidom |
---|
| 60 | USE dom_oce , ONLY : nimppt => nimppt !:i-indexes for each processor |
---|
| 61 | USE dom_oce , ONLY : njmppt => njmppt !:j-indexes for each processor |
---|
| 62 | USE dom_oce , ONLY : ibonit => ibonit !:i-processor neighbour existence |
---|
| 63 | USE dom_oce , ONLY : ibonjt => ibonjt !:j- processor neighbour existence |
---|
| 64 | USE dom_oce , ONLY : nlci => nlci !:i- & j-dimensions of the local subdomain |
---|
| 65 | USE dom_oce , ONLY : nlcj => nlcj !: |
---|
| 66 | USE dom_oce , ONLY : nldi => nldi !:first and last indoor i- and j-indexes |
---|
| 67 | USE dom_oce , ONLY : nlei => nlei !: |
---|
| 68 | USE dom_oce , ONLY : nldj => nldj !: |
---|
| 69 | USE dom_oce , ONLY : nlej => nlej !: |
---|
| 70 | USE dom_oce , ONLY : nlcit => nlcit !:dimensions of every i-subdomain |
---|
| 71 | USE dom_oce , ONLY : nlcjt => nlcjt !:dimensions of every j-subdomain |
---|
| 72 | USE dom_oce , ONLY : nldit => nldit !:first indoor index for each i-domain |
---|
| 73 | USE dom_oce , ONLY : nleit => nleit !:last indoor index for each i-domain |
---|
| 74 | USE dom_oce , ONLY : nldjt => nldjt !:first indoor index for each j-domain |
---|
| 75 | USE dom_oce , ONLY : nlejt => nlejt !:last indoor index for each j-domain |
---|
[335] | 76 | |
---|
[945] | 77 | !* horizontal mesh * |
---|
| 78 | USE dom_oce , ONLY : glamt => glamt !: longitude of t-point (degre) |
---|
| 79 | USE dom_oce , ONLY : glamu => glamu !: longitude of t-point (degre) |
---|
| 80 | USE dom_oce , ONLY : glamv => glamv !: longitude of t-point (degre) |
---|
| 81 | USE dom_oce , ONLY : glamf => glamf !: longitude of t-point (degre) |
---|
| 82 | USE dom_oce , ONLY : gphit => gphit !: latitude of t-point (degre) |
---|
| 83 | USE dom_oce , ONLY : gphiu => gphiu !: latitude of t-point (degre) |
---|
| 84 | USE dom_oce , ONLY : gphiv => gphiv !: latitude of t-point (degre) |
---|
| 85 | USE dom_oce , ONLY : gphif => gphif !: latitude of t-point (degre) |
---|
| 86 | USE dom_oce , ONLY : e1t => e1t !: horizontal scale factors at t-point (m) |
---|
| 87 | USE dom_oce , ONLY : e2t => e2t !: horizontal scale factors at t-point (m) |
---|
| 88 | USE dom_oce , ONLY : e1u => e1u !: horizontal scale factors at u-point (m) |
---|
| 89 | USE dom_oce , ONLY : e2u => e2u !: horizontal scale factors at u-point (m) |
---|
| 90 | USE dom_oce , ONLY : e1v => e1v !: horizontal scale factors at v-point (m) |
---|
| 91 | USE dom_oce , ONLY : e2v => e2v !: horizontal scale factors at v-point (m) |
---|
[335] | 92 | |
---|
[945] | 93 | !* vertical mesh * |
---|
| 94 | USE dom_oce , ONLY : gdept_0 => gdept_0 !: reference depth of t-points (m) |
---|
| 95 | USE dom_oce , ONLY : e3t_0 => e3t_0 !: reference depth of t-points (m) |
---|
| 96 | USE dom_oce , ONLY : e3w_0 => e3w_0 !: reference depth of w-points (m) |
---|
| 97 | USE dom_oce , ONLY : gdepw_0 => gdepw_0 !: reference depth of w-points (m) |
---|
| 98 | # if ! defined key_zco |
---|
| 99 | USE dom_oce , ONLY : gdep3w => gdep3w !: ??? |
---|
| 100 | USE dom_oce , ONLY : gdept => gdept !: depth of t-points (m) |
---|
| 101 | USE dom_oce , ONLY : gdepw => gdepw !: depth of t-points (m) |
---|
| 102 | USE dom_oce , ONLY : e3t => e3t !: vertical scale factors at t- |
---|
| 103 | USE dom_oce , ONLY : e3u => e3u !: vertical scale factors at u- |
---|
| 104 | USE dom_oce , ONLY : e3v => e3v !: vertical scale factors v- |
---|
| 105 | USE dom_oce , ONLY : e3w => e3w !: w-points (m) |
---|
| 106 | USE dom_oce , ONLY : e3f => e3f !: f-points (m) |
---|
| 107 | USE dom_oce , ONLY : e3uw => e3uw !: uw-points (m) |
---|
| 108 | USE dom_oce , ONLY : e3vw => e3vw !: vw-points (m) |
---|
| 109 | # endif |
---|
| 110 | USE dom_oce , ONLY : ln_zps => ln_zps !: partial steps flag |
---|
| 111 | USE dom_oce , ONLY : ln_sco => ln_sco !: s-coordinate flag |
---|
| 112 | USE dom_oce , ONLY : ln_zco => ln_zco !: z-coordinate flag |
---|
| 113 | USE dom_oce , ONLY : lk_zco => lk_zco !: z-coordinate flag (1D or 3D arrays) |
---|
[1753] | 114 | USE dom_oce , ONLY : hbatt => hbatt !: ocean depth at the vertical of t-point (m) |
---|
| 115 | USE dom_oce , ONLY : hbatu => hbatu !: ocean depth at the vertical of u-point (m) |
---|
| 116 | USE dom_oce , ONLY : hbatv => hbatv !: ocean depth at the vertical of w-point (m) |
---|
| 117 | USE dom_oce , ONLY : gsigt => gsigt !: model level depth coefficient at T-levels |
---|
| 118 | USE dom_oce , ONLY : gsigw => gsigw !: model level depth coefficient at W-levels |
---|
| 119 | USE dom_oce , ONLY : gsi3w => gsi3w !: model level depth coef at w-levels (defined as the sum of e3w) |
---|
| 120 | USE dom_oce , ONLY : esigt => esigt !: vertical scale factor coef. at t-levels |
---|
| 121 | USE dom_oce , ONLY : esigw => esigw !: vertical scale factor coef. at w-levels |
---|
| 122 | USE dom_oce , ONLY : lk_vvl => lk_vvl !: variable grid flag |
---|
[186] | 123 | |
---|
[945] | 124 | !* masks, bathymetry * |
---|
[1753] | 125 | USE dom_oce , ONLY : mbathy => mbathy !: number of ocean level (=0, & 1, ... , jpk-1) |
---|
| 126 | USE dom_oce , ONLY : tmask_i => tmask_i !: Interior mask at t-points |
---|
| 127 | USE dom_oce , ONLY : tmask => tmask !: land/ocean mask at t-points |
---|
| 128 | USE dom_oce , ONLY : umask => umask !: land/ocean mask at u-points |
---|
| 129 | USE dom_oce , ONLY : vmask => vmask !: land/ocean mask at v-points |
---|
| 130 | USE dom_oce , ONLY : fmask => fmask !: land/ocean mask at f-points |
---|
[945] | 131 | # if defined key_off_degrad |
---|
[1753] | 132 | USE dom_oce , ONLY : facvol => facvol !: volume factor for degradation |
---|
[945] | 133 | # endif |
---|
[186] | 134 | |
---|
[945] | 135 | !* time domain * |
---|
[1753] | 136 | USE dom_oce , ONLY : neuler => neuler !: restart euler forward option (0=Euler) |
---|
| 137 | USE dom_oce , ONLY : rdt => rdt !: time step for the dynamics |
---|
| 138 | USE dom_oce , ONLY : atfp => atfp !: asselin time filter parameter |
---|
| 139 | USE dom_oce , ONLY : atfp1 => atfp1 !: asselin time filter coeff. (atfp1= 1-2*atfp) |
---|
| 140 | USE dom_oce , ONLY : rdttra => rdttra !: vertical profile of tracer time step |
---|
[1329] | 141 | ! !: it is the accumulated duration of previous runs |
---|
| 142 | ! !: that may have been run with different time steps. |
---|
[1753] | 143 | !* calendar variables * |
---|
| 144 | USE dom_oce , ONLY : nyear => nyear !: current year |
---|
| 145 | USE dom_oce , ONLY : nmonth => nmonth !: current month |
---|
| 146 | USE dom_oce , ONLY : nday => nday !: current day of the month |
---|
| 147 | USE dom_oce , ONLY : ndastp => ndastp !: time step date in yyyymmdd format |
---|
| 148 | USE dom_oce , ONLY : nday_year => nday_year !: current day counted from jan 1st of the current year |
---|
| 149 | USE dom_oce , ONLY : nsec_year => nsec_year !: current time step counted in second since 00h jan 1st of the current year |
---|
| 150 | USE dom_oce , ONLY : nsec_month => nsec_month !: current time step counted in second since 00h 1st day of the current month |
---|
| 151 | USE dom_oce , ONLY : nsec_day => nsec_day !: current time step counted in second since 00h of the current day |
---|
| 152 | USE dom_oce , ONLY : fjulday => fjulday !: julian day |
---|
| 153 | USE dom_oce , ONLY : adatrj => adatrj !: number of elapsed days since the begining of the whole simulation |
---|
| 154 | !: (cumulative duration of previous runs |
---|
| 155 | !: that may have used different time-step size) |
---|
| 156 | USE dom_oce , ONLY : nyear_len => nyear_len !: length in days of the previous/current year |
---|
| 157 | USE dom_oce , ONLY : nmonth_len => nmonth_len !: length in days of the months of the current year |
---|
[499] | 158 | |
---|
[1753] | 159 | |
---|
[945] | 160 | !* ocean fields: here now and after fields * |
---|
| 161 | USE oce , ONLY : ua => ua !: i-horizontal velocity (m s-1) |
---|
| 162 | USE oce , ONLY : va => va !: j-horizontal velocity (m s-1) |
---|
| 163 | USE oce , ONLY : un => un !: i-horizontal velocity (m s-1) |
---|
| 164 | USE oce , ONLY : vn => vn !: j-horizontal velocity (m s-1) |
---|
| 165 | USE oce , ONLY : wn => wn !: vertical velocity (m s-1) |
---|
| 166 | USE oce , ONLY : tn => tn !: pot. temperature (celsius) |
---|
| 167 | USE oce , ONLY : sn => sn !: salinity (psu) |
---|
| 168 | USE oce , ONLY : rhop => rhop !: potential volumic mass (kg m-3) |
---|
| 169 | USE oce , ONLY : rhd => rhd !: in situ density anomalie rhd=(rho-rau0)/rau0 (no units) |
---|
| 170 | USE oce , ONLY : hdivn => hdivn !: horizontal divergence (1/s) |
---|
[1329] | 171 | #if defined key_off_tra |
---|
| 172 | USE oce , ONLY : gtu => gtu !: t-, s- and rd horizontal gradient at u- and |
---|
| 173 | USE oce , ONLY : gsu => gsu !: v-points at bottom ocean level |
---|
| 174 | USE oce , ONLY : gru => gru !: |
---|
| 175 | USE oce , ONLY : gtv => gtv !: |
---|
| 176 | USE oce , ONLY : gsv => gsv !: |
---|
| 177 | USE oce , ONLY : grv => grv !: |
---|
| 178 | #endif |
---|
[945] | 179 | USE lib_mpp , ONLY : lk_mpp => lk_mpp !: Mpp flag |
---|
[201] | 180 | |
---|
[945] | 181 | USE dom_oce , ONLY : n_cla => n_cla !: flag (0/1) for cross land advection |
---|
[186] | 182 | |
---|
[945] | 183 | !* surface fluxes * |
---|
| 184 | USE sbc_oce , ONLY : utau => utau !: i-surface stress component |
---|
| 185 | USE sbc_oce , ONLY : vtau => vtau !: j-surface stress component |
---|
[1011] | 186 | USE sbc_oce , ONLY : wndm => wndm !: 10m wind speed |
---|
[945] | 187 | USE sbc_oce , ONLY : qsr => qsr !: penetrative solar radiation (w m-2) |
---|
| 188 | USE sbc_oce , ONLY : emp => emp !: evaporation minus precipitation (kg m-2 s-2) |
---|
| 189 | USE sbc_oce , ONLY : emps => emps !: evaporation minus precipitation (kg m-2 s-2) |
---|
[1034] | 190 | USE sbc_oce , ONLY : fr_i => fr_i !: ice fraction (between 0 to 1) |
---|
[1445] | 191 | USE traqsr , ONLY : rn_abs => rn_abs !: fraction absorbed in the very near surface |
---|
| 192 | USE traqsr , ONLY : rn_si0 => rn_si0 !: very near surface depth of extinction |
---|
| 193 | USE traqsr , ONLY : rn_si2 => rn_si2 !: deepest depth of extinction (blue & 0.01 mg.m-3) (RGB) |
---|
| 194 | USE traqsr , ONLY : ln_qsr_bio => ln_qsr_bio !: flag to use or not the biological fluxes for light |
---|
[945] | 195 | USE sbcrnf , ONLY : rnfmsk => rnfmsk !: mixed adv scheme in runoffs vicinity (hori.) |
---|
| 196 | USE sbcrnf , ONLY : rnfmsk_z => rnfmsk_z !: mixed adv scheme in runoffs vicinity (vert.) |
---|
[186] | 197 | |
---|
[945] | 198 | !* bottom boundary layer * |
---|
| 199 | # if defined key_trabbl_dif || defined key_trabbl_adv |
---|
[1644] | 200 | # if ! defined key_off_tra |
---|
[1606] | 201 | USE trabbl , ONLY : atrbbl => rn_ahtbbl !: lateral coeff. for bottom boundary layer scheme (m2/s) |
---|
[1644] | 202 | # else |
---|
[945] | 203 | USE trabbl, ONLY : bblx => bblx !: ??? |
---|
| 204 | USE trabbl, ONLY : bbly => bbly !: ??? |
---|
[335] | 205 | # endif |
---|
[945] | 206 | # endif |
---|
[201] | 207 | |
---|
[945] | 208 | !* lateral diffusivity (tracers) * |
---|
| 209 | USE ldftra_oce , ONLY : aht0 => aht0 !: horizontal eddy diffusivity for tracers (m2/s) |
---|
| 210 | USE ldftra_oce , ONLY : ahtb0 => ahtb0 !: background eddy diffusivity for isopycnal diff. (m2/s) |
---|
| 211 | USE ldftra_oce , ONLY : ahtu => ahtu !: lateral diffusivity coef. at u-points |
---|
| 212 | USE ldftra_oce , ONLY : ahtv => ahtv !: lateral diffusivity coef. at v-points |
---|
| 213 | USE ldftra_oce , ONLY : ahtw => ahtw !: lateral diffusivity coef. at w-points |
---|
| 214 | USE ldftra_oce , ONLY : ahtt => ahtt !: lateral diffusivity coef. at t-points |
---|
| 215 | USE ldftra_oce , ONLY : aeiv0 => aeiv0 !: eddy induced velocity coefficient (m2/s) |
---|
| 216 | USE ldftra_oce , ONLY : aeiu => aeiu !: eddy induced velocity coef. at u-points (m2/s) |
---|
| 217 | USE ldftra_oce , ONLY : aeiv => aeiv !: eddy induced velocity coef. at v-points (m2/s) |
---|
| 218 | USE ldftra_oce , ONLY : aeiw => aeiw !: eddy induced velocity coef. at w-points (m2/s) |
---|
[186] | 219 | |
---|
[945] | 220 | !* vertical diffusion * |
---|
| 221 | USE zdf_oce , ONLY : avt => avt !: vert. diffusivity coef. at w-point for temp |
---|
| 222 | # if defined key_zdfddm |
---|
| 223 | USE zdfddm , ONLY : avs => avs !: salinity vertical diffusivity coeff. at w-point |
---|
| 224 | # endif |
---|
[186] | 225 | |
---|
[945] | 226 | !* mixing & mixed layer depth * |
---|
[1177] | 227 | USE zdfmxl , ONLY : nmln => nmln !: number of level in the mixed layer |
---|
[945] | 228 | USE zdfmxl , ONLY : hmld => hmld !: mixing layer depth (turbocline) |
---|
| 229 | USE zdfmxl , ONLY : hmlp => hmlp !: mixed layer depth (rho=rho0+zdcrit) (m) |
---|
| 230 | USE zdfmxl , ONLY : hmlpt => hmlpt !: mixed layer depth at t-points (m) |
---|
[281] | 231 | |
---|
[945] | 232 | !* direction of lateral diffusion * |
---|
| 233 | USE ldfslp , ONLY : lk_ldfslp => lk_ldfslp !: slopes flag |
---|
| 234 | # if defined key_ldfslp |
---|
| 235 | USE ldfslp , ONLY : uslp => uslp !: i-direction slope at u-, w-points |
---|
| 236 | USE ldfslp , ONLY : vslp => vslp !: j-direction slope at v-, w-points |
---|
| 237 | USE ldfslp , ONLY : wslpi => wslpi !: i-direction slope at u-, w-points |
---|
| 238 | USE ldfslp , ONLY : wslpj => wslpj !: j-direction slope at v-, w-points |
---|
| 239 | # endif |
---|
[201] | 240 | |
---|
[945] | 241 | #else |
---|
| 242 | !!---------------------------------------------------------------------- |
---|
| 243 | !! Empty module : No passive tracer |
---|
| 244 | !!---------------------------------------------------------------------- |
---|
[186] | 245 | #endif |
---|
[201] | 246 | |
---|
[945] | 247 | !!====================================================================== |
---|
[186] | 248 | END MODULE oce_trc |
---|