From b9027cfa8c9c9448a06985de5f2716e628001e9e Mon Sep 17 00:00:00 2001 From: Xiaqiong Zhou Date: Tue, 29 Apr 2025 16:41:22 +0000 Subject: [PATCH 1/5] Use different cutoff level for fast_tau_w_sec --- model/dyn_core.F90 | 2 +- model/fv_arrays.F90 | 2 ++ model/fv_control.F90 | 4 +++- model/nh_utils.F90 | 8 ++++---- 4 files changed, 10 insertions(+), 6 deletions(-) diff --git a/model/dyn_core.F90 b/model/dyn_core.F90 index ce53b8467..53bf04a6b 100644 --- a/model/dyn_core.F90 +++ b/model/dyn_core.F90 @@ -633,7 +633,7 @@ subroutine dyn_core(npx, npy, npz, ng, sphum, nq, bdt, n_map, n_split, zvir, cp, ptop, phis, omga, ptc, & q_con, delpc, gz, pkc, ws3, flagstruct%p_fac, & flagstruct%a_imp, flagstruct%scale_z, pfull, & - flagstruct%fast_tau_w_sec, flagstruct%rf_cutoff ) + flagstruct%fast_tau_w_sec, flagstruct%rf_cutoff_fast ) call timing_off('Riem_Solver') if (gridstruct%nested) then diff --git a/model/fv_arrays.F90 b/model/fv_arrays.F90 index 26a9cf153..8c11e8728 100644 --- a/model/fv_arrays.F90 +++ b/model/fv_arrays.F90 @@ -698,6 +698,8 @@ module fv_arrays_mod !< considered; and for non-hydrostatic models values of 10 or less should be !< considered, with smaller values for higher-resolution. real :: rf_cutoff = 30.E2 !< Pressure below which no Rayleigh damping is applied if tau > 0. + real :: rf_cutoff_fast = 30.E2 !< Pressure below which no fast vertical velocity Rayleigh + ! damping is applied if fast_tau_w_sec > 0. real :: fast_tau_w_sec = 0.0 !< Time scale (seconds) for Rayleigh damping applied to vertical velocity only. !< Values of 0.2 are very effective at eliminating spurious vertical motion in !< the stratosphere. Default is 0.0, which disables this. diff --git a/model/fv_control.F90 b/model/fv_control.F90 index 2ead0274c..72b9ddfc8 100644 --- a/model/fv_control.F90 +++ b/model/fv_control.F90 @@ -333,6 +333,7 @@ subroutine fv_control_init(Atm, dt_atmos, this_grid, grids_on_this_pe, p_split, real , pointer :: tau_w real , pointer :: fast_tau_w_sec real , pointer :: rf_cutoff + real , pointer :: rf_cutoff_fast logical , pointer :: filter_phys logical , pointer :: dwind_2d logical , pointer :: breed_vortex_inline @@ -912,6 +913,7 @@ subroutine set_namelist_pointers(Atm) tau_w => Atm%flagstruct%tau_w fast_tau_w_sec => Atm%flagstruct%fast_tau_w_sec rf_cutoff => Atm%flagstruct%rf_cutoff + rf_cutoff_fast => Atm%flagstruct%rf_cutoff_fast filter_phys => Atm%flagstruct%filter_phys dwind_2d => Atm%flagstruct%dwind_2d breed_vortex_inline => Atm%flagstruct%breed_vortex_inline @@ -1080,7 +1082,7 @@ subroutine read_namelist_fv_core_nml(Atm) dry_mass, grid_type, do_Held_Suarez, do_reed_physics, reed_cond_only, & consv_te, fill, filter_phys, fill_dp, fill_wz, fill_gfs, consv_am, RF_fast, & range_warn, dwind_2d, inline_q, z_tracer, reproduce_sum, adiabatic, do_vort_damp, no_dycore, & - tau, tau_w, fast_tau_w_sec, tau_h2o, rf_cutoff, nf_omega, hydrostatic, fv_sg_adj, sg_cutoff, breed_vortex_inline, & + tau, tau_w, fast_tau_w_sec, tau_h2o, rf_cutoff, rf_cutoff_fast, nf_omega, hydrostatic, fv_sg_adj, sg_cutoff, breed_vortex_inline, & na_init, nudge_dz, hybrid_z, Make_NH, n_zs_filter, nord_zs_filter, full_zs_filter, reset_eta, & pnats, dnats, dnrts, a2b_ord, remap_t, p_ref, d2_bg_k1, d2_bg_k2, & c2l_ord, dx_const, dy_const, umax, deglat, & diff --git a/model/nh_utils.F90 b/model/nh_utils.F90 index 2b89aea48..eba929005 100644 --- a/model/nh_utils.F90 +++ b/model/nh_utils.F90 @@ -353,11 +353,11 @@ subroutine Riem_Solver_c(ms, dt, is, ie, js, je, km, ng, & #endif ptop, hs, w3, pt, q_con, & delp, gz, pef, ws, p_fac, a_imp, scale_m, & - pfull, fast_tau_w_sec, rf_cutoff) + pfull, fast_tau_w_sec, rf_cutoff_fast) integer, intent(in):: is, ie, js, je, ng, km integer, intent(in):: ms - real, intent(in):: dt, akap, cp, ptop, p_fac, a_imp, scale_m, fast_tau_w_sec, rf_cutoff + real, intent(in):: dt, akap, cp, ptop, p_fac, a_imp, scale_m, fast_tau_w_sec, rf_cutoff_fast real, intent(in):: ws(is-ng:ie+ng,js-ng:je+ng) real, intent(in), dimension(is-ng:ie+ng,js-ng:je+ng,km):: pt, delp real, intent(in), dimension(is-ng:,js-ng:,1:):: q_con, cappa @@ -392,10 +392,10 @@ subroutine Riem_Solver_c(ms, dt, is, ie, js, je, km, ng, & allocate(rff(km)) RFw_initialized = .true. do k=1,km - if (pfull(k) > rf_cutoff) exit + if (pfull(k) > rf_cutoff_fast) exit k_rf = k rff_temp = real(dt/fast_tau_w_sec,kind=8) & - * sin(0.5d0*pi_8*log(real(rf_cutoff/pfull(k),kind=8))/log(real(rf_cutoff/ptop, kind=8)))**2 + * sin(0.5d0*pi_8*log(real(rf_cutoff_fast/pfull(k),kind=8))/log(real(rf_cutoff_fast/ptop, kind=8)))**2 rff(k) = 1.0d0 / ( 1.0d0+rff_temp ) enddo endif From 247220971c02e7c1134e93a62174771964c0daff Mon Sep 17 00:00:00 2001 From: XiaqiongZhou-NOAA <48254930+XiaqiongZhou-NOAA@users.noreply.github.com> Date: Wed, 7 May 2025 09:27:57 -0400 Subject: [PATCH 2/5] Change rf_cutoff_fast default value --- model/fv_arrays.F90 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/model/fv_arrays.F90 b/model/fv_arrays.F90 index 8c11e8728..d5df4b388 100644 --- a/model/fv_arrays.F90 +++ b/model/fv_arrays.F90 @@ -698,7 +698,7 @@ module fv_arrays_mod !< considered; and for non-hydrostatic models values of 10 or less should be !< considered, with smaller values for higher-resolution. real :: rf_cutoff = 30.E2 !< Pressure below which no Rayleigh damping is applied if tau > 0. - real :: rf_cutoff_fast = 30.E2 !< Pressure below which no fast vertical velocity Rayleigh + real :: rf_cutoff_fast = 1.E2 !< Pressure below which no fast vertical velocity Rayleigh ! damping is applied if fast_tau_w_sec > 0. real :: fast_tau_w_sec = 0.0 !< Time scale (seconds) for Rayleigh damping applied to vertical velocity only. !< Values of 0.2 are very effective at eliminating spurious vertical motion in From b2e9c4f713ef8af372c27e62e3fdefad733879f8 Mon Sep 17 00:00:00 2001 From: Xiaqiong Zhou Date: Mon, 19 May 2025 17:10:18 +0000 Subject: [PATCH 3/5] Change the new paramater name from rf_cutoff_fast to rf_cutoff_w --- model/dyn_core.F90 | 2 +- model/fv_arrays.F90 | 2 +- model/fv_control.F90 | 6 +++--- model/nh_utils.F90 | 8 ++++---- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/model/dyn_core.F90 b/model/dyn_core.F90 index 53bf04a6b..7f69a776c 100644 --- a/model/dyn_core.F90 +++ b/model/dyn_core.F90 @@ -633,7 +633,7 @@ subroutine dyn_core(npx, npy, npz, ng, sphum, nq, bdt, n_map, n_split, zvir, cp, ptop, phis, omga, ptc, & q_con, delpc, gz, pkc, ws3, flagstruct%p_fac, & flagstruct%a_imp, flagstruct%scale_z, pfull, & - flagstruct%fast_tau_w_sec, flagstruct%rf_cutoff_fast ) + flagstruct%fast_tau_w_sec, flagstruct%rf_cutoff_w ) call timing_off('Riem_Solver') if (gridstruct%nested) then diff --git a/model/fv_arrays.F90 b/model/fv_arrays.F90 index d5df4b388..03a04035c 100644 --- a/model/fv_arrays.F90 +++ b/model/fv_arrays.F90 @@ -698,7 +698,7 @@ module fv_arrays_mod !< considered; and for non-hydrostatic models values of 10 or less should be !< considered, with smaller values for higher-resolution. real :: rf_cutoff = 30.E2 !< Pressure below which no Rayleigh damping is applied if tau > 0. - real :: rf_cutoff_fast = 1.E2 !< Pressure below which no fast vertical velocity Rayleigh + real :: rf_cutoff_w = 1.E2 !< Pressure below which no fast vertical velocity Rayleigh ! damping is applied if fast_tau_w_sec > 0. real :: fast_tau_w_sec = 0.0 !< Time scale (seconds) for Rayleigh damping applied to vertical velocity only. !< Values of 0.2 are very effective at eliminating spurious vertical motion in diff --git a/model/fv_control.F90 b/model/fv_control.F90 index 72b9ddfc8..8e3e398b4 100644 --- a/model/fv_control.F90 +++ b/model/fv_control.F90 @@ -333,7 +333,7 @@ subroutine fv_control_init(Atm, dt_atmos, this_grid, grids_on_this_pe, p_split, real , pointer :: tau_w real , pointer :: fast_tau_w_sec real , pointer :: rf_cutoff - real , pointer :: rf_cutoff_fast + real , pointer :: rf_cutoff_w logical , pointer :: filter_phys logical , pointer :: dwind_2d logical , pointer :: breed_vortex_inline @@ -913,7 +913,7 @@ subroutine set_namelist_pointers(Atm) tau_w => Atm%flagstruct%tau_w fast_tau_w_sec => Atm%flagstruct%fast_tau_w_sec rf_cutoff => Atm%flagstruct%rf_cutoff - rf_cutoff_fast => Atm%flagstruct%rf_cutoff_fast + rf_cutoff_w => Atm%flagstruct%rf_cutoff_w filter_phys => Atm%flagstruct%filter_phys dwind_2d => Atm%flagstruct%dwind_2d breed_vortex_inline => Atm%flagstruct%breed_vortex_inline @@ -1082,7 +1082,7 @@ subroutine read_namelist_fv_core_nml(Atm) dry_mass, grid_type, do_Held_Suarez, do_reed_physics, reed_cond_only, & consv_te, fill, filter_phys, fill_dp, fill_wz, fill_gfs, consv_am, RF_fast, & range_warn, dwind_2d, inline_q, z_tracer, reproduce_sum, adiabatic, do_vort_damp, no_dycore, & - tau, tau_w, fast_tau_w_sec, tau_h2o, rf_cutoff, rf_cutoff_fast, nf_omega, hydrostatic, fv_sg_adj, sg_cutoff, breed_vortex_inline, & + tau, tau_w, fast_tau_w_sec, tau_h2o, rf_cutoff, rf_cutoff_w, nf_omega, hydrostatic, fv_sg_adj, sg_cutoff, breed_vortex_inline, & na_init, nudge_dz, hybrid_z, Make_NH, n_zs_filter, nord_zs_filter, full_zs_filter, reset_eta, & pnats, dnats, dnrts, a2b_ord, remap_t, p_ref, d2_bg_k1, d2_bg_k2, & c2l_ord, dx_const, dy_const, umax, deglat, & diff --git a/model/nh_utils.F90 b/model/nh_utils.F90 index eba929005..5f3d7c7fd 100644 --- a/model/nh_utils.F90 +++ b/model/nh_utils.F90 @@ -353,11 +353,11 @@ subroutine Riem_Solver_c(ms, dt, is, ie, js, je, km, ng, & #endif ptop, hs, w3, pt, q_con, & delp, gz, pef, ws, p_fac, a_imp, scale_m, & - pfull, fast_tau_w_sec, rf_cutoff_fast) + pfull, fast_tau_w_sec, rf_cutoff_w) integer, intent(in):: is, ie, js, je, ng, km integer, intent(in):: ms - real, intent(in):: dt, akap, cp, ptop, p_fac, a_imp, scale_m, fast_tau_w_sec, rf_cutoff_fast + real, intent(in):: dt, akap, cp, ptop, p_fac, a_imp, scale_m, fast_tau_w_sec, rf_cutoff_w real, intent(in):: ws(is-ng:ie+ng,js-ng:je+ng) real, intent(in), dimension(is-ng:ie+ng,js-ng:je+ng,km):: pt, delp real, intent(in), dimension(is-ng:,js-ng:,1:):: q_con, cappa @@ -392,10 +392,10 @@ subroutine Riem_Solver_c(ms, dt, is, ie, js, je, km, ng, & allocate(rff(km)) RFw_initialized = .true. do k=1,km - if (pfull(k) > rf_cutoff_fast) exit + if (pfull(k) > rf_cutoff_w) exit k_rf = k rff_temp = real(dt/fast_tau_w_sec,kind=8) & - * sin(0.5d0*pi_8*log(real(rf_cutoff_fast/pfull(k),kind=8))/log(real(rf_cutoff_fast/ptop, kind=8)))**2 + * sin(0.5d0*pi_8*log(real(rf_cutoff_w/pfull(k),kind=8))/log(real(rf_cutoff_w/ptop, kind=8)))**2 rff(k) = 1.0d0 / ( 1.0d0+rff_temp ) enddo endif From 6ef3f8fce19d0393bdc8817573e87d236177750d Mon Sep 17 00:00:00 2001 From: XiaqiongZhou-NOAA <48254930+XiaqiongZhou-NOAA@users.noreply.github.com> Date: Mon, 19 May 2025 13:53:27 -0400 Subject: [PATCH 4/5] retain spacing --- model/fv_control.F90 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/model/fv_control.F90 b/model/fv_control.F90 index 8e3e398b4..921c2ebd0 100644 --- a/model/fv_control.F90 +++ b/model/fv_control.F90 @@ -913,7 +913,7 @@ subroutine set_namelist_pointers(Atm) tau_w => Atm%flagstruct%tau_w fast_tau_w_sec => Atm%flagstruct%fast_tau_w_sec rf_cutoff => Atm%flagstruct%rf_cutoff - rf_cutoff_w => Atm%flagstruct%rf_cutoff_w + rf_cutoff_w => Atm%flagstruct%rf_cutoff_w filter_phys => Atm%flagstruct%filter_phys dwind_2d => Atm%flagstruct%dwind_2d breed_vortex_inline => Atm%flagstruct%breed_vortex_inline From f924f532b3840d4d591f3ba8f557cdb7b3f19edb Mon Sep 17 00:00:00 2001 From: XiaqiongZhou-NOAA <48254930+XiaqiongZhou-NOAA@users.noreply.github.com> Date: Tue, 20 May 2025 09:57:05 -0400 Subject: [PATCH 5/5] Revise bad temperature range for warning --- tools/fv_diagnostics.F90 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/fv_diagnostics.F90 b/tools/fv_diagnostics.F90 index b54f5c84d..95cf4c8c1 100644 --- a/tools/fv_diagnostics.F90 +++ b/tools/fv_diagnostics.F90 @@ -355,8 +355,8 @@ subroutine fv_diag_init(Atm, axes, Time, npx, npy, npz, p_ref) trange = (/ 5., 350. /) ! temperature trange_bad = (/ 130., 350. /) ! temperature #else - trange = (/ 100., 350. /) ! temperature - trange_bad = (/ 150., 350. /) ! temperature + trange = (/ 50., 350. /) ! temperature + trange_bad = (/ 50., 350. /) ! temperature #endif endif rhrange = (/ -10., 150. /) ! RH