Skip to content
11 changes: 10 additions & 1 deletion physics/GFS_rrtmg_pre.F90
Original file line number Diff line number Diff line change
Expand Up @@ -854,6 +854,15 @@ subroutine GFS_rrtmg_pre_run (im, levs, lm, lmk, lmp, n_var_lndp, &
enddo
endif

if(imp_physics == imp_physics_thompson) then
do k=1,lm
k1 = k + kd
do i=1,im
cnvw (i,k1) = cnvw_in(i,k)
enddo
enddo
endif

!mz HWRF physics: icloud=3
if(icloud == 3) then

Expand Down Expand Up @@ -1036,7 +1045,7 @@ subroutine GFS_rrtmg_pre_run (im, levs, lm, lmk, lmp, n_var_lndp, &
ntrac-1, ntcw-1,ntiw-1,ntrw-1, &
ntsw-1,ntgl-1, &
im, lmk, lmp, uni_cld, lmfshal, lmfdeep2, &
cldcov(:,1:LMK), effrl_inout(:,:), &
cldcov(:,1:LMK), cnvw, effrl_inout(:,:), &
effri_inout(:,:), effrs_inout(:,:), &
dzb, xlat_d, julian, yearlen, &
clouds, cldsa, mtopa ,mbota, de_lgth, alpha) ! --- outputs
Expand Down
12 changes: 6 additions & 6 deletions physics/module_mp_thompson.F90
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ MODULE module_mp_thompson
REAL, PARAMETER, PRIVATE:: fv_s = 100.0
REAL, PARAMETER, PRIVATE:: av_g = 442.0
REAL, PARAMETER, PRIVATE:: bv_g = 0.89
REAL, PARAMETER, PRIVATE:: av_i = 1847.5
REAL, PARAMETER, PRIVATE:: av_i = 1493.9
REAL, PARAMETER, PRIVATE:: bv_i = 1.0
REAL, PARAMETER, PRIVATE:: av_c = 0.316946E8
REAL, PARAMETER, PRIVATE:: bv_c = 2.0
Expand Down Expand Up @@ -214,8 +214,8 @@ MODULE module_mp_thompson
REAL, PARAMETER, PRIVATE:: xm0i = 1.E-12
REAL, PARAMETER, PRIVATE:: D0c = 1.E-6
REAL, PARAMETER, PRIVATE:: D0r = 50.E-6
REAL, PARAMETER, PRIVATE:: D0s = 200.E-6
REAL, PARAMETER, PRIVATE:: D0g = 250.E-6
REAL, PARAMETER, PRIVATE:: D0s = 300.E-6
REAL, PARAMETER, PRIVATE:: D0g = 350.E-6
REAL, PRIVATE:: D0i, xm0s, xm0g

!..Min and max radiative effective radius of cloud water, cloud ice, and snow;
Expand Down Expand Up @@ -890,7 +890,7 @@ SUBROUTINE thompson_init(is_aerosol_aware_in, &
!! between rain/snow and cloud water
if (mpirank==mpiroot) write(0,*) ' creating qc collision eff tables'
call table_Efrw
call table_Efsw
call table_Efsw

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

extra whitespace on the end of line

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed. Thanks.


!> - Call table_dropevap() to creat rain drop evaporation table
if (mpirank==mpiroot) write(0,*) ' creating rain evap table'
Expand Down Expand Up @@ -1908,12 +1908,12 @@ subroutine mp_thompson (qv1d, qc1d, qi1d, qr1d, qs1d, qg1d, ni1d, &

DOUBLE PRECISION, PARAMETER:: zeroD0 = 0.0d0
REAL, PARAMETER :: decfl = 8.0
REAL :: dtcfl,rainsfc
REAL :: dtcfl, rainsfc
INTEGER :: niter

REAL, DIMENSION(kts:kte):: temp, pres, qv
REAL, DIMENSION(kts:kte):: rc, ri, rr, rs, rg, ni, nr, nc, nwfa, nifa
REAL, DIMENSION(kts:kte):: rr_tmp,nr_tmp
REAL, DIMENSION(kts:kte):: rr_tmp, nr_tmp
REAL, DIMENSION(kts:kte):: rho, rhof, rhof2
REAL, DIMENSION(kts:kte):: qvs, qvsi, delQvs
REAL, DIMENSION(kts:kte):: satw, sati, ssatw, ssati
Expand Down
11 changes: 8 additions & 3 deletions physics/mp_thompson.F90
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,8 @@ subroutine mp_thompson_init(ncol, nlev, con_g, con_rd, con_eps, &
end if

! Call Thompson init
call thompson_init(is_aerosol_aware_in=is_aerosol_aware, mpicomm=mpicomm, &
call thompson_init(is_aerosol_aware_in=is_aerosol_aware, &

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ruiyu - I think you need to revert back these changes. They involve whitespace only and should not be a part of this PR as Dom suggested - unless I am mistaken on something.

mpicomm=mpicomm, &
mpirank=mpirank, mpiroot=mpiroot, threads=threads, &
errmsg=errmsg, errflg=errflg)
if (errflg /= 0) return
Expand Down Expand Up @@ -303,7 +304,8 @@ subroutine mp_thompson_run(ncol, nlev, con_g, con_rd, &
nwfa2d, nifa2d, &
tgrs, prsl, phii, omega, &
sedi_semi, sedi_semi_update, &
sedi_semi_decfl, dtp, dt_inner, &
sedi_semi_decfl, crt_sati, &
dtp, dt_inner, &
first_time_step, istep, nsteps, &
prcp, rain, graupel, ice, snow, sr, &
refl_10cm, reset_dBZ, do_radar_ref, &
Expand Down Expand Up @@ -361,6 +363,7 @@ subroutine mp_thompson_run(ncol, nlev, con_g, con_rd, &
logical, intent(in) :: sedi_semi
logical, intent(in) :: sedi_semi_update
logical, intent(in) :: sedi_semi_decfl
real, intent(in ) :: crt_sati

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

whitespace problem - look at neighboring lines

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

crt_sati namelist variable is removed from the code.

! MPI and block information
integer, intent(in) :: blkno
integer, intent(in) :: mpicomm
Expand Down Expand Up @@ -619,7 +622,8 @@ subroutine mp_thompson_run(ncol, nlev, con_g, con_rd, &
nc=nc, nwfa=nwfa, nifa=nifa, nwfa2d=nwfa2d, nifa2d=nifa2d, &
tt=tgrs, p=prsl, w=w, dz=dz, dt_in=dtstep, dt_inner=dt_inner, &
sedi_semi=sedi_semi, sedi_semi_update=sedi_semi_update, &
sedi_semi_decfl=sedi_semi_decfl, &
sedi_semi_decfl=sedi_semi_decfl, &

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another stray whitespace is on the end of this line. If you use Github, it can show you these mistakes so you can detect them and fix for quicker approval.

crt_sati=crt_sati, &
rainnc=rain_mp, rainncv=delta_rain_mp, &
snownc=snow_mp, snowncv=delta_snow_mp, &
icenc=ice_mp, icencv=delta_ice_mp, &
Expand Down Expand Up @@ -660,6 +664,7 @@ subroutine mp_thompson_run(ncol, nlev, con_g, con_rd, &
tt=tgrs, p=prsl, w=w, dz=dz, dt_in=dtstep, dt_inner=dt_inner, &
sedi_semi=sedi_semi, sedi_semi_update=sedi_semi_update, &
sedi_semi_decfl=sedi_semi_decfl, &
crt_sati=crt_sati, &
rainnc=rain_mp, rainncv=delta_rain_mp, &
snownc=snow_mp, snowncv=delta_snow_mp, &
icenc=ice_mp, icencv=delta_ice_mp, &
Expand Down
8 changes: 8 additions & 0 deletions physics/mp_thompson.meta
Original file line number Diff line number Diff line change
Expand Up @@ -488,6 +488,14 @@
dimensions = ()
type = logical
intent = in
[crt_sati]
standard_name = critical_over_saturation_for_ice_generation
long_name = critical over saturation for ice generation
units = none
dimensions = ()
type = real
intent = in
kind = kind_phys
[dtp]
standard_name = timestep_for_physics
long_name = physics timestep
Expand Down