IBAMR
An adaptive and distributed-memory parallel implementation of the immersed boundary (IB) method
Public Member Functions | List of all members
IBTK::RobinPhysBdryPatchStrategy Class Reference

Class RobinPhysBdryPatchStrategy is an abstract strategy class that extends the SAMRAI::xfer::RefinePatchStrategy interface to provide routines specific for setting Robin boundary conditions at physical boundaries. This class also provides default implementations of some methods defined in SAMRAI::xfer::RefinePatchStrategy that are generally not needed for filling ghost cell values at physical boundaries. More...

#include </home/runner/work/IBAMR/IBAMR/ibtk/include/ibtk/RobinPhysBdryPatchStrategy.h>

Inheritance diagram for IBTK::RobinPhysBdryPatchStrategy:
Inheritance graph
[legend]

Public Member Functions

 RobinPhysBdryPatchStrategy ()=default
 Default constructor.
 
 ~RobinPhysBdryPatchStrategy ()=default
 Destructor.
 
void setPatchDataIndex (int patch_data_index)
 Reset the patch data index operated upon by this class.
 
void setPatchDataIndices (const std::set< int > &patch_data_indices)
 Reset the patch data indices operated upon by this class.
 
void setPatchDataIndices (const SAMRAI::hier::ComponentSelector &patch_data_indices)
 Reset the patch data indices operated upon by this class.
 
void setPhysicalBcCoef (SAMRAI::solv::RobinBcCoefStrategy< NDIM > *bc_coef)
 Reset the Robin boundary condition specification object employed by this class to set physical boundary conditions. More...
 
void setPhysicalBcCoefs (const std::vector< SAMRAI::solv::RobinBcCoefStrategy< NDIM > * > &bc_coefs)
 Reset the Robin boundary condition specification object employed by this class to set physical boundary conditions. More...
 
void setHomogeneousBc (bool homogeneous_bc)
 Set whether boundary filling should employ homogeneous boundary conditions. More...
 
bool getHomogeneousBc () const
 
- Public Member Functions inherited from SAMRAI::xfer::RefinePatchStrategy< NDIM >
virtual void setPhysicalBoundaryConditions (hier::Patch< NDIM > &patch, const double fill_time, const hier::IntVector< NDIM > &ghost_width_to_fill)=0
 
virtual hier::IntVector< NDIM > getRefineOpStencilWidth () const=0
 
virtual void preprocessRefineBoxes (hier::Patch< NDIM > &fine, const hier::Patch< NDIM > &coarse, const hier::BoxList< NDIM > &fine_boxes, const hier::IntVector< NDIM > &ratio)
 
virtual void postprocessRefineBoxes (hier::Patch< NDIM > &fine, const hier::Patch< NDIM > &coarse, const hier::BoxList< NDIM > &fine_boxes, const hier::IntVector< NDIM > &ratio)
 

Partial implementation of SAMRAI::xfer::RefinePatchStrategy

interface.

std::set< int > d_patch_data_indices
 
std::vector< SAMRAI::solv::RobinBcCoefStrategy< NDIM > * > d_bc_coefs
 
bool d_homogeneous_bc = false
 
void preprocessRefine (SAMRAI::hier::Patch< NDIM > &fine, const SAMRAI::hier::Patch< NDIM > &coarse, const SAMRAI::hier::Box< NDIM > &fine_box, const SAMRAI::hier::IntVector< NDIM > &ratio) override
 
void postprocessRefine (SAMRAI::hier::Patch< NDIM > &fine, const SAMRAI::hier::Patch< NDIM > &coarse, const SAMRAI::hier::Box< NDIM > &fine_box, const SAMRAI::hier::IntVector< NDIM > &ratio) override
 
virtual void accumulateFromPhysicalBoundaryData (SAMRAI::hier::Patch< NDIM > &patch, double fill_time, const SAMRAI::hier::IntVector< NDIM > &ghost_width_to_fill)
 

Detailed Description

Class RobinPhysBdryPatchStrategy is an abstract strategy class that extends the SAMRAI::xfer::RefinePatchStrategy interface to provide routines specific for setting Robin boundary conditions at physical boundaries. This class also provides default implementations of some methods defined in SAMRAI::xfer::RefinePatchStrategy that are generally not needed for filling ghost cell values at physical boundaries.

Member Function Documentation

◆ accumulateFromPhysicalBoundaryData()

