/[lmdze]/trunk/Sources/phylmd/concvl.f
ViewVC logotype

Contents of /trunk/Sources/phylmd/concvl.f

Parent Directory Parent Directory | Revision Log Revision Log


Revision 189 - (show annotations)
Tue Mar 29 15:20:23 2016 UTC (8 years, 1 month ago) by guez
File size: 2506 byte(s)
There was a function gr_phy_write_3d in dyn3d and a function
gr_phy_write_2d in module grid_change. Moved them into a new module
gr_phy_write_m under a generic interface gr_phy_write. Replaced calls
to gr_fi_ecrit by calls to gr_phy_write.

Removed arguments len, nloc and nd of cv30_compress.

Removed arguments wd and wd1 of cv30_uncompress, wd of cv30_yield, wd
of concvl, wd1 of cv_driver. Was just filled with 0. Removed option
ok_gust in physiq, never used.

In cv30_unsat, cv30_yield and cv_driver, we only need to define b to
level nl - 1.

1 module concvl_m
2
3 IMPLICIT NONE
4
5 contains
6
7 SUBROUTINE concvl(dtime, paprs, play, t, q, u, v, sig1, w01, d_t, d_q, d_u, &
8 d_v, rain, kbas, itop_con, upwd, dnwd, dnwd0, ma, cape, iflag, qcondc, &
9 pmflxr, da, phi, mp)
10
11 ! From phylmd/concvl.F, version 1.3, 2005/04/15 12:36:17
12 ! Author: Z. X. Li (LMD/CNRS)
13 ! Date: 1993 August 18
14 ! Objet : schéma de convection d'Emanuel (1991), interface
15
16 use cv_driver_m, only: cv_driver
17 USE dimphy, ONLY: klev, klon
18 USE fcttre, ONLY: foeew
19 USE suphec_m, ONLY: retv, rtt
20 USE yoethf_m, ONLY: r2es
21
22 REAL, INTENT (IN):: dtime ! pas d'integration (s)
23 REAL, INTENT (IN):: paprs(klon, klev + 1)
24 REAL, INTENT (IN):: play(klon, klev)
25 REAL, intent(in):: t(klon, klev) ! temperature (K)
26 real, intent(in):: q(klon, klev) ! fraction massique de vapeur d'eau
27 real, INTENT (IN):: u(klon, klev), v(klon, klev)
28 REAL, intent(inout):: sig1(klon, klev), w01(klon, klev)
29 REAL, intent(out):: d_t(klon, klev)
30 REAL, intent(out):: d_q(klon, klev) ! increment de la vapeur d'eau
31 REAL, intent(out):: d_u(klon, klev), d_v(klon, klev)
32 REAL, intent(out):: rain(klon) ! pluie (mm / s)
33 INTEGER, intent(out):: kbas(klon)
34 integer, intent(inout):: itop_con(klon)
35
36 REAL, intent(out):: upwd(klon, klev)
37 ! saturated updraft mass flux (kg / m2 / s)
38
39 real, intent(out):: dnwd(klon, klev)
40 ! saturated downdraft mass flux (kg / m2 / s)
41
42 real, intent(out):: dnwd0(klon, klev)
43 ! unsaturated downdraft mass flux (kg / m2 / s)
44
45 REAL ma(klon, klev)
46 real cape(klon) ! output (J / kg)
47 INTEGER iflag(klon)
48 REAL qcondc(klon, klev)
49 REAL pmflxr(klon, klev + 1)
50 REAL, intent(inout):: da(klon, klev), phi(klon, klev, klev), mp(klon, klev)
51
52 ! Local:
53 REAL zx_qs, cor
54 INTEGER i, k
55 REAL qs(klon, klev)
56
57 !-----------------------------------------------------------------
58
59 DO k = 1, klev
60 DO i = 1, klon
61 zx_qs = min(0.5, r2es * foeew(t(i, k), rtt >= t(i, k)) / play(i, k))
62 cor = 1. / (1. - retv * zx_qs)
63 qs(i, k) = zx_qs * cor
64 END DO
65 END DO
66
67 CALL cv_driver(t, q, qs, u, v, play / 100., paprs / 100., iflag, d_t, &
68 d_q, d_u, d_v, rain, pmflxr, sig1, w01, kbas, itop_con, dtime, ma, &
69 upwd, dnwd, dnwd0, qcondc, cape, da, phi, mp)
70 rain = rain / 86400.
71 d_t = dtime * d_t
72 d_q = dtime * d_q
73 d_u = dtime * d_u
74 d_v = dtime * d_v
75
76 END SUBROUTINE concvl
77
78 end module concvl_m

  ViewVC Help
Powered by ViewVC 1.1.21