19 |
#include "PARAMS.h" |
#include "PARAMS.h" |
20 |
#include "GRID.h" |
#include "GRID.h" |
21 |
#include "PTRACERS_SIZE.h" |
#include "PTRACERS_SIZE.h" |
|
#include "PTRACERS_PARAMS.h" |
|
22 |
#include "PTRACERS_FIELDS.h" |
#include "PTRACERS_FIELDS.h" |
|
#include "GCHEM.h" |
|
23 |
#include "DIC_VARS.h" |
#include "DIC_VARS.h" |
24 |
#ifdef DIC_BIOTIC |
#ifdef DIC_BIOTIC |
25 |
#include "DIC_DIAGS.h" |
#include "DIC_DIAGS.h" |
26 |
#include "DIC_COST.h" |
#include "DIC_COST.h" |
27 |
#endif |
#endif |
|
c#ifdef ALLOW_SEAICE |
|
|
c#include "SEAICE.h" |
|
|
c#endif |
|
28 |
|
|
29 |
C == Routine arguments == |
C == Routine arguments == |
30 |
INTEGER myThid |
INTEGER myThid |
33 |
|
|
34 |
C == Local variables == |
C == Local variables == |
35 |
INTEGER i, j, bi, bj, k, it |
INTEGER i, j, bi, bj, k, it |
36 |
_RL po4av(nR) |
_RL po4av(Nr) |
37 |
_RL o2av(nR) |
_RL o2av(Nr) |
38 |
_RL volvar(nR) |
_RL volvar(Nr) |
39 |
cswdmonth -add- |
cswdmonth -add- |
40 |
_RL po4avm(12,4) |
_RL po4avm(12,4) |
41 |
_RL o2avm(12,4) |
_RL o2avm(12,4) |
80 |
enddo |
enddo |
81 |
ENDDO |
ENDDO |
82 |
ENDDO |
ENDDO |
|
_BEGIN_MASTER( myThid ) |
|
83 |
CALL READ_FLD_XYZ_RL( 'input/po4obs.bin', ' ', |
CALL READ_FLD_XYZ_RL( 'input/po4obs.bin', ' ', |
84 |
& po4obs, 0, myThid ) |
& po4obs, 0, myThid ) |
85 |
CALL READ_FLD_XYZ_RL( 'input/o2obs.bin', ' ', |
CALL READ_FLD_XYZ_RL( 'input/o2obs.bin', ' ', |
102 |
cQQ CALL READ_FLD_XYZ_RL( 'input/o2lev4.bin', ' ', |
cQQ CALL READ_FLD_XYZ_RL( 'input/o2lev4.bin', ' ', |
103 |
cQQ & o2obsl4, 0, myThid ) |
cQQ & o2obsl4, 0, myThid ) |
104 |
cswdmonth -end- |
cswdmonth -end- |
|
_END_MASTER(myThid) |
|
105 |
_EXCH_XYZ_R8(po4obs , myThid ) |
_EXCH_XYZ_R8(po4obs , myThid ) |
106 |
_EXCH_XYZ_R8(o2obs , myThid ) |
_EXCH_XYZ_R8(o2obs , myThid ) |
107 |
cswdmonth -add- |
cswdmonth -add- |
115 |
cQQ _EXCH_XYZ_R8(o2obsl4 , myThid ) |
cQQ _EXCH_XYZ_R8(o2obsl4 , myThid ) |
116 |
cswdmonth -end- |
cswdmonth -end- |
117 |
|
|
|
_BARRIER |
|
118 |
c calculate layer means |
c calculate layer means |
|
_BEGIN_MASTER( mythid ) |
|
119 |
do k=1,Nr |
do k=1,Nr |
120 |
call tracer_meanarea(myThid,po4obs, k, |
call tracer_meanarea(po4obs, k, |
121 |
& po4av(k)) |
& po4av(k),myThid) |
122 |
call tracer_meanarea(myThid,o2obs, k, |
call tracer_meanarea(o2obs, k, |
123 |
& o2av(k)) |
& o2av(k),myThid) |
124 |
c print*,po4av(k), o2av(k) |
c print*,po4av(k), o2av(k) |
125 |
enddo |
enddo |
126 |
cswdmonth -add- |
cswdmonth -add- |
127 |
do it=1,12 |
do it=1,MIN(12,Nr) |
128 |
call tracer_meanarea(myThid,po4obsl1,it, |
call tracer_meanarea(po4obsl1,it, |
129 |
& po4avm(it,1)) |
& po4avm(it,1),myThid) |
130 |
call tracer_meanarea(myThid,po4obsl2,it, |
call tracer_meanarea(po4obsl2,it, |
131 |
& po4avm(it,2)) |
& po4avm(it,2),myThid) |
132 |
call tracer_meanarea(myThid,po4obsl3,it, |
call tracer_meanarea(po4obsl3,it, |
133 |
& po4avm(it,3)) |
& po4avm(it,3),myThid) |
134 |
cQQ call tracer_meanarea(myThid,po4obsl4,it, |
cQQ call tracer_meanarea(po4obsl4,it, |
135 |
cQQ & po4avm(it,4)) |
cQQ & po4avm(it,4),myThid) |
136 |
call tracer_meanarea(myThid,o2obsl1,it, |
call tracer_meanarea(o2obsl1,it, |
137 |
& o2avm(it,1)) |
& o2avm(it,1),myThid) |
138 |
call tracer_meanarea(myThid,o2obsl2,it, |
call tracer_meanarea(o2obsl2,it, |
139 |
& o2avm(it,2)) |
& o2avm(it,2),myThid) |
140 |
call tracer_meanarea(myThid,o2obsl3,it, |
call tracer_meanarea(o2obsl3,it, |
141 |
& o2avm(it,3)) |
& o2avm(it,3),myThid) |
142 |
cQQ call tracer_meanarea(myThid,o2obsl4,it, |
cQQ call tracer_meanarea(o2obsl4,it, |
143 |
cQQ & o2avm(it,4)) |
cQQ & o2avm(it,4),myThid) |
144 |
|
|
145 |
enddo |
enddo |
|
_END_MASTER(myThid) |
|
146 |
c calculate layer variance |
c calculate layer variance |
|
_BEGIN_MASTER( mythid ) |
|
147 |
DO bj = myByLo(myThid), myByHi(myThid) |
DO bj = myByLo(myThid), myByHi(myThid) |
148 |
DO bi = myBxLo(myThid), myBxHi(myThid) |
DO bi = myBxLo(myThid), myBxHi(myThid) |
149 |
DO j=1-OLy,sNy+OLy |
DO j=1,sNy |
150 |
DO i=1-OLx,sNx+OLx |
DO i=1,sNx |
151 |
DO k=1,Nr |
DO k=1,Nr |
152 |
volvar(k)=volvar(k)+ |
volvar(k)=volvar(k)+ |
153 |
& rA(i,j,bi,bj)*drF(k)*maskC(i,j,k,bi,bj) |
& rA(i,j,bi,bj)*drF(k)*maskC(i,j,k,bi,bj) |
201 |
ENDDO |
ENDDO |
202 |
ENDDO |
ENDDO |
203 |
cswdmonth -end- |
cswdmonth -end- |
|
_END_MASTER(myThid) |
|
204 |
C |
C |
205 |
C Reset averages to zero |
C Reset averages to zero |
206 |
print*,'QQ dic_diags, set to zero, gchem_init' |
print*,'QQ dic_aver_init, set to zero' |
207 |
DO bj = myByLo(myThid), myByHi(myThid) |
DO bj = myByLo(myThid), myByHi(myThid) |
208 |
DO bi = myBxLo(myThid), myBxHi(myThid) |
DO bi = myBxLo(myThid), myBxHi(myThid) |
209 |
CALL TIMEAVE_RESET(PO4ann,Nr,bi,bj,myThid) |
CALL TIMEAVE_RESET(PO4ann,Nr,bi,bj,myThid) |
230 |
c |
c |
231 |
RETURN |
RETURN |
232 |
END |
END |
|
cswd -- end added subroutine -- |
|