Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/lndp noahmp2 : add land perturbation scheme for Noah-MP fractional veg #513

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 11 additions & 16 deletions ccpp/data/GFS_typedefs.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1161,27 +1161,25 @@ module GFS_typedefs
logical :: do_shum
logical :: do_skeb
integer :: skeb_npass
integer :: lndp_type
integer :: lndp_type ! integer indicating land perturbation scheme type:
! 0 - none
! 1 - scheme from Gehne et al, MWR, 2019. (Noah only, not maintained?)
! 2 - scheme from Draper, JHM, 2021.
real(kind=kind_phys) :: sppt_amp ! pjp cloud perturbations
integer :: n_var_lndp
logical :: lndp_each_step ! flag to indicate that land perturbations are applied at every time step,
! otherwise they are applied only after gcycle is run
character(len=3) , pointer :: lndp_var_list(:) ! dimension here must match n_var_max_lndp in stochy_nml_def
real(kind=kind_phys), pointer :: lndp_prt_list(:) ! dimension here must match n_var_max_lndp in stochy_nml_def
! also previous code had dimension 5 for each pert, to allow
! multiple patterns. It wasn't fully coded (and wouldn't have worked
! with nlndp>1, so I just dropped it). If we want to code it properly,
! we'd need to make this dim(6,5).
! next two are duplicated here to support lndp_type=1. If delete that scheme, could remove from GFS defs?
character(len=3) , pointer :: lndp_var_list(:)
real(kind=kind_phys), pointer :: lndp_prt_list(:)
logical :: do_spp ! Overall flag to turn on SPP or not
integer :: spp_pbl
integer :: spp_sfc
integer :: spp_mp
integer :: spp_rad
integer :: spp_gwd
integer :: n_var_spp
character(len=3) , pointer :: spp_var_list(:) ! dimension here must match n_var_spp in stochy_nml_def
real(kind=kind_phys), pointer :: spp_prt_list(:) ! dimension here must match n_var_spp in stochy_nml_def
real(kind=kind_phys), pointer :: spp_stddev_cutoff(:) ! dimension here must match n_var_spp in stochy_nml_def
character(len=3) , pointer :: spp_var_list(:)
junwang-noaa marked this conversation as resolved.
Show resolved Hide resolved
real(kind=kind_phys), pointer :: spp_prt_list(:)
real(kind=kind_phys), pointer :: spp_stddev_cutoff(:)

!--- tracer handling
character(len=32), pointer :: tracer_names(:) !< array of initialized tracers from dynamic core
Expand Down Expand Up @@ -3233,7 +3231,6 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, &
integer :: skeb_npass = 11
integer :: lndp_type = 0
integer :: n_var_lndp = 0
logical :: lndp_each_step = .false.
integer :: n_var_spp = 0
integer :: spp_pbl = 0
integer :: spp_sfc = 0
Expand Down Expand Up @@ -3334,7 +3331,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, &
dlqf, rbcr, shoc_parm, psauras, prauras, wminras, &
do_sppt, do_shum, do_skeb, &
do_spp, n_var_spp, &
lndp_type, n_var_lndp, lndp_each_step, &
lndp_type, n_var_lndp, &
pert_mp,pert_clds,pert_radtend, &
!--- Rayleigh friction
prslrd0, ral_ts, ldiag_ugwp, do_ugwp, do_tofd, &
Expand Down Expand Up @@ -4137,7 +4134,6 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, &
!--- stochastic surface perturbation options
Model%lndp_type = lndp_type
Model%n_var_lndp = n_var_lndp
Model%lndp_each_step = lndp_each_step
Model%do_spp = do_spp
Model%n_var_spp = n_var_spp

Expand Down Expand Up @@ -5742,7 +5738,6 @@ subroutine control_print(Model)
print *, ' do_skeb : ', Model%do_skeb
print *, ' lndp_type : ', Model%lndp_type
print *, ' n_var_lndp : ', Model%n_var_lndp
print *, ' lndp_each_step : ', Model%lndp_each_step
print *, ' do_spp : ', Model%do_spp
print *, ' n_var_spp : ', Model%n_var_spp
print *, ' '
Expand Down
16 changes: 3 additions & 13 deletions ccpp/driver/GFS_diagnostics.F90
Original file line number Diff line number Diff line change
Expand Up @@ -2363,26 +2363,16 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop

if (Model%lndp_type /= 0) then
idx = idx + 1
ExtDiag(idx)%axes = 2
ExtDiag(idx)%name = 'sfc_wts1'
ExtDiag(idx)%axes = 3
ExtDiag(idx)%name = 'sfc_wts'
ExtDiag(idx)%desc = 'perturbation amplitude'
ExtDiag(idx)%unit = 'none'
ExtDiag(idx)%mod_name = 'gfs_phys'
allocate (ExtDiag(idx)%data(nblks))
do nb = 1,nblks
ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%sfc_wts(:,1)
ExtDiag(idx)%data(nb)%var3 => Coupling(nb)%sfc_wts(:,:)
enddo

idx = idx + 1
ExtDiag(idx)%axes = 2
ExtDiag(idx)%name = 'sfc_wts2'
ExtDiag(idx)%desc = 'perturbation amplitude'
ExtDiag(idx)%unit = 'none'
ExtDiag(idx)%mod_name = 'gfs_phys'
allocate (ExtDiag(idx)%data(nblks))
do nb = 1,nblks
ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%sfc_wts(:,2)
enddo
endif

if (Model%do_ca) then
Expand Down
Loading