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.
trcdms_medusa.F90_COLIN4 in branches/NERC/dev_r5518_NOC_MEDUSA_Stable/NEMOGCM/NEMO/TOP_SRC/MEDUSA – NEMO

source: branches/NERC/dev_r5518_NOC_MEDUSA_Stable/NEMOGCM/NEMO/TOP_SRC/MEDUSA/trcdms_medusa.F90_COLIN4 @ 7720

Last change on this file since 7720 was 7720, checked in by jpalmier, 6 years ago

JPALM -- 23-02-2017 -- add new DMS testing config

File size: 8.3 KB
Line 
1MODULE trcdms_medusa
2   !!======================================================================
3   !!                         ***  MODULE trcdms_medusa  ***
4   !! TOP :   MEDUSA
5   !!======================================================================
6   !! History :
7   !!  -   !  2014-08  (J. Palmiéri - A. Yool)    added for UKESM1 project
8   !!----------------------------------------------------------------------
9#if defined key_medusa && defined key_roam
10   !!----------------------------------------------------------------------
11   !!                                        MEDUSA DMS surface concentration
12   !!----------------------------------------------------------------------
13   !!   trc_dms_medusa        : 
14   !!----------------------------------------------------------------------
15      USE oce_trc
16      USE trc
17      USE sms_medusa
18      USE lbclnk
19      USE prtctl_trc      ! Print control for debugging
20      USE in_out_manager  ! I/O manager
21
22      IMPLICIT NONE
23      PRIVATE
24
25      PUBLIC   trc_dms_medusa    ! called in trc_bio_medusa
26
27   !!* Substitution
28#  include "domzgr_substitute.h90"
29   !!----------------------------------------------------------------------
30   !! NEMO/TOP 2.0 , LOCEAN-IPSL (2007)
31   !! $Id$
32   !! Software governed by the CeCILL licence (modipsl/doc/NEMO_CeCILL.txt)
33   !!----------------------------------------------------------------------
34
35
36CONTAINS
37
38!=======================================================================
39!
40   SUBROUTINE trc_dms_medusa( chn, chd, mld, xqsr, xdin,   &  !! inputs
41     &  dms_andr, dms_simo, dms_aran, dms_hall )              !! outputs
42!     
43!=======================================================================
44      !!
45      !! Title  : Calculates DMS ocean surface concentration
46      !! Author : Julien Palmiéri and Andrew Yool
47      !! Date   : 08/08/14
48      !!
49      !! DMS module is called in trc_bio's huge jk,jj,ji loop
50      !! --> DMS concentration is calculated in a specific cell
51      !! (no need of ji,jj,jk)
52      !!
53      !! AXY (13/03/15): amend to include all four schemes tested
54      !!                 during winter/spring 2015; these are:
55      !!
56      !!                 1. Anderson et al. (2001); this uses fields
57      !!                    of surface chl, irradiance and nutrients
58      !!                    to empirically estimate DMS via a broken
59      !!                    stick approach
60      !!
61      !!                 2. Simo & Dachs (2002); this uses fields of
62      !!                    surface chl and mixed layer depth
63      !!
64      !!                 3. Aranami & Tsunogai (2004); this is an
65      !!                    embellishment of Simo & Dachs
66      !!
67      !!                 4. Halloran et al. (2010); this is an
68      !!                    alternative embellishment of Sim & Dachs
69      !!                    and is included because it is formally
70      !!                    published (and different from the above)
71      !!
72      !! AXY (08/07/15): amend to remove Julien's original calculation
73      !!                 as this is now superfluous; the four schemes
74      !!                 are calculated and one is chosen to be passed
75      !!                 to the atmosphere in trc_bio_medusa
76      !!
77!=======================================================================
78
79      IMPLICIT NONE
80!
81      REAL(wp), INTENT( in )    :: chn                  !! non-diatom chlorophyll    (mg/m3)
82      REAL(wp), INTENT( in )    :: chd                  !! diatom chlorophyll        (mg/m3)
83      REAL(wp), INTENT( in )    :: mld                  !! mix layer depth           (m)
84      REAL(wp), INTENT( in )    :: xqsr                 !! surface irradiance        (W/m2)
85      REAL(wp), INTENT( in )    :: xdin                 !! surface DIN               (mmol N/m3)
86      REAL(wp), INTENT( inout ) :: dms_andr             !! DMS surface concentration (nmol/L)
87      REAL(wp), INTENT( inout ) :: dms_simo             !! DMS surface concentration (nmol/L)
88      REAL(wp), INTENT( inout ) :: dms_aran             !! DMS surface concentration (nmol/L)
89      REAL(wp), INTENT( inout ) :: dms_hall             !! DMS surface concentration (nmol/L)
90!
91      REAL(wp) :: CHL, cmr, sw_dms
92      REAL(wp) :: Jterm, Qterm
93      !! temporary variables
94      REAL(wp) :: fq1,fq2,fq3
95! AXY (22/02/17): Colin Jones hack v4
96      REAL(wp) :: fracmin, mldeep1, mldeep2, mlda
97      REAL(wp) :: mldcntl1, mldcntl2, mldcntl3, mlduse
98!
99!=======================================================================
100!
101! AXY (13/03/15): per remarks above, the following calculations estimate
102!                 DMS using all of the schemes examined for UKESM1
103!
104      CHL = 0.0
105      CHL = chn+chd                                 !! mg/m3
106      cmr = CHL / mld
107!
108! AXY (13/03/15): Anderson et al. (2001)
109        Jterm = xqsr + 1.0e-6
110        !! this next line makes a hard-coded assumption about the
111        !! half-saturation constant of MEDUSA (which should be
112        !! done properly; perhaps even scaled with the proportion
113        !! of diatoms and non-diatoms)
114        Qterm = xdin / (xdin + 0.5)
115        fq1 = log10(CHL * Jterm * Qterm)
116        if (fq1 > 1.72) then
117           dms_andr = (8.24 * (fq1 - 1.72)) + 2.29
118        else
119           dms_andr = 2.29
120        endif
121!
122! AXY (13/03/15): Simo & Dachs (2002)
123        fq1 = (-1.0 * log(mld)) + 5.7
124        fq2 = (55.8 * cmr) + 0.6
125        if (cmr < 0.02) then
126           dms_simo = fq1
127        else
128           dms_simo = fq2
129        endif
130!           
131! AXY (13/03/15): Aranami & Tsunogai (2004)
132        fq1 = 60.0 / mld
133        fq2 = (55.8 * cmr) + 0.6
134        if (cmr < 0.02) then
135           dms_aran = fq1
136        else
137           dms_aran = fq2
138        endif
139!       
140! AXY (13/03/15): Halloran et al. (2010)
141        fq1 = (-1.0 * log(mld)) + 5.7
142        fq2 = (55.8 * cmr) + 0.6
143        fq3 = (90.0 / mld)
144        if (cmr < 0.02) then
145           dms_hall = fq1
146        else
147           dms_hall = fq2
148        endif
149        if (mld > 182.5) then
150           dms_hall = fq3
151        endif
152!
153! AXY (22/02/17): Aranami & Tsunogai (2004); Colin Jones hack v4
154!
155! This version modifies Aranami & Tsunogai (2004) to increase DMS
156! especially in the Southern Ocean; to avoid adding extra outputs,
157! it currently hijacks and overwrites Simo & Dachs (2002)
158!
159        fracmin  = 0.1   ! minimum value by which MLD is multiplied
160        mldeep1  = 12.0  ! MLD depth where modification begins to be applied
161        mldeep2  = 100.0 ! MLD depth where we maximise the effect to fracmin
162        mlda     = 3.0   ! power term of 1 - Q**mlda
163        mldcntl1 = 1.0   !
164        mldcntl2 = 1.0   ! initialised; just in case ...
165        mldcntl3 = 1.0   !
166!
167        if (mld .ge. mldeep1) then
168           ! mldcntl1 lies between 0.15 and 1.0 depending on the value of Q;
169           ! as Q increases towards 1, mldcntl1 tends to a minimum of 0.1
170           mldcntl1 = min(1.0, max(fracmin, (1.0 - Qterm**mlda)))
171           ! a second control lies between = 5 (mld = mldeep1) and = 1
172           ! (mld = mldeep2); this is used to ensure mldcntl1 primarily
173           ! operates on deep MLD with high Q values
174           mldcntl2 = min(5.0, max(1.0, (mldeep2 / mld)))
175           mldcntl3 = min(mldcntl1 * mldcntl2, 1.0)
176           mlduse   = mld * mldcntl3
177        else
178           mlduse   = mld
179        endif
180        cmr = CHL / mlduse
181        fq1 = 60.0 / mlduse
182        fq2 = (55.8 * cmr) + 0.6
183        if (cmr < 0.02) then
184           dms_simo = fq1
185        else
186           dms_simo = fq2
187        endif
188
189  END SUBROUTINE trc_dms_medusa
190
191
192!=======================================================================
193!=======================================================================
194!=======================================================================
195
196#else
197   !!======================================================================
198   !!  Dummy module :                                   No MEDUSA bio-model
199   !!======================================================================
200
201CONTAINS
202
203!=======================================================================
204!
205   SUBROUTINE trc_dms_medusa( kt )                                        !! EMPTY Routine
206!     
207!
208      INTEGER, INTENT( in ) ::   kt
209!
210
211      WRITE(*,*) 'trc_dms_medusa: You should not have seen this print! error?'
212
213   END SUBROUTINE trc_dms_medusa
214#endif
215
216   !!======================================================================
217END MODULE  trcdms_medusa
218
219
Note: See TracBrowser for help on using the repository browser.