SCALE-RM
scale_land_grid_index.F90
Go to the documentation of this file.
1 !-------------------------------------------------------------------------------
9 !-------------------------------------------------------------------------------
11  !-----------------------------------------------------------------------------
12  !
13  !++ used modules
14  !
15  use scale_precision
16  use scale_stdio
17  use scale_prof
18  !-----------------------------------------------------------------------------
19  implicit none
20  private
21  !-----------------------------------------------------------------------------
22  !
23  !++ Public procedure
24  !
25  public :: land_grid_index_setup
26 
27  !-----------------------------------------------------------------------------
28  !
29  !++ Public parameters & variables
30  !
31  integer, public :: lkmax = 1 ! # of computational cells: z for land
32 
33  integer, public :: lks ! start point of inner domain: z for land, local
34  integer, public :: lke ! end point of inner domain: z for land, local
35 
36  !-----------------------------------------------------------------------------
37  !
38  !++ Private procedure
39  !
40  !-----------------------------------------------------------------------------
41  !
42  !++ Private parameters & variables
43  !
44  !-----------------------------------------------------------------------------
45 contains
46  !-----------------------------------------------------------------------------
48  subroutine land_grid_index_setup
49  use scale_process, only: &
51  implicit none
52 
53  namelist / param_land_index / &
54  lkmax
55 
56  integer :: ierr
57  !---------------------------------------------------------------------------
58 
59  if( io_l ) write(io_fid_log,*)
60  if( io_l ) write(io_fid_log,*) '++++++ Module[GRID_INDEX] / Categ[LAND GRID] / Origin[SCALElib]'
61 
62  !--- read namelist
63  rewind(io_fid_conf)
64  read(io_fid_conf,nml=param_land_index,iostat=ierr)
65  if( ierr < 0 ) then !--- missing
66  if( io_l ) write(io_fid_log,*) '*** Not found namelist. Default used.'
67  elseif( ierr > 0 ) then !--- fatal error
68  write(*,*) 'xxx Not appropriate names in namelist PARAM_LAND_INDEX. Check!'
69  call prc_mpistop
70  endif
71  if( io_nml ) write(io_fid_nml,nml=param_land_index)
72 
73  lks = 1
74  lke = lkmax
75 
76  if( io_l ) write(io_fid_log,*)
77  if( io_l ) write(io_fid_log,*) '*** Land grid index information ***'
78  if( io_l ) write(io_fid_log,'(1x,A,I6,A,I6,A,I6)') '*** z-axis levels :', lkmax
79 
80  return
81  end subroutine land_grid_index_setup
82 
83 end module scale_land_grid_index
subroutine, public prc_mpistop
Abort MPI.
logical, public io_l
output log or not? (this process)
Definition: scale_stdio.F90:61
module STDIO
Definition: scale_stdio.F90:12
logical, public io_nml
output log or not? (for namelist, this process)
Definition: scale_stdio.F90:62
module PROCESS
subroutine, public land_grid_index_setup
Setup.
module profiler
Definition: scale_prof.F90:10
module PRECISION
module land grid index
integer, public io_fid_conf
Config file ID.
Definition: scale_stdio.F90:55
integer, public io_fid_log
Log file ID.
Definition: scale_stdio.F90:56
integer, public io_fid_nml
Log file ID (only for output namelist)
Definition: scale_stdio.F90:57