0.6.0
Loading...
Searching...
No Matches
mod_immersed_boundary_condition_tools Module Reference

Tools to manipulate immersed boundaries variables. More...

Data Types

interface  get_field_ghost_nodes_to_node_values
 
interface  ibc_extrapolate_dual
 
interface  set_field_ghost_nodes_to_boundary_value
 
interface  set_field_ghost_nodes_to_node_values
 
interface  set_field_ghost_nodes_to_outer_value
 
interface  set_field_outer_nodes_to_outer_value
 

Functions/Subroutines

subroutine set_field_ghost_nodes_homogeneous_neumann (field, ib_metrics)
 Set ghost node values considering homogeneous Neumann BC.
 
pure subroutine get_field_ghost_nodes_to_node_values_double (field, ib_metrics, node_values)
 Get ghost nodes nalues of field.
 
pure subroutine get_field_ghost_nodes_to_node_values_integer (field, ib_metrics, node_values)
 Get ghost nodes nalues of field.
 
pure subroutine get_field_ghost_nodes_to_node_values_logical (field, ib_metrics, node_values)
 Get ghost nodes nalues of field.
 
pure subroutine set_field_ghost_nodes_to_node_values_double (field, ib_metrics, node_values)
 Set ghost node values of double field to node_values.
 
pure subroutine set_field_ghost_nodes_to_node_values_integer (field, ib_metrics, node_values)
 Set ghost node values of integer field to node_values.
 
pure subroutine set_field_ghost_nodes_to_node_values_logical (field, ib_metrics, node_values)
 Set ghost node values of logical field to node_values.
 
subroutine set_field_ghost_nodes_to_boundary_value (field, ib_metrics, ibc_interp)
 Set ghost nodes of field to field values interpolated by ibc_interp.
 
subroutine set_field_ghost_nodes_to_boundary_value_face (field, ib_metrics, ibc_variable)
 
pure subroutine set_field_ghost_nodes_to_outer_value_base (field, ib_metrics, outer_value)
 Set ghost nodes of field to outer_value of ibc_variable.
 
pure subroutine set_field_ghost_nodes_to_outer_value_cell (field, equation_isd_target, ibc_variable, outer_value)
 
pure subroutine set_field_ghost_nodes_to_outer_value_face (field, equation_isd_target, ibc_variable, outer_value)
 
pure subroutine set_field_outer_nodes_to_outer_value_base (field, ib_metrics, outer_value)
 Set outer nodes of field to outer_value of ibc_variable.
 
pure subroutine set_field_outer_nodes_to_outer_value_cell (field, equation_isd_target, ibc_variable, outer_value)
 Set outer nodes of field to outer_value of ibc_variable.
 
pure subroutine set_field_outer_nodes_to_outer_value_face (field, equation_isd_target, ibc_variable, outer_value)
 
pure subroutine set_field_outer_nodes_to_outer_value_penalization (field, ib_metrics)
 
subroutine extrapolate_ibc_cell (field, ib_metrics, ibc_variable, solver, equation_stencil, ls_map, boundary_condition)
 
subroutine extrapolate_ibc_face (field, face_immersed_boundary, ibc_variable, solver, face_equation_stencil, face_ls_map, face_field_boundary_condition, ibm_explicit_extrapolation)
 Extrapolate field over the ghost nodes and apply bc.
 
subroutine ibc_extrapolate_dual (primal_node_type, dual_node_type, ib_metrics, ib_metrics_dual, dual_field)
 Mixed face-cell extrapolation.
 
subroutine ibc_extrapolate_dual_cell (ib_metrics_cell, face_immersed_boundary, face_field_)
 
subroutine ibc_extrapolate_dual_face (face_immersed_boundary, ib_metrics_cell, cell_field)
 

Detailed Description

Tools to manipulate immersed boundaries variables.

In the meantime, the following routines can be used to set ghost / outer node values in different ways:

  • set_field_ghost_nodes_to_condition: Replace ghost node values to the corresponding boundary value using ibc_interpolate. This is used to compute integrals.
  • set_field_ghost_nodes_to_outer / set_field_outer_nodes_to_outer: Replace ghost / outer node values to outer_value of the given ibc_variable argument.

Ghost nodes values can be extracted into some 1D array and put back using:

Interpolation of some field value at boundary points

The following routine does exactly that:

  • ibc_interpolate: Interpolate the given field to the boundary points.

Modification of ghost node values

Ghost nodes values can be extracted into some 1D array and put back using:

Function/Subroutine Documentation

◆ extrapolate_ibc_cell()

