- Timestamp:
- 2016-11-30T17:56:53+01:00 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2016/dev_merge_2016/NEMOGCM/NEMO/TOP_SRC/PISCES/trcini_pisces.F90
r6325 r7403 11 11 !! 3.5 ! 2012-05 (C. Ethe) Merge PISCES-LOBSTER 12 12 !!---------------------------------------------------------------------- 13 #if defined key_pisces || defined key_pisces_reduced14 !!----------------------------------------------------------------------15 !! 'key_pisces' PISCES bio-model16 !!----------------------------------------------------------------------17 13 !! trc_ini_pisces : PISCES biochemical model initialisation 18 14 !!---------------------------------------------------------------------- 19 USE par_trc ! TOP parameters15 USE par_trc ! TOP parameters 20 16 USE oce_trc ! shared variables between ocean and passive tracers 21 17 USE trc ! passive tracers common variables 18 USE trcnam_pisces ! PISCES namelist 22 19 USE sms_pisces ! PISCES Source Minus Sink variables 23 20 … … 41 38 !!---------------------------------------------------------------------- 42 39 43 IF( lk_p4z ) THEN ; CALL p4z_ini ! PISCES 44 ELSE ; CALL p2z_ini ! LOBSTER 40 ! 41 CALL trc_nam_pisces 42 ! 43 IF( ln_p4z .OR. ln_p5z ) THEN ; CALL p4z_ini ! PISCES 44 ELSE ; CALL p2z_ini ! LOBSTER 45 45 ENDIF 46 46 … … 53 53 !! ** Purpose : Initialisation of the PISCES biochemical model 54 54 !!---------------------------------------------------------------------- 55 #if defined key_pisces56 55 ! 57 56 USE p4zsms ! Main P4Z routine … … 70 69 USE p4zlys ! Calcite saturation 71 70 USE p4zsed ! Sedimentation & burial 71 USE p4zpoc ! Remineralization of organic particles 72 USE p4zligand ! Remineralization of organic ligands 73 USE p5zlim ! Co-limitations of differents nutrients 74 USE p5zprod ! Growth rate of the 2 phyto groups 75 USE p5zmicro ! Sources and sinks of microzooplankton 76 USE p5zmeso ! Sources and sinks of mesozooplankton 77 USE p5zmort ! Mortality terms for phytoplankton 78 72 79 ! 73 80 REAL(wp), SAVE :: sco2 = 2.312e-3_wp … … 79 86 REAL(wp), SAVE :: no3 = 30.9e-6_wp * 7.625_wp 80 87 ! 81 INTEGER :: ji, jj, jk, ierr88 INTEGER :: ji, jj, jk, jn, ierr 82 89 REAL(wp) :: zcaralk, zbicarb, zco3 83 90 REAL(wp) :: ztmas, ztmas1 84 !!---------------------------------------------------------------------- 85 86 IF(lwp) WRITE(numout,*) 87 IF(lwp) WRITE(numout,*) ' p4z_ini : PISCES biochemical model initialisation' 88 IF(lwp) WRITE(numout,*) ' ~~~~~~~~~~~~~~' 89 90 ! Allocate PISCES arrays 91 CHARACTER(len = 20) :: cltra 92 93 !!---------------------------------------------------------------------- 94 95 IF(lwp) THEN 96 WRITE(numout,*) 97 IF( ln_p4z ) THEN 98 WRITE(numout,*) ' p4z_ini : PISCES biochemical model initialisation' 99 ELSE 100 WRITE(numout,*) ' p5z_ini : PISCES biochemical model initialisation' 101 WRITE(numout,*) ' With variable stoichiometry' 102 ENDIF 103 WRITE(numout,*) ' ~~~~~~~~~~~~~~' 104 ENDIF 105 ! 106 ! Allocate PISCES arrays 91 107 ierr = sms_pisces_alloc() 92 108 ierr = ierr + p4z_che_alloc() 93 109 ierr = ierr + p4z_sink_alloc() 94 110 ierr = ierr + p4z_opt_alloc() 95 ierr = ierr + p4z_prod_alloc()96 ierr = ierr + p4z_rem_alloc()97 111 ierr = ierr + p4z_flx_alloc() 98 112 ierr = ierr + p4z_sed_alloc() 113 ierr = ierr + p4z_rem_alloc() 114 IF( ln_p4z ) THEN 115 ierr = ierr + p4z_lim_alloc() 116 ierr = ierr + p4z_prod_alloc() 117 ELSE 118 ierr = ierr + p5z_lim_alloc() 119 ierr = ierr + p5z_prod_alloc() 120 ENDIF 99 121 ! 100 122 IF( lk_mpp ) CALL mpp_sum( ierr ) … … 104 126 r1_ryyss = 1. / ryyss 105 127 ! 128 129 ! assign an index in trc arrays for each prognostic variables 130 DO jn = 1, jptra 131 cltra = ctrcnm(jn) 132 IF( cltra == 'DIC' ) jpdic = jn !: dissolved inoganic carbon concentration 133 IF( cltra == 'Alkalini' ) jptal = jn !: total alkalinity 134 IF( cltra == 'O2' ) jpoxy = jn !: oxygen carbon concentration 135 IF( cltra == 'CaCO3' ) jpcal = jn !: calcite concentration 136 IF( cltra == 'PO4' ) jppo4 = jn !: phosphate concentration 137 IF( cltra == 'POC' ) jppoc = jn !: small particulate organic phosphate concentration 138 IF( cltra == 'Si' ) jpsil = jn !: silicate concentration 139 IF( cltra == 'PHY' ) jpphy = jn !: phytoplancton concentration 140 IF( cltra == 'ZOO' ) jpzoo = jn !: zooplancton concentration 141 IF( cltra == 'DOC' ) jpdoc = jn !: dissolved organic carbon concentration 142 IF( cltra == 'PHY2' ) jpdia = jn !: Diatoms Concentration 143 IF( cltra == 'ZOO2' ) jpmes = jn !: Mesozooplankton Concentration 144 IF( cltra == 'DSi' ) jpdsi = jn !: Diatoms Silicate Concentration 145 IF( cltra == 'Fer' ) jpfer = jn !: Iron Concentration 146 IF( cltra == 'BFe' ) jpbfe = jn !: Big iron particles Concentration 147 IF( cltra == 'GOC' ) jpgoc = jn !: Big particulate organic phosphate concentration 148 IF( cltra == 'SFe' ) jpsfe = jn !: Small iron particles Concentration 149 IF( cltra == 'DFe' ) jpdfe = jn !: Diatoms iron Concentration 150 IF( cltra == 'GSi' ) jpgsi = jn !: (big) Silicate Concentration 151 IF( cltra == 'NFe' ) jpnfe = jn !: Nano iron Concentration 152 IF( cltra == 'NCHL' ) jpnch = jn !: Nano Chlorophyll Concentration 153 IF( cltra == 'DCHL' ) jpdch = jn !: Diatoms Chlorophyll Concentration 154 IF( cltra == 'NO3' ) jpno3 = jn !: Nitrates Concentration 155 IF( cltra == 'NH4' ) jpnh4 = jn !: Ammonium Concentration 156 IF( cltra == 'DON' ) jpdon = jn !: Dissolved organic N Concentration 157 IF( cltra == 'DOP' ) jpdop = jn !: Dissolved organic P Concentration 158 IF( cltra == 'PON' ) jppon = jn !: Small Nitrogen particle Concentration 159 IF( cltra == 'POP' ) jppop = jn !: Small Phosphorus particle Concentration 160 IF( cltra == 'GON' ) jpgon = jn !: Big Nitrogen particles Concentration 161 IF( cltra == 'GOP' ) jpgop = jn !: Big Phosphorus Concentration 162 IF( cltra == 'PHYN' ) jpnph = jn !: Nanophytoplankton N biomass 163 IF( cltra == 'PHYP' ) jppph = jn !: Nanophytoplankton P biomass 164 IF( cltra == 'DIAN' ) jpndi = jn !: Diatoms N biomass 165 IF( cltra == 'DIAP' ) jppdi = jn !: Diatoms P biomass 166 IF( cltra == 'PIC' ) jppic = jn !: Picophytoplankton C biomass 167 IF( cltra == 'PICN' ) jpnpi = jn !: Picophytoplankton N biomass 168 IF( cltra == 'PICP' ) jpppi = jn !: Picophytoplankton P biomass 169 IF( cltra == 'PFe' ) jppfe = jn !: Picophytoplankton Fe biomass 170 IF( cltra == 'LGW' ) jplgw = jn !: Weak ligands 171 IF( cltra == 'LFe' ) jpfep = jn !: Fe nanoparticle 172 ENDDO 106 173 107 174 CALL p4z_sms_init ! Maint routine … … 116 183 rdenit = ( ( o2ut + o2nit ) * 0.80 - rno3 - rno3 * 0.60 ) / rno3 117 184 rdenita = 3._wp / 5._wp 118 185 IF( ln_p5z ) THEN 186 no3rat3 = no3rat3 / rno3 187 po4rat3 = po4rat3 / po4r 188 ENDIF 119 189 120 190 ! Initialization of tracer concentration in case of no restart 121 191 !-------------------------------------------------------------- 122 IF( .NOT. ln_rsttr ) THEN 123 192 IF( .NOT.ln_rsttr ) THEN 124 193 trn(:,:,:,jpdic) = sco2 125 194 trn(:,:,:,jpdoc) = bioma0 … … 129 198 trn(:,:,:,jppo4) = po4 / po4r 130 199 trn(:,:,:,jppoc) = bioma0 131 # if ! defined key_kriest132 200 trn(:,:,:,jpgoc) = bioma0 133 201 trn(:,:,:,jpbfe) = bioma0 * 5.e-6 134 # else135 trn(:,:,:,jpnum) = bioma0 / ( 6. * xkr_massp )136 # endif137 202 trn(:,:,:,jpsil) = silic1 138 203 trn(:,:,:,jpdsi) = bioma0 * 0.15 … … 150 215 trn(:,:,:,jpno3) = no3 151 216 trn(:,:,:,jpnh4) = bioma0 152 217 IF( ln_ligand) THEN 218 trn(:,:,:,jplgw) = 0.6E-9 219 trn(:,:,:,jpfep) = 0. * 5.e-6 220 ENDIF 221 IF( ln_p5z ) THEN 222 trn(:,:,:,jpdon) = bioma0 223 trn(:,:,:,jpdop) = bioma0 224 trn(:,:,:,jppon) = bioma0 225 trn(:,:,:,jppop) = bioma0 226 trn(:,:,:,jpgon) = bioma0 227 trn(:,:,:,jpgop) = bioma0 228 trn(:,:,:,jpnph) = bioma0 229 trn(:,:,:,jppph) = bioma0 230 trn(:,:,:,jppic) = bioma0 231 trn(:,:,:,jpnpi) = bioma0 232 trn(:,:,:,jpppi) = bioma0 233 trn(:,:,:,jpndi) = bioma0 234 trn(:,:,:,jppdi) = bioma0 235 trn(:,:,:,jppfe) = bioma0 * 5.e-6 236 trn(:,:,:,jppch) = bioma0 * 12. / 55. 237 ENDIF 153 238 ! initialize the half saturation constant for silicate 154 239 ! ---------------------------------------------------- … … 158 243 159 244 160 CALL p4z_sink_init ! vertical flux of particulate organic matter 161 CALL p4z_opt_init ! Optic: PAR in the water column 162 CALL p4z_lim_init ! co-limitations by the various nutrients 163 CALL p4z_prod_init ! phytoplankton growth rate over the global ocean. 164 CALL p4z_sbc_init ! boundary conditions 165 CALL p4z_fechem_init ! Iron chemistry 166 CALL p4z_rem_init ! remineralisation 167 CALL p4z_mort_init ! phytoplankton mortality 168 CALL p4z_micro_init ! microzooplankton 169 CALL p4z_meso_init ! mesozooplankton 170 CALL p4z_lys_init ! calcite saturation 171 CALL p4z_flx_init ! gas exchange 245 CALL p4z_sink_init ! vertical flux of particulate organic matter 246 CALL p4z_opt_init ! Optic: PAR in the water column 247 IF( ln_p4z ) THEN 248 CALL p4z_lim_init ! co-limitations by the various nutrients 249 CALL p4z_prod_init ! phytoplankton growth rate over the global ocean. 250 ELSE 251 CALL p5z_lim_init ! co-limitations by the various nutrients 252 CALL p5z_prod_init ! phytoplankton growth rate over the global ocean. 253 ENDIF 254 CALL p4z_sbc_init ! boundary conditions 255 CALL p4z_fechem_init ! Iron chemistry 256 CALL p4z_rem_init ! remineralisation 257 CALL p4z_poc_init ! remineralisation of organic particles 258 IF( ln_ligand ) & 259 & CALL p4z_ligand_init ! remineralisation of organic ligands 260 261 IF( ln_p4z ) THEN 262 CALL p4z_mort_init ! phytoplankton mortality 263 CALL p4z_micro_init ! microzooplankton 264 CALL p4z_meso_init ! mesozooplankton 265 ELSE 266 CALL p5z_mort_init ! phytoplankton mortality 267 CALL p5z_micro_init ! microzooplankton 268 CALL p5z_meso_init ! mesozooplankton 269 ENDIF 270 CALL p4z_lys_init ! calcite saturation 271 IF( .NOT.l_co2cpl ) & 272 & CALL p4z_flx_init ! gas exchange 172 273 173 274 ndayflxtr = 0 … … 176 277 IF(lwp) WRITE(numout,*) 'Initialization of PISCES tracers done' 177 278 IF(lwp) WRITE(numout,*) 178 #endif179 279 ! 180 280 END SUBROUTINE p4z_ini … … 186 286 !! ** Purpose : Initialisation of the LOBSTER biochemical model 187 287 !!---------------------------------------------------------------------- 188 #if defined key_pisces_reduced189 288 ! 190 289 USE p2zopt … … 193 292 USE p2zsed 194 293 ! 195 INTEGER :: ji, jj, jk, ierr 294 INTEGER :: ji, jj, jk, jn, ierr 295 CHARACTER(len = 10) :: cltra 196 296 !!---------------------------------------------------------------------- 197 297 … … 205 305 IF( lk_mpp ) CALL mpp_sum( ierr ) 206 306 IF( ierr /= 0 ) CALL ctl_stop( 'STOP', 'p2z_ini: unable to allocate LOBSTER arrays' ) 307 308 DO jn = 1, jptra 309 cltra = ctrcnm(jn) 310 IF( cltra == 'DET' ) jpdet = jn !: detritus [mmoleN/m3] 311 IF( cltra == 'ZOO' ) jpzoo = jn !: zooplancton concentration [mmoleN/m3] 312 IF( cltra == 'PHY' ) jpphy = jn !: phytoplancton concentration [mmoleN/m3] 313 IF( cltra == 'NO3' ) jpno3 = jn !: nitrate concentration [mmoleN/m3] 314 IF( cltra == 'NH4' ) jpnh4 = jn !: ammonium concentration [mmoleN/m3] 315 IF( cltra == 'DOM' ) jpdom = jn !: dissolved organic matter [mmoleN/m3] 316 ENDDO 317 318 jpkb = 10 ! last level where depth less than 200 m 319 DO jk = jpkm1, 1, -1 320 IF( gdept_1d(jk) > 200. ) jpkb = jk 321 END DO 322 IF (lwp) WRITE(numout,*) 323 IF (lwp) WRITE(numout,*) ' first vertical layers where biology is active (200m depth ) ', jpkb 324 IF (lwp) WRITE(numout,*) 325 jpkbm1 = jpkb - 1 326 ! 327 207 328 208 329 ! LOBSTER initialisation for GYRE : init NO3=f(density) by asklod AS Kremeur 2005-07 … … 214 335 trn(:,:,:,jpphy) = 0.1 * tmask(:,:,:) 215 336 trn(:,:,:,jpdom) = 1.0 * tmask(:,:,:) 216 WHERE( rhd(:,:,:) <= 24.5e-3 ) ; trn(:,:,:,jpno3 337 WHERE( rhd(:,:,:) <= 24.5e-3 ) ; trn(:,:,:,jpno3) = 2._wp * tmask(:,:,:) 217 338 ELSE WHERE ; trn(:,:,:,jpno3) = ( 15.55 * ( rhd(:,:,:) * 1000. ) - 380.11 ) * tmask(:,:,:) 218 339 END WHERE … … 227 348 IF(lwp) WRITE(numout,*) 'Initialization of LOBSTER tracers done' 228 349 IF(lwp) WRITE(numout,*) 229 #endif230 350 ! 231 351 END SUBROUTINE p2z_ini 232 #else233 !!----------------------------------------------------------------------234 !! Dummy module No PISCES biochemical model235 !!----------------------------------------------------------------------236 CONTAINS237 SUBROUTINE trc_ini_pisces ! Empty routine238 END SUBROUTINE trc_ini_pisces239 #endif240 352 241 353 !!======================================================================
Note: See TracChangeset
for help on using the changeset viewer.