1# 1 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
30 type(
integer_field),
dimension(1:num_dims,1:2),
intent(inout) :: bc_type
31 integer,
intent(in) :: patch_id
36 if (
patch_bc(patch_id)%dir == 1)
then
44# 44 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
45 if (
patch_bc(patch_id)%loc == -1 .and.
bc_x%beg < 0)
then
48 bc_type(1, 1)%sf(0,
j, 0) =
patch_bc(patch_id)%type
52# 44 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
56 bc_type(1, 2)%sf(0,
j, 0) =
patch_bc(patch_id)%type
60# 52 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
64 if (
patch_bc(patch_id)%dir == 2)
then
72# 64 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
73 if (
patch_bc(patch_id)%loc == -1 .and.
bc_y%beg < 0)
then
76 bc_type(2, 1)%sf(
j, 0, 0) =
patch_bc(patch_id)%type
80# 64 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
84 bc_type(2, 2)%sf(
j, 0, 0) =
patch_bc(patch_id)%type
88# 72 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
96 type(
integer_field),
dimension(1:num_dims,1:2),
intent(inout) :: bc_type
97 integer,
intent(in) :: patch_id
100 if (
patch_bc(patch_id)%dir == 1)
then
105# 89 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
106 if (
patch_bc(patch_id)%loc == -1 .and.
bc_x%beg < 0)
then
110 bc_type(1, 1)%sf(0,
j,
k) =
patch_bc(patch_id)%type
115# 89 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
116 if (
patch_bc(patch_id)%loc == 1 .and.
bc_x%end < 0)
then
120 bc_type(1, 2)%sf(0,
j,
k) =
patch_bc(patch_id)%type
125# 99 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
127 if (
patch_bc(patch_id)%dir == 2)
then
132# 106 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
133 if (
patch_bc(patch_id)%loc == -1 .and.
bc_y%beg < 0)
then
137 bc_type(2, 1)%sf(
j, 0,
k) =
patch_bc(patch_id)%type
142# 106 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
143 if (
patch_bc(patch_id)%loc == 1 .and.
bc_y%end < 0)
then
147 bc_type(2, 2)%sf(
j, 0,
k) =
patch_bc(patch_id)%type
152# 116 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
154 if (
patch_bc(patch_id)%dir == 3)
then
158# 122 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
159 if (
patch_bc(patch_id)%loc == -1 .and.
bc_z%beg < 0)
then
163 bc_type(3, 1)%sf(
j,
k, 0) =
patch_bc(patch_id)%type
168# 122 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
169 if (
patch_bc(patch_id)%loc == 1 .and.
bc_z%end < 0)
then
173 bc_type(3, 2)%sf(
j,
k, 0) =
patch_bc(patch_id)%type
178# 132 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
186 type(
integer_field),
dimension(1:num_dims,1:2),
intent(inout) :: bc_type
187 integer,
intent(in) :: patch_id
190 if (
patch_bc(patch_id)%dir == 1)
then
202# 156 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
203 if (
patch_bc(patch_id)%loc == -1 .and.
bc_x%beg < 0)
then
208 bc_type(1, 1)%sf(0,
j,
k) =
patch_bc(patch_id)%type
213# 156 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
214 if (
patch_bc(patch_id)%loc == 1 .and.
bc_x%end < 0)
then
219 bc_type(1, 2)%sf(0,
j,
k) =
patch_bc(patch_id)%type
224# 167 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
226 if (
patch_bc(patch_id)%dir == 2)
then
238# 181 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
239 if (
patch_bc(patch_id)%loc == -1 .and.
bc_y%beg < 0)
then
244 bc_type(2, 1)%sf(
j, 0,
k) =
patch_bc(patch_id)%type
249# 181 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
250 if (
patch_bc(patch_id)%loc == 1 .and.
bc_y%end < 0)
then
255 bc_type(2, 2)%sf(
j, 0,
k) =
patch_bc(patch_id)%type
260# 192 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
262 if (
patch_bc(patch_id)%dir == 3)
then
273# 205 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
274 if (
patch_bc(patch_id)%loc == -1 .and.
bc_z%beg < 0)
then
279 bc_type(3, 1)%sf(
j,
k, 0) =
patch_bc(patch_id)%type
284# 205 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
285 if (
patch_bc(patch_id)%loc == 1 .and.
bc_z%end < 0)
then
290 bc_type(3, 2)%sf(
j,
k, 0) =
patch_bc(patch_id)%type
295# 216 "/home/runner/work/MFC/MFC/src/pre_process/m_boundary_conditions.fpp"
312 print *,
'Processing boundary condition patch', i
317 else if (
patch_bc(i)%geometry == 3)
then
325 print *,
'Processing boundary condition patch', i
Noncharacteristic and processor boundary condition application for ghost cells and buffer regions.
Applies spatially varying boundary condition patches along domain edges and faces.
type(bounds_info) z_boundary
impure subroutine, public s_apply_boundary_patches(q_prim_vf, bc_type)
Iterate over all boundary condition patches and dispatch them by geometry type.
impure subroutine s_circle_bc(patch_id, bc_type)
Apply a circular boundary condition patch on a domain face in 3D.
impure subroutine s_line_segment_bc(patch_id, bc_type)
Apply a line-segment boundary condition patch along a domain edge in 2D.
impure subroutine s_rectangle_bc(patch_id, bc_type)
Apply a rectangular boundary condition patch on a domain face in 3D.
type(bounds_info) y_boundary
type(bounds_info) x_boundary
Platform-specific file and directory operations: create, delete, inquire, getcwd, and basename.
Rank-staggered file access delays to prevent I/O contention on parallel file systems.
Shared derived types for field data, patch geometry, bubble dynamics, and MPI I/O structures.
Defines global parameters for the computational domain, simulation algorithm, and initial conditions.
type(int_bounds_info) bc_z
Boundary conditions in the x-, y- and z-coordinate directions.
real(wp), dimension(:), allocatable y_cc
integer proc_rank
Rank of the local processor Number of cells in the x-, y- and z-coordinate directions.
integer num_bc_patches
Number of boundary condition patches.
type(bc_patch_parameters), dimension(num_bc_patches_max) patch_bc
Boundary condition patch parameters.
type(int_bounds_info) bc_y
real(wp), dimension(:), allocatable x_cc
Locations of cell-centers (cc) in x-, y- and z-directions, respectively.
type(int_bounds_info) bc_x
real(wp), dimension(:), allocatable z_cc
Derived type adding beginning (beg) and end bounds info as attributes.
Derived type annexing an integer scalar field (SF).
Derived type annexing a scalar field (SF).