subroutine mod_immersed_boundary_condition_tools::extrapolate_ibc_cell ( double precision, dimension(:,:,:), intent(inout) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
class(t_immersed_boundary_condition), intent(in) ibc_variable,
class(t_linear_solver), intent(inout) solver,
type(t_cell_stencil), intent(in) equation_stencil,
type(t_ls_map), intent(in) ls_map,
type(t_boundary_condition), intent(in) boundary_condition )

◆ extrapolate_ibc_face()

subroutine mod_immersed_boundary_condition_tools::extrapolate_ibc_face ( type(t_face_field), intent(inout) field,
type(t_face_immersed_boundary_metrics), intent(in) face_immersed_boundary,
class(t_face_immersed_boundary_condition), intent(in) ibc_variable,
class(t_linear_solver), intent(inout) solver,
type(t_face_stencil), intent(in) face_equation_stencil,
type(t_face_ls_map), intent(in) face_ls_map,
type(t_boundary_condition_face), intent(in) face_field_boundary_condition,
logical, intent(in) ibm_explicit_extrapolation )

Extrapolate field over the ghost nodes and apply bc.

◆ get_field_ghost_nodes_to_node_values_double()

pure subroutine mod_immersed_boundary_condition_tools::get_field_ghost_nodes_to_node_values_double ( double precision, dimension(:,:,:), intent(in) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
double precision, dimension(:), intent(out) node_values )

Get ghost nodes nalues of field.

◆ get_field_ghost_nodes_to_node_values_integer()

pure subroutine mod_immersed_boundary_condition_tools::get_field_ghost_nodes_to_node_values_integer ( integer, dimension(:,:,:), intent(in) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
integer, dimension(:), intent(out) node_values )

Get ghost nodes nalues of field.

◆ get_field_ghost_nodes_to_node_values_logical()

pure subroutine mod_immersed_boundary_condition_tools::get_field_ghost_nodes_to_node_values_logical ( logical, dimension(:,:,:), intent(in) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
logical, dimension(:), intent(out) node_values )

Get ghost nodes nalues of field.

◆ ibc_extrapolate_dual()

subroutine mod_immersed_boundary_condition_tools::ibc_extrapolate_dual ( type(t_node_type), intent(in) primal_node_type,
type(t_node_type), intent(in) dual_node_type,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
type(t_immersed_boundary_metrics), intent(in) ib_metrics_dual,
double precision, dimension(:,:,:), intent(inout) dual_field )

Mixed face-cell extrapolation.

This routine set outer nodes of a dual field to apply discrete operator without harm. For instance, on a cell-centered ghost node:

─┼─∧─┼─
 > o >
─┼─∧─┼─

There may be a face-centered node which is an outer node. In that case, it is not possible to apply discrete operator such as face-to-cell interpolation or face-to-cell divergence. This routine extrapolate the dual field to make discrete operators appliable. Note that the opposite face-centered node is always a ghost node. The same problem occurs around the three face-centered ghost nodes:

───┼───     │ o │
 o > o     ─┼─∧─┼─    …
───┼───     │ o │

which are handled as well.

Currently, this routine simply copy the opposite-side ghost node value to the outer node value. A more elaborate extrapolation may be designed in the future.

◆ ibc_extrapolate_dual_cell()

subroutine mod_immersed_boundary_condition_tools::ibc_extrapolate_dual_cell ( type(t_immersed_boundary_metrics), intent(in) ib_metrics_cell,
type(t_face_immersed_boundary_metrics), intent(in) face_immersed_boundary,
type(t_face_field), intent(inout) face_field_ )

◆ ibc_extrapolate_dual_face()

subroutine mod_immersed_boundary_condition_tools::ibc_extrapolate_dual_face ( type(t_face_immersed_boundary_metrics), intent(in) face_immersed_boundary,
type(t_immersed_boundary_metrics), intent(in) ib_metrics_cell,
double precision, dimension(:,:,:), intent(inout) cell_field )

◆ set_field_ghost_nodes_homogeneous_neumann()

subroutine mod_immersed_boundary_condition_tools::set_field_ghost_nodes_homogeneous_neumann ( double precision, dimension(:,:,:), intent(out) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics )

Set ghost node values considering homogeneous Neumann BC.

Set ghost node values considering homogeneous Neumann BC Ghost value filled with first order gradient discretization

Case 1 \( n_x > 0\) and \( n_y > 0\), normal in top right

\[ \frac{\phi_{i+1,j} - \phi_{i,j}}{\Delta x} n_x + \frac{\phi_{i,j+1} - \phi_{i,j}}{\Delta y} n_y = 0 \]

