1 | MODULE p2zbio |
---|
2 | !!====================================================================== |
---|
3 | !! *** MODULE p2zbio *** |
---|
4 | !! TOP : LOBSTER |
---|
5 | !!====================================================================== |
---|
6 | !! History : - ! 1999-07 (M. Levy) Original code |
---|
7 | !! - ! 2000-12 (E. Kestenare) assign a parameter to name individual tracers |
---|
8 | !! - ! 2001-03 (M. Levy) LNO3 + dia2d |
---|
9 | !! 2.0 ! 2007-12 (C. Deltel, G. Madec) F90 |
---|
10 | !!---------------------------------------------------------------------- |
---|
11 | #if defined key_pisces_reduced |
---|
12 | !!---------------------------------------------------------------------- |
---|
13 | !! 'key_pisces_reduced' LOBSTER bio-model |
---|
14 | !!---------------------------------------------------------------------- |
---|
15 | !! p2z_bio : |
---|
16 | !!---------------------------------------------------------------------- |
---|
17 | USE oce_trc ! |
---|
18 | USE trc ! |
---|
19 | USE sms_pisces |
---|
20 | USE p2zopt |
---|
21 | USE lbclnk ! |
---|
22 | USE prtctl_trc ! Print control for debbuging |
---|
23 | USE trd_oce |
---|
24 | USE trdtrc |
---|
25 | USE iom |
---|
26 | |
---|
27 | IMPLICIT NONE |
---|
28 | PRIVATE |
---|
29 | |
---|
30 | PUBLIC p2z_bio ! called in ??? |
---|
31 | PUBLIC p2z_bio_init ! called in ??? |
---|
32 | |
---|
33 | REAL(wp) :: tmumax ! maximal phytoplankton growth rate [s-1] |
---|
34 | REAL(wp) :: rgamma ! phytoplankton exudation fraction [%] |
---|
35 | REAL(wp) :: fphylab ! NH4 fraction of phytoplankton exsudation |
---|
36 | REAL(wp) :: tmminp ! minimal phytoplancton mortality rate [0.05/86400 s-1=20 days] |
---|
37 | REAL(wp) :: aki ! light photosynthesis half saturation constant[W/m2] |
---|
38 | ! |
---|
39 | REAL(wp) :: akno3 ! nitrate limitation half-saturation value [mmol/m3] |
---|
40 | REAL(wp) :: aknh4 ! ammonium limitation half-saturation value [mmol/m3] |
---|
41 | REAL(wp) :: taunn ! nitrification rate [s-1] |
---|
42 | REAL(wp) :: psinut ! inhibition of nitrate uptake by ammonium |
---|
43 | ! |
---|
44 | REAL(wp) :: taudn ! detritus breakdown rate [0.1/86400 s-1=10 days] |
---|
45 | REAL(wp) :: fdetlab ! NH4 fraction of detritus dissolution |
---|
46 | ! |
---|
47 | REAL(wp) :: taudomn ! DOM breakdown rate [s-1] |
---|
48 | ! ! slow remineralization rate of semi-labile dom to nh4 (1 month) |
---|
49 | ! |
---|
50 | REAL(wp) :: rppz ! ivlev coeff for zoo mortality |
---|
51 | REAL(wp) :: taus ! specific zooplankton maximal grazing rate [s-1] |
---|
52 | ! ! 0.75/86400 s-1=8.680555E-6 1/86400 = 1.15e-5 |
---|
53 | REAL(wp) :: aks ! half-saturation constant for total zooplankton grazing [mmolN.m-3] |
---|
54 | REAL(wp) :: rpnaz ! non-assimilated phytoplankton by zooplancton [%] |
---|
55 | REAL(wp) :: rdnaz ! non-assimilated detritus by zooplankton [%] |
---|
56 | REAL(wp) :: tauzn ! zooplancton specific excretion rate [0.1/86400 s-1=10 days] |
---|
57 | REAL(wp) :: tmminz ! minimal zooplankton mortality rate [(mmolN/m3)-1 d-1] |
---|
58 | REAL(wp) :: fzoolab ! NH4 fraction of zooplankton excretion |
---|
59 | REAL(wp) :: fdbod ! zooplankton mortality fraction that goes to detritus |
---|
60 | |
---|
61 | !! * Substitutions |
---|
62 | # include "vectopt_loop_substitute.h90" |
---|
63 | !!---------------------------------------------------------------------- |
---|
64 | !! NEMO/TOP 3.3 , NEMO Consortium (2010) |
---|
65 | !! $Id$ |
---|
66 | !! Software governed by the CeCILL licence (NEMOGCM/NEMO_CeCILL.txt) |
---|
67 | !!---------------------------------------------------------------------- |
---|
68 | CONTAINS |
---|
69 | |
---|
70 | SUBROUTINE p2z_bio( kt ) |
---|
71 | !!--------------------------------------------------------------------- |
---|
72 | !! *** ROUTINE p2z_bio *** |
---|
73 | !! |
---|
74 | !! ** Purpose : compute the now trend due to biogeochemical processes |
---|
75 | !! and add it to the general trend of passive tracers equations |
---|
76 | !! |
---|
77 | !! ** Method : each now biological flux is calculated in function of now |
---|
78 | !! concentrations of tracers. |
---|
79 | !! depending on the tracer, these fluxes are sources or sinks. |
---|
80 | !! the total of the sources and sinks for each tracer |
---|
81 | !! is added to the general trend. |
---|
82 | !! |
---|
83 | !! tra = tra + zf...tra - zftra... |
---|
84 | !! | | |
---|
85 | !! | | |
---|
86 | !! source sink |
---|
87 | !! |
---|
88 | !! IF 'key_diabio' defined , the biogeochemical trends |
---|
89 | !! for passive tracers are saved for futher diagnostics. |
---|
90 | !!--------------------------------------------------------------------- |
---|
91 | !! |
---|
92 | INTEGER, INTENT( in ) :: kt ! ocean time-step index |
---|
93 | !! |
---|
94 | INTEGER :: ji, jj, jk, jl |
---|
95 | REAL(wp) :: zdet, zzoo, zphy, zno3, znh4, zdom ! now concentrations |
---|
96 | REAL(wp) :: zlno3, zlnh4, zle, zlt ! limitation terms for phyto |
---|
97 | REAL(wp) :: zno3phy, znh4phy, zphynh4, zphydom |
---|
98 | REAL(wp) :: zphydet, zphyzoo, zdetzoo |
---|
99 | REAL(wp) :: zzoonh4, zzoodom, zzoodet, zdetnh4, zdetdom |
---|
100 | REAL(wp) :: znh4no3, zdomnh4, zppz, zpdz, zpppz, zppdz, zfood |
---|
101 | REAL(wp) :: zfilpz, zfildz, zphya, zzooa, zno3a |
---|
102 | REAL(wp) :: znh4a, zdeta, zdoma, zzoobod, zboddet, zdomaju |
---|
103 | REAL(wp) :: ze3t |
---|
104 | REAL(wp), POINTER, DIMENSION(:,:,:) :: zw2d |
---|
105 | REAL(wp), POINTER, DIMENSION(:,:,:,:) :: zw3d |
---|
106 | CHARACTER (len=25) :: charout |
---|
107 | !!--------------------------------------------------------------------- |
---|
108 | ! |
---|
109 | IF( nn_timing == 1 ) CALL timing_start('p2z_bio') |
---|
110 | ! |
---|
111 | IF( ln_diatrc .OR. lk_iomput ) THEN |
---|
112 | CALL wrk_alloc( jpi, jpj, 17, zw2d ) |
---|
113 | CALL wrk_alloc( jpi, jpj, jpk, 3, zw3d ) |
---|
114 | ENDIF |
---|
115 | |
---|
116 | IF( kt == nittrc000 ) THEN |
---|
117 | IF(lwp) WRITE(numout,*) |
---|
118 | IF(lwp) WRITE(numout,*) ' p2z_bio: LOBSTER bio-model' |
---|
119 | IF(lwp) WRITE(numout,*) ' ~~~~~~~' |
---|
120 | ENDIF |
---|
121 | |
---|
122 | xksi(:,:) = 0.e0 ! zooplakton closure ( fbod) |
---|
123 | IF( ln_diatrc .OR. lk_iomput ) THEN |
---|
124 | zw2d (:,:,:) = 0.e0 |
---|
125 | zw3d(:,:,:,:) = 0.e0 |
---|
126 | ENDIF |
---|
127 | |
---|
128 | ! ! -------------------------- ! |
---|
129 | DO jk = 1, jpkbm1 ! Upper ocean (bio-layers) ! |
---|
130 | ! ! -------------------------- ! |
---|
131 | DO jj = 2, jpjm1 |
---|
132 | DO ji = fs_2, fs_jpim1 |
---|
133 | ! trophic variables( det, zoo, phy, no3, nh4, dom) |
---|
134 | ! ------------------------------------------------ |
---|
135 | |
---|
136 | ! negative trophic variables DO not contribute to the fluxes |
---|
137 | zdet = MAX( 0.e0, trn(ji,jj,jk,jpdet) ) |
---|
138 | zzoo = MAX( 0.e0, trn(ji,jj,jk,jpzoo) ) |
---|
139 | zphy = MAX( 0.e0, trn(ji,jj,jk,jpphy) ) |
---|
140 | zno3 = MAX( 0.e0, trn(ji,jj,jk,jpno3) ) |
---|
141 | znh4 = MAX( 0.e0, trn(ji,jj,jk,jpnh4) ) |
---|
142 | zdom = MAX( 0.e0, trn(ji,jj,jk,jpdom) ) |
---|
143 | |
---|
144 | ! Limitations |
---|
145 | zlt = 1. |
---|
146 | zle = 1. - EXP( -etot(ji,jj,jk) / aki / zlt ) |
---|
147 | ! psinut,akno3,aknh4 added by asklod AS Kremeur 2005-03 |
---|
148 | zlno3 = zno3 * EXP( -psinut * znh4 ) / ( akno3 + zno3 ) |
---|
149 | zlnh4 = znh4 / (znh4+aknh4) |
---|
150 | |
---|
151 | ! sinks and sources |
---|
152 | ! phytoplankton production and exsudation |
---|
153 | zno3phy = tmumax * zle * zlt * zlno3 * zphy |
---|
154 | znh4phy = tmumax * zle * zlt * zlnh4 * zphy |
---|
155 | |
---|
156 | ! fphylab added by asklod AS Kremeur 2005-03 |
---|
157 | zphydom = rgamma * (1 - fphylab) * (zno3phy + znh4phy) |
---|
158 | zphynh4 = rgamma * fphylab * (zno3phy + znh4phy) |
---|
159 | ! zooplankton production |
---|
160 | ! preferences |
---|
161 | zppz = rppz |
---|
162 | zpdz = 1. - rppz |
---|
163 | zpppz = ( zppz * zphy ) / ( ( zppz * zphy + zpdz * zdet ) + 1.e-13 ) |
---|
164 | zppdz = ( zpdz * zdet ) / ( ( zppz * zphy + zpdz * zdet ) + 1.e-13 ) |
---|
165 | zfood = zpppz * zphy + zppdz * zdet |
---|
166 | ! filtration |
---|
167 | zfilpz = taus * zpppz / (aks + zfood) |
---|
168 | zfildz = taus * zppdz / (aks + zfood) |
---|
169 | ! grazing |
---|
170 | zphyzoo = zfilpz * zphy * zzoo |
---|
171 | zdetzoo = zfildz * zdet * zzoo |
---|
172 | |
---|
173 | ! fecal pellets production |
---|
174 | zzoodet = rpnaz * zphyzoo + rdnaz * zdetzoo |
---|
175 | |
---|
176 | ! zooplankton liquide excretion |
---|
177 | zzoonh4 = tauzn * fzoolab * zzoo |
---|
178 | zzoodom = tauzn * (1 - fzoolab) * zzoo |
---|
179 | |
---|
180 | ! mortality |
---|
181 | ! phytoplankton mortality |
---|
182 | zphydet = tmminp * zphy |
---|
183 | |
---|
184 | ! zooplankton mortality |
---|
185 | ! closure : flux grazing is redistributed below level jpkbio |
---|
186 | zzoobod = tmminz * zzoo * zzoo |
---|
187 | xksi(ji,jj) = xksi(ji,jj) + (1-fdbod) * zzoobod * e3t_n(ji,jj,jk) |
---|
188 | zboddet = fdbod * zzoobod |
---|
189 | |
---|
190 | ! detritus and dom breakdown |
---|
191 | zdetnh4 = taudn * fdetlab * zdet |
---|
192 | zdetdom = taudn * (1 - fdetlab) * zdet |
---|
193 | |
---|
194 | zdomnh4 = taudomn * zdom |
---|
195 | |
---|
196 | ! flux added to express how the excess of nitrogen from |
---|
197 | ! PHY, ZOO and DET to DOM goes directly to NH4 (flux of ajustment) |
---|
198 | zdomaju = (1 - redf/reddom) * (zphydom + zzoodom + zdetdom) |
---|
199 | |
---|
200 | ! Nitrification |
---|
201 | znh4no3 = taunn * znh4 |
---|
202 | |
---|
203 | ! determination of trends |
---|
204 | ! total trend for each biological tracer |
---|
205 | zphya = zno3phy + znh4phy - zphynh4 - zphydom - zphyzoo - zphydet |
---|
206 | zzooa = zphyzoo + zdetzoo - zzoodet - zzoodom - zzoonh4 - zzoobod |
---|
207 | zno3a = - zno3phy + znh4no3 |
---|
208 | znh4a = - znh4phy - znh4no3 + zphynh4 + zzoonh4 + zdomnh4 + zdetnh4 + zdomaju |
---|
209 | zdeta = zphydet + zzoodet - zdetzoo - zdetnh4 - zdetdom + zboddet |
---|
210 | zdoma = zphydom + zzoodom + zdetdom - zdomnh4 - zdomaju |
---|
211 | |
---|
212 | ! tracer flux at totox-point added to the general trend |
---|
213 | tra(ji,jj,jk,jpdet) = tra(ji,jj,jk,jpdet) + zdeta |
---|
214 | tra(ji,jj,jk,jpzoo) = tra(ji,jj,jk,jpzoo) + zzooa |
---|
215 | tra(ji,jj,jk,jpphy) = tra(ji,jj,jk,jpphy) + zphya |
---|
216 | tra(ji,jj,jk,jpno3) = tra(ji,jj,jk,jpno3) + zno3a |
---|
217 | tra(ji,jj,jk,jpnh4) = tra(ji,jj,jk,jpnh4) + znh4a |
---|
218 | tra(ji,jj,jk,jpdom) = tra(ji,jj,jk,jpdom) + zdoma |
---|
219 | |
---|
220 | |
---|
221 | IF( ( ln_diabio .AND. .NOT. lk_iomput ) .OR. l_trdtrc ) THEN |
---|
222 | trbio(ji,jj,jk,jp_pcs0_trd ) = zno3phy |
---|
223 | trbio(ji,jj,jk,jp_pcs0_trd + 1) = znh4phy |
---|
224 | trbio(ji,jj,jk,jp_pcs0_trd + 2) = zphynh4 |
---|
225 | trbio(ji,jj,jk,jp_pcs0_trd + 3) = zphydom |
---|
226 | trbio(ji,jj,jk,jp_pcs0_trd + 4) = zphyzoo |
---|
227 | trbio(ji,jj,jk,jp_pcs0_trd + 5) = zphydet |
---|
228 | trbio(ji,jj,jk,jp_pcs0_trd + 6) = zdetzoo |
---|
229 | ! trend number 8 in p2zsed |
---|
230 | trbio(ji,jj,jk,jp_pcs0_trd + 8) = zzoodet |
---|
231 | trbio(ji,jj,jk,jp_pcs0_trd + 9) = zzoobod |
---|
232 | trbio(ji,jj,jk,jp_pcs0_trd + 10) = zzoonh4 |
---|
233 | trbio(ji,jj,jk,jp_pcs0_trd + 11) = zzoodom |
---|
234 | trbio(ji,jj,jk,jp_pcs0_trd + 12) = znh4no3 |
---|
235 | trbio(ji,jj,jk,jp_pcs0_trd + 13) = zdomnh4 |
---|
236 | trbio(ji,jj,jk,jp_pcs0_trd + 14) = zdetnh4 |
---|
237 | trbio(ji,jj,jk,jp_pcs0_trd + 15) = zdetdom |
---|
238 | ! trend number 17 in p2zexp |
---|
239 | ENDIF |
---|
240 | IF( ln_diatrc .OR. lk_iomput ) THEN |
---|
241 | ! convert fluxes in per day |
---|
242 | ze3t = e3t_n(ji,jj,jk) * 86400._wp |
---|
243 | zw2d(ji,jj,1) = zw2d(ji,jj,1) + zno3phy * ze3t |
---|
244 | zw2d(ji,jj,2) = zw2d(ji,jj,2) + znh4phy * ze3t |
---|
245 | zw2d(ji,jj,3) = zw2d(ji,jj,3) + zphydom * ze3t |
---|
246 | zw2d(ji,jj,4) = zw2d(ji,jj,4) + zphynh4 * ze3t |
---|
247 | zw2d(ji,jj,5) = zw2d(ji,jj,5) + zphyzoo * ze3t |
---|
248 | zw2d(ji,jj,6) = zw2d(ji,jj,6) + zphydet * ze3t |
---|
249 | zw2d(ji,jj,7) = zw2d(ji,jj,7) + zdetzoo * ze3t |
---|
250 | zw2d(ji,jj,8) = zw2d(ji,jj,8) + zzoodet * ze3t |
---|
251 | zw2d(ji,jj,9) = zw2d(ji,jj,9) + zzoobod * ze3t |
---|
252 | zw2d(ji,jj,10) = zw2d(ji,jj,10) + zzoonh4 * ze3t |
---|
253 | zw2d(ji,jj,11) = zw2d(ji,jj,11) + zzoodom * ze3t |
---|
254 | zw2d(ji,jj,12) = zw2d(ji,jj,12) + znh4no3 * ze3t |
---|
255 | zw2d(ji,jj,13) = zw2d(ji,jj,13) + zdomnh4 * ze3t |
---|
256 | zw2d(ji,jj,14) = zw2d(ji,jj,14) + zdetnh4 * ze3t |
---|
257 | zw2d(ji,jj,15) = zw2d(ji,jj,15) + ( zno3phy + znh4phy - zphynh4 - zphydom - zphyzoo - zphydet ) * ze3t |
---|
258 | zw2d(ji,jj,16) = zw2d(ji,jj,16) + ( zphyzoo + zdetzoo - zzoodet - zzoobod - zzoonh4 - zzoodom ) * ze3t |
---|
259 | zw2d(ji,jj,17) = zw2d(ji,jj,17) + zdetdom * ze3t |
---|
260 | ! |
---|
261 | zw3d(ji,jj,jk,1) = zno3phy * 86400 |
---|
262 | zw3d(ji,jj,jk,2) = znh4phy * 86400 |
---|
263 | zw3d(ji,jj,jk,3) = znh4no3 * 86400 |
---|
264 | ! |
---|
265 | ENDIF |
---|
266 | END DO |
---|
267 | END DO |
---|
268 | END DO |
---|
269 | |
---|
270 | ! ! -------------------------- ! |
---|
271 | DO jk = jpkb, jpkm1 ! Upper ocean (bio-layers) ! |
---|
272 | ! ! -------------------------- ! |
---|
273 | DO jj = 2, jpjm1 |
---|
274 | DO ji = fs_2, fs_jpim1 |
---|
275 | ! remineralisation of all quantities towards nitrate |
---|
276 | |
---|
277 | ! trophic variables( det, zoo, phy, no3, nh4, dom) |
---|
278 | ! negative trophic variables DO not contribute to the fluxes |
---|
279 | zdet = MAX( 0.e0, trn(ji,jj,jk,jpdet) ) |
---|
280 | zzoo = MAX( 0.e0, trn(ji,jj,jk,jpzoo) ) |
---|
281 | zphy = MAX( 0.e0, trn(ji,jj,jk,jpphy) ) |
---|
282 | zno3 = MAX( 0.e0, trn(ji,jj,jk,jpno3) ) |
---|
283 | znh4 = MAX( 0.e0, trn(ji,jj,jk,jpnh4) ) |
---|
284 | zdom = MAX( 0.e0, trn(ji,jj,jk,jpdom) ) |
---|
285 | |
---|
286 | ! Limitations |
---|
287 | zlt = 0.e0 |
---|
288 | zle = 0.e0 |
---|
289 | zlno3 = 0.e0 |
---|
290 | zlnh4 = 0.e0 |
---|
291 | |
---|
292 | ! sinks and sources |
---|
293 | ! phytoplankton production and exsudation |
---|
294 | zno3phy = 0.e0 |
---|
295 | znh4phy = 0.e0 |
---|
296 | zphydom = 0.e0 |
---|
297 | zphynh4 = 0.e0 |
---|
298 | |
---|
299 | ! zooplankton production |
---|
300 | zphyzoo = 0.e0 ! grazing |
---|
301 | zdetzoo = 0.e0 |
---|
302 | |
---|
303 | zzoodet = 0.e0 ! fecal pellets production |
---|
304 | |
---|
305 | zzoonh4 = tauzn * fzoolab * zzoo ! zooplankton liquide excretion |
---|
306 | zzoodom = tauzn * (1 - fzoolab) * zzoo |
---|
307 | |
---|
308 | ! mortality |
---|
309 | zphydet = tmminp * zphy ! phytoplankton mortality |
---|
310 | |
---|
311 | zzoobod = 0.e0 ! zooplankton mortality |
---|
312 | zboddet = 0.e0 ! closure : flux fbod is redistributed below level jpkbio |
---|
313 | |
---|
314 | ! detritus and dom breakdown |
---|
315 | zdetnh4 = taudn * fdetlab * zdet |
---|
316 | zdetdom = taudn * (1 - fdetlab) * zdet |
---|
317 | |
---|
318 | zdomnh4 = taudomn * zdom |
---|
319 | zdomaju = (1 - redf/reddom) * (zphydom + zzoodom + zdetdom) |
---|
320 | |
---|
321 | ! Nitrification |
---|
322 | znh4no3 = taunn * znh4 |
---|
323 | |
---|
324 | |
---|
325 | ! determination of trends |
---|
326 | ! total trend for each biological tracer |
---|
327 | zphya = zno3phy + znh4phy - zphynh4 - zphydom - zphyzoo - zphydet |
---|
328 | zzooa = zphyzoo + zdetzoo - zzoodet - zzoodom - zzoonh4 - zzoobod |
---|
329 | zno3a = - zno3phy + znh4no3 |
---|
330 | znh4a = - znh4phy - znh4no3 + zphynh4 + zzoonh4 + zdomnh4 + zdetnh4 + zdomaju |
---|
331 | zdeta = zphydet + zzoodet - zdetzoo - zdetnh4 - zdetdom + zboddet |
---|
332 | zdoma = zphydom + zzoodom + zdetdom - zdomnh4 - zdomaju |
---|
333 | |
---|
334 | ! tracer flux at totox-point added to the general trend |
---|
335 | tra(ji,jj,jk,jpdet) = tra(ji,jj,jk,jpdet) + zdeta |
---|
336 | tra(ji,jj,jk,jpzoo) = tra(ji,jj,jk,jpzoo) + zzooa |
---|
337 | tra(ji,jj,jk,jpphy) = tra(ji,jj,jk,jpphy) + zphya |
---|
338 | tra(ji,jj,jk,jpno3) = tra(ji,jj,jk,jpno3) + zno3a |
---|
339 | tra(ji,jj,jk,jpnh4) = tra(ji,jj,jk,jpnh4) + znh4a |
---|
340 | tra(ji,jj,jk,jpdom) = tra(ji,jj,jk,jpdom) + zdoma |
---|
341 | ! |
---|
342 | IF( ( ln_diabio .AND. .NOT. lk_iomput ) .OR. l_trdtrc ) THEN |
---|
343 | trbio(ji,jj,jk,jp_pcs0_trd ) = zno3phy |
---|
344 | trbio(ji,jj,jk,jp_pcs0_trd + 1) = znh4phy |
---|
345 | trbio(ji,jj,jk,jp_pcs0_trd + 2) = zphynh4 |
---|
346 | trbio(ji,jj,jk,jp_pcs0_trd + 3) = zphydom |
---|
347 | trbio(ji,jj,jk,jp_pcs0_trd + 4) = zphyzoo |
---|
348 | trbio(ji,jj,jk,jp_pcs0_trd + 5) = zphydet |
---|
349 | trbio(ji,jj,jk,jp_pcs0_trd + 6) = zdetzoo |
---|
350 | ! trend number 8 in p2zsed |
---|
351 | trbio(ji,jj,jk,jp_pcs0_trd + 8) = zzoodet |
---|
352 | trbio(ji,jj,jk,jp_pcs0_trd + 9) = zzoobod |
---|
353 | trbio(ji,jj,jk,jp_pcs0_trd + 10) = zzoonh4 |
---|
354 | trbio(ji,jj,jk,jp_pcs0_trd + 11) = zzoodom |
---|
355 | trbio(ji,jj,jk,jp_pcs0_trd + 12) = znh4no3 |
---|
356 | trbio(ji,jj,jk,jp_pcs0_trd + 13) = zdomnh4 |
---|
357 | trbio(ji,jj,jk,jp_pcs0_trd + 14) = zdetnh4 |
---|
358 | trbio(ji,jj,jk,jp_pcs0_trd + 15) = zdetdom |
---|
359 | ! trend number 17 in p2zexp |
---|
360 | ENDIF |
---|
361 | IF( ln_diatrc .OR. lk_iomput ) THEN |
---|
362 | ! convert fluxes in per day |
---|
363 | ze3t = e3t_n(ji,jj,jk) * 86400._wp |
---|
364 | zw2d(ji,jj,1) = zw2d(ji,jj,1) + zno3phy * ze3t |
---|
365 | zw2d(ji,jj,2) = zw2d(ji,jj,2) + znh4phy * ze3t |
---|
366 | zw2d(ji,jj,3) = zw2d(ji,jj,3) + zphydom * ze3t |
---|
367 | zw2d(ji,jj,4) = zw2d(ji,jj,4) + zphynh4 * ze3t |
---|
368 | zw2d(ji,jj,5) = zw2d(ji,jj,5) + zphyzoo * ze3t |
---|
369 | zw2d(ji,jj,6) = zw2d(ji,jj,6) + zphydet * ze3t |
---|
370 | zw2d(ji,jj,7) = zw2d(ji,jj,7) + zdetzoo * ze3t |
---|
371 | zw2d(ji,jj,8) = zw2d(ji,jj,8) + zzoodet * ze3t |
---|
372 | zw2d(ji,jj,9) = zw2d(ji,jj,9) + zzoobod * ze3t |
---|
373 | zw2d(ji,jj,10) = zw2d(ji,jj,10) + zzoonh4 * ze3t |
---|
374 | zw2d(ji,jj,11) = zw2d(ji,jj,11) + zzoodom * ze3t |
---|
375 | zw2d(ji,jj,12) = zw2d(ji,jj,12) + znh4no3 * ze3t |
---|
376 | zw2d(ji,jj,13) = zw2d(ji,jj,13) + zdomnh4 * ze3t |
---|
377 | zw2d(ji,jj,14) = zw2d(ji,jj,14) + zdetnh4 * ze3t |
---|
378 | zw2d(ji,jj,15) = zw2d(ji,jj,15) + ( zno3phy + znh4phy - zphynh4 - zphydom - zphyzoo - zphydet ) * ze3t |
---|
379 | zw2d(ji,jj,16) = zw2d(ji,jj,16) + ( zphyzoo + zdetzoo - zzoodet - zzoobod - zzoonh4 - zzoodom ) * ze3t |
---|
380 | zw2d(ji,jj,17) = zw2d(ji,jj,17) + zdetdom * ze3t |
---|
381 | ! |
---|
382 | zw3d(ji,jj,jk,1) = zno3phy * 86400._wp |
---|
383 | zw3d(ji,jj,jk,2) = znh4phy * 86400._wp |
---|
384 | zw3d(ji,jj,jk,3) = znh4no3 * 86400._wp |
---|
385 | ! |
---|
386 | ENDIF |
---|
387 | END DO |
---|
388 | END DO |
---|
389 | END DO |
---|
390 | |
---|
391 | IF( ln_diatrc .OR. lk_iomput ) THEN |
---|
392 | DO jl = 1, 17 |
---|
393 | CALL lbc_lnk( zw2d(:,:,jl),'T', 1. ) |
---|
394 | END DO |
---|
395 | DO jl = 1, 3 |
---|
396 | CALL lbc_lnk( zw3d(:,:,:,jl),'T', 1. ) |
---|
397 | END DO |
---|
398 | ENDIF |
---|
399 | IF( lk_iomput ) THEN |
---|
400 | ! Save diagnostics |
---|
401 | CALL iom_put( "TNO3PHY", zw2d(:,:,1) ) |
---|
402 | CALL iom_put( "TNH4PHY", zw2d(:,:,2) ) |
---|
403 | CALL iom_put( "TPHYDOM", zw2d(:,:,3) ) |
---|
404 | CALL iom_put( "TPHYNH4", zw2d(:,:,4) ) |
---|
405 | CALL iom_put( "TPHYZOO", zw2d(:,:,5) ) |
---|
406 | CALL iom_put( "TPHYDET", zw2d(:,:,6) ) |
---|
407 | CALL iom_put( "TDETZOO", zw2d(:,:,7) ) |
---|
408 | CALL iom_put( "TZOODET", zw2d(:,:,8) ) |
---|
409 | CALL iom_put( "TZOOBOD", zw2d(:,:,9) ) |
---|
410 | CALL iom_put( "TZOONH4", zw2d(:,:,10) ) |
---|
411 | CALL iom_put( "TZOODOM", zw2d(:,:,11) ) |
---|
412 | CALL iom_put( "TNH4NO3", zw2d(:,:,12) ) |
---|
413 | CALL iom_put( "TDOMNH4", zw2d(:,:,13) ) |
---|
414 | CALL iom_put( "TDETNH4", zw2d(:,:,14) ) |
---|
415 | CALL iom_put( "TPHYTOT", zw2d(:,:,15) ) |
---|
416 | CALL iom_put( "TZOOTOT", zw2d(:,:,16) ) |
---|
417 | ! |
---|
418 | CALL iom_put( "FNO3PHY", zw3d(:,:,:,1) ) |
---|
419 | CALL iom_put( "FNH4PHY", zw3d(:,:,:,2) ) |
---|
420 | CALL iom_put( "FNH4NO3", zw3d(:,:,:,3) ) |
---|
421 | ! |
---|
422 | ELSE |
---|
423 | IF( ln_diatrc ) THEN |
---|
424 | ! |
---|
425 | trc2d(:,:,jp_pcs0_2d ) = zw2d(:,:,1) |
---|
426 | trc2d(:,:,jp_pcs0_2d + 1) = zw2d(:,:,2) |
---|
427 | trc2d(:,:,jp_pcs0_2d + 2) = zw2d(:,:,3) |
---|
428 | trc2d(:,:,jp_pcs0_2d + 3) = zw2d(:,:,4) |
---|
429 | trc2d(:,:,jp_pcs0_2d + 4) = zw2d(:,:,5) |
---|
430 | trc2d(:,:,jp_pcs0_2d + 5) = zw2d(:,:,6) |
---|
431 | trc2d(:,:,jp_pcs0_2d + 6) = zw2d(:,:,7) |
---|
432 | ! trend number 8 is in p2zsed.F |
---|
433 | trc2d(:,:,jp_pcs0_2d + 8) = zw2d(:,:,8) |
---|
434 | trc2d(:,:,jp_pcs0_2d + 9) = zw2d(:,:,9) |
---|
435 | trc2d(:,:,jp_pcs0_2d + 10) = zw2d(:,:,10) |
---|
436 | trc2d(:,:,jp_pcs0_2d + 11) = zw2d(:,:,11) |
---|
437 | trc2d(:,:,jp_pcs0_2d + 12) = zw2d(:,:,12) |
---|
438 | trc2d(:,:,jp_pcs0_2d + 13) = zw2d(:,:,13) |
---|
439 | trc2d(:,:,jp_pcs0_2d + 14) = zw2d(:,:,14) |
---|
440 | trc2d(:,:,jp_pcs0_2d + 15) = zw2d(:,:,15) |
---|
441 | trc2d(:,:,jp_pcs0_2d + 16) = zw2d(:,:,16) |
---|
442 | trc2d(:,:,jp_pcs0_2d + 17) = zw2d(:,:,17) |
---|
443 | ! trend number 19 is in p2zexp.F |
---|
444 | trc3d(:,:,:,jp_pcs0_3d ) = zw3d(:,:,:,1) |
---|
445 | trc3d(:,:,:,jp_pcs0_3d + 1) = zw3d(:,:,:,2) |
---|
446 | trc3d(:,:,:,jp_pcs0_3d + 2) = zw3d(:,:,:,3) |
---|
447 | ENDIF |
---|
448 | ! |
---|
449 | ENDIF |
---|
450 | |
---|
451 | IF( ln_diabio .AND. .NOT. lk_iomput ) THEN |
---|
452 | DO jl = jp_pcs0_trd, jp_pcs1_trd |
---|
453 | CALL lbc_lnk( trbio(:,:,1,jl),'T', 1. ) |
---|
454 | END DO |
---|
455 | ENDIF |
---|
456 | ! |
---|
457 | IF( l_trdtrc ) THEN |
---|
458 | DO jl = jp_pcs0_trd, jp_pcs1_trd |
---|
459 | CALL trd_trc( trbio(:,:,:,jl), jl, kt ) ! handle the trend |
---|
460 | END DO |
---|
461 | ENDIF |
---|
462 | |
---|
463 | IF(ln_ctl) THEN ! print mean trends (used for debugging) |
---|
464 | WRITE(charout, FMT="('bio')") |
---|
465 | CALL prt_ctl_trc_info(charout) |
---|
466 | CALL prt_ctl_trc(tab4d=tra, mask=tmask, clinfo=ctrcnm) |
---|
467 | ENDIF |
---|
468 | ! |
---|
469 | IF( ln_diatrc .OR. lk_iomput ) THEN |
---|
470 | CALL wrk_dealloc( jpi, jpj, 17, zw2d ) |
---|
471 | CALL wrk_dealloc( jpi, jpj, jpk, 3, zw3d ) |
---|
472 | ENDIF |
---|
473 | ! |
---|
474 | IF( nn_timing == 1 ) CALL timing_stop('p2z_bio') |
---|
475 | ! |
---|
476 | END SUBROUTINE p2z_bio |
---|
477 | |
---|
478 | SUBROUTINE p2z_bio_init |
---|
479 | !!---------------------------------------------------------------------- |
---|
480 | !! *** ROUTINE p2z_bio_init *** |
---|
481 | !! |
---|
482 | !! ** Purpose : biological parameters |
---|
483 | !! |
---|
484 | !! ** Method : Read namelist and check the parameters |
---|
485 | !! |
---|
486 | !!---------------------------------------------------------------------- |
---|
487 | NAMELIST/namlobphy/ tmumax, rgamma, fphylab, tmminp, aki |
---|
488 | NAMELIST/namlobnut/ akno3, aknh4, taunn, psinut |
---|
489 | NAMELIST/namlobzoo/ rppz, taus, aks, rpnaz, rdnaz, tauzn, fzoolab, fdbod, tmminz |
---|
490 | NAMELIST/namlobdet/ taudn, fdetlab |
---|
491 | NAMELIST/namlobdom/ taudomn |
---|
492 | INTEGER :: ios ! Local integer output status for namelist read |
---|
493 | !!---------------------------------------------------------------------- |
---|
494 | |
---|
495 | REWIND( numnatp_ref ) ! Namelist namlobphy in reference namelist : Lobster biological parameters |
---|
496 | READ ( numnatp_ref, namlobphy, IOSTAT = ios, ERR = 901) |
---|
497 | 901 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namlobphy in reference namelist', lwp ) |
---|
498 | |
---|
499 | REWIND( numnatp_cfg ) ! Namelist namlobphy in configuration namelist : Lobster biological parameters |
---|
500 | READ ( numnatp_cfg, namlobphy, IOSTAT = ios, ERR = 902 ) |
---|
501 | 902 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namlobphy in configuration namelist', lwp ) |
---|
502 | IF(lwm) WRITE ( numonp, namlobphy ) |
---|
503 | |
---|
504 | IF(lwp) THEN |
---|
505 | WRITE(numout,*) ' Namelist namlobphy' |
---|
506 | WRITE(numout,*) ' phyto max growth rate tmumax =', 86400 * tmumax, ' d' |
---|
507 | WRITE(numout,*) ' phytoplankton exudation fraction rgamma =', rgamma |
---|
508 | WRITE(numout,*) ' NH4 fraction of phytoplankton exsudation fphylab =', fphylab |
---|
509 | WRITE(numout,*) ' minimal phyto mortality rate tmminp =', 86400 * tmminp |
---|
510 | WRITE(numout,*) ' light hlaf saturation constant aki =', aki |
---|
511 | WRITE(numout,*) ' ' |
---|
512 | ENDIF |
---|
513 | |
---|
514 | REWIND( numnatp_ref ) ! Namelist namlobnut in reference namelist : Lobster nutriments parameters |
---|
515 | READ ( numnatp_ref, namlobnut, IOSTAT = ios, ERR = 903) |
---|
516 | 903 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namlobnut in reference namelist', lwp ) |
---|
517 | |
---|
518 | REWIND( numnatp_cfg ) ! Namelist namlobnut in configuration namelist : Lobster nutriments parameters |
---|
519 | READ ( numnatp_cfg, namlobnut, IOSTAT = ios, ERR = 904 ) |
---|
520 | 904 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namlobnut in configuration namelist', lwp ) |
---|
521 | IF(lwm) WRITE ( numonp, namlobnut ) |
---|
522 | |
---|
523 | IF(lwp) THEN |
---|
524 | WRITE(numout,*) ' Namelist namlobnut' |
---|
525 | WRITE(numout,*) ' half-saturation nutrient for no3 uptake akno3 =', akno3 |
---|
526 | WRITE(numout,*) ' half-saturation nutrient for nh4 uptake aknh4 =', aknh4 |
---|
527 | WRITE(numout,*) ' nitrification rate taunn =', taunn |
---|
528 | WRITE(numout,*) ' inhibition of no3 uptake by nh4 psinut =', psinut |
---|
529 | WRITE(numout,*) ' ' |
---|
530 | ENDIF |
---|
531 | |
---|
532 | REWIND( numnatp_ref ) ! Namelist namlobzoo in reference namelist : Lobster zooplankton parameters |
---|
533 | READ ( numnatp_ref, namlobzoo, IOSTAT = ios, ERR = 905) |
---|
534 | 905 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namlobzoo in reference namelist', lwp ) |
---|
535 | |
---|
536 | REWIND( numnatp_cfg ) ! Namelist namlobzoo in configuration namelist : Lobster zooplankton parameters |
---|
537 | READ ( numnatp_cfg, namlobzoo, IOSTAT = ios, ERR = 906 ) |
---|
538 | 906 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namlobzoo in configuration namelist', lwp ) |
---|
539 | IF(lwm) WRITE ( numonp, namlobzoo ) |
---|
540 | |
---|
541 | IF(lwp) THEN |
---|
542 | WRITE(numout,*) ' Namelist namlobzoo' |
---|
543 | WRITE(numout,*) ' zoo preference for phyto rppz =', rppz |
---|
544 | WRITE(numout,*) ' maximal zoo grazing rate taus =', 86400 * taus, ' d' |
---|
545 | WRITE(numout,*) ' half saturation constant for zoo food aks =', aks |
---|
546 | WRITE(numout,*) ' non-assimilated phyto by zoo rpnaz =', rpnaz |
---|
547 | WRITE(numout,*) ' non-assimilated detritus by zoo rdnaz =', rdnaz |
---|
548 | WRITE(numout,*) ' zoo specific excretion rate tauzn =', 86400 * tauzn |
---|
549 | WRITE(numout,*) ' minimal zoo mortality rate tmminz =', 86400 * tmminz |
---|
550 | WRITE(numout,*) ' NH4 fraction of zooplankton excretion fzoolab =', fzoolab |
---|
551 | WRITE(numout,*) ' Zooplankton mortality fraction that goes to detritus fdbod =', fdbod |
---|
552 | WRITE(numout,*) ' ' |
---|
553 | ENDIF |
---|
554 | |
---|
555 | REWIND( numnatp_ref ) ! Namelist namlobdet in reference namelist : Lobster detritus parameters |
---|
556 | READ ( numnatp_ref, namlobdet, IOSTAT = ios, ERR = 907) |
---|
557 | 907 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namlobdet in reference namelist', lwp ) |
---|
558 | |
---|
559 | REWIND( numnatp_cfg ) ! Namelist namlobdet in configuration namelist : Lobster detritus parameters |
---|
560 | READ ( numnatp_cfg, namlobdet, IOSTAT = ios, ERR = 908 ) |
---|
561 | 908 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namlobdet in configuration namelist', lwp ) |
---|
562 | IF(lwm) WRITE ( numonp, namlobdet ) |
---|
563 | |
---|
564 | IF(lwp) THEN |
---|
565 | WRITE(numout,*) ' Namelist namlobdet' |
---|
566 | WRITE(numout,*) ' detrital breakdown rate taudn =', 86400 * taudn , ' d' |
---|
567 | WRITE(numout,*) ' NH4 fraction of detritus dissolution fdetlab =', fdetlab |
---|
568 | WRITE(numout,*) ' ' |
---|
569 | ENDIF |
---|
570 | |
---|
571 | REWIND( numnatp_ref ) ! Namelist namlobdom in reference namelist : Lobster DOM breakdown rate |
---|
572 | READ ( numnatp_ref, namlobdom, IOSTAT = ios, ERR = 909) |
---|
573 | 909 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namlobdom in reference namelist', lwp ) |
---|
574 | |
---|
575 | REWIND( numnatp_cfg ) ! Namelist namlobdom in configuration namelist : Lobster DOM breakdown rate |
---|
576 | READ ( numnatp_cfg, namlobdom, IOSTAT = ios, ERR = 910 ) |
---|
577 | 910 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namlobdom in configuration namelist', lwp ) |
---|
578 | IF(lwm) WRITE ( numonp, namlobdom ) |
---|
579 | |
---|
580 | IF(lwp) THEN |
---|
581 | WRITE(numout,*) ' Namelist namlobdom' |
---|
582 | WRITE(numout,*) ' DOM breakdown rate taudomn =', 86400 * taudn , ' d' |
---|
583 | WRITE(numout,*) ' ' |
---|
584 | ENDIF |
---|
585 | ! |
---|
586 | END SUBROUTINE p2z_bio_init |
---|
587 | |
---|
588 | #else |
---|
589 | !!====================================================================== |
---|
590 | !! Dummy module : No PISCES bio-model |
---|
591 | !!====================================================================== |
---|
592 | CONTAINS |
---|
593 | SUBROUTINE p2z_bio( kt ) ! Empty routine |
---|
594 | INTEGER, INTENT( in ) :: kt |
---|
595 | WRITE(*,*) 'p2z_bio: You should not have seen this print! error?', kt |
---|
596 | END SUBROUTINE p2z_bio |
---|
597 | #endif |
---|
598 | |
---|
599 | !!====================================================================== |
---|
600 | END MODULE p2zbio |
---|