/[MITgcm]/MITgcm/pkg/gchem/gchem_forcing_sep.F
ViewVC logotype

Annotation of /MITgcm/pkg/gchem/gchem_forcing_sep.F

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


Revision 1.21 - (hide annotations) (download)
Fri Jan 18 01:06:29 2008 UTC (16 years, 4 months ago) by dfer
Branch: MAIN
CVS Tags: checkpoint59o, checkpoint59n
Changes since 1.20: +4 -4 lines
A few "0. _d 0" that I missed a long time ago.

1 dfer 1.21 C $Header: /u/gcmpack/MITgcm/pkg/gchem/gchem_forcing_sep.F,v 1.20 2007/11/08 22:36:08 jmc Exp $
2 jmc 1.5 C $Name: $
3    
4 stephd 1.1 #include "GCHEM_OPTIONS.h"
5    
6 stephd 1.4 CBOP
7 mlosch 1.9 C !ROUTINE: GCHEM_FORCING_SEP
8 stephd 1.1 C !INTERFACE: ==========================================================
9     SUBROUTINE GCHEM_FORCING_SEP(myTime,myIter, myThid )
10    
11 stephd 1.4 C !DESCRIPTION:
12 mlosch 1.9 C calls subroutine that will update passive tracers values
13     C with a separate timestep. Since GCHEM_FORCING_SEP is now
14 jmc 1.17 C called before DO_FIELDS_BLOCKING_EXCHANGES, the passive
15     C tracer values in the halo regions are not up to date and
16 mlosch 1.9 C must not be used.
17 stephd 1.4
18     C !USES: ===============================================================
19 stephd 1.1 IMPLICIT NONE
20     #include "SIZE.h"
21     #include "GRID.h"
22     #include "DYNVARS.h"
23     #include "EEPARAMS.h"
24     #include "PARAMS.h"
25 jmc 1.5 #include "PTRACERS_SIZE.h"
26 jmc 1.17 c#include "PTRACERS_PARAMS.h"
27     #include "PTRACERS_FIELDS.h"
28 stephd 1.6 #ifdef ALLOW_DIC
29 stephd 1.1 #include "DIC_BIOTIC.h"
30     #include "DIC_ABIOTIC.h"
31 mlosch 1.9 #endif /* ALLOW_DIC */
32 stephd 1.1
33     C !INPUT PARAMETERS: ===================================================
34     C myThid :: thread number
35     INTEGER myThid, myIter
36     _RL myTime
37 stephd 1.4
38 stephd 1.6 c!LOCAL VARIABLES: ====================================================
39 stephd 1.4 C i,j :: loop indices
40     C bi,bj :: tile indices
41     C k :: vertical level
42 stephd 1.1 INTEGER bi,bj,imin,imax,jmin,jmax
43     INTEGER i,j
44     INTEGER niter
45 stephd 1.4 CEOP
46 stephd 1.1
47     #ifdef ALLOW_GCHEM
48 mlosch 1.10 #ifdef GCHEM_SEPARATE_FORCING
49 stephd 1.1
50     ccccccccccccccccccccccccc
51     c global calculations c
52     ccccccccccccccccccccccccc
53 stephd 1.11 #ifdef ALLOW_DIC
54 dfer 1.16 #ifdef ALLOW_OLD_VIRTUALFLUX
55 stephd 1.1 c find global surface averages
56 dfer 1.21 gsm_s = 0. _d 0
57     gsm_dic = 0. _d 0
58     gsm_alk = 0. _d 0
59 stephd 1.1 call tracer_meanarea(myThid,salt, 1,gsm_s)
60     call tracer_meanarea(myThid,
61     & ptracer(1-Olx,1-Oly,1,1,1,1), 1, gsm_dic)
62     print*,'mean surface dic', gsm_dic,gsm_s
63     call tracer_meanarea(myThid,
64     & ptracer(1-Olx,1-Oly,1,1,1,2), 1, gsm_alk)
65 dfer 1.16 #endif /* ALLOW_OLD_VIRTUALFLUX */
66 stephd 1.1 #endif
67     ccccccccccccccccccccccccccccccccccccccccccc
68    
69    
70     ccccccccccccccccccccccccc
71     c chemical forcing c
72     ccccccccccccccccccccccccc
73 stephd 1.3 C$taf loop = parallel
74 stephd 1.1 DO bj=myByLo(myThid),myByHi(myThid)
75 stephd 1.3 C$taf loop = parallel
76 stephd 1.1 DO bi=myBxLo(myThid),myBxHi(myThid)
77    
78 stephd 1.13 jMin=1
79     jMax=sNy
80     iMin=1
81     iMax=sNx
82 stephd 1.1 c
83     ccccccccccccccccccccccccccc DIC cccccccccccccccccccccccccccccccc
84     c
85 stephd 1.11 #ifdef ALLOW_DIC
86 stephd 1.1 #ifdef ALLOW_FE
87     call DIC_BIOTIC_Forcing( Ptracer(1-Olx,1-Oly,1,bi,bj,1),
88     & Ptracer(1-Olx,1-Oly,1,bi,bj,2),
89     & Ptracer(1-Olx,1-Oly,1,bi,bj,3),
90     & Ptracer(1-Olx,1-Oly,1,bi,bj,4),
91     & Ptracer(1-Olx,1-Oly,1,bi,bj,5),
92     & Ptracer(1-Olx,1-Oly,1,bi,bj,6),
93     & bi,bj,imin,imax,jmin,jmax,
94     & myIter,myTime,myThid)
95     #else
96 stephd 1.15 #ifdef ALLOW_O2
97 stephd 1.1 call DIC_BIOTIC_Forcing( Ptracer(1-Olx,1-Oly,1,bi,bj,1),
98     & Ptracer(1-Olx,1-Oly,1,bi,bj,2),
99     & Ptracer(1-Olx,1-Oly,1,bi,bj,3),
100     & Ptracer(1-Olx,1-Oly,1,bi,bj,4),
101     & Ptracer(1-Olx,1-Oly,1,bi,bj,5),
102     & bi,bj,imin,imax,jmin,jmax,
103     & myIter,myTime,myThid)
104 stephd 1.15 #else
105     call DIC_BIOTIC_Forcing( Ptracer(1-Olx,1-Oly,1,bi,bj,1),
106     & Ptracer(1-Olx,1-Oly,1,bi,bj,2),
107     & Ptracer(1-Olx,1-Oly,1,bi,bj,3),
108     & Ptracer(1-Olx,1-Oly,1,bi,bj,4),
109     & bi,bj,imin,imax,jmin,jmax,
110     & myIter,myTime,myThid)
111     #endif
112 stephd 1.1 #endif
113 stephd 1.18
114 stephd 1.1 #endif
115     cccccccccccccccccccccccccc END DIC cccccccccccccccccccccccccccccccccc
116 stephd 1.2
117 stephd 1.1 c
118     ENDDO
119     ENDDO
120    
121 stephd 1.19 #ifdef ALLOW_DIC
122 jmc 1.20 CALL DIC_ATMOS( 1, myTime, myIter, myThid )
123 stephd 1.19 #endif
124    
125 mlosch 1.10 #endif /* GCHEM_SEPARATE_FORCING */
126 stephd 1.1 #endif /* ALLOW_GCHEM */
127    
128     RETURN
129     END

  ViewVC Help
Powered by ViewVC 1.1.22