SCALE-RM
Functions/Subroutines
mod_urban_phy_driver Module Reference

module URBAN / Physics Urban Canopy Model (UCM) More...

Functions/Subroutines

subroutine, public urban_phy_driver_setup
 Setup. More...
 
subroutine, public urban_phy_driver_resume
 Resume. More...
 
subroutine, public urban_phy_driver (update_flag)
 Driver. More...
 

Detailed Description

module URBAN / Physics Urban Canopy Model (UCM)

Description
Urban physics module
Author
Team SCALE
NAMELIST
  • No namelist group
History Output
namedescriptionunitvariable
URBAN_QC_t tendency of URBAN_QC kg/kg URBAN_QC_t
URBAN_RAINB_t tendency of URBAN_RAINB K URBAN_RAINB_t
URBAN_RAING_t tendency of URBAN_RAING K URBAN_RAING_t
URBAN_RAINR_t tendency of URBAN_RAINR K URBAN_RAINR_t
URBAN_ROFF_t tendency of URBAN_ROFF K URBAN_ROFF_t
URBAN_TBL_t tendency of URBAN_TBL K URBAN_TBL_t
URBAN_TB_t tendency of URBAN_TB K URBAN_TB_t
URBAN_TC_t tendency of URBAN_TC K URBAN_TC_t
URBAN_TGL_t tendency of URBAN_TGL K URBAN_TGL_t
URBAN_TG_t tendency of URBAN_TG K URBAN_TG_t
URBAN_TRL_t tendency of URBAN_TRL K URBAN_TRL_t
URBAN_TR_t tendency of URBAN_TR K URBAN_TR_t
URBAN_UC_t tendency of URBAN_UC m/s URBAN_UC_t

Function/Subroutine Documentation

◆ urban_phy_driver_setup()

subroutine, public mod_urban_phy_driver::urban_phy_driver_setup ( )

Setup.

Definition at line 52 of file mod_urban_phy_driver.f90.

References scale_stdio::io_fid_log, scale_stdio::io_l, scale_urban_phy::urban_phy_setup(), mod_urban_admin::urban_sw, mod_urban_admin::urban_type, mod_urban_vars::urban_z0e, mod_urban_vars::urban_z0h, and mod_urban_vars::urban_z0m.

Referenced by mod_urban_driver::urban_driver_setup().

52  use scale_urban_phy, only: &
54  use mod_urban_admin, only: &
55  urban_type, &
56  urban_sw
57  use mod_urban_vars, only: &
58  urban_z0m, &
59  urban_z0h, &
60  urban_z0e
61  implicit none
62  !---------------------------------------------------------------------------
63 
64  if( io_l ) write(io_fid_log,*)
65  if( io_l ) write(io_fid_log,*) '++++++ Module[DRIVER] / Categ[URBAN PHY] / Origin[SCALE-RM]'
66 
67  if ( urban_sw ) then
68 
69  ! setup library component
70  call urban_phy_setup( urban_type, & ! [IN]
71  urban_z0m(:,:), & ! [OUT]
72  urban_z0h(:,:), & ! [OUT]
73  urban_z0e(:,:) ) ! [OUT]
74 
75  else
76  if( io_l ) write(io_fid_log,*) '*** this component is never called.'
77  endif
78 
79  return
logical, public urban_sw
module URBAN / Physics
real(rp), dimension(:,:), allocatable, public urban_z0e
real(rp), dimension(:,:), allocatable, public urban_z0m
module URBAN Variables
real(rp), dimension(:,:), allocatable, public urban_z0h
character(len=h_short), public urban_type
subroutine, public urban_phy_setup(URBAN_TYPE, Z0M, Z0H, Z0E)
module Urban admin
Here is the call graph for this function:
Here is the caller graph for this function:

◆ urban_phy_driver_resume()

subroutine, public mod_urban_phy_driver::urban_phy_driver_resume ( )

Resume.

Definition at line 85 of file mod_urban_phy_driver.f90.

References scale_prof::prof_rapend(), scale_prof::prof_rapstart(), mod_admin_restart::restart_run, urban_phy_driver(), and mod_urban_admin::urban_sw.

Referenced by mod_urban_driver::urban_driver_resume().

