Skip to content

Commit

Permalink
Merge pull request NCAR#365 from grantfirl/fix_noahmp_precip_rates
Browse files Browse the repository at this point in the history
Fix NoahMP precip rates
  • Loading branch information
climbfuji authored Dec 9, 2019
2 parents f895fc0 + 7d9cf52 commit 3fad556
Show file tree
Hide file tree
Showing 4 changed files with 75 additions and 240 deletions.
30 changes: 22 additions & 8 deletions physics/GFS_MP_generic.F90
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,8 @@ subroutine GFS_MP_generic_post_run(im, ix, levs, kdt, nrcm, ncld, nncl, ntcw, nt
rann, xlat, xlon, gt0, gq0, prsl, prsi, phii, tsfc, ice, snow, graupel, save_t, save_qv, rain0, ice0, snow0, &
graupel0, del, rain, domr_diag, domzr_diag, domip_diag, doms_diag, tprcp, srflag, sr, cnvprcp, totprcp, totice, &
totsnw, totgrp, cnvprcpb, totprcpb, toticeb, totsnwb, totgrpb, dt3dt, dq3dt, rain_cpl, rainc_cpl, snow_cpl, pwat, &
do_sppt, dtdtr, dtdtc, drain_cpl, dsnow_cpl, lsm, lsm_ruc, raincprv, rainncprv, iceprv, snowprv, graupelprv, &
dtp, errmsg, errflg)
do_sppt, dtdtr, dtdtc, drain_cpl, dsnow_cpl, lsm, lsm_ruc, lsm_noahmp, raincprv, rainncprv, iceprv, snowprv, &
graupelprv, draincprv, drainncprv, diceprv, dsnowprv, dgraupelprv, dtp, errmsg, errflg)
!
use machine, only: kind_phys

Expand Down Expand Up @@ -120,13 +120,18 @@ subroutine GFS_MP_generic_post_run(im, ix, levs, kdt, nrcm, ncld, nncl, ntcw, nt
real(kind=kind_phys), dimension(im), intent(inout) :: drain_cpl
real(kind=kind_phys), dimension(im), intent(inout) :: dsnow_cpl

! Rainfall variables previous time step (update for RUC LSM)
integer, intent(in) :: lsm, lsm_ruc
! Rainfall variables previous time step
integer, intent(in) :: lsm, lsm_ruc, lsm_noahmp
real(kind=kind_phys), dimension(im), intent(inout) :: raincprv
real(kind=kind_phys), dimension(im), intent(inout) :: rainncprv
real(kind=kind_phys), dimension(im), intent(inout) :: iceprv
real(kind=kind_phys), dimension(im), intent(inout) :: snowprv
real(kind=kind_phys), dimension(im), intent(inout) :: graupelprv
real(kind=kind_phys), dimension(im), intent(inout) :: draincprv
real(kind=kind_phys), dimension(im), intent(inout) :: drainncprv
real(kind=kind_phys), dimension(im), intent(inout) :: diceprv
real(kind=kind_phys), dimension(im), intent(inout) :: dsnowprv
real(kind=kind_phys), dimension(im), intent(inout) :: dgraupelprv

real(kind=kind_phys), intent(in) :: dtp

Expand All @@ -152,7 +157,7 @@ subroutine GFS_MP_generic_post_run(im, ix, levs, kdt, nrcm, ncld, nncl, ntcw, nt
errflg = 0

onebg = one/con_g

do i = 1, im
rain(i) = rainc(i) + frain * rain1(i) ! time-step convective plus explicit
enddo
Expand Down Expand Up @@ -184,14 +189,23 @@ subroutine GFS_MP_generic_post_run(im, ix, levs, kdt, nrcm, ncld, nncl, ntcw, nt
tprcp = max (0.,rain) ! time-step convective and explicit precip
ice = frain*rain1*sr ! time-step ice
end if

if (lsm==lsm_ruc) then
if (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_thompson) then

if (lsm==lsm_ruc .or. lsm==lsm_noahmp) then
raincprv(:) = rainc(:)
rainncprv(:) = frain * rain1(:)
iceprv(:) = ice(:)
snowprv(:) = snow(:)
graupelprv(:) = graupel(:)
!for NoahMP, calculate precipitation rates from liquid water equivalent thickness for use in next time step
!Note (GJF): Precipitation LWE thicknesses are multiplied by the frain factor, and are thus on the dynamics time step, but the conversion as written
! (with dtp in the denominator) assumes the rate is calculated on the physics time step. This only works as expected when dtf=dtp (i.e. when frain=1).
if (lsm == lsm_noahmp) then
tem = 1.0 / (dtp*con_p001) !GJF: This conversion was taken from GFS_physics_driver.F90, but should denominator also have the frain factor?
draincprv(:) = tem * raincprv(:)
drainncprv(:) = tem * rainncprv(:)
dsnowprv(:) = tem * snowprv(:)
dgraupelprv(:) = tem * graupelprv(:)
diceprv(:) = tem * iceprv(:)
end if
end if

Expand Down
53 changes: 53 additions & 0 deletions physics/GFS_MP_generic.meta
Original file line number Diff line number Diff line change
Expand Up @@ -774,6 +774,14 @@
type = integer
intent = in
optional = F
[lsm_noahmp]
standard_name = flag_for_noahmp_land_surface_scheme
long_name = flag for NOAH MP land surface model
units = flag
dimensions = ()
type = integer
intent = in
optional = F
[raincprv]
standard_name = lwe_thickness_of_convective_precipitation_amount_from_previous_timestep
long_name = convective_precipitation_amount from previous timestep
Expand Down Expand Up @@ -819,6 +827,51 @@
kind = kind_phys
intent = inout
optional = F
[draincprv]
standard_name = convective_precipitation_rate_from_previous_timestep
long_name = convective precipitation rate from previous timestep
units = mm s-1
dimensions = (horizontal_dimension)
type = real
kind = kind_phys
intent = inout
optional = F
[drainncprv]
standard_name = explicit_rainfall_rate_from_previous_timestep
long_name = explicit rainfall rate previous timestep
units = mm s-1
dimensions = (horizontal_dimension)
type = real
kind = kind_phys
intent = inout
optional = F
[diceprv]
standard_name = ice_precipitation_rate_from_previous_timestep
long_name = ice precipitation rate from previous timestep
units = mm s-1
dimensions = (horizontal_dimension)
type = real
kind = kind_phys
intent = inout
optional = F
[dsnowprv]
standard_name = snow_precipitation_rate_from_previous_timestep
long_name = snow precipitation rate from previous timestep
units = mm s-1
dimensions = (horizontal_dimension)
type = real
kind = kind_phys
intent = inout
optional = F
[dgraupelprv]
standard_name = graupel_precipitation_rate_from_previous_timestep
long_name = graupel precipitation rate from previous timestep
units = mm s-1
dimensions = (horizontal_dimension)
type = real
kind = kind_phys
intent = inout
optional = F
[dtp]
standard_name = time_step_for_physics
long_name = physics timestep
Expand Down
65 changes: 0 additions & 65 deletions physics/sfc_noahmp_pre.F90

This file was deleted.

167 changes: 0 additions & 167 deletions physics/sfc_noahmp_pre.meta

This file was deleted.

0 comments on commit 3fad556

Please sign in to comment.