55 SUBROUTINE frzlvl2(ISOTHERM,ZFRZ,RHFRZ,PFRZL)
58 use vrbls3d, only: pint, t, zmid, pmid, q, zint, alpint
59 use vrbls2d, only: fis, tshltr, pshltr, qz0, qs, qshltr
60 use masks, only: lmh, sm
61 use params_mod, only: gi, d00, capa, d0065, tfrz, pq0, a2, a3, a4, d50
62 use ctlblk_mod, only: jsta, jend, spval, lm, modelname, im, ista, iend
73 REAL,
PARAMETER::pucap=300.0e2
74 real,
intent(in) :: isotherm
75 REAL,
dimension(ista:iend,jsta:jend),
intent(out) :: rhfrz, zfrz, pfrzl
77 integer i,j,l,lice,llmh
78 real htsfc,psfc,qsfc,rhsfc,qw,qsat,delz,delt,delq,delalp,delzp, &
79 zl,zu,dzabv,qfrz,alpl,alph,alpfrz,pfrz,qsfrz,rhz,dzfr, &
90 IF(fis(i,j)<spval)
THEN
103 IF(tshltr(i,j)/=spval .AND. pshltr(i,j)/=spval)
THEN
104 tsfc=tshltr(i,j)*(pshltr(i,j)*1.e-5)**capa
107 tsfc=t(i,j,lm)+d0065*(zmid(i,j,lm)-htsfc-2.0)
113 IF (pmid(i,j,l)>=pucap .AND. &
114 (t(i,j,l)<=isotherm.AND.t(i,j,l+1)>isotherm))lice=l
119 IF (lice==llmh.AND.tsfc<=isotherm)
THEN
120 zfrz(i,j) = htsfc+2.0+(tsfc-isotherm)/d0065
121 qsfc = sm(i,j)*qz0(i,j)+(1.-sm(i,j))*qs(i,j)
122 IF(qshltr(i,j)/=spval)
THEN
131 IF(modelname ==
'GFS' .OR. modelname ==
'RAPR')
THEN
134 qsat=con_eps*es/(psfc+con_epsm1*es)
137 *exp(a2*(tsfc-a3)/(tsfc-a4))
141 rhsfc = amax1(0.01,rhsfc)
142 rhsfc = amin1(rhsfc,1.0)
147 ELSE IF (lice<llmh)
THEN
149 delz = d50*(zint(i,j,l)-zint(i,j,l+2))
150 zl = d50*(zint(i,j,l+1)+zint(i,j,l+2))
151 delt = t(i,j,l)-t(i,j,l+1)
152 zfrz(i,j) = zl+(isotherm-t(i,j,l+1))/delt*delz
155 delq = q(i,j,l)-q(i,j,l+1)
156 qfrz = q(i,j,l+1) + delq/delz*dzabv
157 qfrz = amax1(0.0,qfrz)
159 alpl = alpint(i,j,l+2)
162 delzp = zint(i,j,l)-zint(i,j,l+2)
163 dzfr = zfrz(i,j) - zint(i,j,l+2)
164 alpfrz = alpl + delalp/delzp*dzfr
167 IF(modelname ==
'GFS'.OR.modelname ==
'RAPR')
THEN
170 qsfrz=con_eps*es/(pfrz+con_epsm1*es)
173 *exp(a2*(isotherm-a3)/(isotherm-a4))
178 rhz = amax1(0.01,rhz)
187 IF(tshltr(i,j)/=spval .AND. pshltr(i,j)/=spval)
THEN
188 tsfc=tshltr(i,j)*(pshltr(i,j)*1.e-5)**capa
191 tsfc=t(i,j,lm)+d0065*(zmid(i,j,lm)-htsfc-2.0)
194 zfrz(i,j) = zl + (isotherm-tsfc)/delt*delz
198 IF(qshltr(i,j)/=spval)
THEN
204 qfrz = qsfc + delq/delz*dzabv
205 qfrz = amax1(0.0,qfrz)
210 alpfrz = alpl + delalp/delz*dzabv
213 IF(modelname ==
'GFS'.OR.modelname ==
'RAPR')
THEN
216 qsfrz=con_eps*es/(pfrz+con_epsm1*es)
219 *exp(a2*(isotherm-a3)/(isotherm-a4))
223 rhz = amax1(0.01,rhz)
231 rhfrz(i,j) = amax1(0.01,rhfrz(i,j))
232 rhfrz(i,j) = amin1(rhfrz(i,j),1.00)
233 zfrz(i,j) = amax1(0.0,zfrz(i,j))
subroutine frzlvl2(ISOTHERM, ZFRZ, RHFRZ, PFRZL)
Subroutine that computes FRZING LVL, Z and RH.
elemental real function, public fpvsnew(t)