85  use mod_admin_restart, only: &
87  use mod_urban_admin, only: &
88  urban_sw
89  implicit none
90 
91  if ( urban_sw ) then
92 
93  if ( .NOT. restart_run ) then ! tentative
94  ! run once (only for the diagnostic value)
95  call prof_rapstart('URB_Physics', 1)
96  call urban_phy_driver( update_flag = .true. )
97  call prof_rapend ('URB_Physics', 1)
98  end if
99 
100  end if
101 
102  return
logical, public urban_sw
subroutine, public urban_phy_driver(update_flag)
Driver.
module administrator for restart
logical, public restart_run
Is this run restart?
module Urban admin
Here is the call graph for this function:
Here is the caller graph for this function:

◆ urban_phy_driver()

subroutine, public mod_urban_phy_driver::urban_phy_driver ( logical, intent(in)  update_flag)

Driver.

Definition at line 107 of file mod_urban_phy_driver.f90.

References mod_urban_vars::atmos_dens, mod_urban_vars::atmos_pbl, mod_urban_vars::atmos_pres, mod_urban_vars::atmos_qv, mod_urban_vars::atmos_sfc_pres, mod_urban_vars::atmos_sflx_lw, mod_urban_vars::atmos_sflx_prec, mod_urban_vars::atmos_sflx_sw, mod_urban_vars::atmos_temp, mod_urban_vars::atmos_u, mod_urban_vars::atmos_v, mod_urban_vars::atmos_w, scale_grid_index::ie, scale_grid_index::is, scale_grid_index::je, scale_grid_index::js, scale_mapproj::mprj_basepoint_lat, scale_mapproj::mprj_basepoint_lon, scale_grid_real::real_z1, scale_rm_statistics::statistics_checktotal, scale_time::time_dtsec_urban, scale_time::time_nowdate, scale_urban_grid_index::uke, scale_urban_grid_index::uks, scale_urban_phy::urban_phy, mod_urban_vars::urban_q2, mod_urban_vars::urban_qc, mod_urban_vars::urban_qc_t, mod_urban_vars::urban_rainb, mod_urban_vars::urban_rainb_t, mod_urban_vars::urban_raing, mod_urban_vars::urban_raing_t, mod_urban_vars::urban_rainr, mod_urban_vars::urban_rainr_t, mod_urban_vars::urban_roff, mod_urban_vars::urban_roff_t, mod_urban_vars::urban_sfc_albedo, mod_urban_vars::urban_sfc_temp, mod_urban_vars::urban_sflx_evap, mod_urban_vars::urban_sflx_gh, mod_urban_vars::urban_sflx_lh, mod_urban_vars::urban_sflx_mu, mod_urban_vars::urban_sflx_mv, mod_urban_vars::urban_sflx_mw, mod_urban_vars::urban_sflx_sh, mod_urban_vars::urban_t2, mod_urban_vars::urban_tb, mod_urban_vars::urban_tb_t, mod_urban_vars::urban_tbl, mod_urban_vars::urban_tbl_t, mod_urban_vars::urban_tc, mod_urban_vars::urban_tc_t, mod_urban_vars::urban_tg, mod_urban_vars::urban_tg_t, mod_urban_vars::urban_tgl, mod_urban_vars::urban_tgl_t, mod_urban_vars::urban_tr, mod_urban_vars::urban_tr_t, mod_urban_vars::urban_trl, mod_urban_vars::urban_trl_t, mod_urban_vars::urban_u10, mod_urban_vars::urban_uc, mod_urban_vars::urban_uc_t, mod_urban_vars::urban_v10, mod_urban_vars::urban_z0e, mod_urban_vars::urban_z0h, and mod_urban_vars::urban_z0m.

Referenced by mod_urban_driver::urban_driver(), and urban_phy_driver_resume().

