Takuya Miyashita
This site
Web
Start:
*ソースコード読み解き [#o9260f59]
**JAGURS.f90 [#ec49b13e]
メインのコード.各モジュールを合わせて,初期条件等を読み...
mod_grid の data_grids 構造体は dgrid と定義されている.~
~
**mod_grid.f90 [#z9bdf87d]
変数の定義.グリッド情報を格納する色々な構造体が定義され...
*** data_grids [#q1c31d73]
各計算領域の水深や水位,wetdry などの基本的な情報が諸々含...
data_grids 構造体の中にも色々な構造体があり,wave_arrays ...
Cartesian 座標系で MPI を使わない場合の cpp で見てみると...
#codeprettify(lang-fortran){{
type data_grids
type(grid_info) :: parent
type(grid_info) :: my
type(wave_arrays) :: wave_field
type(depth_arrays) :: depth_field
real(kind=8), allocatable, dimension(:,:) :: ts_field
real(kind=8), allocatable, dimension(:,:) :: zz
type(boundary_arrays) :: ubnd
type(boundary_arrays) :: hbnd
real(kind=8), allocatable, dimension(:,:) :: hzmax
! === To add max velocity output. by tkato 2012/10/02 ===...
real(kind=8), allocatable, dimension(:,:) :: vmax
! =======================================================...
integer(kind=4), allocatable, dimension(:,:) :: wod_fl...
character(len=256) :: wod_file
real(kind=8), allocatable, dimension(:,:) :: wod_field
character(len=256) :: bcf_file
character(len=256) :: bank_file
real(kind=8), allocatable, dimension(:,:) :: bcf_field
type(interp_info) :: fxo
type(interp_info) :: fyo
type(interp_info) :: fxi
type(interp_info) :: fyi
type(interp_info) :: hzi
type(interp_info) :: dzi
! === copy2coarse for hz ================================...
type(interp_info) :: hzo
! =======================================================...
! === Support multiple ruptures. ========================...
integer(kind=4) :: nrupt, irupt, jrupt ! nrupt = numbe...
character(len=256), allocatable, dimension(:) :: ruptgrd
! =======================================================...
! === Do not repeat allocate/deallocate! ================...
! =======================================================...
end type data_grids
}}
**grid_info [#vcdf7ebd]
領域ごとの配列のサイズや入出力ファイル名の情報.
#codeprettify(lang-fortran){{
type grid_info
integer(kind=4) :: id = 1
real(kind=8) :: mlon0
real(kind=8) :: mlat0
real(kind=8) :: dh
real(kind=8) :: th0
real(kind=8) :: dth
integer(kind=4) :: nx
integer(kind=4) :: ny
integer(kind=4) :: linear_flag
character(len=256) :: base_name
character(len=256) :: bath_file
character(len=256) :: disp_file
integer(kind=4) :: nr
integer(kind=4) :: bigNX
integer(kind=4) :: bigNY
integer(kind=4) :: zeroIX
integer(kind=4) :: zeroIY
integer(kind=4) :: nconvout
end type grid_info
}}
***wave_arrays [#o0a40fc7]
fx, fy はフラックス(線流量).~
hz は水位(eta)?
#codeprettify(lang-fortran){{
type wave_arrays
real(kind=8), allocatable, dimension(:,:) :: fx
real(kind=8), allocatable, dimension(:,:) :: fy
real(kind=8), allocatable, dimension(:,:) :: hz
! === Flood Change ======================================...
real(kind=8), allocatable, dimension(:,:) :: hz_old
! =======================================================...
! === DEBUG for wave height gap on nest boundary. 2012/10...
! real(kind=8), allocatable, dimension(:) :: fx_old
real(kind=8), allocatable, dimension(:,:) :: fx_old
! =======================================================...
! === DEBUG for wave height gap on nest boundary. 2012/10...
! real(kind=8), allocatable, dimension(:) :: fy_old
real(kind=8), allocatable, dimension(:,:) :: fy_old
! =======================================================...
! === Dispersive ========================================...
real(kind=8), allocatable, dimension(:,:) :: yu, yv ! ...
real(kind=8), allocatable, dimension(:,:) :: cu, cv ! ...
! =======================================================...
! === Absorbing boundary condition ======================...
real(kind=8), allocatable, dimension(:,:) :: abc
! =======================================================...
! === Optimization ======================================...
real(kind=8), allocatable, dimension(:,:) :: tdx, tdy
! =======================================================...
! === Arrival time ======================================...
integer(kind=4), allocatable, dimension(:,:) :: arrive...
real(kind=8), allocatable, dimension(:,:) :: arrival_t...
! =======================================================...
integer(kind=4), allocatable, dimension(:,:) :: ir
real(kind=8), allocatable, dimension(:,:) :: btx, bty
integer(kind=4), allocatable, dimension(:,:) :: broken...
end type wave_arrays
}}
***depth_arrays [#e9e21b6a]
dz は水深 (dx, dy は半メッシュズレた水深?).~
wave_arrays の hz と depth_arrays の dz を足すとで全水深?
#codeprettify(lang-fortran){{
type depth_arrays
real(kind=8), allocatable, dimension(:,:) :: dx
real(kind=8), allocatable, dimension(:,:) :: dy
real(kind=8), allocatable, dimension(:,:) :: dz
real(kind=8), allocatable, dimension(:,:) :: dx_old
real(kind=8), allocatable, dimension(:,:) :: dy_old
real(kind=8), allocatable, dimension(:,:) :: dxbx
real(kind=8), allocatable, dimension(:,:) :: dyby
end type depth_arrays
}}
End:
*ソースコード読み解き [#o9260f59]
**JAGURS.f90 [#ec49b13e]
メインのコード.各モジュールを合わせて,初期条件等を読み...
mod_grid の data_grids 構造体は dgrid と定義されている.~
~
**mod_grid.f90 [#z9bdf87d]
変数の定義.グリッド情報を格納する色々な構造体が定義され...
*** data_grids [#q1c31d73]
各計算領域の水深や水位,wetdry などの基本的な情報が諸々含...
data_grids 構造体の中にも色々な構造体があり,wave_arrays ...
Cartesian 座標系で MPI を使わない場合の cpp で見てみると...
#codeprettify(lang-fortran){{
type data_grids
type(grid_info) :: parent
type(grid_info) :: my
type(wave_arrays) :: wave_field
type(depth_arrays) :: depth_field
real(kind=8), allocatable, dimension(:,:) :: ts_field
real(kind=8), allocatable, dimension(:,:) :: zz
type(boundary_arrays) :: ubnd
type(boundary_arrays) :: hbnd
real(kind=8), allocatable, dimension(:,:) :: hzmax
! === To add max velocity output. by tkato 2012/10/02 ===...
real(kind=8), allocatable, dimension(:,:) :: vmax
! =======================================================...
integer(kind=4), allocatable, dimension(:,:) :: wod_fl...
character(len=256) :: wod_file
real(kind=8), allocatable, dimension(:,:) :: wod_field
character(len=256) :: bcf_file
character(len=256) :: bank_file
real(kind=8), allocatable, dimension(:,:) :: bcf_field
type(interp_info) :: fxo
type(interp_info) :: fyo
type(interp_info) :: fxi
type(interp_info) :: fyi
type(interp_info) :: hzi
type(interp_info) :: dzi
! === copy2coarse for hz ================================...
type(interp_info) :: hzo
! =======================================================...
! === Support multiple ruptures. ========================...
integer(kind=4) :: nrupt, irupt, jrupt ! nrupt = numbe...
character(len=256), allocatable, dimension(:) :: ruptgrd
! =======================================================...
! === Do not repeat allocate/deallocate! ================...
! =======================================================...
end type data_grids
}}
**grid_info [#vcdf7ebd]
領域ごとの配列のサイズや入出力ファイル名の情報.
#codeprettify(lang-fortran){{
type grid_info
integer(kind=4) :: id = 1
real(kind=8) :: mlon0
real(kind=8) :: mlat0
real(kind=8) :: dh
real(kind=8) :: th0
real(kind=8) :: dth
integer(kind=4) :: nx
integer(kind=4) :: ny
integer(kind=4) :: linear_flag
character(len=256) :: base_name
character(len=256) :: bath_file
character(len=256) :: disp_file
integer(kind=4) :: nr
integer(kind=4) :: bigNX
integer(kind=4) :: bigNY
integer(kind=4) :: zeroIX
integer(kind=4) :: zeroIY
integer(kind=4) :: nconvout
end type grid_info
}}
***wave_arrays [#o0a40fc7]
fx, fy はフラックス(線流量).~
hz は水位(eta)?
#codeprettify(lang-fortran){{
type wave_arrays
real(kind=8), allocatable, dimension(:,:) :: fx
real(kind=8), allocatable, dimension(:,:) :: fy
real(kind=8), allocatable, dimension(:,:) :: hz
! === Flood Change ======================================...
real(kind=8), allocatable, dimension(:,:) :: hz_old
! =======================================================...
! === DEBUG for wave height gap on nest boundary. 2012/10...
! real(kind=8), allocatable, dimension(:) :: fx_old
real(kind=8), allocatable, dimension(:,:) :: fx_old
! =======================================================...
! === DEBUG for wave height gap on nest boundary. 2012/10...
! real(kind=8), allocatable, dimension(:) :: fy_old
real(kind=8), allocatable, dimension(:,:) :: fy_old
! =======================================================...
! === Dispersive ========================================...
real(kind=8), allocatable, dimension(:,:) :: yu, yv ! ...
real(kind=8), allocatable, dimension(:,:) :: cu, cv ! ...
! =======================================================...
! === Absorbing boundary condition ======================...
real(kind=8), allocatable, dimension(:,:) :: abc
! =======================================================...
! === Optimization ======================================...
real(kind=8), allocatable, dimension(:,:) :: tdx, tdy
! =======================================================...
! === Arrival time ======================================...
integer(kind=4), allocatable, dimension(:,:) :: arrive...
real(kind=8), allocatable, dimension(:,:) :: arrival_t...
! =======================================================...
integer(kind=4), allocatable, dimension(:,:) :: ir
real(kind=8), allocatable, dimension(:,:) :: btx, bty
integer(kind=4), allocatable, dimension(:,:) :: broken...
end type wave_arrays
}}
***depth_arrays [#e9e21b6a]
dz は水深 (dx, dy は半メッシュズレた水深?).~
wave_arrays の hz と depth_arrays の dz を足すとで全水深?
#codeprettify(lang-fortran){{
type depth_arrays
real(kind=8), allocatable, dimension(:,:) :: dx
real(kind=8), allocatable, dimension(:,:) :: dy
real(kind=8), allocatable, dimension(:,:) :: dz
real(kind=8), allocatable, dimension(:,:) :: dx_old
real(kind=8), allocatable, dimension(:,:) :: dy_old
real(kind=8), allocatable, dimension(:,:) :: dxbx
real(kind=8), allocatable, dimension(:,:) :: dyby
end type depth_arrays
}}
Page:
Edit with a page name which already exists