/[MITgcm]/MITgcm/pkg/fizhi/fizhi_driver.F
ViewVC logotype

Contents of /MITgcm/pkg/fizhi/fizhi_driver.F

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


Revision 1.31 - (show annotations) (download)
Tue Oct 26 15:36:17 2004 UTC (19 years, 8 months ago) by molod
Branch: MAIN
CVS Tags: checkpoint55j_post, checkpoint56b_post, checkpoint55i_post, checkpoint56, checkpoint56a_post
Changes since 1.30: +2 -2 lines
Correct dimensions for edge level pressures ** kappa

1 C $Header: /u/gcmpack/MITgcm/pkg/fizhi/fizhi_driver.F,v 1.30 2004/10/26 01:03:41 molod Exp $
2 C $Name: $
3
4 #include "FIZHI_OPTIONS.h"
5 subroutine fizhi_driver (myid,im,jm,lm,bi,bj,ptracer,ntracer,
6 . xlats,xlons,
7 . p,u,v,t,q,pl,ple,dpres,pkht,pkl,surfz,fracland,landtype,radswt,
8 . phis_var,tgz,sea_ice,
9 . nchp,chlat,chlon,igrd,nchptot,nchpland,chfr,ityp,
10 . tcanopy,tdeep,ecanopy,swetshal,swetroot,swetdeep,capac,snodep,
11 . ctmt,xxmt,yymt,zetamt,xlmt,khmt,tke,
12 . albvisdr,albvisdf,albnirdr,albnirdf,emiss,alai,agrn,
13 . chemq,chemo3,co2,cfc11,cfc12,cfc22,methane,n2o,
14 . lwdt,lwdtclr,swdt,swdtclr,turbu,turbv,turbt,turbq,
15 . moistu,moistv,moistt,moistq,
16 . radswg,swgclr,fdirpar,fdifpar,osr,osrclr,tg0,radlwg,lwgclr,
17 . st4,dst4,dlwdtg,rainlsp,raincon,snowfall,iras,nlwcld,
18 . cldtot_lw,cldras_lw,cldlsp_lw,nlwlz,lwlz,nswcld,cldtot_sw,
19 . cldras_sw,cldlsp_sw,nswlz,swlz,imstturbsw,imstturblw,qliqavesw,
20 . qliqavelw,fccavesw,fccavelw,qq)
21 C***********************************************************************
22 C Purpose
23 C -------
24 C Driver for the FIZHI high-end Atmospheric Physics
25 C
26 C Arguments Description
27 C ----------------------
28 C nymd ..... Current YYMMDD
29 C nhms ..... Current HHMMSS
30 C fracland.. Land Fractions
31 C landtype.. Land Vegetation Types
32 C radswt ... Incident Solar Radiation
33 C
34 C***********************************************************************
35 implicit none
36
37 c Diagnostic Common
38 c -----------------
39 #ifdef ALLOW_DIAGNOSTICS
40 #include "SIZE.h"
41 #include "diagnostics_SIZE.h"
42 #include "diagnostics.h"
43 #endif
44
45 c Timers Common
46 c -------------
47 #include "chronos.h"
48
49 c Input Parameters
50 c ----------------
51 integer myid,im,jm,lm,bi,bj,ptracer,ntracer
52 integer nchp,igrd(nchp),nchptot,nchpland,ityp(nchp)
53 integer iras,nlwcld,nlwlz,nswcld,nswlz
54 integer imstturbsw,imstturblw
55
56 _RL xlats(im,jm), xlons(im,jm)
57 _RL p(im,jm)
58 _RL u(im,jm,lm),v(im,jm,lm),t(im,jm,lm)
59 _RL q(im,jm,lm,ntracer)
60 _RL pl(im,jm,lm),ple(im,jm,lm+1),dpres(im,jm,lm)
61 _RL pkht(im,jm,lm+1)
62 _RL pkl(im,jm,lm)
63 _RL surfz(im,jm)
64 _RL radswt(im,jm), fracland(im,jm)
65 integer landtype(im,jm)
66 _RL phis_var(im,jm), sea_ice(im,jm)
67 _RL chlat(nchp),chlon(nchp),chfr(nchp)
68 _RL tcanopy(nchp),tdeep(nchp),ecanopy(nchp),swetshal(nchp)
69 _RL swetroot(nchp),swetdeep(nchp),capac(nchp),snodep(nchp)
70 _RL ctmt(nchp),xxmt(nchp),yymt(nchp),zetamt(nchp)
71 _RL xlmt(nchp,lm),khmt(nchp,lm),tke(nchp,lm)
72 _RL co2,cfc11,cfc12,cfc22,methane(lm),n2o(lm)
73 _RL lwdt(im,jm,lm),lwdtclr(im,jm,lm)
74 _RL swdt(im,jm,lm),swdtclr(im,jm,lm)
75 _RL turbu(im,jm,lm),turbv(im,jm,lm),turbt(im,jm,lm)
76 _RL turbq(im,jm,lm,ntracer)
77 _RL moistu(im,jm,lm),moistv(im,jm,lm),moistt(im,jm,lm)
78 _RL moistq(im,jm,lm,ntracer)
79 _RL chemo3(im,jm,lm),chemq(im,jm,lm)
80 _RL albvisdr(im,jm),albvisdf(im,jm),albnirdr(im,jm)
81 _RL albnirdf(im,jm),emiss(im,jm,10)
82 _RL alai(nchp),agrn(nchp)
83 _RL radswg(im,jm),swgclr(im,jm)
84 _RL fdirpar(im,jm),fdifpar(im,jm),osr(im,jm),osrclr(im,jm)
85 _RL tg0(im,jm),radlwg(im,jm),lwgclr(im,jm),st4(im,jm)
86 _RL dst4(im,jm)
87 _RL dlwdtg(im,jm,lm)
88 _RL rainlsp(im,jm),raincon(im,jm),snowfall(im,jm)
89 _RL cldtot_lw(im,jm,lm),cldras_lw(im,jm,lm)
90 _RL cldlsp_lw(im,jm,lm)
91 _RL lwlz(im,jm,lm)
92 _RL cldtot_sw(im,jm,lm),cldras_sw(im,jm,lm)
93 _RL cldlsp_sw(im,jm,lm)
94 _RL swlz(im,jm,lm)
95 _RL qliqavesw(im,jm,lm),qliqavelw(im,jm,lm)
96 _RL fccavesw(im,jm,lm),fccavelw(im,jm,lm)
97 _RL qq(im,jm,lm)
98 _RL tgz(im,jm)
99
100 c Local Variables
101 c ---------------
102 _RL rfu(im,jm,lm),rfv(im,jm,lm),rft(im,jm,lm)
103 logical alarm
104 external alarm
105 integer numpcheck
106 parameter (numpcheck = 5)
107 integer pchecklevs(numpcheck)
108 _RL pcheckpress(numpcheck)
109 data pcheckpress/950.,750.,700.,400.,10./
110
111 integer low_level,mid_level,nltop,nsubmin,nsubmax,Lup
112 integer ndmoist,ndturb,ndlw,ndsw
113 integer istrip,npcs
114 integer i,j,L
115 integer ndum,ndpnt
116 _RL akap,getcon
117 _RL ptop
118 logical lpnt
119
120 istrip = im*jm
121 npcs = 1
122
123 ptop = 0.
124 akap = getcon('KAPPA')
125
126 C **********************************************************************
127 C **** Initialization ****
128 C **********************************************************************
129 call get_alarm ( 'radlw',ndum,ndum,ndlw ,ndum )
130 call get_alarm ( 'radsw',ndum,ndum,ndsw ,ndum )
131 call get_alarm ( 'turb' ,ndum,ndum,ndturb ,ndum )
132 call get_alarm ( 'moist',ndum,ndum,ndmoist,ndum )
133
134 call get_alarm ( 'pnt',ndum,ndum,ndpnt,ndum )
135 lpnt = ndpnt.ne.0
136
137 C Fill array of model levels closest to a given pressure value
138
139 call getpwhere(myid,numpcheck,pcheckpress,pchecklevs)
140
141 low_level = pchecklevs(3)
142 mid_level = pchecklevs(4)
143 nltop = pchecklevs(5)
144 nsubmin = pchecklevs(1)
145 nsubmax = pchecklevs(2)
146 Lup = pchecklevs(3)
147
148 C **********************************************************************
149 C **** Call Physics Mini-Drivers ****
150 C **********************************************************************
151
152 C SHORT WAVE RADIATION
153 C ====================
154 IF ( alarm('radsw') ) THEN
155
156 call swrio ( nymd,nhms,bi,bj,ndsw,myid,istrip,npcs,
157 . low_level,mid_level,im,jm,lm,
158 . p,pl,ple,dpres,pkht,pkl,t,chemq,chemo3,co2,
159 . albvisdr,albvisdf,albnirdr,albnirdf,swdt,swdtclr,
160 . radswg,swgclr,fdifpar,fdirpar,osr,osrclr,
161 . ptop,nswcld,cldtot_sw,cldras_sw,nswlz,swlz,
162 . .false.,imstturbsw,qliqavesw,
163 . fccavesw,landtype,xlats,xlons )
164
165 ENDIF
166
167 C LONG WAVE RADIATION
168 C ===================
169 IF ( alarm('radlw') ) THEN
170
171 c Set Reference Ground Temperature
172 c --------------------------------
173 do j=1,jm
174 do i=1,im
175 tg0(i,j) = tgz(i,j)
176 enddo
177 enddo
178
179 call lwrio ( nymd,nhms,bi,bj,istrip,npcs,
180 . low_level,mid_level,im,jm,lm,
181 . p,pl,ple,dpres,pkht,pkl,t,chemq,chemo3,co2,
182 . cfc11,cfc12,cfc22,methane,n2o,emiss,tgz,radlwg,st4,dst4,
183 . lwdt,dlwdtg,lwdtclr,lwgclr,
184 . nlwcld,cldtot_lw,cldras_lw,nlwlz,lwlz,
185 . .false.,imstturblw,qliqavelw,
186 . fccavelw,landtype )
187
188 ENDIF
189
190 C TURBULENCE
191 C ==========
192 IF ( alarm('turb') ) THEN
193
194 call turbio (im,jm,lm,istrip,nymd,nhms,bi,bj,ndturb,
195 . ptop,p,u,v,t,q,ntracer,ptracer,pl,ple,dpres,pkht,pkl,
196 . ctmt,xxmt,yymt,zetamt,xlmt,khmt,tke,
197 . tgz,fracland,landtype,
198 . tcanopy,ecanopy,tdeep,swetshal,swetroot,swetdeep,snodep,capac,
199 . nchp,nchptot,nchpland,chfr,chlat,chlon,igrd,ityp,
200 . alai,agrn,sea_ice,lpnt,
201 . turbu,turbv,turbt,turbq,radlwg,st4,dst4,radswg,radswt,
202 . fdifpar,fdirpar,rainlsp,raincon,snowfall,tg0,
203 . imstturblw,imstturbsw,qliqavelw,qliqavesw,fccavelw,fccavesw,qq,
204 . myid)
205
206 c Add Gravity-Wave Drag Tendency
207 c ------------------------------
208 C Comment this out for now - run tropospheric resolutions only.
209 C Need to see how to get zonal wavelengths on the cube.
210
211 c call gwdrag (myid,p,pl,ple,dpres,pkht,pkl,u,v,t,q,phis_var,
212 c . turbu,turbv,turbt,im,jm,lm,ptop,istrip,npcs,
213 c . imglobal)
214
215 c Add Rayleigh Friction Damping Above 70 Km
216 c -----------------------------------------
217
218 call rayleigh(myid,pl,pkl,pkht,surfz,u,v,t,q,im,jm,lm,
219 . bi,bj,rfu,rfv,rft)
220 C Now Add Rayleigh Friction Tendencies to Turb Tendency
221
222 do L=1,lm
223 do j=1,jm
224 do i=1,im
225 turbu(i,j,L) = turbu(i,j,L) + rfu(i,j,L)
226 turbv(i,j,L) = turbv(i,j,L) + rfv(i,j,L)
227 turbt(i,j,L) = turbt(i,j,L) + rft(i,j,L)
228 enddo
229 enddo
230 enddo
231
232 endif
233
234 C MOIST PROCESSES
235 C ===============
236 if ( alarm('moist') ) then
237 call moistio (ndmoist,istrip,npcs,
238 . low_level,mid_level,nltop,nsubmin,nsubmax,Lup,
239 . p,pl,ple,dpres,pkht,pkl,t,q,bi,bj,ntracer,ptracer,qq,
240 . moistu,moistv,moistt,moistq,im,jm,lm,ptop,iras,
241 . rainlsp,raincon,snowfall,
242 . nswcld,cldtot_sw,cldras_sw,cldlsp_sw,nswlz,swlz,
243 . nlwcld,cldtot_lw,cldras_lw,cldlsp_lw,nlwlz,lwlz,
244 . .false.,myid)
245 endif
246
247 return
248 end

  ViewVC Help
Powered by ViewVC 1.1.22