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 8039 for branches/UKMO/dev_r5518_medusa_chg_trc_bio_medusa/NEMOGCM/NEMO/TOP_SRC/MEDUSA/detritus_fast_sink.F90 – NEMO

Ignore:
Timestamp:
2017-05-18T11:14:31+02:00 (7 years ago)
Author:
marc
Message:

Removed about 40 2d arrays from bio_medusa_mod.F90

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/UKMO/dev_r5518_medusa_chg_trc_bio_medusa/NEMOGCM/NEMO/TOP_SRC/MEDUSA/detritus_fast_sink.F90

    r8023 r8039  
    3535                                   f_benout_si,                            & 
    3636                                   f_fbenin_c, f_fbenin_ca, f_fbenin_fe,   & 
    37                                    f_fbenin_n, f_fbenin_si,                & 
    38                                    f_omcal, fcaco3,                        & 
    39                                    fccd, fccd_dep, fdep1, fdd,             & 
     37                                   f_fbenin_n, f_fbenin_si, f_omcal,       & 
     38                                   fccd, fdep1, fdd,                       & 
    4039                                   fdpd, fdpd2, fdpds, fdpds2,             & 
    4140                                   fdpn, fdpn2,                            & 
     
    5251                                   fmeexcr, fmiexcr,                       & 
    5352                                   fofd_fe, fofd_n, fofd_si,               & 
    54                                    fprotf,                                 & 
    5553                                   fregen, fregenfast, fregenfastsi,       & 
    5654                                   fregensi,                               & 
     
    7371      USE oce,               ONLY: tsn 
    7472      USE par_kind,          ONLY: wp 
    75       USE par_oce,           ONLY: jpim1, jpjm1 
     73      USE par_oce,           ONLY: jpi, jpim1, jpj, jpjm1 
    7674      USE sms_medusa,        ONLY: f2_ccd_cal, f3_omcal,                   & 
    7775                                   jexport, jfdfate, jinorgben, jocalccd,  & 
     
    102100      INTEGER :: ji, jj 
    103101 
    104       REAL(wp) ::    fb_val, fl_sst 
     102      REAL(wp) :: fb_val, fl_sst 
     103      !! Particle flux 
     104      REAL(wp) :: fcaco3 
     105      REAL(wp) :: fprotf 
     106      REAL(wp), DIMENSION(jpi,jpj) :: fccd_dep 
    105107      !! temporary variables 
    106108      REAL(wp) :: fq0,fq1,fq2,fq3,fq4,fq5,fq6,fq7,fq8 
     
    236238                  !!             primary production 
    237239                  !!               0.10 at equator; 0.02 at pole 
    238                   fcaco3(ji,jj) = xcaco3a + ((xcaco3b - xcaco3a) *           & 
    239                                              ((90.0 - abs(gphit(ji,jj))) /   & 
    240                                                90.0)) 
     240                  fcaco3 = xcaco3a + ((xcaco3b - xcaco3a) *                  & 
     241                                      ((90.0 - abs(gphit(ji,jj))) / 90.0)) 
    241242               elseif (jrratio.eq.1) then 
    242243                  !! CaCO3:      Ridgwell et al. (2007) submodel, version 1 
     
    248249                     fq1 = 0. 
    249250                  endif 
    250                   fcaco3(ji,jj) = xridg_r0 * fq1 
     251                  fcaco3 = xridg_r0 * fq1 
    251252               elseif (jrratio.eq.2) then 
    252253                  !! CaCO3:      Ridgwell et al. (2007) submodel, version 2 
     
    258259                     fq1 = 0. 
    259260                  endif 
    260                   fcaco3(ji,jj) = xridg_r0 * fq1 
     261                  fcaco3 = xridg_r0 * fq1 
    261262               endif 
    262             ENDIF 
    263          ENDDO 
    264       ENDDO 
    265263# else 
    266       DO jj = 2,jpjm1 
    267          DO ji = 2,jpim1 
    268             if (tmask(ji,jj,jk) == 1) then 
    269264               !! CaCO3:      latitudinally-based fraction of total primary 
    270265               !!              production 
    271266               !!               0.10 at equator; 0.02 at pole 
    272                fcaco3(ji,jj) = xcaco3a + ((xcaco3b - xcaco3a) *              & 
    273                                           ((90.0 - abs(gphit(ji,jj))) / 90.0)) 
    274             ENDIF 
    275          ENDDO 
    276       ENDDO 
     267               fcaco3 = xcaco3a + ((xcaco3b - xcaco3a) *                      & 
     268                                   ((90.0 - abs(gphit(ji,jj))) / 90.0)) 
    277269# endif 
    278  
    279       DO jj = 2,jpjm1 
    280          DO ji = 2,jpim1 
    281             if (tmask(ji,jj,jk) == 1) then 
    282270               !! AXY (09/03/09): convert CaCO3 production from function of  
    283271               !! primary production into a function of fast-sinking material;  
     
    286274               !! chlorophyll to an export flux for which they apply conversion  
    287275               !! factors to estimate the various elemental fractions (Si, Ca) 
    288                ftempca(ji,jj) = ftempc(ji,jj) * fcaco3(ji,jj) 
     276               ftempca(ji,jj) = ftempc(ji,jj) * fcaco3 
    289277 
    290278# if defined key_debug_medusa 
     
    316304                  IF (lwp) write (numout,*) 'flat(',jk,')    = ',             & 
    317305                                            abs(gphit(ji,jj)) 
    318                   IF (lwp) write (numout,*) 'fcaco3(',jk,')  = ', fcaco3(ji,jj) 
     306                  IF (lwp) write (numout,*) 'fcaco3(',jk,')  = ', fcaco3 
    319307               endif 
    320308# endif 
     
    428416                        if (fq4.lt.fq1) then 
    429417                           !! protected fraction of total organic C (non-dim) 
    430                            fprotf(ji,jj)   = (fq4 / (fq1 + tiny(fq1))) 
     418                           fprotf   = (fq4 / (fq1 + tiny(fq1))) 
    431419                        else 
    432420                           !! all organic C is protected (non-dim) 
    433                            fprotf(ji,jj)   = 1.0 
     421                           fprotf   = 1.0 
    434422                        endif 
    435423                        !! unprotected fraction of total organic C (non-dim) 
    436                         fq5      = (1.0 - fprotf(ji,jj)) 
     424                        fq5      = (1.0 - fprotf) 
    437425                        !! how much organic C is unprotected (mol) 
    438426                        fq6      = (fq0 * fq5) 
     
    440428                        fq7      = (fq6 * exp(-(fse3t(ji,jj,jk) / xfastc))) 
    441429                        !! how much total C leaves this box (mol) 
    442                         fq8      = (fq7 + (fq0 * fprotf(ji,jj))) 
     430                        fq8      = (fq7 + (fq0 * fprotf)) 
    443431                        !! C remineralisation in this box (mol) 
    444432                        freminc(ji,jj)  = (fq0 - fq8) / fse3t(ji,jj,jk) 
     
    454442                                       fq4 
    455443                              IF (lwp) write (numout,*) 'fprotf(',jk,')  = ', & 
    456                                        fprotf(ji,jj) 
     444                                       fprotf 
    457445                              IF (lwp) write (numout,*)                       & 
    458446                                       '------------------------------' 
     
    480468                     if (iball.eq.1) then 
    481469                        !! unprotected fraction of total organic N (non-dim) 
    482                         fq5      = (1.0 - fprotf(ji,jj)) 
     470                        fq5      = (1.0 - fprotf) 
    483471                        !! how much organic N is unprotected (mol) 
    484472                        fq6      = (fq0 * fq5) 
     
    486474                        fq7      = (fq6 * exp(-(fse3t(ji,jj,jk) / xfastc))) 
    487475                        !! how much total N leaves this box (mol) 
    488                         fq8      = (fq7 + (fq0 * fprotf(ji,jj))) 
     476                        fq8      = (fq7 + (fq0 * fprotf)) 
    489477                        !! N remineralisation in this box (mol) 
    490478                        freminn(ji,jj)  = (fq0 - fq8) / fse3t(ji,jj,jk) 
     
    498486                           IF (lwp) write (numout,*) 'prtctN(',jk,')  = ', fq4 
    499487                           IF (lwp) write (numout,*) 'fprotf(',jk,')  = ',    & 
    500                                     fprotf(ji,jj) 
     488                                    fprotf 
    501489                           IF (lwp) write (numout,*)                          & 
    502490                                    '------------------------------' 
     
    525513                     if (iball.eq.1) then 
    526514                        !! unprotected fraction of total organic Fe (non-dim) 
    527                         fq5      = (1.0 - fprotf(ji,jj)) 
     515                        fq5      = (1.0 - fprotf) 
    528516                        !! how much organic Fe is unprotected (mol) 
    529517                        fq6      = (fq0 * fq5) 
     
    531519                        fq7      = (fq6 * exp(-(fse3t(ji,jj,jk) / xfastc))) 
    532520                        !! how much total Fe leaves this box (mol) 
    533                         fq8      = (fq7 + (fq0 * fprotf(ji,jj))) 
     521                        fq8      = (fq7 + (fq0 * fprotf)) 
    534522                        !! Fe remineralisation in this box (mol) 
    535523                        freminfe(ji,jj) = (fq0 - fq8) / fse3t(ji,jj,jk) 
Note: See TracChangeset for help on using the changeset viewer.