void IBTK::RobinPhysBdryPatchStrategy::accumulateFromPhysicalBoundaryData ( SAMRAI::hier::Patch< NDIM > &  patch,
double  fill_time,
const SAMRAI::hier::IntVector< NDIM > &  ghost_width_to_fill 
)
virtual

Function to accumulate data near physical boundaries from values set in the ghost cell region using the adjoint of the operator used to extrapolate the ghost cell values. This function can be used to construct the adjoint of linear operators that use ghost cell data.

Note
A default implementation is provided that emits an error message.
Parameters
patchPatch on which to fill boundary data.
fill_timeDouble simulation time for boundary filling.
ghost_width_to_fillInteger vector describing maximum ghost width to fill over all registered scratch components.

Reimplemented in IBTK::CartSideRobinPhysBdryOp, and IBTK::CartCellRobinPhysBdryOp.

◆ getHomogeneousBc()

bool IBTK::RobinPhysBdryPatchStrategy::getHomogeneousBc ( ) const
Returns
Whether boundary filling employs homogeneous boundary conditions.

◆ postprocessRefine()

void IBTK::RobinPhysBdryPatchStrategy::postprocessRefine ( SAMRAI::hier::Patch< NDIM > &  fine,
const SAMRAI::hier::Patch< NDIM > &  coarse,
const SAMRAI::hier::Box< NDIM > &  fine_box,
const SAMRAI::hier::IntVector< NDIM > &  ratio 
)
overridevirtual

Function to perform user-defined postprocess data refine operations. This member function is called after standard refine operations (expressed using concrete subclasses of the SAMRAI::xfer::RefineOperator base class). The postprocess function must refine data from the scratch components of the coarse patch into the scratch components of the fine patch on the specified fine box region. Recall that the scratch components are specified in calls to the registerRefine() function in the SAMRAI::xfer::RefineAlgorithm class.

The implementation does nothing. This behavior can be overridden by subclasses.

Parameters
fineFine patch containing destination data.
coarseCoarse patch containing source data.
fine_boxBox region on fine patch into which data is refined.
ratioInteger vector containing ratio relating index space between coarse and fine patches.

Implements SAMRAI::xfer::RefinePatchStrategy< NDIM >.

◆ preprocessRefine()

void IBTK::RobinPhysBdryPatchStrategy::preprocessRefine ( SAMRAI::hier::Patch< NDIM > &  fine,
const SAMRAI::hier::Patch< NDIM > &  coarse,
const SAMRAI::hier::Box< NDIM > &  fine_box,
const SAMRAI::hier::IntVector< NDIM > &  ratio 
)
overridevirtual

Function to perform user-defined preprocess data refine operations. This member function is called before standard refine operations (expressed using concrete subclasses of the SAMRAI::xfer::RefineOperator base class). The preprocess function must refine data from the scratch components of the coarse patch into the scratch components of the fine patch on the specified fine box region. Recall that the scratch components are specified in calls to the registerRefine() function in the SAMRAI::xfer::RefineAlgorithm class.

The default implementation does nothing. This behavior can be overridden by subclasses.

Parameters
fineFine patch containing destination data.
coarseCoarse patch containing source data.
fine_boxBox region on fine patch into which data is refined.
ratioInteger vector containing ratio relating index space between coarse and fine patches.

Implements SAMRAI::xfer::RefinePatchStrategy< NDIM >.

◆ setHomogeneousBc()

void IBTK::RobinPhysBdryPatchStrategy::setHomogeneousBc ( bool  homogeneous_bc)

Set whether boundary filling should employ homogeneous boundary conditions.

Note
By default, inhomogeneous boundary conditions are assumed.

◆ setPhysicalBcCoef()

void IBTK::RobinPhysBdryPatchStrategy::setPhysicalBcCoef ( SAMRAI::solv::RobinBcCoefStrategy< NDIM > *  bc_coef)

Reset the Robin boundary condition specification object employed by this class to set physical boundary conditions.

Note
bc_coef cannot be NULL.

◆ setPhysicalBcCoefs()

void IBTK::RobinPhysBdryPatchStrategy::setPhysicalBcCoefs ( const std::vector< SAMRAI::solv::RobinBcCoefStrategy< NDIM > * > &  bc_coefs)

Reset the Robin boundary condition specification object employed by this class to set physical boundary conditions.

Note
None of the elements of bc_coefs can be NULL.

The documentation for this class was generated from the following files: