1 |
jahn |
1.3 |
C $Header: /u/gcmpack/MITgcm_contrib/darwin2/pkg/darwin/DARWIN_IO.h,v 1.2 2011/05/11 18:11:56 stephd Exp $ |
2 |
stephd |
1.2 |
C $Name: $ |
3 |
jahn |
1.1 |
|
4 |
|
|
#include "DARWIN_OPTIONS.h" |
5 |
|
|
|
6 |
|
|
c DARWIN_IO.h |
7 |
|
|
c -------------------------------------------------------------------- |
8 |
|
|
c Description: input and diagnostic output for DARWIN pkg |
9 |
|
|
c Stephanie Dutkiewicz: Spring 2006 |
10 |
|
|
c NOTE: additional diagnostics still needed |
11 |
|
|
c -------------------------------------------------------------------- |
12 |
|
|
|
13 |
|
|
C-- COMMON /DARWIN_FILENAMES/ |
14 |
|
|
C darwin_iceFile :: file name of seaice fraction |
15 |
|
|
C darwin_ironFile :: file name of aeolian iron flux |
16 |
|
|
C darwin_PARFile :: file name of Photosynthetically Active Radiation at surface |
17 |
|
|
C darwin_nutWVelFile :: file name of nutrient wvel |
18 |
|
|
C darwin_waterabsorbFile :: file name of water absorption/scattering spectra |
19 |
|
|
C darwin_phytoabsorbFile :: file name of phyto absorption/scattering spectra |
20 |
|
|
C darwin_particleabsorbFile :: file name of particle absorption/scattering spectra |
21 |
|
|
C darwin_surfacespecFile :: file name of spectrum of incident light |
22 |
|
|
C darwin_acdomFile :: file name of CDOM absorption spectrum |
23 |
jahn |
1.3 |
C darwin_PARunits :: units of data in PAR file; one of Ein/m2/d, uEin/m2/s, W/m2 |
24 |
|
|
C darwin_PARFileConv :: conversion factor from PAR file units to uEin/m2/s |
25 |
|
|
C darwin_W_to_uEins :: conversion factor from W to uEin/s |
26 |
jahn |
1.1 |
C darwin_forcingPeriod :: perioDARWIN forcing parameter specific for DARWIN (seconds) |
27 |
|
|
C darwin_forcingCycle :: perioDARWIN forcing parameter specific for DARWIN (seconds) |
28 |
|
|
C darwin_seed :: seed for the random number generator |
29 |
|
|
|
30 |
|
|
COMMON /DARWIN_FILENAMES/ |
31 |
|
|
& darwin_iceFile, |
32 |
|
|
& darwin_ironFile, |
33 |
|
|
& darwin_PARFile, |
34 |
|
|
& darwin_nutWVelFile, |
35 |
|
|
& darwin_PO4_relaxFile, darwin_NO3_relaxFile, |
36 |
|
|
& darwin_FeT_relaxFile, darwin_Si_relaxFile, |
37 |
|
|
& darwin_relaxscale, |
38 |
|
|
& darwin_PO4_fluxFile, darwin_NO3_FluxFile, |
39 |
|
|
& darwin_FeT_fluxFile, darwin_Si_fluxFile, |
40 |
|
|
& darwin_oasim_edFile, darwin_oasim_esFile, |
41 |
|
|
& darwin_waterabsorbFile, darwin_phytoabsorbFile, |
42 |
|
|
& darwin_surfacespecFile, darwin_acdomFile, |
43 |
|
|
& darwin_particleabsorbFile, |
44 |
jahn |
1.3 |
& darwin_PARunits, darwin_PARFileConv, |
45 |
|
|
& darwin_W_to_uEins, |
46 |
jahn |
1.1 |
& darwin_forcingPeriod, darwin_forcingCycle, |
47 |
|
|
& darwin_seed |
48 |
|
|
|
49 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_iceFile |
50 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_ironFile |
51 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_PARFile |
52 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_NutWVelFile |
53 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_PO4_relaxFile |
54 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_NO3_relaxFile |
55 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_FeT_relaxFile |
56 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_Si_relaxFile |
57 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_PO4_fluxFile |
58 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_NO3_fluxFile |
59 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_FeT_fluxFile |
60 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_Si_fluxFile |
61 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_oasim_edFile |
62 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_oasim_esFile |
63 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_waterabsorbFile |
64 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_phytoabsorbFile |
65 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_particleabsorbFile |
66 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_surfacespecFile |
67 |
|
|
CHARACTER*(MAX_LEN_FNAM) darwin_acdomFile |
68 |
jahn |
1.3 |
CHARACTER*(MAX_LEN_FNAM) darwin_PARunits |
69 |
jahn |
1.1 |
|
70 |
|
|
_RL darwin_relaxscale |
71 |
|
|
_RL darwin_forcingPeriod |
72 |
|
|
_RL darwin_forcingCycle |
73 |
jahn |
1.3 |
_RL darwin_PARFileConv |
74 |
|
|
_RL darwin_W_to_uEins |
75 |
jahn |
1.1 |
INTEGER darwin_seed |
76 |
|
|
|
77 |
|
|
c INPUT: |
78 |
|
|
c fice - ice fraction |
79 |
|
|
c inputFe - aeolian input of iron |
80 |
|
|
c sur_par - surface PAR |
81 |
|
|
COMMON /DARWIN_INPUT/ |
82 |
|
|
& fice, inputFe, sur_par |
83 |
|
|
#ifdef NUT_SUPPLY |
84 |
|
|
& ,nut_wvel |
85 |
|
|
#endif |
86 |
|
|
#ifdef RELAX_NUTS |
87 |
|
|
& ,po4_obs, no3_obs, fet_obs, si_obs |
88 |
|
|
#endif |
89 |
|
|
#ifdef FLUX_NUTS |
90 |
|
|
& ,po4_flx, no3_flx, fet_flx, si_flx |
91 |
|
|
#endif |
92 |
|
|
c |
93 |
|
|
_RL fice(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx, nSy) |
94 |
|
|
_RL inputFe(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx, nSy) |
95 |
|
|
_RL sur_par(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx, nSy) |
96 |
|
|
#ifdef NUT_SUPPLY |
97 |
|
|
_RL nut_wvel(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
98 |
|
|
#endif |
99 |
|
|
#ifdef RELAX_NUTS |
100 |
|
|
_RL po4_obs(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
101 |
|
|
_RL no3_obs(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
102 |
|
|
_RL fet_obs(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
103 |
|
|
_RL si_obs(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
104 |
|
|
#endif |
105 |
|
|
#ifdef FLUX_NUTS |
106 |
|
|
_RL po4_flx(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
107 |
|
|
_RL no3_flx(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
108 |
|
|
_RL fet_flx(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
109 |
|
|
_RL si_flx(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
110 |
|
|
#endif |
111 |
|
|
c |
112 |
|
|
c OUPUT DIAGNOSTICS |
113 |
|
|
c PPave - average primary production |
114 |
|
|
c Nfixave - average N fixation |
115 |
|
|
c Zoograzave - average zooplankton consumption |
116 |
|
|
c Parave - average PAR |
117 |
|
|
c Chlave - average chlorophyll |
118 |
|
|
c npzd_timeave - time for averaging |
119 |
|
|
|
120 |
|
|
COMMON /DARWIN_OUPUT/ |
121 |
|
|
& PPave, Nfixave, Zoograzave, |
122 |
|
|
& PARave, Chlave, Denitave, |
123 |
|
|
c ANNA_TAVE |
124 |
|
|
#ifdef WAVES_DIAG_PCHL |
125 |
|
|
& Pchlave, |
126 |
|
|
#endif |
127 |
|
|
#ifdef DAR_DIAG_ACDOM |
128 |
|
|
& aCDOMave, |
129 |
|
|
#endif |
130 |
|
|
c ANNA end TAVE |
131 |
|
|
#ifdef DAR_DIAG_RSTAR |
132 |
|
|
& Rstarave, RNstarave, |
133 |
|
|
#endif |
134 |
|
|
#ifdef DAR_DIAG_DIVER |
135 |
|
|
& Diver1ave, Diver2ave, Diver3ave, Diver4ave, |
136 |
|
|
#endif |
137 |
|
|
#ifdef DAR_DIAG_GROW |
138 |
|
|
& Growave, Growsqave, |
139 |
|
|
#endif |
140 |
|
|
#ifdef ALLOW_DIAZ |
141 |
|
|
#ifdef DAR_DIAG_NFIXP |
142 |
|
|
& NfixPave, |
143 |
|
|
#endif |
144 |
|
|
#endif |
145 |
|
|
& dar_timeave |
146 |
|
|
c |
147 |
|
|
_RL PPave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
148 |
|
|
_RL Nfixave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
149 |
|
|
_RL Zoograzave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
150 |
|
|
_RL PARave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
151 |
|
|
_RL Chlave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
152 |
|
|
_RL Denitave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
153 |
|
|
c ANNA_TAVE |
154 |
|
|
#ifdef WAVES_DIAG_PCHL |
155 |
|
|
_RL Pchlave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy,npmax) |
156 |
|
|
#endif |
157 |
|
|
#ifdef DAR_DIAG_ACDOM |
158 |
|
|
_RL aCDOMave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx,nSy) |
159 |
|
|
#endif |
160 |
|
|
c ANNA end TAVE |
161 |
|
|
#ifdef DAR_DIAG_RSTAR |
162 |
|
|
_RL Rstarave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy,npmax) |
163 |
|
|
_RL RNstarave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy,npmax) |
164 |
|
|
#endif |
165 |
|
|
#ifdef DAR_DIAG_DIVER |
166 |
|
|
_RL Diver1ave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
167 |
|
|
_RL Diver2ave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
168 |
|
|
_RL Diver3ave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
169 |
|
|
_RL Diver4ave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy) |
170 |
|
|
#endif |
171 |
|
|
#ifdef DAR_DIAG_GROW |
172 |
|
|
_RL Growave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy,npmax) |
173 |
|
|
_RL Growsqave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy,npmax) |
174 |
|
|
#endif |
175 |
|
|
#ifdef ALLOW_DIAZ |
176 |
|
|
#ifdef DAR_DIAG_NFIXP |
177 |
|
|
_RL NfixPave(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx, nSy,npmax) |
178 |
|
|
#endif |
179 |
|
|
#endif |
180 |
|
|
_RL DAR_timeave(nSx,nSy,nR) |
181 |
|
|
|
182 |
|
|
#ifdef CHECK_CONS |
183 |
|
|
COMMON /DARWIN_CHECK_CONS/ |
184 |
|
|
& DAR_cons_unit1, DAR_cons_unit2, |
185 |
|
|
& DAR_cons_unit3, DAR_cons_unit4, |
186 |
|
|
& DAR_cons_unit5, DAR_cons_unit6, |
187 |
|
|
& DAR_cons_unit7 |
188 |
|
|
INTEGER DAR_cons_unit1 |
189 |
|
|
INTEGER DAR_cons_unit2 |
190 |
|
|
INTEGER DAR_cons_unit3 |
191 |
|
|
INTEGER DAR_cons_unit4 |
192 |
|
|
INTEGER DAR_cons_unit5 |
193 |
|
|
INTEGER DAR_cons_unit6 |
194 |
|
|
INTEGER DAR_cons_unit7 |
195 |
|
|
#endif |
196 |
|
|
|
197 |
stephd |
1.2 |
#ifdef CALC_RATE_TOTALS |
198 |
|
|
COMMON /DARWIN_RATE_TOT/ |
199 |
|
|
& DAR_ratetot_unit, DAR_fluxtot_unit |
200 |
|
|
INTEGER DAR_ratetot_unit |
201 |
|
|
INTEGER DAR_fluxtot_unit |
202 |
|
|
#endif |
203 |
|
|
|
204 |
jahn |
1.1 |
#ifdef ALLOW_PAR_DAY |
205 |
|
|
C PARday :: array for accumulating/storing daily-averaged PAR |
206 |
|
|
COMMON /DARWIN_PAR_DAY/ PARday, |
207 |
|
|
& darwin_PARavPeriod, darwin_PARnav |
208 |
|
|
_RL PARday(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx,nSy,2) |
209 |
|
|
_RL darwin_PARavPeriod |
210 |
|
|
INTEGER darwin_PARnav |
211 |
|
|
#endif |
212 |
|
|
|
213 |
|
|
#ifdef ALLOW_CARBON |
214 |
|
|
C-- COMMON /DIC_FILENAMES/ |
215 |
|
|
C DIC_windFile :: file name of wind speeds |
216 |
|
|
C DIC_atmospFile :: file name of atmospheric pressure |
217 |
|
|
C dic_pCO2 :: Atmospheric pCO2 to be rad in data.dic |
218 |
|
|
C dic_int* :: place holder to read in a integer number, set at run time |
219 |
|
|
|
220 |
|
|
COMMON /DIC_FILENAMES/ |
221 |
|
|
& DIC_windFile, DIC_atmospFile, |
222 |
|
|
& dic_pCO2, dic_int1, dic_int2, dic_int3, dic_int4 |
223 |
|
|
CHARACTER*(MAX_LEN_FNAM) DIC_windFile |
224 |
|
|
CHARACTER*(MAX_LEN_FNAM) DIC_atmospFile |
225 |
|
|
_RL dic_pCO2 |
226 |
|
|
INTEGER dic_int1 |
227 |
|
|
INTEGER dic_int2 |
228 |
|
|
INTEGER dic_int3 |
229 |
|
|
INTEGER dic_int4 |
230 |
|
|
#endif |
231 |
|
|
|