IBAMR  IBAMR version 0.19.
Public Member Functions | Private Member Functions | Private Attributes | List of all members
IBTK::NodeSynchCopyFillPattern Class Referenceabstract

Class NodeCellSynchCopyFillPattern is a concrete implementation of the abstract base class SAMRAI::xfer::VariableFillPattern. It is used to calculate overlaps according to a pattern which limits overlaps to the node-centered ghost region surrounding a patch appropriate for "synchronizing" node-centered values in an axis-by-axis manner at patch boundaries. More...

#include <ibtk/NodeSynchCopyFillPattern.h>

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

Public Member Functions

 NodeSynchCopyFillPattern (unsigned int axis)
 Constructor. More...
 
 ~NodeSynchCopyFillPattern ()=default
 Destructor. More...
 
SAMRAI::tbox::Pointer< SAMRAI::hier::BoxOverlap< NDIM > > calculateOverlap (const SAMRAI::hier::BoxGeometry< NDIM > &dst_geometry, const SAMRAI::hier::BoxGeometry< NDIM > &src_geometry, const SAMRAI::hier::Box< NDIM > &dst_patch_box, const SAMRAI::hier::Box< NDIM > &src_mask, bool overwrite_interior, const SAMRAI::hier::IntVector< NDIM > &src_offset) const override
 
SAMRAI::hier::IntVector< NDIM > & getStencilWidth () override
 
const std::string & getPatternName () const override
 
virtual tbox::Pointer< hier::BoxOverlap< DIM > > calculateOverlap (const hier::BoxGeometry< DIM > &dst_geometry, const hier::BoxGeometry< DIM > &src_geometry, const hier::Box< DIM > &dst_patch_box, const hier::Box< DIM > &src_mask, const bool overwrite_interior, const hier::IntVector< DIM > &src_offset) const=0
 
virtual tbox::Pointer< hier::BoxOverlap< DIM > > calculateOverlapOnLevel (const hier::BoxGeometry< DIM > &dst_geometry, const hier::BoxGeometry< DIM > &src_geometry, const hier::Box< DIM > &dst_patch_box, const hier::Box< DIM > &src_mask, const bool overwrite_interior, const hier::IntVector< DIM > &src_offset, const int dst_level_num, const int src_level_num) const
 
virtual void setTargetPatchLevelNumber (const int level_num)
 
virtual const std::string & getPatternName () const=0
 

Private Member Functions

 NodeSynchCopyFillPattern ()=delete
 Default constructor. More...
 
 NodeSynchCopyFillPattern (const NodeSynchCopyFillPattern &from)=delete
 Copy constructor. More...
 
NodeSynchCopyFillPatternoperator= (const NodeSynchCopyFillPattern &that)=delete
 Assignment operator. More...
 

Private Attributes

SAMRAI::hier::IntVector< NDIM > d_stencil_width = 1
 
const unsigned int d_axis
 

Detailed Description

Note
We synchronize data one axis at a time because node-centered values can be shared by more than two patches. For instance, to synchronize nodal values in three spatial dimensions, we first synchronize values in the x direction, then in the y direction, and finally in the z direction.

Constructor & Destructor Documentation

◆ NodeSynchCopyFillPattern() [1/3]

IBTK::NodeSynchCopyFillPattern::NodeSynchCopyFillPattern ( unsigned int  axis)

◆ ~NodeSynchCopyFillPattern()

IBTK::NodeSynchCopyFillPattern::~NodeSynchCopyFillPattern ( )
default

◆ NodeSynchCopyFillPattern() [2/3]

IBTK::NodeSynchCopyFillPattern::NodeSynchCopyFillPattern ( )
privatedelete
Note
This constructor is not implemented and should not be used.

◆ NodeSynchCopyFillPattern() [3/3]

IBTK::NodeSynchCopyFillPattern::NodeSynchCopyFillPattern ( const NodeSynchCopyFillPattern from)
privatedelete
Note
This constructor is not implemented and should not be used.
Parameters
fromThe value to copy to this object.

Member Function Documentation

◆ calculateOverlap() [1/2]

SAMRAI::tbox::Pointer<SAMRAI::hier::BoxOverlap<NDIM> > IBTK::NodeSynchCopyFillPattern::calculateOverlap ( const SAMRAI::hier::BoxGeometry< NDIM > &  dst_geometry,
const SAMRAI::hier::BoxGeometry< NDIM > &  src_geometry,
const SAMRAI::hier::Box< NDIM > &  dst_patch_box,
const SAMRAI::hier::Box< NDIM > &  src_mask,
bool  overwrite_interior,
const SAMRAI::hier::IntVector< NDIM > &  src_offset 
) const
override

