Skip to content

Commit

Permalink
Merge pull request #732 from junwang-noaa/noahmp_rstfix
Browse files Browse the repository at this point in the history
restart fix for NoahMP and changes from PR#731
  • Loading branch information
climbfuji authored Sep 24, 2021
2 parents 84c6144 + badab05 commit a9237ce
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 21 deletions.
8 changes: 4 additions & 4 deletions physics/GFS_surface_composites.F90
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ subroutine GFS_surface_composites_pre_run (im, flag_init, flag_restart, lkm, lsm
! when cplflx is .true. (e.g., for the S2S application).
! Whereas, for the HAFS FV3ATM-HYCOM coupling, cplice is set as
! .false.. In the future HAFS FV3ATM-MOM6 coupling, the cplflx
! could be .true., while cplice being .false..
! could be .true., while cplice being .false..
if (cplice .and. cplflx) then
islmsk_cice(i) = 4
flag_cice(i) = .true.
Expand Down Expand Up @@ -229,7 +229,7 @@ subroutine GFS_surface_composites_pre_run (im, flag_init, flag_restart, lkm, lsm
uustar_lnd(i) = uustar(i)
weasd_lnd(i) = weasd(i)
tsurf_lnd(i) = tsfcl(i)
if (iemsflg == 2 .and. .not. flag_init) then
if (iemsflg == 2 .and. (.not.flag_init .or. flag_restart)) then
!-- use land emissivity from the LSM
semis_lnd(i) = emis_lnd(i)
else
Expand Down Expand Up @@ -455,7 +455,7 @@ subroutine GFS_surface_composites_post_run (
fh2, cmm, chh, gflx, ep1d, weasd, snowd, tprcp, evap, hflx, qss, tsfc, tsfco, tsfcl, tisfc

real(kind=kind_phys), dimension(:), intent(inout) :: hice, cice
real(kind=kind_phys), dimension(:), intent(inout) :: sigmaf, zvfun, hflxq, hffac
real(kind=kind_phys), dimension(:), intent(inout) :: sigmaf, zvfun, hflxq, hffac
real(kind=kind_phys), intent(in ) :: h0facu, h0facs
real(kind=kind_phys), intent(in ) :: min_seaice
real(kind=kind_phys), intent(in ) :: rd, rvrdm1
Expand Down Expand Up @@ -613,7 +613,7 @@ subroutine GFS_surface_composites_post_run (
endif
!
call stability(z1(i), zvfun(i), gdx, tv1, thv1, wind(i), & ! inputs
z0max, ztmax, tvs, grav, thsfc_loc, & ! inputs
z0max, ztmax, tvs, grav, thsfc_loc, & ! inputs
rb(i), ffmm(i), ffhh(i), fm10(i), fh2(i), cd(i), cdq(i), & ! outputs
stress(i), uustar(i))
endif ! Checking to see if point is one or multiple surface types
Expand Down
7 changes: 3 additions & 4 deletions physics/scm_sfc_flux_spec.F90
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ end subroutine scm_sfc_flux_spec_finalize
!! -# Calculate the surface drag coefficient for heat and moisture.
!! -# Calculate the u and v wind at 10m.
subroutine scm_sfc_flux_spec_run (u1, v1, z1, t1, q1, p1, roughness_length, spec_sh_flux, spec_lh_flux, &
exner_inverse, T_surf, cp, grav, hvap, rd, fvirt, vonKarman, sh_flux, lh_flux, sh_flux_chs, lh_flux_chs, u_star, sfc_stress, cm, ch, &
exner_inverse, T_surf, cp, grav, hvap, rd, fvirt, vonKarman, sh_flux, lh_flux, sh_flux_chs, u_star, sfc_stress, cm, ch, &
fm, fh, rb, u10m, v10m, wind1, qss, t2m, q2m, errmsg, errflg)

use machine, only: kind_phys
Expand All @@ -63,7 +63,7 @@ subroutine scm_sfc_flux_spec_run (u1, v1, z1, t1, q1, p1, roughness_length, spec
real(kind=kind_phys), intent(in) :: cp, grav, hvap, rd, fvirt, vonKarman
real(kind=kind_phys), intent(out) :: sh_flux(:), lh_flux(:), u_star(:), sfc_stress(:), &
cm(:), ch(:), fm(:), fh(:), rb(:), u10m(:), v10m(:), wind1(:), qss(:), t2m(:), q2m(:), &
sh_flux_chs(:), lh_flux_chs(:)
sh_flux_chs(:)

character(len=*), intent(out) :: errmsg
integer, intent(out) :: errflg
Expand All @@ -83,8 +83,7 @@ subroutine scm_sfc_flux_spec_run (u1, v1, z1, t1, q1, p1, roughness_length, spec
sh_flux(i) = spec_sh_flux(i)
lh_flux(i) = spec_lh_flux(i)
sh_flux_chs(i) = sh_flux(i)
lh_flux_chs(i) = lh_flux(i)


roughness_length_m = 0.01*roughness_length(i)

wind1(i) = sqrt(u1(i)*u1(i) + v1(i)*v1(i))
Expand Down
17 changes: 4 additions & 13 deletions physics/scm_sfc_flux_spec.meta
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,8 @@
intent = in
optional = F
[vonKarman]
standard_name = vonKarman_constant
long_name = vonKarman constant
standard_name = von_karman_constant
long_name = Von Karman constant
units = none
dimensions = ()
type = real
Expand All @@ -209,23 +209,14 @@
intent = out
optional = F
[sh_flux_chs]
standard_name = kinematic_surface_upward_sensible_heat_flux_reduced_by_surface_roughness
long_name = kinematic surface upward sensible heat flux reduced by surface roughness
standard_name = kinematic_surface_upward_sensible_heat_flux_reduced_by_surface_roughness_and_vegetation
long_name = kinematic surface upward sensible heat flux reduced by surface roughness and vegetation
units = K m s-1
dimensions = (horizontal_loop_extent)
type = real
kind = kind_phys
intent = out
optional = F
[lh_flux_chs]
standard_name = surface_upward_specific_humidity_flux_reduced_by_surface_roughness
long_name = kinematic surface upward latent heat flux reduced by surface roughness
units = kg kg-1 m s-1
dimensions = (horizontal_loop_extent)
type = real
kind = kind_phys
intent = out
optional = F
[u_star]
standard_name = surface_friction_velocity
long_name = boundary layer parameter
Expand Down

0 comments on commit a9237ce

Please sign in to comment.