New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 15459 for NEMO/trunk/src/TOP/PISCES/P4Z/p4zpoc.F90 – NEMO

Ignore:
Timestamp:
2021-10-29T10:19:18+02:00 (3 years ago)
Author:
cetlod
Message:

Various bug fixes and more comments in PISCES routines ; sette test OK in debug mode, nn_hls=1/2, with tiling ; run.stat unchanged ; of course tracer.stat different

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/trunk/src/TOP/PISCES/P4Z/p4zpoc.F90

    r15090 r15459  
    33   !!                         ***  MODULE p4zpoc  *** 
    44   !! TOP :   PISCES Compute remineralization of organic particles 
     5   !!         Same module for both PISCES and PISCES-QUOTA 
    56   !!========================================================================= 
    67   !! History :   1.0  !  2004     (O. Aumont) Original code 
     
    89   !!             3.4  !  2011-06  (O. Aumont, C. Ethe) Quota model for iron 
    910   !!             3.6  !  2016-03  (O. Aumont) Quota model and diverse 
     11   !!             4.0  !  2018     (O. Aumont) Variable lability parameterization 
    1012   !!---------------------------------------------------------------------- 
    1113   !!   p4z_poc       :  Compute remineralization/dissolution of organic compounds 
    1214   !!   p4z_poc_init  :  Initialisation of parameters for remineralisation 
     15   !!   alngam and gamain : computation of the incomplete gamma function 
    1316   !!---------------------------------------------------------------------- 
    1417   USE oce_trc         !  shared variables between ocean and passive tracers 
     
    2225 
    2326   PUBLIC   p4z_poc         ! called in p4zbio.F90 
    24    PUBLIC   p4z_poc_init    ! called in trcsms_pisces.F90 
    25    PUBLIC   alngam          ! 
     27   PUBLIC   p4z_poc_init    ! called in trcini_pisces.F90 
     28   PUBLIC   alngam          !  
    2629   PUBLIC   gamain          ! 
    2730 
     
    3336   REAL(wp), PUBLIC ::   rshape     !: shape factor of the gamma distribution 
    3437 
    35    REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:)       ::   alphan, reminp   !: 
    36    REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:,:,:) ::   alphap           !: 
     38   REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:)       ::   alphan, reminp   !: variable lability of POC and initial distribution 
     39   REAL(wp), PUBLIC, ALLOCATABLE, SAVE, DIMENSION(:,:,:,:) ::   alphap           !: lability distribution of small particles 
    3740 
    3841 
     
    5255      !! 
    5356      !! ** Purpose :   Compute remineralization of organic particles 
     57      !!                A reactivity-continuum parameterization is chosen 
     58      !!                to describe the lability of the organic particles 
     59      !!                As a consequence, the remineralisation rates of the  
     60      !!                the different pools change with time as a function of  
     61      !!                the lability distribution 
    5462      !! 
    55       !! ** Method  : - ??? 
     63      !! ** Method  : - Computation of the remineralisation rates is performed 
     64      !!                according to reactivity continuum formalism described 
     65      !!                in Aumont et al. (2017).  
    5666      !!--------------------------------------------------------------------- 
    5767      INTEGER, INTENT(in) ::   kt, knt         ! ocean time step and ??? 
     
    8393      solgoc = 0.04/ 2.56 * 1./ ( 1.-50**(-0.04) ) 
    8494 
    85       ! Initialisation of temprary arrys 
     95      ! Initialisation of temporary arrays 
    8696      IF( ln_p4z ) THEN 
    8797         zremipoc(:,:,:) = xremip 
     
    96106      zfolimi (:,:,:) = 0. 
    97107 
     108      ! Initialisation of the lability distributions that are set to  
     109      ! the distribution of newly produced organic particles 
    98110      DO jn = 1, jcpoc 
    99111        alphag(:,:,:,jn) = alphan(jn) 
     
    101113      END DO 
    102114 
    103      ! ----------------------------------------------------------------------- 
    104115     ! Lability parameterization. This is the big particles part (GOC) 
    105      ! This lability parameterization can be activated only with the standard 
    106      ! particle scheme. Does not work with Kriest parameterization. 
     116     ! This lability parameterization is always active. However, if only one 
     117     ! lability class is specified in the namelist, this is equivalent to  
     118     ! a standard parameterisation with a constant lability 
    107119     ! ----------------------------------------------------------------------- 
    108120     ztremint(:,:,:) = zremigoc(:,:,:) 
     
    192204 
    193205      IF( ln_p4z ) THEN 
     206         ! The standard PISCES part 
    194207         DO_3D( nn_hls, nn_hls, nn_hls, nn_hls, 1, jpkm1) 
    195             ! POC disaggregation by turbulence and bacterial activity.  
    196             ! -------------------------------------------------------- 
     208            ! POC degradation by bacterial activity. It is a function  
     209            ! of the mean lability and of temperature. This also includes 
     210            ! shrinking of particles due to the bacterial activity 
     211            ! ----------------------------------------------------------- 
    197212            zremig = zremigoc(ji,jj,jk) * xstep * tgfunc(ji,jj,jk) 
    198213            zorem2  = zremig * tr(ji,jj,jk,jpgoc,Kbb) 
     
    202217            zofer3 = zremig * solgoc * tr(ji,jj,jk,jpbfe,Kbb) 
    203218 
    204             ! ------------------------------------- 
     219            ! update of the TRA arrays 
    205220            tr(ji,jj,jk,jppoc,Krhs) = tr(ji,jj,jk,jppoc,Krhs) + zorem3(ji,jj,jk) 
    206221            tr(ji,jj,jk,jpgoc,Krhs) = tr(ji,jj,jk,jpgoc,Krhs) - zorem2 - zorem3(ji,jj,jk) 
     
    213228      ELSE 
    214229         DO_3D( nn_hls, nn_hls, nn_hls, nn_hls, 1, jpkm1) 
    215              ! POC disaggregation by turbulence and bacterial activity.  
     230            ! POC degradation by bacterial activity. It is a function  
     231            ! of the mean lability and of temperature. This also includes 
     232            ! shrinking of particles due to the bacterial activity 
    216233            ! -------------------------------------------------------- 
    217234            zremig = zremigoc(ji,jj,jk) * xstep * tgfunc(ji,jj,jk) 
     
    223240            zofer2 = xremipn / xremipc * zremig * tr(ji,jj,jk,jpbfe,Kbb) 
    224241 
    225             ! ------------------------------------- 
     242            ! update of the TRA arrays 
    226243            tr(ji,jj,jk,jppoc,Krhs) = tr(ji,jj,jk,jppoc,Krhs) + zorem3(ji,jj,jk) 
    227244            tr(ji,jj,jk,jppon,Krhs) = tr(ji,jj,jk,jppon,Krhs) + solgoc * zopon2  
     
    246263     ENDIF 
    247264 
    248      ! ------------------------------------------------------------------ 
    249265     ! Lability parameterization for the small OM particles. This param  
    250266     ! is based on the same theoretical background as the big particles. 
    251267     ! However, because of its low sinking speed, lability is not supposed 
    252268     ! to be equal to its initial value (the value of the freshly produced 
    253      ! organic matter). It is however uniform in the mixed layer. 
    254      ! ------------------------------------------------------------------- 
    255      ! 
     269     ! organic matter) in the MLD. It is however uniform in the mixed layer. 
     270     ! --------------------------------------------------------------------- 
    256271     totprod (:,:) = 0. 
    257272     totthick(:,:) = 0. 
    258273     totcons (:,:) = 0. 
     274 
    259275     ! intregrated production and consumption of POC in the mixed layer 
    260276     ! ---------------------------------------------------------------- 
    261      !  
    262277     DO_3D( nn_hls, nn_hls, nn_hls, nn_hls, 1, jpkm1) 
    263278        zdep = hmld(ji,jj) 
     
    272287 
    273288     ! Computation of the lability spectrum in the mixed layer. In the mixed  
    274      ! layer, this spectrum is supposed to be uniform. 
     289     ! layer, this spectrum is supposed to be uniform as a result of intense 
     290     ! mixing. 
    275291     ! --------------------------------------------------------------------- 
    276292     ztremint(:,:,:) = zremipoc(:,:,:) 
     
    302318     ENDIF 
    303319 
    304      ! ----------------------------------------------------------------------- 
    305320     ! The lability parameterization is used here. The code is here  
    306321     ! almost identical to what is done for big particles. The only difference 
     
    309324     ! should be determined before. 
    310325     ! ----------------------------------------------------------------------- 
    311      ! 
    312326     DO_3D( nn_hls, nn_hls, nn_hls, nn_hls, 2, jpkm1) 
    313327        IF (tmask(ji,jj,jk) == 1.) THEN 
     
    386400         DO_3D( nn_hls, nn_hls, nn_hls, nn_hls, 1, jpkm1) 
    387401            IF (tmask(ji,jj,jk) == 1.) THEN 
    388               ! POC disaggregation by turbulence and bacterial activity.  
     402              ! POC disaggregation by turbulence and bacterial activity.It is a function 
     403              ! of the mean lability and of temperature   
    389404              ! -------------------------------------------------------- 
    390405              zremip          = zremipoc(ji,jj,jk) * xstep * tgfunc(ji,jj,jk) 
    391406              zorem           = zremip * tr(ji,jj,jk,jppoc,Kbb) 
    392407              zofer           = zremip * tr(ji,jj,jk,jpsfe,Kbb) 
    393  
     408               
     409              ! Update of the TRA arrays 
    394410              tr(ji,jj,jk,jpdoc,Krhs) = tr(ji,jj,jk,jpdoc,Krhs) + zorem 
    395411              orem(ji,jj,jk)      = orem(ji,jj,jk) + zorem 
     
    402418     ELSE 
    403419       DO_3D( nn_hls, nn_hls, nn_hls, nn_hls, 1, jpkm1) 
    404           ! POC disaggregation by turbulence and bacterial activity.  
    405           ! -------------------------------------------------------- 
     420          ! POC disaggregation by turbulence and bacterial activity.It is a function 
     421          ! of the mean lability and of temperature   
     422          !-------------------------------------------------------- 
    406423          zremip = zremipoc(ji,jj,jk) * xstep * tgfunc(ji,jj,jk) 
    407424          zopoc  = zremip * tr(ji,jj,jk,jppoc,Kbb) 
     
    410427          zopop  = xremipp / xremipc * zremip * tr(ji,jj,jk,jppop,Kbb) 
    411428          zofer  = xremipn / xremipc * zremip * tr(ji,jj,jk,jpsfe,Kbb) 
    412  
     429               
     430          ! Update of the TRA arrays 
    413431          tr(ji,jj,jk,jppoc,Krhs) = tr(ji,jj,jk,jppoc,Krhs) - zopoc 
    414432          tr(ji,jj,jk,jppon,Krhs) = tr(ji,jj,jk,jppon,Krhs) - zopon 
     
    426444        IF( knt == nrdttrc ) THEN 
    427445          zrfact2 = 1.e3 * rfact2r 
    428           CALL iom_put( "REMINP" , zremipoc(:,:,:) * tmask(:,:,:) )  ! Remineralisation rate 
    429           CALL iom_put( "REMING" , zremigoc(:,:,:) * tmask(:,:,:) )  ! Remineralisation rate 
    430           CALL iom_put( "REMINF" , zfolimi(:,:,:)  * tmask(:,:,:)  * 1.e+9 * zrfact2 )  ! Remineralisation rate 
     446          CALL iom_put( "REMINP" , zremipoc(:,:,:) * tmask(:,:,:) )  ! Remineralisation rate of small particles 
     447          CALL iom_put( "REMING" , zremigoc(:,:,:) * tmask(:,:,:) )  ! Remineralisation rate of large particles 
     448          CALL iom_put( "REMINF" , zfolimi(:,:,:)  * tmask(:,:,:)  * 1.e+9 * zrfact2 )  ! Remineralisation of biogenic particulate iron 
    431449        ENDIF 
    432450     ENDIF 
     
    493511      ALLOCATE( alphan(jcpoc) , reminp(jcpoc) , alphap(jpi,jpj,jpk,jcpoc) ) 
    494512      ! 
    495       IF (jcpoc > 1) THEN 
     513      IF (jcpoc > 1) THEN  ! Case when more than one lability class is used 
    496514         ! 
    497515         remindelta = LOG(4. * 1000. ) / REAL(jcpoc-1, wp) 
     
    517535         reminp(jcpoc) = reminp(jcpoc) * xremip / alphan(jcpoc) 
    518536 
    519       ELSE 
     537      ELSE  ! Only one lability class is used 
    520538         alphan(jcpoc) = 1. 
    521539         reminp(jcpoc) = xremip 
Note: See TracChangeset for help on using the changeset viewer.