Calculate overlaps between the destination and source geometries according to the desired pattern. This will return the portion of the intersection of the geometries that lies in the ghost region of the specified width surrounding the patch, excluding all edges and corners. The patch is identified by the argument dst_patch_box.

Parameters
dst_geometrygeometry object for destination box
src_geometrygeometry object for source box
dst_patch_boxbox for the destination patch
src_maskthe source mask, the box resulting from shifting the source box
overwrite_interiorcontrols whether or not to include the destination box interior in the overlap
src_offsetthe offset between source and destination index space (src + src_offset = dst)
Returns
pointer to the calculated overlap object

◆ getStencilWidth()

SAMRAI::hier::IntVector<NDIM>& IBTK::NodeSynchCopyFillPattern::getStencilWidth ( )
overridevirtual

Returns the stencil width.

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

◆ getPatternName() [1/2]

const std::string& IBTK::NodeSynchCopyFillPattern::getPatternName ( ) const
override

Returns a string name identifier "NODE_SYNCH_COPY_FILL_PATTERN".

◆ operator=()

NodeSynchCopyFillPattern& IBTK::NodeSynchCopyFillPattern::operator= ( const NodeSynchCopyFillPattern that)
privatedelete
Note
This operator is not implemented and should not be used.
Parameters
thatThe value to assign to this object.
Returns
A reference to this object.

◆ calculateOverlap() [2/2]

virtual tbox::Pointer< hier::BoxOverlap<DIM> > SAMRAI::xfer::VariableFillPattern< DIM >::calculateOverlap ( const hier::BoxGeometry< DIM > &  dst_geometry,
const hier::BoxGeometry< DIM > &  src_geometry,
const hier::Box< DIM > &  dst_patch_box,
const hier::Box< DIM > &  src_mask,
const bool  overwrite_interior,
const hier::IntVector< DIM > &  src_offset 
) const
pure virtualinherited

This pure virtual method provides an interface to calculate overlaps between the destination and source geometries.

Parameters
dst_geometrygeometry object for destination box
src_geometrygeometry object for source box
dst_patch_boxbox for the destination patch
src_maskthe source mask, the box resulting from shifting the source box
overwrite_interiorcontrols whether or not to include the destination box interior in the overlap
src_offsetthe offset between source and destination index space. src + src_offset = dst
Returns
Pointer to the calculated overlap object

◆ calculateOverlapOnLevel()

virtual tbox::Pointer< hier::BoxOverlap<DIM> > SAMRAI::xfer::VariableFillPattern< DIM >::calculateOverlapOnLevel ( const hier::BoxGeometry< DIM > &  dst_geometry,
const hier::BoxGeometry< DIM > &  src_geometry,
const hier::Box< DIM > &  dst_patch_box,
const hier::Box< DIM > &  src_mask,
const bool  overwrite_interior,
const hier::IntVector< DIM > &  src_offset,
const int  dst_level_num,
const int  src_level_num 
) const
virtualinherited

This virtual method provides an interface to calculate overlaps between the destination and source geometries on a specified level of the patch hierarchy.

Note
A default implementation is provided that simply calls the pure virtual method calculateOverlap() for implementations that are level independent.
Parameters
dst_geometrygeometry object for destination box
src_geometrygeometry object for source box
dst_patch_boxbox for the destination patch
src_maskthe source mask, the box resulting from shifting the source box
overwrite_interiorcontrols whether or not to include the destination box interior in the overlap
src_offsetthe offset between source and destination index space. src + src_offset = dst
dst_level_numthe level of the patch hierarchy on which the dst boxes are located
src_level_numthe level of the patch hierarchy on which the src boxes are located
Returns
Pointer to the calculated overlap object

◆ setTargetPatchLevelNumber()

virtual void SAMRAI::xfer::VariableFillPattern< DIM >::setTargetPatchLevelNumber ( const int  level_num)
virtualinherited

Set the target patch level number for the variable fill pattern. The default implementation is empty.

Reimplemented in IBTK::SideNoCornersFillPattern, and IBTK::CellNoCornersFillPattern.

◆ getPatternName() [2/2]

virtual const std::string& SAMRAI::xfer::VariableFillPattern< DIM >::getPatternName ( ) const
pure virtualinherited

Return a string name identifying the concrete subclass.

Member Data Documentation

◆ d_stencil_width

SAMRAI::hier::IntVector<NDIM> IBTK::NodeSynchCopyFillPattern::d_stencil_width = 1
private

◆ d_axis

const unsigned int IBTK::NodeSynchCopyFillPattern::d_axis
private

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