[1992] | 1 | |
---|
[524] | 2 | ! $Header$ |
---|
| 3 | |
---|
[1992] | 4 | SUBROUTINE tlift43(p, t, q, qs, gz, icb, nk, tvp, tpk, clw, nd, nl, kk) |
---|
| 5 | REAL gz(nd), tpk(nd), clw(nd), p(nd) |
---|
| 6 | REAL t(nd), q(nd), qs(nd), tvp(nd), lv0 |
---|
[524] | 7 | |
---|
[1992] | 8 | ! *** ASSIGN VALUES OF THERMODYNAMIC CONSTANTS *** |
---|
[524] | 9 | |
---|
[1992] | 10 | ! -- sb: |
---|
| 11 | ! ! CPD=1005.7 |
---|
| 12 | ! ! CPV=1870.0 |
---|
| 13 | ! ! CL=4190.0 |
---|
| 14 | ! ! RV=461.5 |
---|
| 15 | ! ! RD=287.04 |
---|
| 16 | ! ! LV0=2.501E6 |
---|
| 17 | ! ! G=9.8 |
---|
| 18 | ! ! ROWL=1000.0 |
---|
| 19 | ! ajouts: |
---|
| 20 | include "YOMCST.h" |
---|
| 21 | cpd = rcpd |
---|
| 22 | cpv = rcpv |
---|
| 23 | cl = rcw |
---|
| 24 | lv0 = rlvtt |
---|
| 25 | g = rg |
---|
| 26 | rowl = ratm/100. |
---|
| 27 | gravity = rg !sb: Pr que gravite ne devienne pas humidite! |
---|
| 28 | ! sb -- |
---|
| 29 | |
---|
| 30 | cpvmcl = cl - cpv |
---|
| 31 | eps = rd/rv |
---|
| 32 | epsi = 1./eps |
---|
| 33 | |
---|
| 34 | ! *** CALCULATE CERTAIN PARCEL QUANTITIES, INCLUDING STATIC ENERGY *** |
---|
| 35 | |
---|
| 36 | ah0 = (cpd*(1.-q(nk))+cl*q(nk))*t(nk) + q(nk)*(lv0-cpvmcl*(t(nk)-273.15)) + & |
---|
| 37 | gz(nk) |
---|
| 38 | cpp = cpd*(1.-q(nk)) + q(nk)*cpv |
---|
| 39 | cpinv = 1./cpp |
---|
| 40 | |
---|
| 41 | IF (kk==1) THEN |
---|
| 42 | |
---|
| 43 | ! *** CALCULATE LIFTED PARCEL QUANTITIES BELOW CLOUD BASE *** |
---|
| 44 | |
---|
| 45 | DO i = 1, icb - 1 |
---|
| 46 | clw(i) = 0.0 |
---|
| 47 | END DO |
---|
| 48 | DO i = nk, icb - 1 |
---|
| 49 | tpk(i) = t(nk) - (gz(i)-gz(nk))*cpinv |
---|
| 50 | tvp(i) = tpk(i)*(1.+q(nk)*epsi) |
---|
| 51 | END DO |
---|
| 52 | END IF |
---|
| 53 | |
---|
| 54 | ! *** FIND LIFTED PARCEL QUANTITIES ABOVE CLOUD BASE *** |
---|
| 55 | |
---|
| 56 | nst = icb |
---|
| 57 | nsb = icb |
---|
| 58 | IF (kk==2) THEN |
---|
| 59 | nst = nl |
---|
| 60 | nsb = icb + 1 |
---|
| 61 | END IF |
---|
| 62 | DO i = nsb, nst |
---|
| 63 | tg = t(i) |
---|
| 64 | qg = qs(i) |
---|
| 65 | alv = lv0 - cpvmcl*(t(i)-273.15) |
---|
| 66 | DO j = 1, 2 |
---|
| 67 | s = cpd + alv*alv*qg/(rv*t(i)*t(i)) |
---|
| 68 | s = 1./s |
---|
| 69 | ahg = cpd*tg + (cl-cpd)*q(nk)*t(i) + alv*qg + gz(i) |
---|
| 70 | tg = tg + s*(ah0-ahg) |
---|
| 71 | tg = max(tg, 35.0) |
---|
| 72 | tc = tg - 273.15 |
---|
| 73 | denom = 243.5 + tc |
---|
| 74 | IF (tc>=0.0) THEN |
---|
| 75 | es = 6.112*exp(17.67*tc/denom) |
---|
| 76 | ELSE |
---|
| 77 | es = exp(23.33086-6111.72784/tg+0.15215*log(tg)) |
---|
| 78 | END IF |
---|
| 79 | qg = eps*es/(p(i)-es*(1.-eps)) |
---|
| 80 | END DO |
---|
| 81 | alv = lv0 - cpvmcl*(t(i)-273.15) |
---|
| 82 | tpk(i) = (ah0-(cl-cpd)*q(nk)*t(i)-gz(i)-alv*qg)/cpd |
---|
| 83 | clw(i) = q(nk) - qg |
---|
| 84 | clw(i) = max(0.0, clw(i)) |
---|
| 85 | rg = qg/(1.-q(nk)) |
---|
| 86 | tvp(i) = tpk(i)*(1.+rg*epsi) |
---|
| 87 | END DO |
---|
| 88 | |
---|
| 89 | ! -- sb: |
---|
| 90 | rg = gravity ! RG redevient la gravite de YOMCST (sb) |
---|
| 91 | ! sb -- |
---|
| 92 | |
---|
| 93 | RETURN |
---|
| 94 | END SUBROUTINE tlift43 |
---|
| 95 | |
---|