Skip to content

Commit

Permalink
Merge branch 'hr3_land_upgrades' of https://github.com/HelinWei-NOAA/…
Browse files Browse the repository at this point in the history
…ccpp-physics into ufs/dev_meso_fix_new_ksmax

Incorporates PR#115
  • Loading branch information
mdtoyNOAA committed Oct 16, 2023
2 parents 627a3bb + 4f8004a commit 4704ecf
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
15 changes: 9 additions & 6 deletions physics/module_sf_noahmplsm.F90
Original file line number Diff line number Diff line change
Expand Up @@ -2116,7 +2116,7 @@ subroutine energy (parameters,ice ,vegtyp ,ist ,nsnow ,nsoil , & !in
! thermal properties of soil, snow, lake, and frozen soil

call thermoprop (parameters,nsoil ,nsnow ,isnow ,ist ,dzsnso , & !in
dt ,snowh ,snice ,snliq , & !in
dt ,snowh ,snice ,snliq , shdfac, & !in
smc ,sh2o ,tg ,stc ,ur , & !in
lat ,z0m ,zlvl ,vegtyp , & !in
df ,hcpct ,snicev ,snliqv ,epore , & !out
Expand Down Expand Up @@ -2463,7 +2463,7 @@ end subroutine energy

!>\ingroup NoahMP_LSM
subroutine thermoprop (parameters,nsoil ,nsnow ,isnow ,ist ,dzsnso , & !in
dt ,snowh ,snice ,snliq , & !in
dt ,snowh ,snice ,snliq , shdfac, & !in
smc ,sh2o ,tg ,stc ,ur , & !in
lat ,z0m ,zlvl ,vegtyp , & !in
df ,hcpct ,snicev ,snliqv ,epore , & !out
Expand All @@ -2480,6 +2480,7 @@ subroutine thermoprop (parameters,nsoil ,nsnow ,isnow ,ist ,dzsnso ,
real (kind=kind_phys) , intent(in) :: dt !< time step [s]
real (kind=kind_phys), dimension(-nsnow+1: 0), intent(in) :: snice !< snow ice mass (kg/m2)
real (kind=kind_phys), dimension(-nsnow+1: 0), intent(in) :: snliq !< snow liq mass (kg/m2)
real (kind=kind_phys) , intent(in) :: shdfac !< green vegetation fraction [0.0-1.0]
real (kind=kind_phys), dimension(-nsnow+1:nsoil), intent(in) :: dzsnso !< thickness of snow/soil layers [m]
real (kind=kind_phys), dimension( 1:nsoil), intent(in) :: smc !< soil moisture (ice + liq.) [m3/m3]
real (kind=kind_phys), dimension( 1:nsoil), intent(in) :: sh2o !< liquid soil moisture [m3/m3]
Expand Down Expand Up @@ -2539,6 +2540,7 @@ subroutine thermoprop (parameters,nsoil ,nsnow ,isnow ,ist ,dzsnso ,
! not in use because of the separation of the canopy layer from the ground.
! but this may represent the effects of leaf litter (niu comments)
! df1 = df1 * exp (sbeta * shdfac)
df(1) = df(1) * exp (sbeta * shdfac)

! compute lake thermal properties
! (no consideration of turbulent mixing for this version)
Expand Down Expand Up @@ -4888,7 +4890,7 @@ subroutine bare_flux (parameters,nsnow ,nsoil ,isnow ,dt ,sag , &
end if
endif ! 4

! use sfc_diag to calculate t2mv and q2v for opt_sfc=1&3
! use sfc_diag to calculate t2mb and q2b for opt_sfc=1&3
if(opt_diag ==3) then
if(opt_sfc == 1 .or. opt_sfc == 3) then

Expand Down Expand Up @@ -5823,7 +5825,8 @@ subroutine thermalz0(parameters, fveg, z0m, z0mg, zlvl,

elseif (opt_trs == chen09) then

z0m_out = exp(fveg * log(z0m) + (1.0 - fveg) * log(z0mg))
! z0m_out = exp(fveg * log(z0m) + (1.0 - fveg) * log(z0mg))
z0m_out = fveg * z0m + (1.0 - fveg) * z0mg
czil = 10.0 ** (- 0.4 * parameters%hvt)

reyn = ustarx*z0m_out/viscosity ! Blumel99 eqn 36c
Expand Down Expand Up @@ -5873,15 +5876,15 @@ subroutine thermalz0(parameters, fveg, z0m, z0mg, zlvl,

z0h_out = z0m_out

elseif (opt_trs == tessel) then
elseif (opt_trs == chen09 .or. opt_trs == tessel) then

if (vegtyp <= 5) then
z0h_out = z0m_out
else
z0h_out = z0m_out * 0.01
endif

elseif (opt_trs == blumel99 .or. opt_trs == chen09) then
elseif (opt_trs == blumel99) then

reyn = ustarx*z0m_out/viscosity ! Blumel99 eqn 36c
if (reyn > 2.0) then
Expand Down
2 changes: 1 addition & 1 deletion physics/noahmpdrv.F90
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,7 @@ subroutine noahmpdrv_run &
integer :: iopt_pedo = 1 ! option for pedotransfer function
integer :: iopt_crop = 0 ! option for crop model
integer :: iopt_gla = 2 ! option for glacier treatment
integer :: iopt_z0m = 2 ! option for z0m treatment
integer :: iopt_z0m = 1 ! option for z0m treatment

!
! --- local inputs to noah-mp and glacier subroutines; listed in order in noah-mp call
Expand Down
3 changes: 0 additions & 3 deletions physics/sfcsub.F
Original file line number Diff line number Diff line change
Expand Up @@ -7491,9 +7491,6 @@ subroutine clima(lugb,iy,im,id,ih,fh,len,lsoil,slmskl,slmskw, &
endif
call abort
endif
!
! soil type
print *,'in FIXREAD fnsotc =',fnsotc
!
if(fnsotc(1:8).ne.' ') then
if ( index(fnsotc, "tileX.nc") == 0) then ! grib file
Expand Down

0 comments on commit 4704ecf

Please sign in to comment.