SCALE-RM
scale_urban_grid_cartesC_index.F90
Go to the documentation of this file.
1 !-------------------------------------------------------------------------------
9 !-------------------------------------------------------------------------------
10 #include "scalelib.h"
12  !-----------------------------------------------------------------------------
13  !
14  !++ used modules
15  !
16  use scale_precision
17  use scale_io
18  use scale_prof
19  !-----------------------------------------------------------------------------
20  implicit none
21  private
22  !-----------------------------------------------------------------------------
23  !
24  !++ Public procedure
25  !
27 
28  !-----------------------------------------------------------------------------
29  !
30  !++ Public parameters & variables
31  !
32  integer, public :: ukmax = -1 ! # of computational cells: z for urban
33  integer, public :: uimax = -1 ! # of computational cells: x for urban
34  integer, public :: ujmax = -1 ! # of computational cells: y for urban
35  !$acc declare create(UKMAX, UIMAX, UJMAX)
36 
37  integer, public :: uka = -1 ! # of total grids: z for urban, local
38  integer, public :: uks ! start point of inner domain: z for urban, local
39  integer, public :: uke ! end point of inner domain: z for urban, local
40 
41  integer, public :: uia ! # of total grids: x for urban, local
42  integer, public :: uis ! start point of inner domain: x for urban, local
43  integer, public :: uie ! end point of inner domain: x for urban, local
44 
45  integer, public :: uja ! # of total grids: Y for urban, local
46  integer, public :: ujs ! start point of inner domain: y for urban, local
47  integer, public :: uje ! end point of inner domain: y for urban, local
48  !$acc declare create(UKA, UKS, UKE, UIA, UIS, UIE, UJA, UJS, UJE)
49 
50  !-----------------------------------------------------------------------------
51  !
52  !++ Private procedure
53  !
54  !-----------------------------------------------------------------------------
55  !
56  !++ Private parameters & variables
57  !
58  !-----------------------------------------------------------------------------
59 contains
60  !-----------------------------------------------------------------------------
63  use scale_prc, only: &
64  prc_abort
66  imax, &
67  ia, is, ie, &
68  jmax, &
69  ja, js, je
70  implicit none
71 
72  namelist / param_urban_grid_cartesc_index / &
73  ukmax
74 
75  integer :: ierr
76  !---------------------------------------------------------------------------
77 
78  log_newline
79  log_info("URBAN_GRID_CARTESC_INDEX_setup",*) 'Setup'
80 
81  !--- read namelist
82  rewind(io_fid_conf)
83  read(io_fid_conf,nml=param_urban_grid_cartesc_index,iostat=ierr)
84  if( ierr < 0 ) then !--- missing
85  log_info("URBAN_GRID_CARTESC_INDEX_setup",*) 'Not found namelist. Default used.'
86  elseif( ierr > 0 ) then !--- fatal error
87  log_error("URBAN_GRID_CARTESC_INDEX_setup",*) 'Not appropriate names in namelist PARAM_URBAN_GRID_CARTESC_INDEX. Check!'
88  call prc_abort
89  endif
90  log_nml(param_urban_grid_cartesc_index)
91 
92  if ( ukmax < 1 ) then
93  log_error("URBAN_GRID_CARTESC_INDEX_setup",*) 'UKMAX must be >= 1 ', ukmax
94  call prc_abort
95  end if
96 
97  uka = ukmax
98  uks = 1
99  uke = ukmax
100 
101  log_newline
102  log_info("URBAN_GRID_CARTESC_INDEX_setup",*) 'Urban grid index information '
103  log_info_cont('(1x,A,I6,A,I6,A,I6)') 'z-axis levels :', ukmax
104 
105  ! at this moment horizontal grid is same as that in atmosphere
106  uimax = imax
107  uia = ia
108  uis = is
109  uie = ie
110 
111  ujmax = jmax
112  uja = ja
113  ujs = js
114  uje = je
115 
116  !$acc update device(UKMAX, UIMAX, UJMAX)
117 
118  !$acc update device(UKA, UKS, UKE, UIA, UIS, UIE, UJA, UJS, UJE)
119 
120  return
121  end subroutine urban_grid_cartesc_index_setup
122 
scale_urban_grid_cartesc_index::uja
integer, public uja
Definition: scale_urban_grid_cartesC_index.F90:45
scale_prc::prc_abort
subroutine, public prc_abort
Abort Process.
Definition: scale_prc.F90:350
scale_urban_grid_cartesc_index::uia
integer, public uia
Definition: scale_urban_grid_cartesC_index.F90:41
scale_precision
module PRECISION
Definition: scale_precision.F90:14
scale_urban_grid_cartesc_index::uimax
integer, public uimax
Definition: scale_urban_grid_cartesC_index.F90:33
scale_urban_grid_cartesc_index
module urban / grid / icosahedralA / index
Definition: scale_urban_grid_cartesC_index.F90:11
scale_atmos_grid_cartesc_index::imax
integer, public imax
Definition: scale_atmos_grid_cartesC_index.F90:37
scale_urban_grid_cartesc_index::ukmax
integer, public ukmax
Definition: scale_urban_grid_cartesC_index.F90:32
scale_prc
module PROCESS
Definition: scale_prc.F90:11
scale_atmos_grid_cartesc_index::ie
integer, public ie
end point of inner domain: x, local
Definition: scale_atmos_grid_cartesC_index.F90:54
scale_io
module STDIO
Definition: scale_io.F90:10
scale_urban_grid_cartesc_index::urban_grid_cartesc_index_setup
subroutine, public urban_grid_cartesc_index_setup
Setup.
Definition: scale_urban_grid_cartesC_index.F90:63
scale_atmos_grid_cartesc_index
module atmosphere / grid / cartesC index
Definition: scale_atmos_grid_cartesC_index.F90:12
scale_atmos_grid_cartesc_index::ia
integer, public ia
Definition: scale_atmos_grid_cartesC_index.F90:48
scale_prof
module profiler
Definition: scale_prof.F90:11
scale_atmos_grid_cartesc_index::is
integer, public is
start point of inner domain: x, local
Definition: scale_atmos_grid_cartesC_index.F90:53
scale_atmos_grid_cartesc_index::ja
integer, public ja
Definition: scale_atmos_grid_cartesC_index.F90:49
scale_urban_grid_cartesc_index::uks
integer, public uks
Definition: scale_urban_grid_cartesC_index.F90:38
scale_atmos_grid_cartesc_index::jmax
integer, public jmax
Definition: scale_atmos_grid_cartesC_index.F90:38
scale_urban_grid_cartesc_index::ujmax
integer, public ujmax
Definition: scale_urban_grid_cartesC_index.F90:34
scale_atmos_grid_cartesc_index::js
integer, public js
start point of inner domain: y, local
Definition: scale_atmos_grid_cartesC_index.F90:55
scale_urban_grid_cartesc_index::uka
integer, public uka
Definition: scale_urban_grid_cartesC_index.F90:37
scale_urban_grid_cartesc_index::uis
integer, public uis
Definition: scale_urban_grid_cartesC_index.F90:42
scale_urban_grid_cartesc_index::uje
integer, public uje
Definition: scale_urban_grid_cartesC_index.F90:47
scale_urban_grid_cartesc_index::ujs
integer, public ujs
Definition: scale_urban_grid_cartesC_index.F90:46
scale_io::io_fid_conf
integer, public io_fid_conf
Config file ID.
Definition: scale_io.F90:57
scale_atmos_grid_cartesc_index::je
integer, public je
end point of inner domain: y, local
Definition: scale_atmos_grid_cartesC_index.F90:56
scale_urban_grid_cartesc_index::uie
integer, public uie
Definition: scale_urban_grid_cartesC_index.F90:43
scale_urban_grid_cartesc_index::uke
integer, public uke
Definition: scale_urban_grid_cartesC_index.F90:39