From 329364bd0bdf0f4a4d5ab71060889947c98f95d0 Mon Sep 17 00:00:00 2001 From: Grant Firl Date: Tue, 18 May 2021 13:06:44 -0600 Subject: [PATCH] copy GFS_phys_time_vary.fv3.F90/meta changes over to SCM versions --- physics/GFS_phys_time_vary.scm.F90 | 63 ++++++++++++++-------- physics/GFS_phys_time_vary.scm.meta | 83 +++++++++++++++++++++++------ 2 files changed, 109 insertions(+), 37 deletions(-) diff --git a/physics/GFS_phys_time_vary.scm.F90 b/physics/GFS_phys_time_vary.scm.F90 index 9fa4e2de3..e1b5c3d9b 100644 --- a/physics/GFS_phys_time_vary.scm.F90 +++ b/physics/GFS_phys_time_vary.scm.F90 @@ -69,16 +69,18 @@ subroutine GFS_phys_time_vary_init ( isot, ivegsrc, nlunit, sncovr, sncovr_ice, lsm, lsm_noahmp, lsm_ruc, min_seaice, & fice, landfrac, vtype, weasd, lsoil, zs, dzs, lsnow_lsm_lbound, lsnow_lsm_ubound, & tvxy, tgxy, tahxy, canicexy, canliqxy, eahxy, cmxy, chxy, fwetxy, sneqvoxy, alboldxy,& - qsnowxy, wslakexy, albdvis, albdnir, albivis, albinir, emiss, taussxy, waxy, wtxy, & + qsnowxy, wslakexy, albdvis_lnd, albdnir_lnd, albivis_lnd, albinir_lnd, albdvis_ice, & + albdnir_ice, albivis_ice, albinir_ice, emiss_lnd, emiss_ice, taussxy, waxy, wtxy, & zwtxy, xlaixy, xsaixy, lfmassxy, stmassxy, rtmassxy, woodxy, stblcpxy, fastcpxy, & smcwtdxy, deeprechxy, rechxy, snowxy, snicexy, snliqxy, tsnoxy , smoiseq, zsnsoxy, & - slc, smc, stc, tsfcl, snowd, canopy, tg3, stype, con_t0c, nthrds, errmsg, errflg) + slc, smc, stc, tsfcl, snowd, canopy, tg3, stype, con_t0c, flag_restart, nthrds, & + errmsg, errflg) implicit none ! Interface variables integer, intent(in) :: me, master, ntoz, iccn, iflip, im, nx, ny - logical, intent(in) :: h2o_phys, iaerclm + logical, intent(in) :: h2o_phys, iaerclm, flag_restart integer, intent(in) :: idate(:) real(kind_phys), intent(in) :: xlat_d(:), xlon_d(:) @@ -119,11 +121,16 @@ subroutine GFS_phys_time_vary_init ( real(kind_phys), intent(inout) :: alboldxy(:) real(kind_phys), intent(inout) :: qsnowxy(:) real(kind_phys), intent(inout) :: wslakexy(:) - real(kind_phys), intent(inout) :: albdvis(:) - real(kind_phys), intent(inout) :: albdnir(:) - real(kind_phys), intent(inout) :: albivis(:) - real(kind_phys), intent(inout) :: albinir(:) - real(kind_phys), intent(inout) :: emiss(:) + real(kind_phys), intent(inout) :: albdvis_lnd(:) + real(kind_phys), intent(inout) :: albdnir_lnd(:) + real(kind_phys), intent(inout) :: albivis_lnd(:) + real(kind_phys), intent(inout) :: albinir_lnd(:) + real(kind_phys), intent(inout) :: albdvis_ice(:) + real(kind_phys), intent(inout) :: albdnir_ice(:) + real(kind_phys), intent(inout) :: albivis_ice(:) + real(kind_phys), intent(inout) :: albinir_ice(:) + real(kind_phys), intent(inout) :: emiss_lnd(:) + real(kind_phys), intent(inout) :: emiss_ice(:) real(kind_phys), intent(inout) :: taussxy(:) real(kind_phys), intent(inout) :: waxy(:) real(kind_phys), intent(inout) :: wtxy(:) @@ -339,8 +346,30 @@ subroutine GFS_phys_time_vary_init ( if (errflg/=0) return end if - if (lsm == lsm_noahmp) then - if (all(tvxy <= zero)) then + !--- For Noah MP or RUC LSMs: initialize four components of albedo for + !--- land and ice - not for restart runs + lsm_init: if (.not.flag_restart) then + if (lsm == lsm_noahmp .or. lsm == lsm_ruc) then + if (me == master ) write(0,'(a)') 'GFS_phys_time_vary_init: initialize albedo for land and ice' + do ix=1,im + albdvis_lnd(ix) = 0.2_kind_phys + albdnir_lnd(ix) = 0.2_kind_phys + albivis_lnd(ix) = 0.2_kind_phys + albinir_lnd(ix) = 0.2_kind_phys + emiss_lnd(ix) = 0.95_kind_phys + enddo + endif + if (lsm == lsm_ruc) then + do ix=1,im + albdvis_ice(ix) = 0.6_kind_phys + albdnir_ice(ix) = 0.6_kind_phys + albivis_ice(ix) = 0.6_kind_phys + albinir_ice(ix) = 0.6_kind_phys + emiss_ice(ix) = 0.97_kind_phys + enddo + endif + + noahmp_init: if (lsm == lsm_noahmp) then allocate(dzsno (lsnow_lsm_lbound:lsnow_lsm_ubound)) allocate(dzsnso(lsnow_lsm_lbound:lsoil) ) dzsno(:) = missing_value @@ -359,11 +388,6 @@ subroutine GFS_phys_time_vary_init ( alboldxy(:) = missing_value qsnowxy(:) = missing_value wslakexy(:) = missing_value - albdvis(:) = missing_value - albdnir(:) = missing_value - albivis(:) = missing_value - albinir(:) = missing_value - emiss(:) = missing_value taussxy(:) = missing_value waxy(:) = missing_value wtxy(:) = missing_value @@ -418,11 +442,6 @@ subroutine GFS_phys_time_vary_init ( ! already set to 0.0 wslakexy(ix) = zero taussxy(ix) = zero - albdvis(ix) = 0.2_kind_phys - albdnir(ix) = 0.2_kind_phys - albivis(ix) = 0.2_kind_phys - albinir(ix) = 0.2_kind_phys - emiss(ix) = 0.95_kind_phys waxy(ix) = 4900.0_kind_phys wtxy(ix) = waxy(ix) @@ -592,8 +611,8 @@ subroutine GFS_phys_time_vary_init ( deallocate(dzsno) deallocate(dzsnso) - endif - endif !if Noah MP cold start ends + endif noahmp_init + endif lsm_init is_initialized = .true. diff --git a/physics/GFS_phys_time_vary.scm.meta b/physics/GFS_phys_time_vary.scm.meta index 74408d533..23df2cfb2 100644 --- a/physics/GFS_phys_time_vary.scm.meta +++ b/physics/GFS_phys_time_vary.scm.meta @@ -755,45 +755,90 @@ kind = kind_phys intent = inout optional = F -[albdvis] - standard_name = surface_albedo_direct_visible - long_name = direct surface albedo visible band +[albdvis_lnd] + standard_name = surface_albedo_direct_visible_over_land + long_name = direct surface albedo visible band over land units = frac dimensions = (horizontal_dimension) type = real kind = kind_phys intent = inout optional = F -[albdnir] - standard_name = surface_albedo_direct_NIR - long_name = direct surface albedo NIR band +[albdnir_lnd] + standard_name = surface_albedo_direct_NIR_over_land + long_name = direct surface albedo NIR band over land units = frac dimensions = (horizontal_dimension) type = real kind = kind_phys intent = inout optional = F -[albivis] - standard_name = surface_albedo_diffuse_visible - long_name = diffuse surface albedo visible band +[albivis_lnd] + standard_name = surface_albedo_diffuse_visible_over_land + long_name = diffuse surface albedo visible band over land units = frac dimensions = (horizontal_dimension) type = real kind = kind_phys intent = inout optional = F -[albinir] - standard_name = surface_albedo_diffuse_NIR - long_name = diffuse surface albedo NIR band +[albinir_lnd] + standard_name = surface_albedo_diffuse_NIR_over_land + long_name = diffuse surface albedo NIR band over land units = frac dimensions = (horizontal_dimension) type = real kind = kind_phys intent = inout optional = F -[emiss] - standard_name = surface_emissivity_lsm - long_name = surface emissivity from lsm +[albdvis_ice] + standard_name = surface_albedo_direct_visible_over_ice + long_name = direct surface albedo visible band over ice + units = frac + dimensions = (horizontal_dimension) + type = real + kind = kind_phys + intent = inout + optional = F +[albdnir_ice] + standard_name = surface_albedo_direct_NIR_over_ice + long_name = direct surface albedo NIR band over ice + units = frac + dimensions = (horizontal_dimension) + type = real + kind = kind_phys + intent = inout + optional = F +[albivis_ice] + standard_name = surface_albedo_diffuse_visible_over_ice + long_name = diffuse surface albedo visible band over ice + units = frac + dimensions = (horizontal_dimension) + type = real + kind = kind_phys + intent = inout + optional = F +[albinir_ice] + standard_name = surface_albedo_diffuse_NIR_over_ice + long_name = diffuse surface albedo NIR band over ice + units = frac + dimensions = (horizontal_dimension) + type = real + kind = kind_phys + intent = inout + optional = F +[emiss_lnd] + standard_name = surface_longwave_emissivity_over_land + long_name = surface lw emissivity in fraction over land + units = frac + dimensions = (horizontal_dimension) + type = real + kind = kind_phys + intent = inout + optional = F +[emiss_ice] + standard_name = surface_longwave_emissivity_over_ice + long_name = surface lw emissivity in fraction over ice units = frac dimensions = (horizontal_dimension) type = real @@ -935,6 +980,14 @@ kind = kind_phys intent = in optional = F +[flag_restart] + standard_name = flag_for_restart + long_name = flag for restart (warmstart) or coldstart + units = flag + dimensions = () + type = logical + intent = in + optional = F [nthrds] standard_name = omp_threads long_name = number of OpenMP threads available for physics schemes