1 | ! |
---|
2 | ! $Id: phys_state_var_mod.F90 1322 2010-03-12 10:54:11Z idelkadi $ |
---|
3 | ! |
---|
4 | MODULE phys_state_var_mod |
---|
5 | ! Variables sauvegardees pour le startphy.nc |
---|
6 | !====================================================================== |
---|
7 | ! |
---|
8 | ! |
---|
9 | !====================================================================== |
---|
10 | ! Declaration des variables |
---|
11 | USE dimphy |
---|
12 | INTEGER, PARAMETER :: nlevSTD=17 |
---|
13 | INTEGER, PARAMETER :: nout=3 |
---|
14 | INTEGER, PARAMETER :: napisccp=1 |
---|
15 | INTEGER, SAVE :: radpas |
---|
16 | REAL, SAVE :: dtime, solaire_etat0 |
---|
17 | !$OMP THREADPRIVATE(radpas) |
---|
18 | !$OMP THREADPRIVATE(dtime, solaire_etat0) |
---|
19 | |
---|
20 | REAL, ALLOCATABLE, SAVE :: rlat(:), rlon(:), pctsrf(:,:) |
---|
21 | !$OMP THREADPRIVATE(rlat, rlon, pctsrf) |
---|
22 | REAL, ALLOCATABLE, SAVE :: ftsol(:,:) |
---|
23 | !$OMP THREADPRIVATE(ftsol) |
---|
24 | ! character(len=6), SAVE :: ocean |
---|
25 | !!!!!!$OMP THREADPRIVATE(ocean) |
---|
26 | ! logical, SAVE :: ok_veget |
---|
27 | !!!!!!$OMP THREADPRIVATE(ok_veget) |
---|
28 | REAL, ALLOCATABLE, SAVE :: falb1(:,:), falb2(:,:) |
---|
29 | !$OMP THREADPRIVATE(falb1, falb2) |
---|
30 | REAL, ALLOCATABLE, SAVE :: rain_fall(:), snow_fall(:) |
---|
31 | !$OMP THREADPRIVATE( rain_fall, snow_fall) |
---|
32 | REAL, ALLOCATABLE, SAVE :: solsw(:), sollw(:) |
---|
33 | !$OMP THREADPRIVATE(solsw, sollw) |
---|
34 | REAL, ALLOCATABLE, SAVE :: radsol(:) |
---|
35 | !$OMP THREADPRIVATE(radsol) |
---|
36 | |
---|
37 | !clesphy0 param physiq |
---|
38 | ! |
---|
39 | ! Parametres de l'Orographie a l'Echelle Sous-Maille (OESM): |
---|
40 | ! |
---|
41 | REAL, ALLOCATABLE, SAVE :: zmea(:), zstd(:), zsig(:), zgam(:) |
---|
42 | !$OMP THREADPRIVATE(zmea, zstd, zsig, zgam) |
---|
43 | REAL, ALLOCATABLE, SAVE :: zthe(:), zpic(:), zval(:) |
---|
44 | !$OMP THREADPRIVATE(zthe, zpic, zval) |
---|
45 | ! REAL tabcntr0(100) |
---|
46 | REAL, ALLOCATABLE, SAVE :: rugoro(:) |
---|
47 | !$OMP THREADPRIVATE(rugoro) |
---|
48 | REAL, ALLOCATABLE, SAVE :: t_ancien(:,:), q_ancien(:,:) |
---|
49 | !$OMP THREADPRIVATE(t_ancien, q_ancien) |
---|
50 | REAL, ALLOCATABLE, SAVE :: u_ancien(:,:), v_ancien(:,:) |
---|
51 | !$OMP THREADPRIVATE(u_ancien, v_ancien) |
---|
52 | LOGICAL, SAVE :: ancien_ok |
---|
53 | !$OMP THREADPRIVATE(ancien_ok) |
---|
54 | REAL, ALLOCATABLE, SAVE :: clwcon(:,:),rnebcon(:,:) |
---|
55 | !$OMP THREADPRIVATE(clwcon,rnebcon) |
---|
56 | REAL, ALLOCATABLE, SAVE :: ratqs(:,:) |
---|
57 | !$OMP THREADPRIVATE(ratqs) |
---|
58 | REAL, ALLOCATABLE, SAVE :: pbl_tke(:,:,:) ! turb kinetic energy |
---|
59 | !$OMP THREADPRIVATE(pbl_tke) |
---|
60 | REAL, ALLOCATABLE, SAVE :: zmax0(:), f0(:) ! |
---|
61 | !$OMP THREADPRIVATE(zmax0,f0) |
---|
62 | REAL, ALLOCATABLE, SAVE :: ema_work1(:,:), ema_work2(:,:) |
---|
63 | !$OMP THREADPRIVATE(ema_work1,ema_work2) |
---|
64 | REAL, ALLOCATABLE, SAVE :: entr_therm(:,:), fm_therm(:,:) |
---|
65 | !$OMP THREADPRIVATE(entr_therm,fm_therm) |
---|
66 | REAL, ALLOCATABLE, SAVE :: detr_therm(:,:) |
---|
67 | !$OMP THREADPRIVATE(detr_therm) |
---|
68 | !IM 150408 |
---|
69 | ! pour phsystoke avec thermiques |
---|
70 | REAL,ALLOCATABLE,SAVE :: clwcon0th(:,:),rnebcon0th(:,:) |
---|
71 | !$OMP THREADPRIVATE(clwcon0th,rnebcon0th) |
---|
72 | ! radiation outputs |
---|
73 | REAL,ALLOCATABLE,SAVE :: swdn0(:,:), swdn(:,:) |
---|
74 | !$OMP THREADPRIVATE(swdn0,swdn) |
---|
75 | REAL,ALLOCATABLE,SAVE :: swup0(:,:), swup(:,:) |
---|
76 | !$OMP THREADPRIVATE(swup0,swup) |
---|
77 | REAL,ALLOCATABLE,SAVE :: SWdn200clr(:), SWdn200(:) |
---|
78 | !$OMP THREADPRIVATE(SWdn200clr,SWdn200) |
---|
79 | REAL,ALLOCATABLE,SAVE :: SWup200clr(:), SWup200(:) |
---|
80 | !$OMP THREADPRIVATE(SWup200clr,SWup200) |
---|
81 | REAL,ALLOCATABLE,SAVE :: lwdn0(:,:), lwdn(:,:) |
---|
82 | !$OMP THREADPRIVATE(lwdn0,lwdn) |
---|
83 | REAL,ALLOCATABLE,SAVE :: lwup0(:,:), lwup(:,:) |
---|
84 | !$OMP THREADPRIVATE(lwup0,lwup) |
---|
85 | REAL,ALLOCATABLE,SAVE :: LWdn200clr(:), LWdn200(:) |
---|
86 | !$OMP THREADPRIVATE(LWdn200clr,LWdn200) |
---|
87 | REAL,ALLOCATABLE,SAVE :: LWup200clr(:), LWup200(:) |
---|
88 | !$OMP THREADPRIVATE(LWup200clr,LWup200) |
---|
89 | REAL,ALLOCATABLE,SAVE :: LWdnTOA(:), LWdnTOAclr(:) |
---|
90 | !$OMP THREADPRIVATE(LWdnTOA,LWdnTOAclr) |
---|
91 | ! pressure level |
---|
92 | REAL,ALLOCATABLE,SAVE :: tsumSTD(:,:,:) |
---|
93 | !$OMP THREADPRIVATE(tsumSTD) |
---|
94 | REAL,ALLOCATABLE,SAVE :: usumSTD(:,:,:), vsumSTD(:,:,:) |
---|
95 | !$OMP THREADPRIVATE(usumSTD,vsumSTD) |
---|
96 | REAL,ALLOCATABLE,SAVE :: wsumSTD(:,:,:), phisumSTD(:,:,:) |
---|
97 | !$OMP THREADPRIVATE(wsumSTD,phisumSTD) |
---|
98 | REAL,ALLOCATABLE,SAVE :: qsumSTD(:,:,:), rhsumSTD(:,:,:) |
---|
99 | !$OMP THREADPRIVATE(qsumSTD,rhsumSTD) |
---|
100 | REAL,ALLOCATABLE,SAVE :: tnondef(:,:,:) |
---|
101 | !$OMP THREADPRIVATE(tnondef) |
---|
102 | REAL,ALLOCATABLE,SAVE :: uvsumSTD(:,:,:) |
---|
103 | !$OMP THREADPRIVATE(uvsumSTD) |
---|
104 | REAL,ALLOCATABLE,SAVE :: vqsumSTD(:,:,:) |
---|
105 | !$OMP THREADPRIVATE(vqsumSTD) |
---|
106 | REAL,ALLOCATABLE,SAVE :: vTsumSTD(:,:,:) |
---|
107 | !$OMP THREADPRIVATE(vTsumSTD) |
---|
108 | REAL,ALLOCATABLE,SAVE :: wqsumSTD(:,:,:) |
---|
109 | !$OMP THREADPRIVATE(wqsumSTD) |
---|
110 | REAL,ALLOCATABLE,SAVE :: vphisumSTD(:,:,:) |
---|
111 | !$OMP THREADPRIVATE(vphisumSTD) |
---|
112 | REAL,ALLOCATABLE,SAVE :: wTsumSTD(:,:,:) |
---|
113 | !$OMP THREADPRIVATE(wTsumSTD) |
---|
114 | REAL,ALLOCATABLE,SAVE :: u2sumSTD(:,:,:) |
---|
115 | !$OMP THREADPRIVATE(u2sumSTD) |
---|
116 | REAL,ALLOCATABLE,SAVE :: v2sumSTD(:,:,:) |
---|
117 | !$OMP THREADPRIVATE(v2sumSTD) |
---|
118 | REAL,ALLOCATABLE,SAVE :: T2sumSTD(:,:,:) |
---|
119 | !$OMP THREADPRIVATE(T2sumSTD) |
---|
120 | INTEGER,ALLOCATABLE,SAVE :: seed_old(:,:) |
---|
121 | !$OMP THREADPRIVATE(seed_old) |
---|
122 | REAL,ALLOCATABLE,SAVE :: zuthe(:),zvthe(:) |
---|
123 | !$OMP THREADPRIVATE(zuthe,zvthe) |
---|
124 | REAL,ALLOCATABLE,SAVE :: alb_neig(:) |
---|
125 | !$OMP THREADPRIVATE(alb_neig) |
---|
126 | !cloud base mass flux |
---|
127 | REAL,ALLOCATABLE,SAVE :: ema_workcbmf(:), ema_cbmf(:) |
---|
128 | !$OMP THREADPRIVATE(ema_workcbmf,ema_cbmf) |
---|
129 | !cloud base pressure & cloud top pressure |
---|
130 | REAL,ALLOCATABLE,SAVE :: ema_pcb(:), ema_pct(:) |
---|
131 | !$OMP THREADPRIVATE(ema_pcb,ema_pct) |
---|
132 | REAL,ALLOCATABLE,SAVE :: Ma(:,:) ! undilute upward mass flux |
---|
133 | !$OMP THREADPRIVATE(Ma) |
---|
134 | REAL,ALLOCATABLE,SAVE :: qcondc(:,:) ! in-cld water content from convect |
---|
135 | !$OMP THREADPRIVATE(qcondc) |
---|
136 | REAL,ALLOCATABLE,SAVE :: wd(:) ! sb |
---|
137 | !$OMP THREADPRIVATE(wd) |
---|
138 | REAL,ALLOCATABLE,SAVE :: sigd(:) |
---|
139 | !$OMP THREADPRIVATE(sigd) |
---|
140 | ! |
---|
141 | REAL,ALLOCATABLE,SAVE :: cin(:) |
---|
142 | !$OMP THREADPRIVATE(cin) |
---|
143 | ! ftd : differential heating between wake and environment |
---|
144 | REAL,ALLOCATABLE,SAVE :: ftd(:,:) |
---|
145 | !$OMP THREADPRIVATE(ftd) |
---|
146 | ! fqd : differential moistening between wake and environment |
---|
147 | REAL,ALLOCATABLE,SAVE :: fqd(:,:) |
---|
148 | !$OMP THREADPRIVATE(fqd) |
---|
149 | !34EK |
---|
150 | ! -- Variables de controle de ALE et ALP |
---|
151 | !ALE : Energie disponible pour soulevement : utilisee par la |
---|
152 | ! convection d'Emanuel pour le declenchement et la regulation |
---|
153 | REAL,ALLOCATABLE,SAVE :: ALE(:) |
---|
154 | !$OMP THREADPRIVATE(ALE) |
---|
155 | !ALP : Puissance disponible pour soulevement |
---|
156 | REAL,ALLOCATABLE,SAVE :: ALP(:) |
---|
157 | !$OMP THREADPRIVATE(ALP) |
---|
158 | ! |
---|
159 | ! nouvelles variables pour le couplage convection-couche limite |
---|
160 | REAL,ALLOCATABLE,SAVE :: Ale_bl(:) |
---|
161 | !$OMP THREADPRIVATE(Ale_bl) |
---|
162 | REAL,ALLOCATABLE,SAVE :: Alp_bl(:) |
---|
163 | !$OMP THREADPRIVATE(Alp_bl) |
---|
164 | INTEGER,ALLOCATABLE,SAVE :: lalim_conv(:) |
---|
165 | !$OMP THREADPRIVATE(lalim_conv) |
---|
166 | REAL,ALLOCATABLE,SAVE :: wght_th(:,:) |
---|
167 | !$OMP THREADPRIVATE(wght_th) |
---|
168 | ! |
---|
169 | ! variables de la wake |
---|
170 | ! wake_deltat : ecart de temperature avec la zone non perturbee |
---|
171 | ! wake_deltaq : ecart d'humidite avec la zone non perturbee |
---|
172 | ! wake_Cstar : vitesse d'etalement de la poche |
---|
173 | ! wake_s : fraction surfacique occupee par la poche froide |
---|
174 | ! wake_pe : wake potential energy - WAPE |
---|
175 | ! wake_fip : Gust Front Impinging power - ALP |
---|
176 | ! dt_wake, dq_wake: LS tendencies due to wake |
---|
177 | REAL,ALLOCATABLE,SAVE :: wake_deltat(:,:) |
---|
178 | !$OMP THREADPRIVATE(wake_deltat) |
---|
179 | REAL,ALLOCATABLE,SAVE :: wake_deltaq(:,:) |
---|
180 | !$OMP THREADPRIVATE(wake_deltaq) |
---|
181 | REAL,ALLOCATABLE,SAVE :: wake_Cstar(:) |
---|
182 | !$OMP THREADPRIVATE(wake_Cstar) |
---|
183 | REAL,ALLOCATABLE,SAVE :: wake_s(:) |
---|
184 | !$OMP THREADPRIVATE(wake_s) |
---|
185 | REAL,ALLOCATABLE,SAVE :: wake_pe(:) |
---|
186 | !$OMP THREADPRIVATE(wake_pe) |
---|
187 | REAL,ALLOCATABLE,SAVE :: wake_fip(:) |
---|
188 | !$OMP THREADPRIVATE(wake_fip) |
---|
189 | REAL,ALLOCATABLE,SAVE :: dt_wake(:,:) |
---|
190 | !$OMP THREADPRIVATE(dt_wake) |
---|
191 | REAL,ALLOCATABLE,SAVE :: dq_wake(:,:) |
---|
192 | !$OMP THREADPRIVATE(dq_wake) |
---|
193 | ! |
---|
194 | ! pfrac_impa : Produits des coefs lessivage impaction |
---|
195 | ! pfrac_nucl : Produits des coefs lessivage nucleation |
---|
196 | ! pfrac_1nucl: Produits des coefs lessi nucl (alpha = 1) |
---|
197 | REAL,ALLOCATABLE,SAVE :: pfrac_impa(:,:), pfrac_nucl(:,:) |
---|
198 | !$OMP THREADPRIVATE(pfrac_impa,pfrac_nucl) |
---|
199 | REAL,ALLOCATABLE,SAVE :: pfrac_1nucl(:,:) |
---|
200 | !$OMP THREADPRIVATE(pfrac_1nucl) |
---|
201 | ! |
---|
202 | REAL,ALLOCATABLE,SAVE :: total_rain(:), nday_rain(:) |
---|
203 | !$OMP THREADPRIVATE(total_rain,nday_rain) |
---|
204 | REAL,ALLOCATABLE,SAVE :: paire_ter(:) |
---|
205 | !$OMP THREADPRIVATE(paire_ter) |
---|
206 | ! albsol1: albedo du sol total pour SW visible |
---|
207 | ! albsol2: albedo du sol total pour SW proche IR |
---|
208 | REAL,ALLOCATABLE,SAVE :: albsol1(:), albsol2(:) |
---|
209 | !$OMP THREADPRIVATE(albsol1,albsol2) |
---|
210 | |
---|
211 | REAL, ALLOCATABLE, SAVE:: wo(:, :, :) |
---|
212 | ! column-density of ozone in a layer, in kilo-Dobsons |
---|
213 | ! Third dimension has size 1 or 2. |
---|
214 | ! "wo(:, :, 1)" is for the average day-night field, |
---|
215 | ! "wo(:, :, 2)" is for daylight time. |
---|
216 | !$OMP THREADPRIVATE(wo) |
---|
217 | |
---|
218 | ! heat : chauffage solaire |
---|
219 | ! heat0: chauffage solaire ciel clair |
---|
220 | ! cool : refroidissement infrarouge |
---|
221 | ! cool0 : refroidissement infrarouge ciel clair |
---|
222 | ! sollwdown : downward LW flux at surface |
---|
223 | ! sollwdownclr : downward CS LW flux at surface |
---|
224 | ! toplwdown : downward CS LW flux at TOA |
---|
225 | ! toplwdownclr : downward CS LW flux at TOA |
---|
226 | REAL,ALLOCATABLE,SAVE :: clwcon0(:,:),rnebcon0(:,:) |
---|
227 | !$OMP THREADPRIVATE(clwcon0,rnebcon0) |
---|
228 | REAL,ALLOCATABLE,SAVE :: heat(:,:) |
---|
229 | !$OMP THREADPRIVATE(heat) |
---|
230 | REAL,ALLOCATABLE,SAVE :: heat0(:,:) |
---|
231 | !$OMP THREADPRIVATE(heat0) |
---|
232 | REAL,ALLOCATABLE,SAVE :: cool(:,:) |
---|
233 | !$OMP THREADPRIVATE(cool) |
---|
234 | REAL,ALLOCATABLE,SAVE :: cool0(:,:) |
---|
235 | !$OMP THREADPRIVATE(cool0) |
---|
236 | REAL,ALLOCATABLE,SAVE :: topsw(:), toplw(:) |
---|
237 | !$OMP THREADPRIVATE(topsw,toplw) |
---|
238 | REAL,ALLOCATABLE,SAVE :: sollwdown(:) |
---|
239 | !$OMP THREADPRIVATE(sollwdown) |
---|
240 | REAL,ALLOCATABLE,SAVE :: sollwdownclr(:) |
---|
241 | !$OMP THREADPRIVATE(sollwdownclr) |
---|
242 | REAL,ALLOCATABLE,SAVE :: toplwdown(:) |
---|
243 | !$OMP THREADPRIVATE(toplwdown) |
---|
244 | REAL,ALLOCATABLE,SAVE :: toplwdownclr(:) |
---|
245 | !$OMP THREADPRIVATE(toplwdownclr) |
---|
246 | REAL,ALLOCATABLE,SAVE :: topsw0(:),toplw0(:),solsw0(:),sollw0(:) |
---|
247 | !$OMP THREADPRIVATE(topsw0,toplw0,solsw0,sollw0) |
---|
248 | REAL,ALLOCATABLE,SAVE :: albpla(:) |
---|
249 | !$OMP THREADPRIVATE(albpla) |
---|
250 | ! pbase : cloud base pressure |
---|
251 | ! bbase : cloud base buoyancy |
---|
252 | REAL,ALLOCATABLE,SAVE :: cape(:) |
---|
253 | !$OMP THREADPRIVATE(cape) |
---|
254 | REAL,ALLOCATABLE,SAVE :: pbase(:) |
---|
255 | !$OMP THREADPRIVATE(pbase) |
---|
256 | REAL,ALLOCATABLE,SAVE :: bbase(:) |
---|
257 | !$OMP THREADPRIVATE(bbase) |
---|
258 | ! |
---|
259 | REAL,SAVE,ALLOCATABLE :: zqasc(:,:) |
---|
260 | !$OMP THREADPRIVATE( zqasc) |
---|
261 | INTEGER,ALLOCATABLE,SAVE :: ibas_con(:), itop_con(:) |
---|
262 | !$OMP THREADPRIVATE(ibas_con,itop_con) |
---|
263 | REAL,SAVE,ALLOCATABLE :: rain_con(:) |
---|
264 | !$OMP THREADPRIVATE(rain_con) |
---|
265 | REAL,SAVE,ALLOCATABLE :: snow_con(:) |
---|
266 | !$OMP THREADPRIVATE(snow_con) |
---|
267 | ! |
---|
268 | REAL,SAVE,ALLOCATABLE :: rlonPOS(:) |
---|
269 | !$OMP THREADPRIVATE(rlonPOS) |
---|
270 | REAL,SAVE,ALLOCATABLE :: newsst(:) |
---|
271 | !$OMP THREADPRIVATE(newsst) |
---|
272 | REAL,SAVE,ALLOCATABLE :: u10m(:,:), v10m(:,:) |
---|
273 | !$OMP THREADPRIVATE(u10m,v10m) |
---|
274 | ! |
---|
275 | ! ok_ade=T -ADE=topswad-topsw |
---|
276 | ! ok_aie=T -> |
---|
277 | ! ok_ade=T -AIE=topswai-topswad |
---|
278 | ! ok_ade=F -AIE=topswai-topsw |
---|
279 | ! |
---|
280 | !topswad, solswad : Aerosol direct effect |
---|
281 | REAL,SAVE,ALLOCATABLE :: topswad(:), solswad(:) |
---|
282 | !$OMP THREADPRIVATE(topswad,solswad) |
---|
283 | !topswai, solswai : Aerosol indirect effect |
---|
284 | REAL,SAVE,ALLOCATABLE :: topswai(:), solswai(:) |
---|
285 | !$OMP THREADPRIVATE(topswai,solswai) |
---|
286 | |
---|
287 | REAL,SAVE,ALLOCATABLE :: tau_aero(:,:,:,:), piz_aero(:,:,:,:), cg_aero(:,:,:,:) |
---|
288 | !$OMP THREADPRIVATE(tau_aero, piz_aero, cg_aero) |
---|
289 | REAL,SAVE,ALLOCATABLE :: ccm(:,:,:) |
---|
290 | !$OMP THREADPRIVATE(ccm) |
---|
291 | |
---|
292 | CONTAINS |
---|
293 | |
---|
294 | !====================================================================== |
---|
295 | SUBROUTINE phys_state_var_init(read_climoz) |
---|
296 | use dimphy |
---|
297 | USE control_mod |
---|
298 | use aero_mod |
---|
299 | IMPLICIT NONE |
---|
300 | |
---|
301 | integer, intent(in):: read_climoz |
---|
302 | ! read ozone climatology |
---|
303 | ! Allowed values are 0, 1 and 2 |
---|
304 | ! 0: do not read an ozone climatology |
---|
305 | ! 1: read a single ozone climatology that will be used day and night |
---|
306 | ! 2: read two ozone climatologies, the average day and night |
---|
307 | ! climatology and the daylight climatology |
---|
308 | |
---|
309 | #include "indicesol.h" |
---|
310 | ALLOCATE(rlat(klon), rlon(klon)) |
---|
311 | ALLOCATE(pctsrf(klon,nbsrf)) |
---|
312 | ALLOCATE(ftsol(klon,nbsrf)) |
---|
313 | ALLOCATE(falb1(klon,nbsrf)) |
---|
314 | ALLOCATE(falb2(klon,nbsrf)) |
---|
315 | ALLOCATE(rain_fall(klon)) |
---|
316 | ALLOCATE(snow_fall(klon)) |
---|
317 | ALLOCATE(solsw(klon), sollw(klon)) |
---|
318 | ALLOCATE(radsol(klon)) |
---|
319 | ALLOCATE(zmea(klon), zstd(klon), zsig(klon), zgam(klon)) |
---|
320 | ALLOCATE(zthe(klon), zpic(klon), zval(klon)) |
---|
321 | |
---|
322 | ALLOCATE(rugoro(klon)) |
---|
323 | ALLOCATE(t_ancien(klon,klev), q_ancien(klon,klev)) |
---|
324 | ALLOCATE(u_ancien(klon,klev), v_ancien(klon,klev)) |
---|
325 | ALLOCATE(clwcon(klon,klev),rnebcon(klon,klev)) |
---|
326 | ALLOCATE(ratqs(klon,klev)) |
---|
327 | ALLOCATE(pbl_tke(klon,klev+1,nbsrf)) |
---|
328 | ALLOCATE(zmax0(klon), f0(klon)) |
---|
329 | ALLOCATE(ema_work1(klon,klev), ema_work2(klon,klev)) |
---|
330 | ALLOCATE(entr_therm(klon,klev), fm_therm(klon,klev+1)) |
---|
331 | ALLOCATE(detr_therm(klon,klev)) |
---|
332 | ! pour phsystoke avec thermiques |
---|
333 | ALLOCATE(clwcon0th(klon,klev),rnebcon0th(klon,klev)) |
---|
334 | ! radiation outputs |
---|
335 | ALLOCATE(swdn0(klon,klevp1), swdn(klon,klevp1)) |
---|
336 | ALLOCATE(swup0(klon,klevp1), swup(klon,klevp1)) |
---|
337 | ALLOCATE(lwdn0(klon,klevp1), lwdn(klon,klevp1)) |
---|
338 | ALLOCATE(lwup0(klon,klevp1), lwup(klon,klevp1)) |
---|
339 | ALLOCATE(SWdn200clr(klon), SWdn200(klon)) |
---|
340 | ALLOCATE(SWup200clr(klon), SWup200(klon)) |
---|
341 | ALLOCATE(LWdn200clr(klon), LWdn200(klon)) |
---|
342 | ALLOCATE(LWup200clr(klon), LWup200(klon)) |
---|
343 | ALLOCATE(LWdnTOA(klon), LWdnTOAclr(klon)) |
---|
344 | ! pressure level |
---|
345 | ALLOCATE(tsumSTD(klon,nlevSTD,nout)) |
---|
346 | ALLOCATE(usumSTD(klon,nlevSTD,nout), vsumSTD(klon,nlevSTD,nout)) |
---|
347 | ALLOCATE(wsumSTD(klon,nlevSTD,nout), phisumSTD(klon,nlevSTD,nout)) |
---|
348 | ALLOCATE(qsumSTD(klon,nlevSTD,nout), rhsumSTD(klon,nlevSTD,nout)) |
---|
349 | ALLOCATE(tnondef(klon,nlevSTD,nout)) |
---|
350 | ALLOCATE(uvsumSTD(klon,nlevSTD,nout)) |
---|
351 | ALLOCATE(vqsumSTD(klon,nlevSTD,nout)) |
---|
352 | ALLOCATE(vTsumSTD(klon,nlevSTD,nout)) |
---|
353 | ALLOCATE(wqsumSTD(klon,nlevSTD,nout)) |
---|
354 | ALLOCATE(vphisumSTD(klon,nlevSTD,nout)) |
---|
355 | ALLOCATE(wTsumSTD(klon,nlevSTD,nout)) |
---|
356 | ALLOCATE(u2sumSTD(klon,nlevSTD,nout)) |
---|
357 | ALLOCATE(v2sumSTD(klon,nlevSTD,nout)) |
---|
358 | ALLOCATE(T2sumSTD(klon,nlevSTD,nout)) |
---|
359 | ALLOCATE(seed_old(klon,napisccp)) |
---|
360 | ALLOCATE(zuthe(klon),zvthe(klon)) |
---|
361 | ALLOCATE(alb_neig(klon)) |
---|
362 | !cloud base mass flux |
---|
363 | ALLOCATE(ema_workcbmf(klon), ema_cbmf(klon)) |
---|
364 | !cloud base pressure & cloud top pressure |
---|
365 | ALLOCATE(ema_pcb(klon), ema_pct(klon)) |
---|
366 | ! |
---|
367 | ALLOCATE(Ma(klon,klev)) |
---|
368 | ALLOCATE(qcondc(klon,klev)) |
---|
369 | ALLOCATE(wd(klon)) |
---|
370 | ALLOCATE(sigd(klon)) |
---|
371 | ALLOCATE(cin(klon), ALE(klon), ALP(klon)) |
---|
372 | ALLOCATE(ftd(klon,klev), fqd(klon,klev)) |
---|
373 | ALLOCATE(Ale_bl(klon)) |
---|
374 | ALLOCATE(Alp_bl(klon)) |
---|
375 | ALLOCATE(lalim_conv(klon)) |
---|
376 | ALLOCATE(wght_th(klon,klev)) |
---|
377 | ALLOCATE(wake_deltat(klon,klev), wake_deltaq(klon,klev)) |
---|
378 | ALLOCATE(wake_Cstar(klon), wake_s(klon)) |
---|
379 | ALLOCATE(wake_pe(klon), wake_fip(klon)) |
---|
380 | ALLOCATE(dt_wake(klon,klev), dq_wake(klon,klev)) |
---|
381 | ALLOCATE(pfrac_impa(klon,klev), pfrac_nucl(klon,klev)) |
---|
382 | ALLOCATE(pfrac_1nucl(klon,klev)) |
---|
383 | ALLOCATE(total_rain(klon), nday_rain(klon)) |
---|
384 | ALLOCATE(paire_ter(klon)) |
---|
385 | ALLOCATE(albsol1(klon), albsol2(klon)) |
---|
386 | |
---|
387 | if (read_climoz <= 1) then |
---|
388 | ALLOCATE(wo(klon,klev, 1)) |
---|
389 | else |
---|
390 | ! read_climoz == 2 |
---|
391 | ALLOCATE(wo(klon,klev, 2)) |
---|
392 | end if |
---|
393 | |
---|
394 | ALLOCATE(clwcon0(klon,klev),rnebcon0(klon,klev)) |
---|
395 | ALLOCATE(heat(klon,klev), heat0(klon,klev)) |
---|
396 | ALLOCATE(cool(klon,klev), cool0(klon,klev)) |
---|
397 | ALLOCATE(topsw(klon), toplw(klon)) |
---|
398 | ALLOCATE(sollwdown(klon), sollwdownclr(klon)) |
---|
399 | ALLOCATE(toplwdown(klon), toplwdownclr(klon)) |
---|
400 | ALLOCATE(topsw0(klon),toplw0(klon),solsw0(klon),sollw0(klon)) |
---|
401 | ALLOCATE(albpla(klon)) |
---|
402 | ALLOCATE(cape(klon)) |
---|
403 | ALLOCATE(pbase(klon),bbase(klon)) |
---|
404 | ALLOCATE(zqasc(klon,klev)) |
---|
405 | ALLOCATE(ibas_con(klon), itop_con(klon)) |
---|
406 | ALLOCATE(rain_con(klon), snow_con(klon)) |
---|
407 | ALLOCATE(rlonPOS(klon)) |
---|
408 | ALLOCATE(newsst(klon)) |
---|
409 | ALLOCATE(u10m(klon,nbsrf), v10m(klon,nbsrf)) |
---|
410 | ALLOCATE(topswad(klon), solswad(klon)) |
---|
411 | ALLOCATE(topswai(klon), solswai(klon)) |
---|
412 | ALLOCATE(tau_aero(klon,klev,naero_grp,nbands),piz_aero(klon,klev,naero_grp,nbands),cg_aero(klon,klev,naero_grp,nbands)) |
---|
413 | ALLOCATE(ccm(klon,klev,nbands)) |
---|
414 | |
---|
415 | END SUBROUTINE phys_state_var_init |
---|
416 | |
---|
417 | !====================================================================== |
---|
418 | SUBROUTINE phys_state_var_end |
---|
419 | use dimphy |
---|
420 | use control_mod |
---|
421 | IMPLICIT NONE |
---|
422 | #include "indicesol.h" |
---|
423 | |
---|
424 | deallocate(rlat, rlon, pctsrf, ftsol, falb1, falb2) |
---|
425 | deallocate(rain_fall, snow_fall, solsw, sollw, radsol) |
---|
426 | deallocate(zmea, zstd, zsig, zgam) |
---|
427 | deallocate(zthe, zpic, zval) |
---|
428 | deallocate(rugoro, t_ancien, q_ancien, clwcon, rnebcon) |
---|
429 | deallocate( u_ancien, v_ancien ) |
---|
430 | deallocate(ratqs, pbl_tke) |
---|
431 | deallocate(zmax0, f0) |
---|
432 | deallocate(ema_work1, ema_work2) |
---|
433 | deallocate(entr_therm, fm_therm) |
---|
434 | deallocate(detr_therm) |
---|
435 | deallocate(clwcon0th, rnebcon0th) |
---|
436 | ! radiation outputs |
---|
437 | deallocate(swdn0, swdn) |
---|
438 | deallocate(swup0, swup) |
---|
439 | deallocate(lwdn0, lwdn) |
---|
440 | deallocate(lwup0, lwup) |
---|
441 | deallocate(SWdn200clr, SWdn200) |
---|
442 | deallocate(SWup200clr, SWup200) |
---|
443 | deallocate(LWdn200clr, LWdn200) |
---|
444 | deallocate(LWup200clr, LWup200) |
---|
445 | deallocate(LWdnTOA, LWdnTOAclr) |
---|
446 | ! pressure level |
---|
447 | deallocate(tsumSTD) |
---|
448 | deallocate(usumSTD, vsumSTD) |
---|
449 | deallocate(wsumSTD, phisumSTD) |
---|
450 | deallocate(tnondef) |
---|
451 | deallocate(qsumSTD, rhsumSTD) |
---|
452 | deallocate(uvsumSTD) |
---|
453 | deallocate(vqsumSTD) |
---|
454 | deallocate(vTsumSTD) |
---|
455 | deallocate(wqsumSTD) |
---|
456 | deallocate(vphisumSTD) |
---|
457 | deallocate(wTsumSTD) |
---|
458 | deallocate(u2sumSTD) |
---|
459 | deallocate(v2sumSTD) |
---|
460 | deallocate(T2sumSTD) |
---|
461 | deallocate(seed_old) |
---|
462 | deallocate(zuthe, zvthe) |
---|
463 | deallocate(alb_neig) |
---|
464 | deallocate(ema_workcbmf, ema_cbmf) |
---|
465 | deallocate(ema_pcb, ema_pct) |
---|
466 | deallocate(Ma, qcondc) |
---|
467 | deallocate(wd, sigd) |
---|
468 | deallocate(cin, ALE, ALP) |
---|
469 | deallocate(ftd, fqd) |
---|
470 | deallocate(Ale_bl, Alp_bl) |
---|
471 | deallocate(lalim_conv, wght_th) |
---|
472 | deallocate(wake_deltat, wake_deltaq) |
---|
473 | deallocate(wake_Cstar, wake_s, wake_pe, wake_fip) |
---|
474 | deallocate(dt_wake, dq_wake) |
---|
475 | deallocate(pfrac_impa, pfrac_nucl) |
---|
476 | deallocate(pfrac_1nucl) |
---|
477 | deallocate(total_rain, nday_rain) |
---|
478 | deallocate(paire_ter) |
---|
479 | deallocate(albsol1, albsol2) |
---|
480 | deallocate(wo) |
---|
481 | deallocate(clwcon0,rnebcon0) |
---|
482 | deallocate(heat, heat0) |
---|
483 | deallocate(cool, cool0) |
---|
484 | deallocate(topsw, toplw) |
---|
485 | deallocate(sollwdown, sollwdownclr) |
---|
486 | deallocate(toplwdown, toplwdownclr) |
---|
487 | deallocate(topsw0,toplw0,solsw0,sollw0) |
---|
488 | deallocate(albpla) |
---|
489 | deallocate(cape) |
---|
490 | deallocate(pbase,bbase) |
---|
491 | deallocate(zqasc) |
---|
492 | deallocate(ibas_con, itop_con) |
---|
493 | deallocate(rain_con, snow_con) |
---|
494 | deallocate(rlonPOS) |
---|
495 | deallocate(newsst) |
---|
496 | deallocate(u10m, v10m) |
---|
497 | deallocate(topswad, solswad) |
---|
498 | deallocate(topswai, solswai) |
---|
499 | deallocate(tau_aero,piz_aero,cg_aero) |
---|
500 | deallocate(ccm) |
---|
501 | |
---|
502 | END SUBROUTINE phys_state_var_end |
---|
503 | |
---|
504 | END MODULE phys_state_var_mod |
---|