@@ -98,8 +98,8 @@ end subroutine GFS_rrtmgp_pre_init
98
98
! !
99
99
subroutine GFS_rrtmgp_pre_run (nCol , nLev , nTracers , i_o3 , lsswr , lslwr , fhswr , fhlwr , &
100
100
xlat , xlon , prsl , tgrs , prslk , prsi , qgrs , tsfc , con_eps , con_epsm1 , con_fvirt , &
101
- con_epsqs , minGPpres , minGPtemp , raddt , p_lay , t_lay , p_lev , t_lev , tsfg , tsfa , &
102
- qs_lay , q_lay , tv_lay , relhum , tracer , gas_concentrations , errmsg , errflg )
101
+ con_epsqs , minGPpres , minGPtemp , maxGPtemp , raddt , p_lay , t_lay , p_lev , t_lev , tsfg , &
102
+ tsfa , qs_lay , q_lay , tv_lay , relhum , tracer , gas_concentrations , errmsg , errflg )
103
103
104
104
! Inputs
105
105
integer , intent (in ) :: &
@@ -112,6 +112,7 @@ subroutine GFS_rrtmgp_pre_run(nCol, nLev, nTracers, i_o3, lsswr, lslwr, fhswr, f
112
112
lslwr ! Call LW radiation
113
113
real (kind_phys), intent (in ) :: &
114
114
minGPtemp, & ! Minimum temperature allowed in RRTMGP.
115
+ maxGPtemp, & ! Maximum temperature allowed in RRTMGP.
115
116
minGPpres, & ! Minimum pressure allowed in RRTMGP.
116
117
fhswr, & ! Frequency of SW radiation call.
117
118
fhlwr ! Frequency of LW radiation call.
@@ -208,11 +209,14 @@ subroutine GFS_rrtmgp_pre_run(nCol, nLev, nTracers, i_o3, lsswr, lslwr, fhswr, f
208
209
if (t_lay(iCol,iLay) .le. minGPtemp) then
209
210
t_lay(iCol,iLay) = minGPtemp + epsilon (minGPtemp)
210
211
endif
212
+ if (t_lay(iCol,iLay) .ge. maxGPtemp) then
213
+ t_lay(iCol,iLay) = maxGPtemp - epsilon (maxGPtemp)
214
+ endif
211
215
enddo
212
216
enddo
213
217
214
218
! Temperature at layer-interfaces
215
- call cmp_tlev(nCol,nLev,minGPpres,p_lay,t_lay,p_lev,tsfc,t_lev)
219
+ call cmp_tlev(nCol,nLev,minGPpres,minGPtemp,maxGPtemp, p_lay,t_lay,p_lev,tsfc,t_lev)
216
220
217
221
! Compute a bunch of thermodynamic fields needed by the cloud microphysics schemes.
218
222
! Relative humidity, saturation mixing-ratio, vapor mixing-ratio, virtual temperature,
@@ -273,7 +277,7 @@ subroutine GFS_rrtmgp_pre_run(nCol, nLev, nTracers, i_o3, lsswr, lslwr, fhswr, f
273
277
! #######################################################################################
274
278
! Setup surface ground temperature and ground/air skin temperature if required.
275
279
! #######################################################################################
276
- tsfg(1 :NCOL) = tsfc (1 :NCOL)
280
+ tsfg(1 :NCOL) = t_lev (1 :NCOL,iSFC )
277
281
tsfa(1 :NCOL) = t_lay(1 :NCOL,iSFC)
278
282
279
283
end subroutine GFS_rrtmgp_pre_run
0 commit comments