Skip to content

Commit

Permalink
Revert some changes
Browse files Browse the repository at this point in the history
  • Loading branch information
dustinswales committed Apr 3, 2024
1 parent c776501 commit d65198c
Show file tree
Hide file tree
Showing 23 changed files with 44 additions and 143 deletions.
4 changes: 0 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -119,10 +119,6 @@ if(${LOCAL_CURRENT_SOURCE_DIR}/physics/MP/GFDL/fv_sat_adj.F90 IN_LIST SCHEMES)
list(APPEND SCHEMES_DYNAMICS ${LOCAL_CURRENT_SOURCE_DIR}/physics/MP/GFDL/fv_sat_adj.F90)
endif()

if(${LOCAL_CURRENT_SOURCE_DIR}/physics/MP/GFDL/fv_sat_adj_v3.F90 IN_LIST SCHEMES)
list(APPEND SCHEMES_DYNAMICS ${LOCAL_CURRENT_SOURCE_DIR}/physics/MP/GFDL/fv_sat_adj_v3.F90)
endif()

# Remove files that need to be compiled with different precision
# of files with standard compiler flags, and assign OpenMP flags
if(SCHEMES_DYNAMICS)
Expand Down
19 changes: 7 additions & 12 deletions physics/Interstitials/UFS_SCM_NEPTUNE/GFS_MP_generic_post.F90
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@ module GFS_MP_generic_post
!> \section gfs_mp_gen GFS MP Generic Post General Algorithm
!> @{
subroutine GFS_MP_generic_post_run( &
im, levs, kdt, nrcm, nncl, ntcw, ntrac, imp_physics, imp_physics_gfdl, imp_physics_gfdl_v3, &
imp_physics_thompson, imp_physics_nssl, &
im, levs, kdt, nrcm, nncl, ntcw, ntrac, imp_physics, imp_physics_gfdl, imp_physics_thompson, imp_physics_nssl, &
imp_physics_mg, imp_physics_fer_hires, cal_pre, cplflx, cplchm, cpllnd, progsigma, con_g, rhowater, rainmin, dtf, &
frain, rainc, rain1, rann, xlat, xlon, gt0, gq0, prsl, prsi, phii, tsfc, ice, phil, htop, refl_10cm, &
imfshalcnv,imfshalcnv_gf,imfdeepcnv,imfdeepcnv_gf,imfdeepcnv_samf, con_t0c, snow, graupel, save_t, save_q, &
Expand All @@ -38,8 +37,7 @@ subroutine GFS_MP_generic_post_run(
implicit none

integer, intent(in) :: im, levs, kdt, nrcm, nncl, ntcw, ntrac, num_dfi_radar, index_of_process_dfi_radar
integer, intent(in) :: imp_physics, imp_physics_gfdl, imp_physics_gfdl_v3
integer, intent(in) :: imp_physics_thompson, imp_physics_mg, imp_physics_fer_hires
integer, intent(in) :: imp_physics, imp_physics_gfdl, imp_physics_thompson, imp_physics_mg, imp_physics_fer_hires
integer, intent(in) :: imp_physics_nssl, iopt_lake_clm, iopt_lake, lkm
logical, intent(in) :: cal_pre, lssav, ldiag3d, qdiag3d, cplflx, cplchm, cpllnd, progsigma, exticeden
integer, intent(in) :: index_of_temperature,index_of_process_mp,use_lake_model(:)
Expand Down Expand Up @@ -184,8 +182,7 @@ subroutine GFS_MP_generic_post_run(
endif

! compute surface snowfall, graupel/sleet, freezing rain and precip ice density
if (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_gfdl_v3 &
.or. imp_physics == imp_physics_thompson .or. imp_physics == imp_physics_nssl) then
if (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_thompson .or. imp_physics == imp_physics_nssl ) then
do i = 1, im
if (gt0(i,1) .le. 273) then
frzr(i) = frzr(i) + rain0(i)
Expand Down Expand Up @@ -254,7 +251,7 @@ subroutine GFS_MP_generic_post_run(
! GFS_physics_driver is written, Diag%{graupel,ice,snow} are on the
! physics timestep, while Diag%{rain,rainc} and all totprecip etc
! are on the dynamics timestep. Confusing, but works if frain=1. *DH
if (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_gfdl_v3) then
if (imp_physics == imp_physics_gfdl) then
tprcp = max(zero, rain) ! clu: rain -> tprcp
!graupel = frain*graupel0
!ice = frain*ice0
Expand Down Expand Up @@ -309,8 +306,7 @@ subroutine GFS_MP_generic_post_run(
!
! HCHUANG: use new precipitation type to decide snow flag for LSM snow accumulation

if (imp_physics /= imp_physics_gfdl .and. imp_physics /= imp_physics_gfdl_v3 &
.and. imp_physics /= imp_physics_thompson .and. imp_physics /= imp_physics_nssl) then
if (imp_physics /= imp_physics_gfdl .and. imp_physics /= imp_physics_thompson .and. imp_physics /= imp_physics_nssl) then
do i=1,im
tprcp(i) = max(zero, rain(i) )
if(doms(i) > zero .or. domip(i) > zero) then
Expand Down Expand Up @@ -397,9 +393,8 @@ subroutine GFS_MP_generic_post_run(
!! and convective rainfall from the cumulus scheme if the surface temperature is below
!! \f$0^oC\f$.

if (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_gfdl_v3 &
.or. imp_physics == imp_physics_thompson &
.or. imp_physics == imp_physics_nssl ) then
if (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_thompson .or. &
imp_physics == imp_physics_nssl ) then

! determine convective rain/snow by surface temperature
! determine large-scale rain/snow by rain/snow coming out directly from MP
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,6 @@
dimensions = ()
type = integer
intent = in
[imp_physics_gfdl_v3]
standard_name = identifier_for_gfdl_microphysics_v3_scheme
long_name = choice of GFDL microphysics v3 scheme
units = flag
dimensions = ()
type = integer
intent = in
[imp_physics_thompson]
standard_name = identifier_for_thompson_microphysics_scheme
long_name = choice of Thompson microphysics scheme
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ module GFS_PBL_generic_common
subroutine set_aerosol_tracer_index(imp_physics, imp_physics_wsm6, &
imp_physics_thompson, ltaerosol,mraerosol, &
imp_physics_mg, ntgl, imp_physics_gfdl, &
imp_physics_gfdl_v3, &
imp_physics_zhao_carr, imp_physics_nssl,&
nssl_hail_on, nssl_ccn_on, kk, &
errmsg, errflg)
Expand All @@ -23,7 +22,6 @@ subroutine set_aerosol_tracer_index(imp_physics, imp_physics_wsm6, &
integer, intent(in ) :: imp_physics, imp_physics_wsm6, &
imp_physics_thompson, &
imp_physics_mg, ntgl, imp_physics_gfdl, &
imp_physics_gfdl_v3, &
imp_physics_zhao_carr,imp_physics_nssl
logical, intent(in ) :: ltaerosol, mraerosol, nssl_hail_on, nssl_ccn_on
integer, intent(out) :: kk
Expand Down Expand Up @@ -52,7 +50,7 @@ subroutine set_aerosol_tracer_index(imp_physics, imp_physics_wsm6, &
else
kk = 10
endif
elseif (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_gfdl_v3) then
elseif (imp_physics == imp_physics_gfdl) then
! GFDL MP
kk = 7
elseif (imp_physics == imp_physics_zhao_carr) then
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ module GFS_PBL_generic_post
subroutine GFS_PBL_generic_post_run (im, levs, nvdiff, ntrac, &
ntqv, ntcw, ntiw, ntrw, ntsw, ntlnc, ntinc, ntrnc, ntsnc, ntgnc, ntwa, ntia, ntgl, ntoz, ntke, ntkev,nqrimef, &
trans_aero, ntchs, ntchm, ntccn, nthl, nthnc, ntgv, nthv, ntrz, ntgz, nthz, &
imp_physics, imp_physics_gfdl, imp_physics_gfdl_v3, imp_physics_thompson, imp_physics_wsm6, imp_physics_zhao_carr, &
imp_physics_mg, imp_physics_fer_hires, imp_physics_nssl, nssl_ccn_on, ltaerosol, mraerosol, nssl_hail_on, nssl_3moment,&
imp_physics, imp_physics_gfdl, imp_physics_thompson, imp_physics_wsm6, imp_physics_zhao_carr, imp_physics_mg, &
imp_physics_fer_hires, imp_physics_nssl, nssl_ccn_on, ltaerosol, mraerosol, nssl_hail_on, nssl_3moment, &
cplflx, cplaqm, cplchm, lssav, flag_for_pbl_generic_tend, ldiag3d, lsidea, hybedmf, do_shoc, satmedmf, &
shinhong, do_ysu, dvdftra, dusfc1, dvsfc1, dtsfc1, dqsfc1, dtf, dudt, dvdt, dtdt, htrsw, htrlw, xmu, &
dqdt, dusfc_cpl, dvsfc_cpl, dtsfc_cpl, dtend, dtidx, index_of_temperature, index_of_x_wind, index_of_y_wind, &
Expand All @@ -32,7 +32,7 @@ subroutine GFS_PBL_generic_post_run (im, levs, nvdiff, ntrac,
integer, intent(in) :: ntqv, ntcw, ntiw, ntrw, ntsw, ntlnc, ntinc, ntrnc, ntsnc, ntgnc, ntwa, ntia, ntgl, ntoz, ntke, ntkev, nqrimef
integer, intent(in) :: ntccn, nthl, nthnc, ntgv, nthv, ntrz, ntgz, nthz
logical, intent(in) :: trans_aero
integer, intent(in) :: imp_physics, imp_physics_gfdl, imp_physics_gfdl_v3, imp_physics_thompson, imp_physics_wsm6
integer, intent(in) :: imp_physics, imp_physics_gfdl, imp_physics_thompson, imp_physics_wsm6
integer, intent(in) :: imp_physics_zhao_carr, imp_physics_mg, imp_physics_fer_hires
integer, intent(in) :: imp_physics_nssl
logical, intent(in) :: nssl_ccn_on, nssl_hail_on, nssl_3moment
Expand Down Expand Up @@ -106,7 +106,6 @@ subroutine GFS_PBL_generic_post_run (im, levs, nvdiff, ntrac,
call set_aerosol_tracer_index(imp_physics, imp_physics_wsm6, &
imp_physics_thompson, ltaerosol,mraerosol, &
imp_physics_mg, ntgl, imp_physics_gfdl, &
imp_physics_gfdl_v3, &
imp_physics_zhao_carr, imp_physics_nssl,&
nssl_hail_on, nssl_ccn_on, kk, &
errmsg, errflg)
Expand Down Expand Up @@ -230,7 +229,7 @@ subroutine GFS_PBL_generic_post_run (im, levs, nvdiff, ntrac,
enddo
enddo
endif
elseif (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_gfdl_v3) then ! GFDL MP
elseif (imp_physics == imp_physics_gfdl) then ! GFDL MP
do k=1,levs
do i=1,im
dqdt(i,k,ntqv) = dvdftra(i,k,1)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -246,13 +246,6 @@
dimensions = ()
type = integer
intent = in
[imp_physics_gfdl_v3]
standard_name = identifier_for_gfdl_microphysics_v3_scheme
long_name = choice of GFDL microphysics v3 scheme
units = flag
dimensions = ()
type = integer
intent = in
[imp_physics_thompson]
standard_name = identifier_for_thompson_microphysics_scheme
long_name = choice of Thompson microphysics scheme
Expand Down
10 changes: 4 additions & 6 deletions physics/Interstitials/UFS_SCM_NEPTUNE/GFS_PBL_generic_pre.F90
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ module GFS_PBL_generic_pre
subroutine GFS_PBL_generic_pre_run (im, levs, nvdiff, ntrac, rtg_ozone_index, &
ntqv, ntcw, ntiw, ntrw, ntsw, ntlnc, ntinc, ntrnc, ntsnc, ntgnc, &
ntwa, ntia, ntgl, ntoz, ntke, ntkev, nqrimef, trans_aero, ntchs, ntchm, &
ntccn, nthl, nthnc, ntgv, nthv, ntrz, ntgz, nthz, imp_physics, &
imp_physics_gfdl, imp_physics_gfdl_v3, imp_physics_thompson, imp_physics_wsm6, &
ntccn, nthl, nthnc, ntgv, nthv, ntrz, ntgz, nthz, &
imp_physics, imp_physics_gfdl, imp_physics_thompson, imp_physics_wsm6, &
imp_physics_zhao_carr, imp_physics_mg, imp_physics_fer_hires, imp_physics_nssl, &
ltaerosol, mraerosol, nssl_ccn_on, nssl_hail_on, nssl_3moment, &
hybedmf, do_shoc, satmedmf, qgrs, vdftra, save_u, save_v, save_t, save_q, &
Expand All @@ -31,8 +31,7 @@ subroutine GFS_PBL_generic_pre_run (im, levs, nvdiff, ntrac, rtg_ozone_index,
integer, intent(in) :: ntwa, ntia, ntgl, ntoz, ntke, ntkev, nqrimef,ntchs, ntchm
integer, intent(in) :: ntccn, nthl, nthnc, ntgv, nthv, ntrz, ntgz, nthz
logical, intent(in) :: trans_aero, ldiag3d, qdiag3d, lssav
integer, intent(in) :: imp_physics, imp_physics_gfdl, imp_physics_gfdl_v3
integer, intent(in) :: imp_physics_thompson, imp_physics_wsm6
integer, intent(in) :: imp_physics, imp_physics_gfdl, imp_physics_thompson, imp_physics_wsm6
integer, intent(in) :: imp_physics_zhao_carr, imp_physics_mg, imp_physics_fer_hires
logical, intent(in) :: ltaerosol, hybedmf, do_shoc, satmedmf, flag_for_pbl_generic_tend, mraerosol
integer, intent(in) :: imp_physics_nssl
Expand Down Expand Up @@ -178,7 +177,7 @@ subroutine GFS_PBL_generic_pre_run (im, levs, nvdiff, ntrac, rtg_ozone_index,
enddo
rtg_ozone_index = 10
endif
elseif (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_gfdl_v3) then
elseif (imp_physics == imp_physics_gfdl) then
! GFDL MP
do k=1,levs
do i=1,im
Expand Down Expand Up @@ -276,7 +275,6 @@ subroutine GFS_PBL_generic_pre_run (im, levs, nvdiff, ntrac, rtg_ozone_index,
call set_aerosol_tracer_index(imp_physics, imp_physics_wsm6, &
imp_physics_thompson, ltaerosol,mraerosol, &
imp_physics_mg, ntgl, imp_physics_gfdl, &
imp_physics_gfdl_v3, &
imp_physics_zhao_carr, imp_physics_nssl,&
nssl_hail_on, nssl_ccn_on, kk, &
errmsg, errflg)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -252,13 +252,6 @@
dimensions = ()
type = integer
intent = in
[imp_physics_gfdl_v3]
standard_name = identifier_for_gfdl_microphysics_v3_scheme
long_name = choice of GFDL microphysics v3 scheme
units = flag
dimensions = ()
type = integer
intent = in
[imp_physics_thompson]
standard_name = identifier_for_thompson_microphysics_scheme
long_name = choice of Thompson microphysics scheme
Expand Down
3 changes: 1 addition & 2 deletions physics/Interstitials/UFS_SCM_NEPTUNE/GFS_debug.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1392,8 +1392,7 @@ subroutine GFS_interstitialtoscreen_run (Model, Statein, Stateout, Sfcprop, Coup
call print_var(mpirank, omprank, blkno, Grid%xlat_d, Grid%xlon_d, 'Interstitial%clxss ', Interstitial%clxss )
end if
! GFDL and Thompson MP
if (Model%imp_physics == Model%imp_physics_gfdl .or. Model%imp_physics == Model%imp_physics_gfdl_v3 &
.or. Model%imp_physics == Model%imp_physics_thompson .or. Model%imp_physics == Model%imp_physics_nssl) then
if (Model%imp_physics == Model%imp_physics_gfdl .or. Model%imp_physics == Model%imp_physics_thompson .or. Model%imp_physics == Model%imp_physics_nssl) then
call print_var(mpirank, omprank, blkno, Grid%xlat_d, Grid%xlon_d, 'Interstitial%graupelmp ', Interstitial%graupelmp )
call print_var(mpirank, omprank, blkno, Grid%xlat_d, Grid%xlon_d, 'Interstitial%icemp ', Interstitial%icemp )
call print_var(mpirank, omprank, blkno, Grid%xlat_d, Grid%xlon_d, 'Interstitial%rainmp ', Interstitial%rainmp )
Expand Down
11 changes: 4 additions & 7 deletions physics/Interstitials/UFS_SCM_NEPTUNE/GFS_rrtmg_pre.F90
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@ subroutine GFS_rrtmg_pre_run (im, levs, lm, lmk, lmp, n_var_lndp, lextop,&
ntdu1, ntdu2, ntdu3, ntdu4, ntdu5, ntss1, ntss2, &
ntss3, ntss4, ntss5, ntsu, ntbcb, ntbcl, ntocb, ntocl, ntchm, &
imp_physics,imp_physics_nssl, nssl_ccn_on, nssl_invertccn, &
imp_physics_thompson, imp_physics_gfdl, imp_physics_gfdl_v3, &
imp_physics_zhao_carr, &
imp_physics_thompson, imp_physics_gfdl, imp_physics_zhao_carr, &
imp_physics_zhao_carr_pdf, imp_physics_mg, imp_physics_wsm6, &
imp_physics_fer_hires, iovr, iovr_rand, iovr_maxrand, iovr_max, &
iovr_dcorr, iovr_exp, iovr_exprand, idcor, idcor_con, idcor_hogan, &
Expand Down Expand Up @@ -100,7 +99,6 @@ subroutine GFS_rrtmg_pre_run (im, levs, lm, lmk, lmp, n_var_lndp, lextop,&
kdt, imp_physics, &
imp_physics_thompson, &
imp_physics_gfdl, &
imp_physics_gfdl_v3, &
imp_physics_zhao_carr, &
imp_physics_zhao_carr_pdf, &
imp_physics_mg, imp_physics_wsm6, &
Expand Down Expand Up @@ -780,7 +778,7 @@ subroutine GFS_rrtmg_pre_run (im, levs, lm, lmk, lmp, n_var_lndp, lextop,&
enddo
enddo
enddo
if (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_gfdl_v3) then
if (imp_physics == imp_physics_gfdl) then
if (.not. lgfdlmprad) then


Expand Down Expand Up @@ -824,7 +822,7 @@ subroutine GFS_rrtmg_pre_run (im, levs, lm, lmk, lmp, n_var_lndp, lextop,&
enddo
enddo
endif
elseif (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_gfdl_v3) then ! GFDL MP
elseif (imp_physics == imp_physics_gfdl) then ! GFDL MP
if ((imfdeepcnv==imfdeepcnv_gf .or. imfdeepcnv==imfdeepcnv_c3) .and. kdt>1) then
do k=1,lm
k1 = k + kd
Expand Down Expand Up @@ -977,8 +975,7 @@ subroutine GFS_rrtmg_pre_run (im, levs, lm, lmk, lmp, n_var_lndp, lextop,&
& deltaq, sup, dcorr_con, me, icloud, kdt, &
& ntrac, ntcw, ntiw, ntrw, ntsw, ntgl, ntclamt, &
& imp_physics, imp_physics_nssl, imp_physics_fer_hires, &
& imp_physics_gfdl, imp_physics_gfdl_v3, &
& imp_physics_thompson, imp_physics_wsm6, &
& imp_physics_gfdl, imp_physics_thompson, imp_physics_wsm6, &
& imp_physics_zhao_carr, imp_physics_zhao_carr_pdf, &
& imp_physics_mg, iovr, iovr_rand, iovr_maxrand, iovr_max, &
& iovr_dcorr, iovr_exp, iovr_exprand, idcor, idcor_con, &
Expand Down
7 changes: 0 additions & 7 deletions physics/Interstitials/UFS_SCM_NEPTUNE/GFS_rrtmg_pre.meta
Original file line number Diff line number Diff line change
Expand Up @@ -476,13 +476,6 @@
dimensions = ()
type = integer
intent = in
[imp_physics_gfdl_v3]
standard_name = identifier_for_gfdl_microphysics_v3_scheme
long_name = choice of GFDL microphysics v3 scheme
units = flag
dimensions = ()
type = integer
intent = in
[imp_physics_zhao_carr]
standard_name = identifier_for_zhao_carr_microphysics_scheme
long_name = choice of Zhao-Carr microphysics scheme
Expand Down
8 changes: 3 additions & 5 deletions physics/Interstitials/UFS_SCM_NEPTUNE/GFS_rrtmgp_cloud_mp.F90
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,7 @@ module GFS_rrtmgp_cloud_mp
subroutine GFS_rrtmgp_cloud_mp_run(nCol, nLev, nTracers, ncnd, i_cldliq, i_cldice, &
i_cldrain, i_cldsnow, i_cldgrpl, i_cldtot, i_cldliq_nc, i_cldice_nc, i_twa, kdt, &
imfdeepcnv, imfdeepcnv_gf, imfdeepcnv_samf, doSWrad, doLWrad, effr_in, lmfshal, &
ltaerosol,mraerosol, icloud, imp_physics, imp_physics_thompson, &
imp_physics_gfdl, imp_physics_gfdl_v3, &
ltaerosol,mraerosol, icloud, imp_physics, imp_physics_thompson, imp_physics_gfdl, &
lgfdlmprad, do_mynnedmf, uni_cld, lmfdeep2, p_lev, p_lay, t_lay, qs_lay, q_lay, &
relhum, lsmask, xlon, xlat, dx, tv_lay, effrin_cldliq, effrin_cldice, &
effrin_cldrain, effrin_cldsnow, tracer, cnv_mixratio, cld_cnv_frac, qci_conv, &
Expand Down Expand Up @@ -80,8 +79,7 @@ subroutine GFS_rrtmgp_cloud_mp_run(nCol, nLev, nTracers, ncnd, i_cldliq, i_cldic
kdt, & ! Current forecast iteration
imp_physics, & ! Choice of microphysics scheme
imp_physics_thompson, & ! Choice of Thompson
imp_physics_gfdl, & ! Choice of GFDL v1
imp_physics_gfdl_v3, & ! Choice of GFDL v3
imp_physics_gfdl, & ! Choice of GFDL MP
icloud ! Control for cloud are fraction option
logical, intent(in) :: &
doSWrad, & ! Call SW radiation?
Expand Down Expand Up @@ -181,7 +179,7 @@ subroutine GFS_rrtmgp_cloud_mp_run(nCol, nLev, nTracers, ncnd, i_cldliq, i_cldic
! GFDL Microphysics
! ("Implicit" SGS cloud-coupling to the radiation)
! ###################################################################################
if (imp_physics == imp_physics_gfdl .or. imp_physics == imp_physics_gfdl_v3) then
if (imp_physics == imp_physics_gfdl) then
! GFDL-Lin
if (.not. lgfdlmprad) then
errflg = 1
Expand Down
Loading

0 comments on commit d65198c

Please sign in to comment.