/[MITgcm]/MITgcm/pkg/dic/o2_surfforcing.F
ViewVC logotype

Contents of /MITgcm/pkg/dic/o2_surfforcing.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.4 - (show annotations) (download)
Thu Feb 12 16:11:46 2004 UTC (20 years, 4 months ago) by stephd
Branch: MAIN
CVS Tags: checkpoint52l_pre, hrcube4, checkpoint52j_post, checkpoint52l_post, checkpoint52k_post, hrcube5, checkpoint52j_pre
Changes since 1.3: +20 -12 lines
o clean up and add extra documentation

1 #include "DIC_OPTIONS.h"
2 #include "GCHEM_OPTIONS.h"
3
4 CBOP
5 C !ROUTINE: O2_SURFFORCING
6
7 C !INTERFACE: ==========================================================
8 SUBROUTINE O2_SURFFORCING( PTR_O2, GO2,
9 I bi,bj,iMin,iMax,jMin,jMax,
10 I myIter, myTime, myThid )
11
12 C !DESCRIPTION:
13 C Calculate the oxygen air-sea flux terms
14
15 C !USES: ===============================================================
16 IMPLICIT NONE
17 #include "SIZE.h"
18 #include "DYNVARS.h"
19 #include "EEPARAMS.h"
20 #include "PARAMS.h"
21 #include "GRID.h"
22 #include "FFIELDS.h"
23 #ifdef DIC_BIOTIC
24 #include "DIC_ABIOTIC.h"
25 #include "PTRACERS.h"
26 #endif
27
28
29 c !INPUT PARAMETERS: ===================================================
30 C myThid :: thread number
31 C myIter :: current timestep
32 C myTime :: current time
33 C PTR_O2 :: oxygen tracer field
34 _RL myTime
35 _RL PTR_O2(1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr)
36 INTEGER iMin,iMax,jMin,jMax, bi, bj
37
38 c !OUTPUT PARAMETERS: ===================================================
39 C GO2 :: air-sea exchange of oxygen
40 _RL GO2(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
41
42 #ifdef ALLOW_PTRACERS
43
44
45 C !LOCAL VARIABLES: ===================================================
46 C I, J, K - Loop counters
47 INTEGER I,J,K
48 C Solubility relation coefficients
49 _RL SchmidtNoO2(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
50 _RL O2sat(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
51 _RL Kwexch(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
52 _RL FluxO2(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
53 _RL AtmosO2(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
54 _RL aTT
55 _RL aTK
56 _RL aTS
57 _RL aTS2
58 _RL aTS3
59 _RL aTS4
60 _RL aTS5
61 _RL o2s
62 _RL ttemp
63 _RL stemp
64 _RL oCnew
65 CEOP
66
67
68 K=1
69
70 C calculate SCHMIDT NO. for O2
71 DO j=jMin,jMax
72 DO i=iMin,iMax
73 IF (hFacC(i,j,k,bi,bj).NE.0.) THEN
74 SchmidtNoO2(i,j) =
75 & sox1
76 & + sox2 * theta(i,j,k,bi,bj)
77 & + sox3 * theta(i,j,k,bi,bj)*theta(i,j,k,bi,bj)
78 & + sox4 * theta(i,j,k,bi,bj)*theta(i,j,k,bi,bj)
79 & *theta(i,j,k,bi,bj)
80
81 C Determine surface flux of O2
82 C exchange coeff, accounting for ice cover and Schmidt no.
83 Kwexch(i,j) =
84 & pisvel(i,j,bi,bj)
85 & / sqrt(SchmidtNoO2(i,j)/660.0)
86 c ice influence
87 cQQ Kwexch(i,j) =(1.d0-Fice(i,j,bi,bj))*Kwexch(i,j)
88
89 ttemp = theta(i,j,k,bi,bj)
90 stemp = salt(i,j,k,bi,bj)
91 C determine saturation O2
92 C using Garcia and Gordon (1992), L&O (mistake in original???)
93 aTT = 298.15-ttemp
94 aTK = 273.15+ttemp
95 aTS = log(aTT/aTK)
96 aTS2 = aTS*aTS
97 aTS3 = aTS2*aTS
98 aTS4 = aTS3*aTS
99 aTS5 = aTS4*aTS
100
101 oCnew = oA0 + oA1*aTS + oA2*aTS2 + oA3*aTS3 +
102 & oA4*aTS4 + oA5*aTS5
103 & + stemp*(oB0 + oB1*aTS + oB2*aTS2 + oB3*aTS3)
104 & + oC0*(stemp*stemp)
105
106 o2s = EXP(oCnew)
107
108 c Convert from ml/l to mol/m^3
109 O2sat(i,j) = o2s/22391.6*1000.0
110
111 c Determine flux, inc. correction for local atmos surface pressure
112 cQQ PTR_O2?
113 FluxO2(i,j) = maskC(i,j,k,bi,bj)*Kwexch(i,j)*
114 & (atmosP(i,j,bi,bj)*O2sat(i,j)
115 & - PTR_O2(i,j,1))
116 ELSE
117 FluxO2(i,j) = 0.d0
118 ENDIF
119
120
121 END DO
122 END DO
123
124 C update surface tendencies
125 DO j=jMin,jMax
126 DO i=iMin,iMax
127 GO2(i,j)= maskC(i,j,1,bi,bj)*FluxO2(i,j)*recip_drF(1)
128 ENDDO
129 ENDDO
130 #endif
131
132
133 RETURN
134 END
135

  ViewVC Help
Powered by ViewVC 1.1.22