◆ set_field_ghost_nodes_to_boundary_value()

subroutine mod_immersed_boundary_condition_tools::set_field_ghost_nodes_to_boundary_value ( double precision, dimension(:,:,:), intent(inout) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
type(t_immersed_boundary_condition), intent(in) ibc_interp )

Set ghost nodes of field to field values interpolated by ibc_interp.

Warning
Be sure to have an extrapolated field before using this!

◆ set_field_ghost_nodes_to_boundary_value_face()

subroutine mod_immersed_boundary_condition_tools::set_field_ghost_nodes_to_boundary_value_face ( type(t_face_field), intent(inout) field,
type(t_face_immersed_boundary_metrics), intent(in) ib_metrics,
type(t_face_immersed_boundary_condition), intent(in) ibc_variable )

◆ set_field_ghost_nodes_to_node_values_double()

pure subroutine mod_immersed_boundary_condition_tools::set_field_ghost_nodes_to_node_values_double ( double precision, dimension(:,:,:), intent(out) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
double precision, dimension(:), intent(in) node_values )

Set ghost node values of double field to node_values.

◆ set_field_ghost_nodes_to_node_values_integer()

pure subroutine mod_immersed_boundary_condition_tools::set_field_ghost_nodes_to_node_values_integer ( integer, dimension(:,:,:), intent(out) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
integer, dimension(:), intent(in) node_values )

Set ghost node values of integer field to node_values.

◆ set_field_ghost_nodes_to_node_values_logical()

pure subroutine mod_immersed_boundary_condition_tools::set_field_ghost_nodes_to_node_values_logical ( logical, dimension(:,:,:), intent(out) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
logical, dimension(:), intent(in) node_values )

Set ghost node values of logical field to node_values.

◆ set_field_ghost_nodes_to_outer_value_base()

pure subroutine mod_immersed_boundary_condition_tools::set_field_ghost_nodes_to_outer_value_base ( double precision, dimension(:,:,:), intent(inout) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
double precision, intent(in) outer_value )

Set ghost nodes of field to outer_value of ibc_variable.

◆ set_field_ghost_nodes_to_outer_value_cell()

pure subroutine mod_immersed_boundary_condition_tools::set_field_ghost_nodes_to_outer_value_cell ( double precision, dimension(:,:,:), intent(inout) field,
integer, dimension(:), intent(in) equation_isd_target,
type(t_immersed_boundary_condition), dimension(:), intent(in) ibc_variable,
double precision, intent(in), optional outer_value )

◆ set_field_ghost_nodes_to_outer_value_face()

pure subroutine mod_immersed_boundary_condition_tools::set_field_ghost_nodes_to_outer_value_face ( type(t_face_field), intent(inout) field,
integer, dimension(:), intent(in) equation_isd_target,
type(t_face_immersed_boundary_condition), dimension(:), intent(in) ibc_variable,
double precision, dimension(3), intent(in), optional outer_value )

◆ set_field_outer_nodes_to_outer_value_base()

pure subroutine mod_immersed_boundary_condition_tools::set_field_outer_nodes_to_outer_value_base ( double precision, dimension(:,:,:), intent(inout) field,
type(t_immersed_boundary_metrics), intent(in) ib_metrics,
double precision, intent(in) outer_value )

Set outer nodes of field to outer_value of ibc_variable.

◆ set_field_outer_nodes_to_outer_value_cell()

pure subroutine mod_immersed_boundary_condition_tools::set_field_outer_nodes_to_outer_value_cell ( double precision, dimension(:,:,:), intent(inout) field,
integer, dimension(:), intent(in) equation_isd_target,
type(t_immersed_boundary_condition), dimension(:), intent(in) ibc_variable,
double precision, intent(in), optional outer_value )

Set outer nodes of field to outer_value of ibc_variable.

◆ set_field_outer_nodes_to_outer_value_face()

pure subroutine mod_immersed_boundary_condition_tools::set_field_outer_nodes_to_outer_value_face ( type(t_face_field), intent(inout) field,
integer, dimension(:), intent(in) equation_isd_target,
type(t_face_immersed_boundary_condition), dimension(:), intent(in) ibc_variable,
double precision, dimension(3), intent(in), optional outer_value )

◆ set_field_outer_nodes_to_outer_value_penalization()

pure subroutine mod_immersed_boundary_condition_tools::set_field_outer_nodes_to_outer_value_penalization ( double precision, dimension(:,:,:), intent(inout) field,
type (t_immersed_boundary_metrics), intent(in) ib_metrics )