Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iovr=4 cleanup in RRTMG #780

Merged
merged 6 commits into from
Dec 28, 2021
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
67 changes: 0 additions & 67 deletions physics/GFS_rrtmg_pre.F90
Original file line number Diff line number Diff line change
Expand Up @@ -854,72 +854,6 @@ subroutine GFS_rrtmg_pre_run (im, levs, lm, lmk, lmp, n_var_lndp, &
enddo
endif

!mz HWRF physics: icloud=3
if(icloud == 3) then

! Set internal dimensions
ids = 1
ims = 1
its = 1
ide = size(xlon,1)
ime = size(xlon,1)
ite = size(xlon,1)
jds = 1
jms = 1
jts = 1
jde = 1
jme = 1
jte = 1
kds = 1
kms = 1
kts = 1
kde = lm+LTP ! should this be lmk instead of lm? no, or?
kme = lm+LTP
kte = lm+LTP

do k = 1, LMK
do i = 1, IM
rho(i,k)=plyr(i,k)*100./(con_rd*tlyr(i,k))
plyrpa(i,k)=plyr(i,k)*100. !hPa->Pa
end do
end do

do i=1,im
if (slmsk(i)==1. .or. slmsk(i)==2.) then ! sea/land/ice mask (=0/1/2) in FV3
xland(i)=1.0 ! but land/water = (1/2) in HWRF
else
xland(i)=2.0
endif
enddo

gridkm = sqrt(2.0)*sqrt(dx(1)*0.001*dx(1)*0.001)

do i =1, im
do k =1, lmk
qc_save(i,k) = ccnd(i,k,1)
qi_save(i,k) = ccnd(i,k,2)
qs_save(i,k) = ccnd(i,k,4)
enddo
enddo


call cal_cldfra3(cldcov,qlyr,ccnd(:,:,1),ccnd(:,:,2), &
ccnd(:,:,4),plyrpa,tlyr,rho,xland,gridkm, &
ids,ide,jds,jde,kds,kde, &
ims,ime,jms,jme,kms,kme, &
its,ite,jts,jte,kts,kte)

!mz* back to micro-only qc qi,qs
do i =1, im
do k =1, lmk
ccnd(i,k,1) = qc_save(i,k)
ccnd(i,k,2) = qi_save(i,k)
ccnd(i,k,4) = qs_save(i,k)
enddo
enddo

endif ! icloud == 3

if (lextop) then
climbfuji marked this conversation as resolved.
Show resolved Hide resolved
do i=1,im
cldcov(i,lyb) = cldcov(i,lya)
Expand Down Expand Up @@ -1002,7 +936,6 @@ subroutine GFS_rrtmg_pre_run (im, levs, lm, lmk, lmp, n_var_lndp, &
call progcld5 (plyr,plvl,tlyr,tvly,qlyr,qstl,rhly,tracer1, & ! --- inputs
xlat,xlon,slmsk,dz,delp, &
ntrac-1, ntcw-1,ntiw-1,ntrw-1, &
!mz ntsw-1,ntgl-1, &
im, lmk, lmp, icloud, uni_cld, lmfshal, lmfdeep2, &
cldcov(:,1:LMK),effrl_inout(:,:), &
effri_inout(:,:), effrs_inout(:,:), &
Expand Down
59 changes: 1 addition & 58 deletions physics/radiation_clouds.f
Original file line number Diff line number Diff line change
Expand Up @@ -2645,7 +2645,7 @@ subroutine progcld5 &

!mz* if (uni_cld) then ! use unified sgs clouds generated outside
!mz* use unified sgs or thompson clouds generated outside
if (uni_cld .or. icloud == 3) then
if (uni_cld) then
do k = 1, NLAY
do i = 1, IX
cldtot(i,k) = cldcov(i,k)
Expand Down Expand Up @@ -2733,63 +2733,6 @@ subroutine progcld5 &
enddo
enddo
endif
!mz
if (icloud .ne. 0) then
! assign/calculate efective radii for cloud water, ice, rain, snow

do k = 1, NLAY
do i = 1, IX
rew(i,k) = reliq_def ! default liq radius to 10 micron
rei(i,k) = reice_def ! default ice radius to 50 micron
rer(i,k) = rrain_def ! default rain radius to 1000 micron
res(i,k) = rsnow_def ! default snow radius to 250 micron
enddo
enddo
!> -# Compute effective liquid cloud droplet radius over land.
do i = 1, IX
if (nint(slmsk(i)) == 1) then
do k = 1, NLAY
tem1 = min(1.0, max(0.0, (con_ttp-tlyr(i,k))*0.05))
rew(i,k) = 5.0 + 5.0 * tem1
enddo
endif
enddo

!> -# Compute effective ice cloud droplet radius following Heymsfield
!! and McFarquhar (1996) \cite heymsfield_and_mcfarquhar_1996.

do k = 1, NLAY
do i = 1, IX
tem2 = tlyr(i,k) - con_ttp

if (cip(i,k) > 0.0) then
tem3 = gord * cip(i,k) * plyr(i,k) / (delp(i,k)*tvly(i,k))

if (tem2 < -50.0) then
rei(i,k) = (1250.0/9.917) * tem3 ** 0.109
elseif (tem2 < -40.0) then
rei(i,k) = (1250.0/9.337) * tem3 ** 0.08
elseif (tem2 < -30.0) then
rei(i,k) = (1250.0/9.208) * tem3 ** 0.055
else
rei(i,k) = (1250.0/9.387) * tem3 ** 0.031
endif
rei(i,k) = max(25.,rei(i,k)) !mz* HWRF
endif
rei(i,k) = min(rei(i,k), 135.72) !- 1.0315*rei<= 140 microns
enddo
enddo

!mz
!> -# Compute effective snow cloud droplet radius
do k = 1, NLAY
do i = 1, IX
res(i,k) = 10.0
enddo
enddo

endif ! end icloud
!mz end
do k = 1, NLAY
do i = 1, IX
clouds(i,k,1) = cldtot(i,k)
Expand Down
Loading