/wrfv2_fire/phys/module_sf_bep.F
FORTRAN Legacy | 3239 lines | 1873 code | 634 blank | 732 comment | 38 complexity | 0c3989f4b2ba6aaa590bea8e69427a24 MD5 | raw file
Possible License(s): AGPL-1.0
Large files files are truncated, but you can click here to view the full file
- MODULE module_sf_bep
- !USE module_model_constants
- USE module_sf_urban
- ! SGClarke 09/11/2008
- ! Access urban_param.tbl values through calling urban_param_init in module_physics_init
- ! for CASE (BEPSCHEME) select sf_urban_physics
- !
- ! -----------------------------------------------------------------------
- ! Dimension for the array used in the BEP module
- ! -----------------------------------------------------------------------
- integer nurbm ! Maximum number of urban classes
- parameter (nurbm=3)
- integer ndm ! Maximum number of street directions
- parameter (ndm=2)
- integer nz_um ! Maximum number of vertical levels in the urban grid
- parameter(nz_um=13)
- integer ng_u ! Number of grid levels in the ground
- parameter (ng_u=10)
- integer nwr_u ! Number of grid levels in the walls or roofs
- parameter (nwr_u=10)
- real dz_u ! Urban grid resolution
- parameter (dz_u=5.)
- ! The change of ng_u, nwr_u should be done in agreement with the block data
- ! in the routine "surf_temp"
- ! -----------------------------------------------------------------------
- ! Constant used in the BEP module
- ! -----------------------------------------------------------------------
-
- real vk ! von Karman constant
- real g_u ! Gravity acceleration
- real pi !
- real r ! Perfect gas constant
- real cp_u ! Specific heat at constant pressure
- real rcp_u !
- real sigma !
- real p0 ! Reference pressure at the sea level
- real cdrag ! Drag force constant
- parameter(vk=0.40,g_u=9.81,pi=3.141592653,r=287.,cp_u=1004.)
- parameter(rcp_u=r/cp_u,sigma=5.67e-08,p0=1.e+5,cdrag=0.4)
- ! -----------------------------------------------------------------------
- CONTAINS
-
- subroutine BEP(FRC_URB2D,UTYPE_URB2D,itimestep,dz8w,dt,u_phy,v_phy, &
- th_phy,rho,p_phy,swdown,glw, &
- gmt,julday,xlong,xlat, &
- declin_urb,cosz_urb2d,omg_urb2d, &
- num_urban_layers, &
- trb_urb4d,tw1_urb4d,tw2_urb4d,tgb_urb4d, &
- sfw1_urb3d,sfw2_urb3d,sfr_urb3d,sfg_urb3d, &
- a_u,a_v,a_t,a_e,b_u,b_v, &
- b_t,b_e,dlg,dl_u,sf,vl, &
- rl_up,rs_abs,emiss,grdflx_urb, &
- ids,ide, jds,jde, kds,kde, &
- ims,ime, jms,jme, kms,kme, &
- its,ite, jts,jte, kts,kte)
- implicit none
- !------------------------------------------------------------------------
- ! Input
- !------------------------------------------------------------------------
- INTEGER :: ids,ide, jds,jde, kds,kde, &
- ims,ime, jms,jme, kms,kme, &
- its,ite, jts,jte, kts,kte, &
- itimestep
-
- REAL, DIMENSION( ims:ime, kms:kme, jms:jme ):: DZ8W
- REAL, DIMENSION( ims:ime, kms:kme, jms:jme ):: P_PHY
- REAL, DIMENSION( ims:ime, kms:kme, jms:jme ):: RHO
- REAL, DIMENSION( ims:ime, kms:kme, jms:jme ):: TH_PHY
- REAL, DIMENSION( ims:ime, kms:kme, jms:jme ):: T_PHY
- REAL, DIMENSION( ims:ime, kms:kme, jms:jme ):: U_PHY
- REAL, DIMENSION( ims:ime, kms:kme, jms:jme ):: V_PHY
- REAL, DIMENSION( ims:ime, kms:kme, jms:jme ):: U
- REAL, DIMENSION( ims:ime, kms:kme, jms:jme ):: V
- REAL, DIMENSION( ims:ime , jms:jme ) :: GLW
- REAL, DIMENSION( ims:ime , jms:jme ) :: swdown
- REAL, DIMENSION( ims:ime, jms:jme ) :: UST
- INTEGER, DIMENSION( ims:ime , jms:jme ), INTENT(IN ):: UTYPE_URB2D
- REAL, DIMENSION( ims:ime , jms:jme ), INTENT(IN ):: FRC_URB2D
- REAL, INTENT(IN ) :: GMT
- INTEGER, INTENT(IN ) :: JULDAY
- REAL, DIMENSION( ims:ime, jms:jme ), &
- INTENT(IN ) :: XLAT, XLONG
- REAL, INTENT(IN) :: DECLIN_URB
- REAL, DIMENSION( ims:ime, jms:jme ), INTENT(IN) :: COSZ_URB2D
- REAL, DIMENSION( ims:ime, jms:jme ), INTENT(IN) :: OMG_URB2D
- INTEGER, INTENT(IN ) :: num_urban_layers
- REAL, DIMENSION( ims:ime, 1:num_urban_layers, jms:jme ), INTENT(INOUT) :: trb_urb4d
- REAL, DIMENSION( ims:ime, 1:num_urban_layers, jms:jme ), INTENT(INOUT) :: tw1_urb4d
- REAL, DIMENSION( ims:ime, 1:num_urban_layers, jms:jme ), INTENT(INOUT) :: tw2_urb4d
- REAL, DIMENSION( ims:ime, 1:num_urban_layers, jms:jme ), INTENT(INOUT) :: tgb_urb4d
- REAL, DIMENSION( ims:ime, 1:num_urban_layers, jms:jme ), INTENT(INOUT) :: sfw1_urb3d
- REAL, DIMENSION( ims:ime, 1:num_urban_layers, jms:jme ), INTENT(INOUT) :: sfw2_urb3d
- REAL, DIMENSION( ims:ime, 1:num_urban_layers, jms:jme ), INTENT(INOUT) :: sfr_urb3d
- REAL, DIMENSION( ims:ime, 1:num_urban_layers, jms:jme ), INTENT(INOUT) :: sfg_urb3d
- ! integer nx,ny,nz ! Number of points in the mesocsale grid
- real z(ims:ime,kms:kme,jms:jme) ! Vertical coordinates
- REAL, INTENT(IN ):: DT ! Time step
- ! real zr(ims:ime,jms:jme) ! Solar zenith angle
- ! real deltar(ims:ime,jms:jme) ! Declination of the sun
- ! real ah(ims:ime,jms:jme) ! Hour angle
- ! real rs(ims:ime,jms:jme) ! Solar radiation
- !------------------------------------------------------------------------
- ! Output
- !------------------------------------------------------------------------
- ! real tsk(ims:ime,jms:jme) ! Average of surface temperatures (roads and roofs)
- !
- ! Implicit and explicit components of the source and sink terms at each levels,
- ! the fluxes can be computed as follow: FX = A*X + B example: t_fluxes = a_t * pt + b_t
- real a_u(ims:ime,kms:kme,jms:jme) ! Implicit component for the momemtum in X-direction (center)
- real a_v(ims:ime,kms:kme,jms:jme) ! Implicit component for the momemtum in Y-direction (center)
- real a_t(ims:ime,kms:kme,jms:jme) ! Implicit component for the temperature
- real a_e(ims:ime,kms:kme,jms:jme) ! Implicit component for the TKE
- real b_u(ims:ime,kms:kme,jms:jme) ! Explicit component for the momemtum in X-direction (center)
- real b_v(ims:ime,kms:kme,jms:jme) ! Explicit component for the momemtum in Y-direction (center)
- real b_t(ims:ime,kms:kme,jms:jme) ! Explicit component for the temperature
- real b_e(ims:ime,kms:kme,jms:jme) ! Explicit component for the TKE
- real dlg(ims:ime,kms:kme,jms:jme) ! Height above ground (L_ground in formula (24) of the BLM paper).
- real dl_u(ims:ime,kms:kme,jms:jme) ! Length scale (lb in formula (22) ofthe BLM paper).
- ! urban surface and volumes
- real sf(ims:ime,kms:kme,jms:jme) ! surface of the urban grid cells
- real vl(ims:ime,kms:kme,jms:jme) ! volume of the urban grid cells
- ! urban fluxes
- real rl_up(ims:ime,jms:jme) ! upward long wave radiation
- real rs_abs(ims:ime,jms:jme) ! absorbed short wave radiation
- real emiss(ims:ime,jms:jme) ! emissivity averaged for urban surfaces
- real grdflx_urb(ims:ime,jms:jme) ! ground heat flux for urban areas
- !------------------------------------------------------------------------
- ! Local
- !------------------------------------------------------------------------
- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
- ! Building parameters
- real alag_u(nurbm) ! Ground thermal diffusivity [m^2 s^-1]
- real alaw_u(nurbm) ! Wall thermal diffusivity [m^2 s^-1]
- real alar_u(nurbm) ! Roof thermal diffusivity [m^2 s^-1]
- real csg_u(nurbm) ! Specific heat of the ground material [J m^3 K^-1]
- real csw_u(nurbm) ! Specific heat of the wall material [J m^3 K^-1]
- real csr_u(nurbm) ! Specific heat of the roof material [J m^3 K^-1]
- real twini_u(nurbm) ! Initial temperature inside the building's wall [K]
- real trini_u(nurbm) ! Initial temperature inside the building's roof [K]
- real tgini_u(nurbm) ! Initial road temperature
- !
- ! for twini_u, and trini_u the initial value at the deepest level is kept constant during the simulation
- !
- ! Radiation paramters
- real albg_u(nurbm) ! Albedo of the ground
- real albw_u(nurbm) ! Albedo of the wall
- real albr_u(nurbm) ! Albedo of the roof
- real emg_u(nurbm) ! Emissivity of ground
- real emw_u(nurbm) ! Emissivity of wall
- real emr_u(nurbm) ! Emissivity of roof
- ! fww,fwg,fgw,fsw,fsg are the view factors used to compute the long wave
- ! and the short wave radation.
- real fww(nz_um,nz_um,ndm,nurbm) ! from wall to wall
- real fwg(nz_um,ndm,nurbm) ! from wall to ground
- real fgw(nz_um,ndm,nurbm) ! from ground to wall
- real fsw(nz_um,ndm,nurbm) ! from sky to wall
- real fws(nz_um,ndm,nurbm) ! from sky to wall
- real fsg(ndm,nurbm) ! from sky to ground
- ! Roughness parameters
- real z0g_u(nurbm) ! The ground's roughness length
- real z0r_u(nurbm) ! The roof's roughness length
- ! Street parameters
- integer nd_u(nurbm) ! Number of street direction for each urban class
- real strd_u(ndm,nurbm) ! Street length (fix to greater value to the horizontal length of the cells)
- real drst_u(ndm,nurbm) ! Street direction
- real ws_u(ndm,nurbm) ! Street width
- real bs_u(ndm,nurbm) ! Building width
- real h_b(nz_um,nurbm) ! Bulding's heights
- real d_b(nz_um,nurbm) ! Probability that a building has an height h_b
- real ss_u(nz_um,nurbm) ! Probability that a building has an height equal to z
- real pb_u(nz_um,nurbm) ! Probability that a building has an height greater or equal to z
- ! Grid parameters
- integer nz_u(nurbm) ! Number of layer in the urban grid
-
- real z_u(nz_um) ! Height of the urban grid levels
- ! 1D array used for the input and output of the routine "urban"
- real z1D(kms:kme) ! vertical coordinates
- real ua1D(kms:kme) ! wind speed in the x directions
- real va1D(kms:kme) ! wind speed in the y directions
- real pt1D(kms:kme) ! potential temperature
- real da1D(kms:kme) ! air density
- real pr1D(kms:kme) ! air pressure
- real pt01D(kms:kme) ! reference potential temperature
- real zr1D ! zenith angle
- real deltar1D ! declination of the sun
- real ah1D ! hour angle (it should come from the radiation routine)
- real rs1D ! solar radiation
- real rld1D ! downward flux of the longwave radiation
- real tw1D(2*ndm,nz_um,nwr_u) ! temperature in each layer of the wall
- real tg1D(ndm,ng_u) ! temperature in each layer of the ground
- real tr1D(ndm,nz_um,nwr_u) ! temperature in each layer of the roof
- real sfw1D(2*ndm,nz_um) ! sensible heat flux from walls
- real sfg1D(ndm) ! sensible heat flux from ground (road)
- real sfr1D(ndm,nz_um) ! sensible heat flux from roofs
- real sf1D(kms:kme) ! surface of the urban grid cells
- real vl1D(kms:kme) ! volume of the urban grid cells
- real a_u1D(kms:kme) ! Implicit component of the momentum sources or sinks in the X-direction
- real a_v1D(kms:kme) ! Implicit component of the momentum sources or sinks in the Y-direction
- real a_t1D(kms:kme) ! Implicit component of the heat sources or sinks
- real a_e1D(kms:kme) ! Implicit component of the TKE sources or sinks
- real b_u1D(kms:kme) ! Explicit component of the momentum sources or sinks in the X-direction
- real b_v1D(kms:kme) ! Explicit component of the momentum sources or sinks in the Y-direction
- real b_t1D(kms:kme) ! Explicit component of the heat sources or sinks
- real b_e1D(kms:kme) ! Explicit component of the TKE sources or sinks
- real dlg1D(kms:kme) ! Height above ground (L_ground in formula (24) of the BLM paper).
- real dl_u1D(kms:kme) ! Length scale (lb in formula (22) ofthe BLM paper)
- real tsk1D ! Average of the road surface temperatures
- real time_bep
- ! arrays used to collapse indexes
- integer ind_zwd(nz_um,nwr_u,ndm)
- integer ind_gd(ng_u,ndm)
- integer ind_zd(nz_um,ndm)
- !
- integer ix,iy,iz,iurb,id,iz_u,iw,ig,ir,ix1,iy1,k
- integer it, nint
- integer iii
- real time_h,tempo,shtot
- logical first
- character(len=80) :: text
- data first/.true./
- save first,time_bep
- save alag_u,alaw_u,alar_u,csg_u,csw_u,csr_u, &
- albg_u,albw_u,albr_u,emg_u,emw_u,emr_u,fww,fwg,fgw,fsw,fws,fsg, &
- z0g_u,z0r_u, nd_u,strd_u,drst_u,ws_u,bs_u,h_b,d_b,ss_u,pb_u, &
- nz_u,z_u
- !------------------------------------------------------------------------
- ! Calculation of the momentum, heat and turbulent kinetic fluxes
- ! produced by buildings
- !
- ! Reference:
- ! Martilli, A., Clappier, A., Rotach, M.W.:2002, 'AN URBAN SURFACE EXCHANGE
- ! PARAMETERISATION FOR MESOSCALE MODELS', Boundary-Layer Meteorolgy 104:
- ! 261-304
- !------------------------------------------------------------------------
- !prepare the arrays to collapse indexes
- if(num_urban_layers.lt.nz_um*ndm*nwr_u)then
- write(*,*)'num_urban_layers too small, please increase to at least ', nz_um*ndm*nwr_u
- stop
- endif
- iii=0
- do iz_u=1,nz_um
- do iw=1,nwr_u
- do id=1,ndm
- iii=iii+1
- ind_zwd(iz_u,iw,id)=iii
- enddo
- enddo
- enddo
- iii=0
- do ig=1,ng_u
- do id=1,ndm
- iii=iii+1
- ind_gd(ig,id)=iii
- enddo
- enddo
- iii=0
- do iz_u=1,nz_um
- do id=1,ndm
- iii=iii+1
- ind_zd(iz_u,id)=iii
- enddo
- enddo
- do ix=its,ite
- do iy=jts,jte
- z(ix,kts,iy)=0.
- do iz=kts+1,kte+1
- z(ix,iz,iy)=z(ix,iz-1,iy)+dz8w(ix,iz-1,iy)
- enddo
- enddo
- enddo
- if (first) then ! True only on first call
- call init_para(alag_u,alaw_u,alar_u,csg_u,csw_u,csr_u,&
- twini_u,trini_u,tgini_u,albg_u,albw_u,albr_u,emg_u,emw_u,&
- emr_u,z0g_u,z0r_u,nd_u,strd_u,drst_u,ws_u,bs_u,h_b,d_b)
- ! Initialisation of the urban parameters and calculation of the view factors
- call icBEP(alag_u,alaw_u,alar_u,csg_u,csw_u,csr_u, &
- albg_u,albw_u,albr_u,emg_u,emw_u,emr_u, &
- fww,fwg,fgw,fsw,fws,fsg, &
- z0g_u,z0r_u, &
- nd_u,strd_u,drst_u,ws_u,bs_u,h_b,d_b,ss_u,pb_u, &
- nz_u,z_u, &
- twini_u,trini_u)
- first=.false.
- endif ! first
-
- do ix=its,ite
- do iy=jts,jte
- if (FRC_URB2D(ix,iy).gt.0.) then ! Calling BEP only for existing urban classes.
-
- iurb=UTYPE_URB2D(ix,iy)
- do iz= kts,kte
- ua1D(iz)=u_phy(ix,iz,iy)
- va1D(iz)=v_phy(ix,iz,iy)
- pt1D(iz)=th_phy(ix,iz,iy)
- da1D(iz)=rho(ix,iz,iy)
- pr1D(iz)=p_phy(ix,iz,iy)
- ! pt01D(iz)=th_phy(ix,iz,iy)
- pt01D(iz)=300.
- z1D(iz)=z(ix,iz,iy)
- a_u1D(iz)=0.
- a_v1D(iz)=0.
- a_t1D(iz)=0.
- a_e1D(iz)=0.
- b_u1D(iz)=0.
- b_v1D(iz)=0.
- b_t1D(iz)=0.
- b_e1D(iz)=0.
- enddo
- z1D(kte+1)=z(ix,kte+1,iy)
- do id=1,ndm
- do iz_u=1,nz_um
- do iw=1,nwr_u
- ! tw1D(2*id-1,iz_u,iw)=tw1_u(ix,iy,ind_zwd(iz_u,iw,id))
- ! tw1D(2*id,iz_u,iw)=tw2_u(ix,iy,ind_zwd(iz_u,iw,id))
- if(ind_zwd(iz_u,iw,id).gt.num_urban_layers)write(*,*)'ind_zwd too big w',ind_zwd(iz_u,iw,id)
- tw1D(2*id-1,iz_u,iw)=tw1_urb4d(ix,ind_zwd(iz_u,iw,id),iy)
- tw1D(2*id,iz_u,iw)=tw2_urb4d(ix,ind_zwd(iz_u,iw,id),iy)
- enddo
- enddo
- enddo
-
- do id=1,ndm
- do ig=1,ng_u
- ! tg1D(id,ig)=tg_u(ix,iy,ind_gd(ig,id))
- tg1D(id,ig)=tgb_urb4d(ix,ind_gd(ig,id),iy)
- enddo
- do iz_u=1,nz_um
- do ir=1,nwr_u
- ! tr1D(id,iz_u,ir)=tr_u(ix,iy,ind_zwd(iz_u,ir,id))
- if(ind_zwd(iz_u,ir,id).gt.num_urban_layers)write(*,*)'ind_zwd too big r',ind_zwd(iz_u,ir,id)
- tr1D(id,iz_u,ir)=trb_urb4d(ix,ind_zwd(iz_u,ir,id),iy)
- enddo
- enddo
- enddo
- do id=1,ndm
- do iz=1,nz_um
- ! sfw1D(2*id-1,iz)=sfw1(ix,iy,ind_zd(iz,id))
- ! sfw1D(2*id,iz)=sfw2(ix,iy,ind_zd(iz,id))
- sfw1D(2*id-1,iz)=sfw1_urb3d(ix,ind_zd(iz,id),iy)
- sfw1D(2*id,iz)=sfw2_urb3d(ix,ind_zd(iz,id),iy)
- enddo
- enddo
-
- do id=1,ndm
- ! sfg1D(id)=sfg(ix,iy,id)
- sfg1D(id)=sfg_urb3d(ix,id,iy)
- enddo
-
- do id=1,ndm
- do iz=1,nz_um
- ! sfr1D(id,iz)=sfr(ix,iy,ind_zd(iz,id))
- sfr1D(id,iz)=sfr_urb3d(ix,ind_zd(iz,id),iy)
- enddo
- enddo
-
- rs1D=swdown(ix,iy)
- rld1D=glw(ix,iy)
- time_h=(itimestep*dt)/3600.+gmt
- zr1D=acos(COSZ_URB2D(ix,iy))
- deltar1D=DECLIN_URB
- ah1D=OMG_URB2D(ix,iy)
- ! call angle(xlong(ix,iy),xlat(ix,iy),julday,time_h,zr1D,deltar1D,ah1D)
- call BEP1D(iurb,kms,kme,kts,kte,z1D,dt,ua1D,va1D,pt1D,da1D,pr1D,pt01D, &
- zr1D,deltar1D,ah1D,rs1D,rld1D, &
- alag_u,alaw_u,alar_u,csg_u,csw_u,csr_u, &
- albg_u,albw_u,albr_u,emg_u,emw_u,emr_u, &
- fww,fwg,fgw,fsw,fws,fsg, &
- z0g_u,z0r_u, &
- nd_u,strd_u,drst_u,ws_u,bs_u,h_b,d_b,ss_u,pb_u, &
- nz_u,z_u, &
- tw1D,tg1D,tr1D,sfw1D,sfg1D,sfr1D, &
- a_u1D,a_v1D,a_t1D,a_e1D, &
- b_u1D,b_v1D,b_t1D,b_e1D, &
- dlg1D,dl_u1D,tsk1D,sf1D,vl1D,rl_up(ix,iy), &
- rs_abs(ix,iy),emiss(ix,iy),grdflx_urb(ix,iy))
- do id=1,ndm
- do iz=1,nz_um
- sfw1_urb3d(ix,ind_zd(iz,id),iy)=sfw1D(2*id-1,iz)
- sfw2_urb3d(ix,ind_zd(iz,id),iy)=sfw1D(2*id,iz)
- enddo
- enddo
-
- do id=1,ndm
- sfg_urb3d(ix,id,iy)=sfg1D(id)
- enddo
-
- do id=1,ndm
- do iz=1,nz_um
- sfr_urb3d(ix,ind_zd(iz,id),iy)=sfr1D(id,iz)
- enddo
- enddo
- !
- do id=1,ndm
- do iz_u=1,nz_um
- do iw=1,nwr_u
- tw1_urb4d(ix,ind_zwd(iz_u,iw,id),iy)=tw1D(2*id-1,iz_u,iw)
- tw2_urb4d(ix,ind_zwd(iz_u,iw,id),iy)=tw1D(2*id,iz_u,iw)
- enddo
- enddo
- enddo
-
- do id=1,ndm
- do ig=1,ng_u
- tgb_urb4d(ix,ind_gd(ig,id),iy)=tg1D(id,ig)
- enddo
- do iz_u=1,nz_um
- do ir=1,nwr_u
- trb_urb4d(ix,ind_zwd(iz_u,ir,id),iy)=tr1D(id,iz_u,ir)
- enddo
- enddo
- enddo
- do iz= kts,kte
- sf(ix,iz,iy)=sf1D(iz)
- vl(ix,iz,iy)=vl1D(iz)
- a_u(ix,iz,iy)=a_u1D(iz)
- a_v(ix,iz,iy)=a_v1D(iz)
- a_t(ix,iz,iy)=a_t1D(iz)
- a_e(ix,iz,iy)=a_e1D(iz)
- b_u(ix,iz,iy)=b_u1D(iz)
- b_v(ix,iz,iy)=b_v1D(iz)
- b_t(ix,iz,iy)=b_t1D(iz)
- b_e(ix,iz,iy)=b_e1D(iz)
- dlg(ix,iz,iy)=dlg1D(iz)
- dl_u(ix,iz,iy)=dl_u1D(iz)
- enddo
- sf(ix,kte+1,iy)=sf1D(kte+1)
- ! tsk(ix,iy)=tsk1D
- !
- endif ! FRC_URB2D
-
- enddo ! iy
- enddo ! ix
- time_bep=time_bep+dt
-
-
- return
- end subroutine BEP
-
- ! ===6=8===============================================================72
- subroutine BEP1D(iurb,kms,kme,kts,kte,z,dt,ua,va,pt,da,pr,pt0, &
- zr,deltar,ah,rs,rld, &
- alag_u,alaw_u,alar_u,csg_u,csw_u,csr_u, &
- albg_u,albw_u,albr_u,emg_u,emw_u,emr_u, &
- fww,fwg,fgw,fsw,fws,fsg, &
- z0g_u,z0r_u, &
- nd_u,strd_u,drst_u,ws_u,bs_u,h_b,d_b,ss_u,pb_u, &
- nz_u,z_u, &
- tw,tg,tr,sfw,sfg,sfr, &
- a_u,a_v,a_t,a_e, &
- b_u,b_v,b_t,b_e, &
- dlg,dl_u,tsk,sf,vl,rl_up,rs_abs,emiss,grdflx_urb)
- ! ----------------------------------------------------------------------
- ! This routine computes the effects of buildings on momentum, heat and
- ! TKE (turbulent kinetic energy) sources or sinks and on the mixing length.
- ! It provides momentum, heat and TKE sources or sinks at different levels of a
- ! mesoscale grid defined by the altitude of its cell interfaces "z" and
- ! its number of levels "nz".
- ! The meteorological input parameters (wind, temperature, solar radiation)
- ! are specified on the "mesoscale grid".
- ! The inputs concerning the building and street charateristics are defined
- ! on a "urban grid". The "urban grid" is defined with its number of levels
- ! "nz_u" and its space step "dz_u".
- ! The input parameters are interpolated on the "urban grid". The sources or sinks
- ! are calculated on the "urban grid". Finally the sources or sinks are
- ! interpolated on the "mesoscale grid".
-
- ! Mesoscale grid Urban grid Mesoscale grid
- !
- ! z(4) --- ---
- ! | |
- ! | |
- ! | Interpolation Interpolation |
- ! | Sources or sinks calculation |
- ! z(3) --- ---
- ! | ua ua_u --- uv_a a_u |
- ! | va va_u | uv_b b_u |
- ! | pt pt_u --- uh_b a_v |
- ! z(2) --- | etc... etc...---
- ! | z_u(1) --- |
- ! | | |
- ! z(1) ------------------------------------------------------------
- !
- ! Reference:
- ! Martilli, A., Clappier, A., Rotach, M.W.:2002, 'AN URBAN SURFACE EXCHANGE
- ! PARAMETERISATION FOR MESOSCALE MODELS', Boundary-Layer Meteorolgy 104:
- ! 261-304
-
- ! ----------------------------------------------------------------------
- implicit none
-
- ! ----------------------------------------------------------------------
- ! INPUT:
- ! ----------------------------------------------------------------------
- ! Data relative to the "mesoscale grid"
- ! integer nz ! Number of vertical levels
- integer kms,kme,kts,kte
- real z(kms:kme) ! Altitude above the ground of the cell interfaces.
- real ua(kms:kme) ! Wind speed in the x direction
- real va(kms:kme) ! Wind speed in the y direction
- real pt(kms:kme) ! Potential temperature
- real da(kms:kme) ! Air density
- real pr(kms:kme) ! Air pressure
- real pt0(kms:kme) ! Reference potential temperature (could be equal to "pt")
- real dt ! Time step
- real zr ! Zenith angle
- real deltar ! Declination of the sun
- real ah ! Hour angle
- real rs ! Solar radiation
- real rld ! Downward flux of the longwave radiation
- ! Data relative to the "urban grid"
- integer iurb ! Current urban class
- ! Building parameters
- real alag_u(nurbm) ! Ground thermal diffusivity [m^2 s^-1]
- real alaw_u(nurbm) ! Wall thermal diffusivity [m^2 s^-1]
- real alar_u(nurbm) ! Roof thermal diffusivity [m^2 s^-1]
- real csg_u(nurbm) ! Specific heat of the ground material [J m^3 K^-1]
- real csw_u(nurbm) ! Specific heat of the wall material [J m^3 K^-1]
- real csr_u(nurbm) ! Specific heat of the roof material [J m^3 K^-1]
- ! Radiation parameters
- real albg_u(nurbm) ! Albedo of the ground
- real albw_u(nurbm) ! Albedo of the wall
- real albr_u(nurbm) ! Albedo of the roof
- real emg_u(nurbm) ! Emissivity of ground
- real emw_u(nurbm) ! Emissivity of wall
- real emr_u(nurbm) ! Emissivity of roof
- ! fww,fwg,fgw,fsw,fsg are the view factors used to compute the long and
- ! short wave radation.
- ! The calculation of these factor is explained in the Appendix A of the BLM paper
- real fww(nz_um,nz_um,ndm,nurbm) ! from wall to wall
- real fwg(nz_um,ndm,nurbm) ! from wall to ground
- real fgw(nz_um,ndm,nurbm) ! from ground to wall
- real fsw(nz_um,ndm,nurbm) ! from sky to wall
- real fws(nz_um,ndm,nurbm) ! from wall to sky
- real fsg(ndm,nurbm) ! from sky to ground
- ! Roughness parameters
- real z0g_u(nurbm) ! The ground's roughness length
- real z0r_u(nurbm) ! The roof's roughness length
-
- ! Street parameters
- integer nd_u(nurbm) ! Number of street direction for each urban class
- real strd_u(ndm,nurbm) ! Street length (set to a greater value then the horizontal length of the cells)
- real drst_u(ndm,nurbm) ! Street direction
- real ws_u(ndm,nurbm) ! Street width
- real bs_u(ndm,nurbm) ! Building width
- real h_b(nz_um,nurbm) ! Bulding's heights
- real d_b(nz_um,nurbm) ! The probability that a building has an height "h_b"
- real ss_u(nz_um,nurbm) ! The probability that a building has an height equal to "z"
- real pb_u(nz_um,nurbm) ! The probability that a building has an height greater or equal to "z"
-
- ! Grid parameters
- integer nz_u(nurbm) ! Number of layer in the urban grid
- ! real dz_u ! Urban grid resolution
- real z_u(nz_um) ! Height of the urban grid levels
- ! ----------------------------------------------------------------------
- ! INPUT-OUTPUT
- ! ----------------------------------------------------------------------
- ! Data relative to the "urban grid" which should be stored from the current time step to the next one
- real tw(2*ndm,nz_um,nwr_u) ! Temperature in each layer of the wall [K]
- real tr(ndm,nz_um,nwr_u) ! Temperature in each layer of the roof [K]
- real tg(ndm,ng_u) ! Temperature in each layer of the ground [K]
- real sfw(2*ndm,nz_um) ! Sensible heat flux from walls
- real sfg(ndm) ! Sensible heat flux from ground (road)
- real sfr(ndm,nz_um) ! Sensible heat flux from roofs
- real gfg(ndm) ! Heat flux transferred from the surface of the ground (road) towards the interior
- real gfr(ndm,nz_um) ! Heat flux transferred from the surface of the roof towards the interior
- real gfw(2*ndm,nz_um) ! Heat flux transfered from the surface of the walls towards the interior
- ! ----------------------------------------------------------------------
- ! OUTPUT:
- ! ----------------------------------------------------------------------
- ! Data relative to the "mesoscale grid"
- real sf(kms:kme) ! Surface of the "mesoscale grid" cells taking into account the buildings
- real vl(kms:kme) ! Volume of the "mesoscale grid" cells taking into account the buildings
-
- ! Implicit and explicit components of the source and sink terms at each levels,
- ! the fluxes can be computed as follow: FX = A*X + B example: Heat fluxes = a_t * pt + b_t
- real a_u(kms:kme) ! Implicit component of the momentum sources or sinks in the X-direction
- real a_v(kms:kme) ! Implicit component of the momentum sources or sinks in the Y-direction
- real a_t(kms:kme) ! Implicit component of the heat sources or sinks
- real a_e(kms:kme) ! Implicit component of the TKE sources or sinks
- real b_u(kms:kme) ! Explicit component of the momentum sources or sinks in the X-direction
- real b_v(kms:kme) ! Explicit component of the momentum sources or sinks in the Y-direction
- real b_t(kms:kme) ! Explicit component of the heat sources or sinks
- real b_e(kms:kme) ! Explicit component of the TKE sources or sinks
- real dlg(kms:kme) ! Height above ground (L_ground in formula (24) of the BLM paper).
- real dl_u(kms:kme) ! Length scale (lb in formula (22) ofthe BLM paper).
- real tsk ! Average of the road surface temperatures
-
- ! ----------------------------------------------------------------------
- ! LOCAL:
- ! ----------------------------------------------------------------------
- real dz(kms:kme) ! vertical space steps of the "mesoscale grid"
- ! Data interpolated from the "mesoscale grid" to the "urban grid"
- real ua_u(nz_um) ! Wind speed in the x direction
- real va_u(nz_um) ! Wind speed in the y direction
- real pt_u(nz_um) ! Potential temperature
- real da_u(nz_um) ! Air density
- real pt0_u(nz_um) ! Reference potential temperature
- real pr_u(nz_um) ! Air pressure
- ! Data defining the building and street charateristics
- integer nd ! Number of street direction for the current urban class
- real alag(ng_u) ! Ground thermal diffusivity for the current urban class [m^2 s^-1]
- real alar(nwr_u) ! Roof thermal diffusivity for the current urban class [m^2 s^-1]
- real alaw(nwr_u) ! Walls thermal diffusivity for the current urban class [m^2 s^-1]
- real csg(ng_u) ! Specific heat of the ground material of the current urban class [J m^3 K^-1]
- real csr(nwr_u) ! Specific heat of the roof material for the current urban class [J m^3 K^-1]
- real csw(nwr_u) ! Specific heat of the wall material for the current urban class [J m^3 K^-1]
- real z0(ndm,nz_um) ! Roughness lengths "profiles"
- real ws(ndm) ! Street widths of the current urban class
- real bs(ndm) ! Building widths of the current urban class
- real strd(ndm) ! Street lengths for the current urban class
- real drst(ndm) ! Street directions for the current urban class
- real ss(nz_um) ! Probability to have a building with height h
- real pb(nz_um) ! Probability to have a building with an height equal
- ! Solar radiation at each level of the "urban grid"
- real rsg(ndm) ! Short wave radiation from the ground
- real rsw(2*ndm,nz_um) ! Short wave radiation from the walls
- real rlg(ndm) ! Long wave radiation from the ground
- real rlw(2*ndm,nz_um) ! Long wave radiation from the walls
- ! Potential temperature of the surfaces at each level of the "urban grid"
- real ptg(ndm) ! Ground potential temperatures
- real ptr(ndm,nz_um) ! Roof potential temperatures
- real ptw(2*ndm,nz_um) ! Walls potential temperatures
-
- ! Explicit and implicit component of the momentum, temperature and TKE sources or sinks on
- ! vertical surfaces (walls) ans horizontal surfaces (roofs and street)
- ! The fluxes can be computed as follow: Fluxes of X = A*X + B
- ! Example: Momentum fluxes on vertical surfaces = uva_u * ua_u + uvb_u
- real uhb_u(ndm,nz_um) ! U (wind component) Horizontal surfaces, B (explicit) term
- real uva_u(2*ndm,nz_um) ! U (wind component) Vertical surfaces, A (implicit) term
- real uvb_u(2*ndm,nz_um) ! U (wind component) Vertical surfaces, B (explicit) term
- real vhb_u(ndm,nz_um) ! V (wind component) Horizontal surfaces, B (explicit) term
- real vva_u(2*ndm,nz_um) ! V (wind component) Vertical surfaces, A (implicit) term
- real vvb_u(2*ndm,nz_um) ! V (wind component) Vertical surfaces, B (explicit) term
- real thb_u(ndm,nz_um) ! Temperature Horizontal surfaces, B (explicit) term
- real tva_u(2*ndm,nz_um) ! Temperature Vertical surfaces, A (implicit) term
- real tvb_u(2*ndm,nz_um) ! Temperature Vertical surfaces, B (explicit) term
- real ehb_u(ndm,nz_um) ! Energy (TKE) Horizontal surfaces, B (explicit) term
- real evb_u(2*ndm,nz_um) ! Energy (TKE) Vertical surfaces, B (explicit) term
-
- !
- real rs_abs ! solar radiation absorbed by urban surfaces
- real rl_up ! longwave radiation emitted by urban surface to the atmosphere
- real emiss ! mean emissivity of the urban surface
- real grdflx_urb ! ground heat flux
- real shtot,aaa
- real dt_int ! internal time step
- integer nt_int ! number of internal time step
- integer iz,id, it_int
- integer iwrong,iw,ix,iy
- ! ----------------------------------------------------------------------
- ! END VARIABLES DEFINITIONS
- ! ----------------------------------------------------------------------
- ! Fix some usefull parameters for the computation of the sources or sinks
- do iz=kts,kte
- dz(iz)=z(iz+1)-z(iz)
- end do
- call param(iurb,nz_u(iurb),nd_u(iurb), &
- csg_u,csg,alag_u,alag,csr_u,csr, &
- alar_u,alar,csw_u,csw,alaw_u,alaw, &
- ws_u,ws,bs_u,bs,z0g_u,z0r_u,z0, &
- strd_u,strd,drst_u,drst,ss_u,ss,pb_u,pb)
- ! Interpolation on the "urban grid"
- call interpol(kms,kme,kts,kte,nz_u(iurb),z,z_u,ua,ua_u)
- call interpol(kms,kme,kts,kte,nz_u(iurb),z,z_u,va,va_u)
- call interpol(kms,kme,kts,kte,nz_u(iurb),z,z_u,pt,pt_u)
- call interpol(kms,kme,kts,kte,nz_u(iurb),z,z_u,pt0,pt0_u)
- call interpol(kms,kme,kts,kte,nz_u(iurb),z,z_u,pr,pr_u)
- call interpol(kms,kme,kts,kte,nz_u(iurb),z,z_u,da,da_u)
-
- ! Compute the modification of the radiation due to the buildings
- call modif_rad(iurb,nd_u(iurb),nz_u(iurb),z_u,ws, &
- drst,strd,ss,pb, &
- tw,tg,albg_u(iurb),albw_u(iurb), &
- emw_u(iurb),emg_u(iurb), &
- fww,fwg,fgw,fsw,fsg, &
- zr,deltar,ah, &
- rs,rld,rsw,rsg,rlw,rlg)
-
- ! calculation of the urban albedo and the upward long wave radiation
- call upward_rad(nd_u(iurb),iurb,nz_u(iurb),ws,bs,sigma,fsw,fsg,pb,ss, &
- tg,emg_u(iurb),albg_u(iurb),rlg,rsg,sfg, &
- tw,emw_u(iurb),albw_u(iurb),rlw,rsw,sfw, &
- tr,emr_u(iurb),albr_u(iurb),rld,rs,sfr, &
- rs_abs,rl_up,emiss,grdflx_urb)
-
- ! Compute the surface temperatures
-
- call surf_temp(nz_u(iurb),nd_u(iurb),pr_u,dt,ss, &
- rs,rld,rsg,rlg,rsw,rlw, &
- tg,alag,csg,emg_u(iurb),albg_u(iurb),ptg,sfg,gfg, &
- tr,alar,csr,emr_u(iurb),albr_u(iurb),ptr,sfr,gfr, &
- tw,alaw,csw,emw_u(iurb),albw_u(iurb),ptw,sfw,gfw)
-
-
- ! Compute the implicit and explicit components of the sources or sinks on the "urban grid"
-
- call buildings(nd_u(iurb),nz_u(iurb),z0,ua_u,va_u, &
- pt_u,pt0_u,ptg,ptr,da_u,ptw,drst, &
- uva_u,vva_u,uvb_u,vvb_u,tva_u,tvb_u,evb_u, &
- uhb_u,vhb_u,thb_u,ehb_u,ss,dt)
-
-
- ! Calculation of the sensible heat fluxes for the ground, the wall and roof
- ! Sensible Heat Flux = density * Cp_U * ( A* potential temperature + B )
- ! where A and B are the implicit and explicit components of the heat sources or sinks.
- !
- !
-
- do id=1,nd_u(iurb)
- sfg(id)=-da_u(1)*cp_u*thb_u(id,1)
- do iz=2,nz_u(iurb)
- sfr(id,iz)=-da_u(iz)*cp_u*thb_u(id,iz)
- enddo
-
- do iz=1,nz_u(iurb)
- sfw(2*id-1,iz)=-da_u(iz)*cp_u*(tvb_u(2*id-1,iz)+ &
- tva_u(2*id-1,iz)*pt_u(iz))
- sfw(2*id,iz)=-da_u(iz)*cp_u*(tvb_u(2*id,iz)+ &
- tva_u(2*id,iz)*pt_u(iz))
- enddo
- enddo
-
- ! calculation of the urban albedo and the upward long wave radiation
-
- ! call upward_rad(nd_u(iurb),iurb,nz_u(iurb),ws,bs,sigma,fsw,fsg,pb,ss, &
- ! tg,emg_u(iurb),albg_u(iurb),rlg,rsg, &
- ! tw,emw_u(iurb),albw_u(iurb),rlw,rsw, &
- ! tr,emr_u(iurb),albr_u(iurb),rld,rs, &
- ! rs_abs,rl_up,emiss)
- ! Interpolation on the "mesoscale grid"
- call urban_meso(nd_u(iurb),kms,kme,kts,kte,nz_u(iurb),z,dz,z_u,pb,ss,bs,ws,sf, &
- vl,uva_u,vva_u,uvb_u,vvb_u,tva_u,tvb_u,evb_u, &
- uhb_u,vhb_u,thb_u,ehb_u, &
- a_u,a_v,a_t,a_e,b_u,b_v,b_t,b_e)
-
- ! computation of the mean road temperature tsk (this value could be used
- ! to replace the surface temperature in the radiation routines, if needed).
- ! tsk=0.
- ! do id=1,nd_u(iurb)
- ! tsk=tsk+tg(id,ng_u)/nd_u(iurb)
- ! enddo
- ! Calculation of the length scale taking into account the buildings effects
- call interp_length(nd_u(iurb),kms,kme,kts,kte,nz_u(iurb),z_u,z,ss,ws,bs,dlg,dl_u)
- return
- end subroutine BEP1D
- ! ===6=8===============================================================72
- ! ===6=8===============================================================72
- subroutine param(iurb,nz,nd, &
- csg_u,csg,alag_u,alag,csr_u,csr, &
- alar_u,alar,csw_u,csw,alaw_u,alaw, &
- ws_u,ws,bs_u,bs,z0g_u,z0r_u,z0, &
- strd_u,strd,drst_u,drst,ss_u,ss,pb_u,pb)
- ! ----------------------------------------------------------------------
- ! This routine prepare some usefull parameters
- ! ----------------------------------------------------------------------
- implicit none
-
- ! ----------------------------------------------------------------------
- ! INPUT:
- ! ----------------------------------------------------------------------
- integer iurb ! Current urban class
- integer nz ! Number of vertical urban levels in the current class
- integer nd ! Number of street direction for the current urban class
- real alag_u(nurbm) ! Ground thermal diffusivity [m^2 s^-1]
- real alar_u(nurbm) ! Roof thermal diffusivity [m^2 s^-1]
- real alaw_u(nurbm) ! Wall thermal diffusivity [m^2 s^-1]
- real bs_u(ndm,nurbm) ! Building width
- real csg_u(nurbm) ! Specific heat of the ground material [J m^3 K^-1]
- real csr_u(nurbm) ! Specific heat of the roof material [J m^3 K^-1]
- real csw_u(nurbm) ! Specific heat of the wall material [J m^3 K^-1]
- real drst_u(ndm,nurbm) ! Street direction
- real strd_u(ndm,nurbm) ! Street length
- real ws_u(ndm,nurbm) ! Street width
- real z0g_u(nurbm) ! The ground's roughness length
- real z0r_u(nurbm) ! The roof's roughness length
- real ss_u(nz_um,nurbm) ! The probability that a building has an height equal to "z"
- real pb_u(nz_um,nurbm) ! The probability that a building has an height greater or equal to "z"
- ! ----------------------------------------------------------------------
- ! OUTPUT:
- ! ----------------------------------------------------------------------
- real alag(ng_u) ! Ground thermal diffusivity at each ground levels
- real alar(nwr_u) ! Roof thermal diffusivity at each roof levels
- real alaw(nwr_u) ! Wall thermal diffusivity at each wall levels
- real csg(ng_u) ! Specific heat of the ground material at each ground levels
- real csr(nwr_u) ! Specific heat of the roof material at each roof levels
- real csw(nwr_u) ! Specific heat of the wall material at each wall levels
- real bs(ndm) ! Building width for the current urban class
- real drst(ndm) ! street directions for the current urban class
- real strd(ndm) ! Street lengths for the current urban class
- real ws(ndm) ! Street widths of the current urban class
- real z0(ndm,nz_um) ! Roughness lengths "profiles"
- real ss(nz_um) ! Probability to have a building with height h
- real pb(nz_um) ! Probability to have a building with an height equal
- ! ----------------------------------------------------------------------
- ! LOCAL:
- ! ----------------------------------------------------------------------
- integer id,ig,ir,iw,iz
- ! ----------------------------------------------------------------------
- ! END VARIABLES DEFINITIONS
- ! ----------------------------------------------------------------------
- !
- !Initialize the variables
- !
- ss=0.
- pb=0.
- csg=0.
- alag=0.
- csr=0.
- alar=0.
- csw=0.
- alaw=0.
- z0=0.
- ws=0.
- bs=0.
- strd=0.
- drst=0.
-
- do iz=1,nz+1
- ss(iz)=ss_u(iz,iurb)
- pb(iz)=pb_u(iz,iurb)
- end do
-
- do ig=1,ng_u
- csg(ig)=csg_u(iurb)
- alag(ig)=alag_u(iurb)
- enddo
-
- do ir=1,nwr_u
- csr(ir)=csr_u(iurb)
- alar(ir)=alar_u(iurb)
- enddo
-
- do iw=1,nwr_u
- csw(iw)=csw_u(iurb)
- alaw(iw)=alaw_u(iurb)
- enddo
-
- do id=1,nd
- z0(id,1)=z0g_u(iurb)
- do iz=2,nz+1
- z0(id,iz)=z0r_u(iurb)
- enddo
- enddo
-
- do id=1,nd
- ws(id)=ws_u(id,iurb)
- bs(id)=bs_u(id,iurb)
- strd(id)=strd_u(id,iurb)
- drst(id)=drst_u(id,iurb)
- enddo
-
- return
- end subroutine param
-
- ! ===6=8===============================================================72
- ! ===6=8===============================================================72
- subroutine interpol(kms,kme,kts,kte,nz_u,z,z_u,c,c_u)
- ! ----------------------------------------------------------------------
- ! This routine interpolate para
- ! meters from the "mesoscale grid" to
- ! the "urban grid".
- ! See p300 Appendix B.1 of the BLM paper.
- ! ----------------------------------------------------------------------
- implicit none
- ! ----------------------------------------------------------------------
- ! INPUT:
- ! ----------------------------------------------------------------------
- ! Data relative to the "mesoscale grid"
- integer kts,kte,kms,kme
- real z(kms:kme) ! Altitude of the cell interface
- real c(kms:kme) ! Parameter which has to be interpolated
- ! Data relative to the "urban grid"
- integer nz_u ! Number of levels
- !! real z_u(nz_u+1) ! Altitude of the cell interface
- real z_u(nz_um) ! Altitude of the cell interface
- ! ----------------------------------------------------------------------
- ! OUTPUT:
- ! ----------------------------------------------------------------------
- !! real c_u(nz_u) ! Interpolated paramters in the "urban grid"
- real c_u(nz_um) ! Interpolated paramters in the "urban grid"
- ! LOCAL:
- ! ----------------------------------------------------------------------
- integer iz_u,iz
- real ctot,dz
- ! ----------------------------------------------------------------------
- ! END VARIABLES DEFINITIONS
- ! ----------------------------------------------------------------------
- do iz_u=1,nz_u
- ctot=0.
- do iz=kts,kte
- dz=max(min(z(iz+1),z_u(iz_u+1))-max(z(iz),z_u(iz_u)),0.)
- ctot=ctot+c(iz)*dz
- enddo
- c_u(iz_u)=ctot/(z_u(iz_u+1)-z_u(iz_u))
- enddo
-
- return
- end subroutine interpol
-
- ! ===6=8===============================================================72
- ! ===6=8===============================================================72
- subroutine modif_rad(iurb,nd,nz_u,z,ws,drst,strd,ss,pb, &
- tw,tg,albg,albw,emw,emg, &
- fww,fwg,fgw,fsw,fsg, &
- zr,deltar,ah, &
- rs,rl,rsw,rsg,rlw,rlg)
-
- ! ----------------------------------------------------------------------
- ! This routine computes the modification of the short wave and
- ! long wave radiation due to the buildings.
- ! ----------------------------------------------------------------------
- implicit none
-
-
- ! ----------------------------------------------------------------------
- ! INPUT:
- ! ----------------------------------------------------------------------
- integer iurb ! current urban class
- integer nd ! Number of street direction for the current urban class
- integer nz_u ! Number of layer in the urban grid
- real z(nz_um) ! Height of the urban grid levels
- real ws(ndm) ! Street widths of the current urban class
- real drst(ndm) ! street directions for the current urban class
- real strd(ndm) ! Street lengths for the current urban class
- real ss(nz_um) ! probability to have a building with height h
- real pb(nz_um) ! probability to have a building with an height equal
- real tw(2*ndm,nz_um,nwr_u) ! Temperature in each layer of the wall [K]
- real tg(ndm,ng_u) ! Temperature in each layer of the ground [K]
- real albg ! Albedo of the ground for the current urban class
- real albw ! Albedo of the wall for the current urban class
- real emg ! Emissivity of ground for the current urban class
- real emw ! Emissivity of wall for the current urban class
- real fgw(nz_um,ndm,nurbm) ! View factors from ground to wall
- real fsg(ndm,nurbm) ! View factors from sky to ground
- real fsw(nz_um,ndm,nurbm) ! View factors from sky to wall
- real fws(nz_um,ndm,nurbm) ! View factors from wall to sky
- real fwg(nz_um,ndm,nurbm) ! View factors from wall to ground
- real fww(nz_um,nz_um,ndm,nurbm) ! View factors from wall to wall
- real ah ! Hour angle (it should come from the radiation routine)
- real zr ! zenith angle
- real deltar ! Declination of the sun
- real rs ! solar radiation
- real rl ! downward flux of the longwave radiation
- ! ----------------------------------------------------------------------
- ! OUTPUT:
- ! ----------------------------------------------------------------------
- real rlg(ndm) ! Long wave radiation at the ground
- real rlw(2*ndm,nz_um) ! Long wave radiation at the walls
- real rsg(ndm) ! Short wave radiation at the ground
- real rsw(2*ndm,nz_um) ! Short wave radiation at the walls
- ! ----------------------------------------------------------------------
- ! LOCAL:
- ! ----------------------------------------------------------------------
- integer id,iz
- ! Calculation of the shadow effects
- call shadow_mas(nd,nz_u,zr,deltar,ah,drst,ws,ss,pb,z, &
- rs,rsw,rsg)
- ! Calculation of the reflection effects …
Large files files are truncated, but you can click here to view the full file