IGMBaseLib 1.0
|
00001 00017 module IcGrid2D_FVM_Builder 00018 00019 ! モジュール引用 ; Use statements 00020 ! 00021 00022 ! 種類型パラメタ 00023 ! Kind type parameter 00024 ! 00025 use dc_types, only: DP ! 倍精度実数型. Double precision 00026 00027 ! 正二十面格子データの管理 00028 ! Manage of icosahedral grid data 00029 ! 00030 use IcGrid2D_FVM_Manager, only: & 00031 & IcGrid2D_FVM, & 00032 & IcGrid2D_FVM_Init, malloc_GP_array, malloc_CV_array, & 00033 & GTYPE_STDGRID, GTYPE_STDGCGRID, GTYPE_SPRGCGRID 00034 00035 ! STD-grid の構築 00036 ! STD-grid construction 00037 ! 00038 use STDGrid_Builder, only: & 00039 & construct_STDGrid, calc_CV_vertex, calc_CV_Area 00040 00041 ! STD-GC-grid の構築 00042 ! STD-GC-grid construction 00043 ! 00044 use STDGCGrid_Builder, only: & 00045 & construct_STDGCGrid 00046 00047 ! SPR-GC-grid の構築 00048 ! SPR-GC-grid construction 00049 ! 00050 use SPRGCGrid_Builder, only: & 00051 & construct_SPRGCGrid, set_iteration_limiter 00052 00053 ! 宣言文 ; Declaration statements 00054 ! 00055 implicit none 00056 private 00057 00058 ! 公開手続き 00059 ! Public procedures 00060 ! 00061 public :: construct_icosahedral_grid 00062 public :: calc_CV_vertex, calc_CV_Area ! Cascade 00063 public :: GTYPE_STDGRID, GTYPE_STDGCGRID, GTYPE_SPRGCGRID ! Cascade 00064 public :: set_iteration_limiter ! Cascade ( SPRGCGrid_Builder module) 00065 00066 ! interface 文 ; interface statements 00067 ! 00068 interface construct_icosahedral_grid 00069 module procedure construct_icosahedral_grid1 00070 module procedure construct_icosahedral_grid2 00071 end interface construct_icosahedral_grid 00072 00073 contains 00074 00075 ! 00094 subroutine construct_icosahedral_grid1( & 00095 & grid_type, glevel, ic_radius, & ! (in) 00096 & icgrid & ! (out) 00097 & ) 00098 00099 ! 宣言文 ; Declaration statements 00100 ! 00101 integer, intent(in) :: grid_type 00102 integer, intent(in) :: glevel 00103 real(DP), intent(in) :: ic_radius 00104 type(IcGrid2D_FVM), intent(out) :: icgrid 00105 00106 ! 実行文 ; Executable statements 00107 ! 00108 00109 call IcGrid2D_FVM_Init(icgrid, glevel, ic_radius) 00110 call malloc_GP_array(icgrid) 00111 call malloc_CV_array(icgrid) 00112 00113 call construct_icosahedral_grid2(grid_type, icgrid) 00114 00115 end subroutine construct_icosahedral_grid1 00116 00117 ! 00131 subroutine construct_icosahedral_grid2( & 00132 & grid_type, & ! (in) 00133 & icgrid & ! (inout) 00134 & ) 00135 00136 ! 宣言文 ; Declaration statements 00137 ! 00138 integer, intent(in) :: grid_type 00139 type(IcGrid2D_FVM), intent(inout) :: icgrid 00140 00141 00142 ! 実行文 ; Executable statements 00143 ! 00144 00145 ! 指定された正二十面格子の種類に合わせて, 格子を生成する. 00146 ! 00147 select case (grid_type) 00148 case (GTYPE_STDGRID) 00149 ! STD-grid の構築 00150 call construct_STDGrid(icgrid) 00151 00152 case (GTYPE_STDGCGRID) 00153 ! STD-GC-grid の構築 00154 call construct_STDGCGrid(icgrid) 00155 00156 case (GTYPE_SPRGCGRID) 00157 ! SPR-GC-grid の構築 00158 call construct_SPRGCGrid(icgrid) 00159 00160 case default 00161 00162 end select 00163 00164 end subroutine construct_icosahedral_grid2 00165 00166 00167 end module IcGrid2D_FVM_Builder