107  use scale_atmos_hydrometeor, only: &
108  hydrometeor_lhv => atmos_hydrometeor_lhv
109  use scale_time, only: &
110  nowdate => time_nowdate, &
111  dt => time_dtsec_urban
112  use scale_rm_statistics, only: &
114  stat_total
115  use scale_history, only: &
116  hist_in
117  use scale_mapproj, only: &
118  base_lon => mprj_basepoint_lon, &
119  base_lat => mprj_basepoint_lat
120  use scale_grid_real, only: &
121  real_z1
122  use scale_urban_phy, only: &
123  urban_phy
124  use mod_urban_vars, only: &
125  urban_tr, &
126  urban_tb, &
127  urban_tg, &
128  urban_tc, &
129  urban_qc, &
130  urban_uc, &
131  urban_trl, &
132  urban_tbl, &
133  urban_tgl, &
134  urban_rainr, &
135  urban_rainb, &
136  urban_raing, &
137  urban_roff, &
138  urban_tr_t, &
139  urban_tb_t, &
140  urban_tg_t, &
141  urban_tc_t, &
142  urban_qc_t, &
143  urban_uc_t, &
144  urban_trl_t, &
145  urban_tbl_t, &
146  urban_tgl_t, &
147  urban_rainr_t, &
148  urban_rainb_t, &
149  urban_raing_t, &
150  urban_roff_t, &
151  urban_sfc_temp, &
153  urban_sflx_mw, &
154  urban_sflx_mu, &
155  urban_sflx_mv, &
156  urban_sflx_sh, &
157  urban_sflx_lh, &
158  urban_sflx_gh, &
159  urban_sflx_evap, &
160  urban_z0m, &
161  urban_z0h, &
162  urban_z0e, &
163  urban_u10, &
164  urban_v10, &
165  urban_t2, &
166  urban_q2, &
167  atmos_temp, &
168  atmos_pres, &
169  atmos_w, &
170  atmos_u, &
171  atmos_v, &
172  atmos_dens, &
173  atmos_qv, &
174  atmos_pbl, &
175  atmos_sfc_pres, &
176  atmos_sflx_lw, &
177  atmos_sflx_sw, &
179  implicit none
180 
181  ! arguments
182  logical, intent(in) :: update_flag
183 
184  ! works
185  real(RP) :: LHV(IA,JA) ! latent heat of vaporization [J/kg]
186  real(RP) :: total ! dummy
187 
188  character(len=2) :: sk
189 
190  integer :: k, i, j
191  !---------------------------------------------------------------------------
192 
193  if ( update_flag ) then
194 
195  call urban_phy( urban_tr_t(:,:), & ! [OUT]
196  urban_tb_t(:,:), & ! [OUT]
197  urban_tg_t(:,:), & ! [OUT]
198  urban_tc_t(:,:), & ! [OUT]
199  urban_qc_t(:,:), & ! [OUT]
200  urban_uc_t(:,:), & ! [OUT]
201  urban_trl_t(:,:,:), & ! [OUT]
202  urban_tbl_t(:,:,:), & ! [OUT]
203  urban_tgl_t(:,:,:), & ! [OUT]
204  urban_rainr_t(:,:), & ! [OUT]
205  urban_rainb_t(:,:), & ! [OUT]
206  urban_raing_t(:,:), & ! [OUT]
207  urban_roff_t(:,:), & ! [OUT]
208  urban_sfc_temp(:,:), & ! [OUT]
209  urban_sfc_albedo(:,:,i_lw), & ! [OUT]
210  urban_sfc_albedo(:,:,i_sw), & ! [OUT]
211  urban_sflx_mw(:,:), & ! [OUT]
212  urban_sflx_mu(:,:), & ! [OUT]
213  urban_sflx_mv(:,:), & ! [OUT]
214  urban_sflx_sh(:,:), & ! [OUT]
215  urban_sflx_lh(:,:), & ! [OUT]
216  urban_sflx_gh(:,:), & ! [OUT]
217  urban_z0m(:,:), & ! [OUT]
218  urban_z0h(:,:), & ! [OUT]
219  urban_z0e(:,:), & ! [OUT]
220  urban_u10(:,:), & ! [OUT]
221  urban_v10(:,:), & ! [OUT]
222  urban_t2(:,:), & ! [OUT]
223  urban_q2(:,:), & ! [OUT]
224  atmos_temp(:,:), & ! [IN]
225  atmos_pres(:,:), & ! [IN]
226  atmos_w(:,:), & ! [IN]
227  atmos_u(:,:), & ! [IN]
228  atmos_v(:,:), & ! [IN]
229  atmos_dens(:,:), & ! [IN]
230  atmos_qv(:,:), & ! [IN]
231  real_z1(:,:), & ! [IN]
232  atmos_pbl(:,:), & ! [IN]
233  atmos_sfc_pres(:,:), & ! [IN]
234  atmos_sflx_lw(:,:,:), & ! [IN]
235  atmos_sflx_sw(:,:,:), & ! [IN]
236  atmos_sflx_prec(:,:), & ! [IN]
237  urban_tr(:,:), & ! [IN]
238  urban_tb(:,:), & ! [IN]
239  urban_tg(:,:), & ! [IN]
240  urban_tc(:,:), & ! [IN]
241  urban_qc(:,:), & ! [IN]
242  urban_uc(:,:), & ! [IN]
243  urban_trl(:,:,:), & ! [IN]
244  urban_tbl(:,:,:), & ! [IN]
245  urban_tgl(:,:,:), & ! [IN]
246  urban_rainr(:,:), & ! [IN]
247  urban_rainb(:,:), & ! [IN]
248  urban_raing(:,:), & ! [IN]
249  urban_roff(:,:), & ! [IN]
250  base_lon, & ! [IN]
251  base_lat, & ! [IN]
252  nowdate(:), & ! [IN]
253  dt ) ! [IN]
254 
255  call hydrometeor_lhv( lhv(:,:), atmos_temp(:,:) )
256 
257 !OCL XFILL
258  do j = js, je
259  do i = is, ie
260  urban_sflx_evap(i,j) = urban_sflx_lh(i,j) / lhv(i,j)
261  end do
262  end do
263 
264  call hist_in( urban_tr_t(:,:), 'URBAN_TR_t', 'tendency of URBAN_TR', 'K' )
265  call hist_in( urban_tb_t(:,:), 'URBAN_TB_t', 'tendency of URBAN_TB', 'K' )
266  call hist_in( urban_tg_t(:,:), 'URBAN_TG_t', 'tendency of URBAN_TG', 'K' )
267  call hist_in( urban_tc_t(:,:), 'URBAN_TC_t', 'tendency of URBAN_TC', 'K' )
268  call hist_in( urban_qc_t(:,:), 'URBAN_QC_t', 'tendency of URBAN_QC', 'kg/kg' )
269  call hist_in( urban_uc_t(:,:), 'URBAN_UC_t', 'tendency of URBAN_UC', 'm/s' )
270 
271  call hist_in( urban_trl_t(:,:,:), 'URBAN_TRL_t', 'tendency of URBAN_TRL', 'K', zdim='urban' )
272  call hist_in( urban_tbl_t(:,:,:), 'URBAN_TBL_t', 'tendency of URBAN_TBL', 'K', zdim='urban' )
273  call hist_in( urban_tgl_t(:,:,:), 'URBAN_TGL_t', 'tendency of URBAN_TGL', 'K', zdim='urban' )
274 
275  call hist_in( urban_rainr_t(:,:), 'URBAN_RAINR_t', 'tendency of URBAN_RAINR', 'K' )
276  call hist_in( urban_rainb_t(:,:), 'URBAN_RAINB_t', 'tendency of URBAN_RAINB', 'K' )
277  call hist_in( urban_raing_t(:,:), 'URBAN_RAING_t', 'tendency of URBAN_RAING', 'K' )
278  call hist_in( urban_roff_t(:,:), 'URBAN_ROFF_t', 'tendency of URBAN_ROFF', 'K' )
279 
280  endif
281 
282  if ( statistics_checktotal ) then
283  call stat_total( total, urban_tr_t(:,:), 'URBAN_TR_t' )
284  call stat_total( total, urban_tb_t(:,:), 'URBAN_TB_t' )
285  call stat_total( total, urban_tg_t(:,:), 'URBAN_TG_t' )
286  call stat_total( total, urban_tc_t(:,:), 'URBAN_TC_t' )
287  call stat_total( total, urban_qc_t(:,:), 'URBAN_QC_t' )
288  call stat_total( total, urban_uc_t(:,:), 'URBAN_UC_t' )
289 
290  do k = uks, uke
291  write(sk,'(I2.2)') k
292 
293  call stat_total( total, urban_trl_t(k,:,:), 'URBAN_TRL_t'//sk )
294  call stat_total( total, urban_tbl_t(k,:,:), 'URBAN_TBL_t'//sk )
295  call stat_total( total, urban_tgl_t(k,:,:), 'URBAN_TGL_t'//sk )
296  enddo
297 
298  call stat_total( total, urban_rainr_t(:,:), 'URBAN_RAINR_t' )
299  call stat_total( total, urban_rainb_t(:,:), 'URBAN_RAINB_t' )
300  call stat_total( total, urban_raing_t(:,:), 'URBAN_RAING_t' )
301  call stat_total( total, urban_roff_t(:,:), 'URBAN_ROFF_t' )
302  endif
303 
304  return
real(rp), dimension(:,:), allocatable, public urban_qc_t
logical, public statistics_checktotal
calc&report variable totals to logfile?
real(rp), dimension(:,:), allocatable, public urban_qc
real(rp), dimension(:,:), allocatable, public urban_rainr_t
real(rp), dimension(:,:,:), allocatable, public urban_trl_t
real(rp), public mprj_basepoint_lat
real(rp), dimension(:,:), allocatable, public urban_tg_t
real(rp), dimension(:,:), allocatable, public urban_u10
module URBAN / Physics
real(rp), dimension(:,:), allocatable, public urban_v10
real(rp), dimension(:,:), allocatable, public urban_raing_t
real(rp), dimension(:,:), allocatable, public urban_z0e
real(rp), dimension(:,:), allocatable, public urban_sflx_mu
real(rp), dimension(:,:), allocatable, public urban_sflx_evap
real(rp), dimension(:,:), allocatable, public urban_z0m
real(rp), dimension(:,:), allocatable, public urban_tb_t
real(rp), dimension(:,:), allocatable, public urban_t2
real(rp), dimension(:,:), allocatable, public urban_tb
module URBAN Variables
real(rp), dimension(:,:), allocatable, public urban_raing
real(rp), public mprj_basepoint_lon
procedure(urb), pointer, public urban_phy
real(rp), dimension(:,:), allocatable, public urban_uc
real(rp), dimension(:,:), allocatable, public atmos_sflx_prec
integer, parameter, public i_lw
module Statistics
integer, parameter, public i_sw
real(rp), dimension(:,:), allocatable, public atmos_pbl
real(rp), dimension(:,:), allocatable, public urban_sflx_sh
real(rp), dimension(:,:), allocatable, public urban_tr
real(rp), dimension(:,:,:), allocatable, public urban_tgl
real(rp), dimension(:,:), allocatable, public real_z1
Height of the lowermost grid from surface (cell center) [m].
module GRID (real space)
real(rp), dimension(:,:), allocatable, public atmos_qv
real(rp), dimension(:,:), allocatable, public atmos_sfc_pres
real(rp), dimension(:,:), allocatable, public urban_uc_t
real(rp), dimension(:,:), allocatable, public urban_z0h
real(rp), dimension(:,:,:), allocatable, public atmos_sflx_sw
real(rp), dimension(:,:), allocatable, public atmos_v
module TIME
Definition: scale_time.F90:15
real(rp), dimension(:,:), allocatable, public urban_roff
real(rp), dimension(:,:), allocatable, public atmos_dens
real(rp), dimension(:,:,:), allocatable, public urban_sfc_albedo
real(rp), dimension(:,:), allocatable, public urban_sflx_lh
real(rp), dimension(:,:), allocatable, public urban_tc
real(rp), dimension(:,:), allocatable, public atmos_pres
real(rp), dimension(:,:), allocatable, public urban_rainr
real(rp), dimension(:,:), allocatable, public atmos_temp
module HISTORY
real(rp), dimension(:,:), allocatable, public urban_q2
real(rp), dimension(:,:), allocatable, public urban_tg
real(rp), dimension(:,:), allocatable, public atmos_u
real(rp), dimension(:,:), allocatable, public urban_sfc_temp
integer, dimension(6), public time_nowdate
current time [YYYY MM DD HH MM SS]
Definition: scale_time.F90:65
real(rp), dimension(:,:,:), allocatable, public urban_trl
real(rp), dimension(:,:), allocatable, public urban_rainb_t
real(rp), dimension(:,:,:), allocatable, public atmos_sflx_lw
real(rp), dimension(:,:,:), allocatable, public urban_tbl
real(dp), public time_dtsec_urban
time interval of urban step [sec]
Definition: scale_time.F90:49
real(rp), dimension(:,:), allocatable, public urban_tr_t
real(rp), dimension(:,:,:), allocatable, public urban_tgl_t
real(rp), dimension(:,:), allocatable, public urban_sflx_gh
real(rp), dimension(:,:), allocatable, public urban_sflx_mv
real(rp), dimension(:,:), allocatable, public atmos_w
real(rp), dimension(:,:), allocatable, public urban_rainb
real(rp), dimension(:,:), allocatable, public urban_tc_t
real(rp), dimension(:,:), allocatable, public urban_roff_t
real(rp), dimension(:,:,:), allocatable, public urban_tbl_t
real(rp), dimension(:,:), allocatable, public urban_sflx_mw
module Map projection
Here is the caller graph for this function: