diff --git a/physics/GWD/drag_suite.F90 b/physics/GWD/drag_suite.F90 index 91edfbec8..707cef597 100644 --- a/physics/GWD/drag_suite.F90 +++ b/physics/GWD/drag_suite.F90 @@ -513,7 +513,6 @@ subroutine drag_suite_run( & real(kind=kind_phys),parameter :: olmin = 1.0e-5 real(kind=kind_phys),parameter :: odmin = 0.1 real(kind=kind_phys),parameter :: odmax = 10. - real(kind=kind_phys),parameter :: erad = 6371.315e+3 integer :: komax(im) integer :: kblk real(kind=kind_phys) :: cd @@ -1552,7 +1551,7 @@ subroutine drag_suite_psl( & integer, parameter :: ims=1, kms=1, its=1, kts=1 real(kind=kind_phys), intent(in) :: fv, pi real(kind=kind_phys) :: rcl, cdmb - real(kind=kind_phys) :: g_inv, g_cp + real(kind=kind_phys) :: g_inv, g_cp, rd_inv real(kind=kind_phys), intent(inout) :: & & dudt(:,:),dvdt(:,:), & @@ -1736,7 +1735,6 @@ subroutine drag_suite_psl( & real(kind=kind_phys),parameter :: odmin = 0.1 real(kind=kind_phys),parameter :: odmax = 10. real(kind=kind_phys),parameter :: cdmin = 0.0 - real(kind=kind_phys),parameter :: erad = 6371.315e+3 integer :: komax(im),kbmax(im),kblk(im) real(kind=kind_phys) :: hmax(im) real(kind=kind_phys) :: cd @@ -1808,43 +1806,43 @@ subroutine drag_suite_psl( & endif enddo -! Remove ss_tapering -ss_taper(:) = 1. + ! Remove ss_tapering + ss_taper(:) = 1. -! SPP, if spp_gwd is 0, no perturbations are applied. -if ( spp_gwd==1 ) then - do i = its,im - var_stoch(i) = var(i) + var(i)*0.75*spp_wts_gwd(i,1) - varss_stoch(i) = varss(i) + varss(i)*0.75*spp_wts_gwd(i,1) - varmax_ss_stoch(i) = varmax_ss + varmax_ss*0.75*spp_wts_gwd(i,1) - varmax_fd_stoch(i) = varmax_fd + varmax_fd*0.75*spp_wts_gwd(i,1) - enddo -else - do i = its,im - var_stoch(i) = var(i) - varss_stoch(i) = varss(i) - varmax_ss_stoch(i) = varmax_ss - varmax_fd_stoch(i) = varmax_fd - enddo -endif + ! SPP, if spp_gwd is 0, no perturbations are applied. + if ( spp_gwd==1 ) then + do i = its,im + var_stoch(i) = var(i) + var(i)*0.75*spp_wts_gwd(i,1) + varss_stoch(i) = varss(i) + varss(i)*0.75*spp_wts_gwd(i,1) + varmax_ss_stoch(i) = varmax_ss + varmax_ss*0.75*spp_wts_gwd(i,1) + varmax_fd_stoch(i) = varmax_fd + varmax_fd*0.75*spp_wts_gwd(i,1) + enddo + else + do i = its,im + var_stoch(i) = var(i) + varss_stoch(i) = varss(i) + varmax_ss_stoch(i) = varmax_ss + varmax_fd_stoch(i) = varmax_fd + enddo + endif -!--- calculate length of grid for flow-blocking drag -! -do i=1,im - delx = dx(i) - dely = dx(i) - dxy4(i,1) = delx - dxy4(i,2) = dely - dxy4(i,3) = sqrt(delx*delx + dely*dely) - dxy4(i,4) = dxy4(i,3) - dxy4p(i,1) = dxy4(i,2) - dxy4p(i,2) = dxy4(i,1) - dxy4p(i,3) = dxy4(i,4) - dxy4p(i,4) = dxy4(i,3) - cleff(i) = psl_gwd_dx_factor*(delx+dely)*0.5 - cleff_ss(i) = 0.1 * max(dxmax_ss,dxy4(i,3)) -! cleff_ss(i) = cleff(i) ! consider ..... -enddo + !--- calculate length of grid for flow-blocking drag + ! + do i=1,im + delx = dx(i) + dely = dx(i) + dxy4(i,1) = delx + dxy4(i,2) = dely + dxy4(i,3) = sqrt(delx*delx + dely*dely) + dxy4(i,4) = dxy4(i,3) + dxy4p(i,1) = dxy4(i,2) + dxy4p(i,2) = dxy4(i,1) + dxy4p(i,3) = dxy4(i,4) + dxy4p(i,4) = dxy4(i,3) + cleff(i) = psl_gwd_dx_factor*(delx+dely)*0.5 + cleff_ss(i) = 0.1 * max(dxmax_ss,dxy4(i,3)) + ! cleff_ss(i) = cleff(i) ! consider ..... + enddo ! !-----initialize arrays ! @@ -1928,11 +1926,12 @@ subroutine drag_suite_psl( & kbmax(1:im) = 0 kblk(1:im) = 0 ! + rd_inv = 1./rd do k = kts,km do i = its,im vtj(i,k) = t1(i,k) * (1.+fv*q1(i,k)) vtk(i,k) = vtj(i,k) / prslk(i,k) - ro(i,k) = 1./rd * prsl(i,k) / vtj(i,k) ! density kg/m**3 + ro(i,k) = rd_inv * prsl(i,k) / vtj(i,k) ! density kg/m**3 enddo enddo ! diff --git a/physics/GWD/drag_suite.meta b/physics/GWD/drag_suite.meta index 088387cfd..5413a5482 100644 --- a/physics/GWD/drag_suite.meta +++ b/physics/GWD/drag_suite.meta @@ -458,13 +458,6 @@ type = real kind = kind_phys intent = in -[vtype] - standard_name = vegetation_type_classification - long_name = vegetation type for lsm - units = index - dimensions = (horizontal_loop_extent) - type = integer - intent = in [g] standard_name = gravitational_acceleration long_name = gravitational acceleration @@ -531,7 +524,7 @@ [alpha_fd] standard_name = alpha_coefficient_for_turbulent_orographic_form_drag long_name = alpha coefficient for Beljaars et al turbulent orographic form drag - units = none + units = 1 dimensions = () type = real kind = kind_phys @@ -608,14 +601,6 @@ dimensions = () type = logical intent = in -[psl_gwd_dx_factor] - standard_name = effective_grid_spacing_of_psl_gwd_suite - long_name = multiplication of grid spacing - units = 1 - dimensions = () - type = real - kind = kind_phys - intent = in [dtend] standard_name = cumulative_change_of_state_variables long_name = diagnostic tendencies for state variables diff --git a/physics/GWD/ugwpv1_gsldrag.meta b/physics/GWD/ugwpv1_gsldrag.meta index e1a201d57..6d9f5426b 100644 --- a/physics/GWD/ugwpv1_gsldrag.meta +++ b/physics/GWD/ugwpv1_gsldrag.meta @@ -477,7 +477,7 @@ [alpha_fd] standard_name = alpha_coefficient_for_turbulent_orographic_form_drag long_name = alpha coefficient for Beljaars et al turbulent orographic form drag - units = none + units = 1 dimensions = () type = real kind = kind_phys diff --git a/physics/GWD/unified_ugwp.F90 b/physics/GWD/unified_ugwp.F90 index 5e47f2001..adedeeb15 100644 --- a/physics/GWD/unified_ugwp.F90 +++ b/physics/GWD/unified_ugwp.F90 @@ -253,7 +253,7 @@ subroutine unified_ugwp_run(me, master, im, levs, ak,bk, ntrac, dtp, fhzero, kdt cdmbgwd, alpha_fd, jdat, xlat, xlat_d, sinlat, coslat, area, & ugrs, vgrs, tgrs, q1, prsi, prsl, prslk, phii, phil, & del, kpbl, dusfcg, dvsfcg, gw_dudt, gw_dvdt, gw_dtdt, gw_kdis, & - tau_tofd, tau_mtb, tau_ogw, tau_ngw, zmtb, zlwb, zogw, & + tau_tofd, tau_mtb, tau_ogw, tau_ngw, & dudt_mtb, dudt_tms, du3dt_mtb, du3dt_ogw, du3dt_tms, & dudt, dvdt, dtdt, rdxzb, con_g, con_omega, con_pi, con_cp, con_rd, con_rv, & con_rerth, con_fvirt, rain, ntke, q_tke, dqdt_tke, lprnt, ipr, & @@ -311,7 +311,7 @@ subroutine unified_ugwp_run(me, master, im, levs, ak,bk, ntrac, dtp, fhzero, kdt & slmsk(:) real(kind=kind_phys), intent(out), dimension(:) :: dusfcg, dvsfcg - real(kind=kind_phys), intent(out), dimension(:) :: zmtb, zlwb, zogw, rdxzb + real(kind=kind_phys), intent(out), dimension(:) :: rdxzb real(kind=kind_phys), intent(out), dimension(:) :: tau_mtb, tau_ogw, tau_tofd, tau_ngw real(kind=kind_phys), intent(out), dimension(:,:) :: gw_dudt, gw_dvdt, gw_dtdt, gw_kdis real(kind=kind_phys), intent(out), dimension(:,:) :: dudt_mtb, dudt_tms @@ -385,6 +385,18 @@ subroutine unified_ugwp_run(me, master, im, levs, ak,bk, ntrac, dtp, fhzero, kdt errflg = 0 + ! Initialize intent(out) variables in case they are not set below + dusfcg(:) = 0.0 + dvsfcg(:) = 0.0 + rdxzb(:) = 0.0 + tau_ngw(:) = 0.0 + gw_dudt(:,:) = 0.0 + gw_dvdt(:,:) = 0.0 + gw_dtdt(:,:) = 0.0 + gw_kdis(:,:) = 0.0 + dudt_mtb(:,:) = 0.0 + dudt_tms(:,:) = 0.0 + ! 1) ORO stationary GWs ! ------------------ diff --git a/physics/GWD/unified_ugwp.meta b/physics/GWD/unified_ugwp.meta index 5dc347650..91f63f03e 100644 --- a/physics/GWD/unified_ugwp.meta +++ b/physics/GWD/unified_ugwp.meta @@ -718,7 +718,7 @@ [alpha_fd] standard_name = alpha_coefficient_for_turbulent_orographic_form_drag long_name = alpha coefficient for Beljaars et al turbulent orographic form drag - units = none + units = 1 dimensions = () type = real kind = kind_phys @@ -938,30 +938,6 @@ type = real kind = kind_phys intent = out -[zmtb] - standard_name = height_of_mountain_blocking - long_name = height of mountain blocking drag - units = m - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - intent = out -[zlwb] - standard_name = height_of_low_level_wave_breaking - long_name = height of low level wave breaking - units = m - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - intent = out -[zogw] - standard_name = height_of_launch_level_of_orographic_gravity_wave - long_name = height of launch level of orographic gravity wave - units = m - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - intent = out [dudt_mtb] standard_name = instantaneous_change_in_x_wind_due_to_mountain_blocking_drag long_name = instantaneous change in x wind due to mountain blocking drag diff --git a/physics/SFC_Models/Land/Noahmp/module_sf_noahmplsm.F90 b/physics/SFC_Models/Land/Noahmp/module_sf_noahmplsm.F90 index a3b466f46..97f11a1ba 100644 --- a/physics/SFC_Models/Land/Noahmp/module_sf_noahmplsm.F90 +++ b/physics/SFC_Models/Land/Noahmp/module_sf_noahmplsm.F90 @@ -2020,6 +2020,8 @@ subroutine energy (parameters,ice ,vegtyp ,ist ,nsnow ,nsoil , & !in chuc = 0. chv2 = 0. rb = 0. + laisun = 0. + laisha = 0. cdmnv = 0.0 ezpdv = 0.0 diff --git a/physics/SFC_Models/Land/Noahmp/noahmpdrv.F90 b/physics/SFC_Models/Land/Noahmp/noahmpdrv.F90 index 4af3b93b6..0f62fb68e 100644 --- a/physics/SFC_Models/Land/Noahmp/noahmpdrv.F90 +++ b/physics/SFC_Models/Land/Noahmp/noahmpdrv.F90 @@ -158,7 +158,7 @@ subroutine noahmpdrv_run & sncovr1, qsurf, gflux, drain, evap, hflx, ep, runoff, & cmm, chh, evbs, evcw, sbsno, pah, ecan, etran, edir, snowc,& stm, snohf,smcwlt2, smcref2, wet1, t2mmp, q2mp,zvfun, & - ztmax, rca, errmsg, errflg, & + ztmax, rca, errmsg, errflg, & canopy_heat_storage_ccpp, & rainfall_ccpp, & sw_absorbed_total_ccpp, & diff --git a/physics/SFC_Models/Land/Noahmp/noahmpdrv.meta b/physics/SFC_Models/Land/Noahmp/noahmpdrv.meta index 594903122..7376ba4a2 100644 --- a/physics/SFC_Models/Land/Noahmp/noahmpdrv.meta +++ b/physics/SFC_Models/Land/Noahmp/noahmpdrv.meta @@ -665,7 +665,7 @@ [gwd_z0m_factor] standard_name = momentum_roughness_factor_in_turbulent_form_drag long_name = multiplication of orograhic standard deviation - units = count + units = 1 dimensions = () type = real kind = kind_phys