Chombo + EB  3.0
Protected Member Functions | Protected Attributes | List of all members
DomainNodeBC Class Reference

Class to enforce boundary conditions. More...

#include <NodeBC.H>

Public Member Functions

Constructors, destructor and defines
 DomainNodeBC ()
 
 ~DomainNodeBC ()
 
DomainNodeBCoperator= (const DomainNodeBC &)
 
 DomainNodeBC (const DomainNodeBC &)
 
Access functions
const FaceNodeBCoperator() (int direction, Side::LoHiSide side) const
 
Setting functions
void setFaceNodeBC (const FaceNodeBC &a_bc)
 
Functions to apply boundary conditions
void applyHomogeneousBCs (NodeFArrayBox &a_state, const ProblemDomain &a_domain, Real a_dx) const
 
void applyHomogeneousBCs (NodeFArrayBox &a_state, const Box &a_domain, Real a_dx) const
 
void applyInhomogeneousBCs (NodeFArrayBox &a_state, const ProblemDomain &a_domain, Real a_dx) const
 
void applyInhomogeneousBCs (NodeFArrayBox &a_state, const Box &a_domain, Real a_dx) const
 

Protected Member Functions

bool isBCDefined (int a_dir, const Side::LoHiSide a_side) const
 
void resetFaceNodeBC (const int a_dir, const Side::LoHiSide a_side)
 

Protected Attributes

Tuple< FaceNodeBC *, SpaceDimm_loBC
 
Tuple< FaceNodeBC *, SpaceDimm_hiBC
 

Detailed Description

Class to enforce boundary conditions.

This class holds a domain's worth of FaceNodeBCs, one for each face of the physical domain. The user adds a FaceNodeBC-derived class for each face to enforce boundary conditions.

If the solution is phi and the face normal direction is x, the boundary conditions at a face are expressed as
A*dphi/dx + B*phi = C.

The class derived from FaceNodeBC provides a function to to fill A and B and C. DomainNodeBC calls this function and fills the boundary nodes appropriately.

Constructor & Destructor Documentation

DomainNodeBC::DomainNodeBC ( )

Empty constructor. Need to assign boundary conditions for each face with calls to setFaceNodeBC().

DomainNodeBC::~DomainNodeBC ( )

Destructor.

DomainNodeBC::DomainNodeBC ( const DomainNodeBC )

Copy constructor.

Member Function Documentation

DomainNodeBC& DomainNodeBC::operator= ( const DomainNodeBC )

Assignment, copies input.

const FaceNodeBC& DomainNodeBC::operator() ( int  direction,
Side::LoHiSide  side 
) const

Retrieve FaceNodeBC for a particular face.

void DomainNodeBC::setFaceNodeBC ( const FaceNodeBC a_bc)

Set boundary condition object at a face.

void DomainNodeBC::applyHomogeneousBCs ( NodeFArrayBox a_state,
const ProblemDomain a_domain,
Real  a_dx 
) const

Apply homogeneous boundary conditions on all faces of physical domain.

Parameters
a_statearray on which boundary conditions will be applied
a_domainCELL-centered physical domain
a_dxmesh spacing
void DomainNodeBC::applyHomogeneousBCs ( NodeFArrayBox a_state,
const Box a_domain,
Real  a_dx 
) const

Apply homogeneous boundary conditions on all faces of physical domain.

Parameters
a_statearray on which boundary conditions will be applied
a_domainCELL-centered physical domain
a_dxmesh spacing
void DomainNodeBC::applyInhomogeneousBCs ( NodeFArrayBox a_state,
const ProblemDomain a_domain,
Real  a_dx 
) const

Apply inhomogeneous boundary conditions on all faces of physical domain.

Parameters
a_statearray on which boundary conditions will be applied
a_domainCELL-centered physical domain
a_dxmesh spacing
void DomainNodeBC::applyInhomogeneousBCs ( NodeFArrayBox a_state,
const Box a_domain,
Real  a_dx 
) const

Apply inhomogeneous boundary conditions on all faces of physical domain.

Parameters
a_statearray on which boundary conditions will be applied
a_domainCELL-centered physical domain
a_dxmesh spacing
bool DomainNodeBC::isBCDefined ( int  a_dir,
const Side::LoHiSide  a_side 
) const
protected

Return true if the FaceNodeBC for the specified face is defined.

void DomainNodeBC::resetFaceNodeBC ( const int  a_dir,
const Side::LoHiSide  a_side 
)
protected

Reset the FaceNodeBC for the specified face to NULL.

Member Data Documentation

Tuple<FaceNodeBC*, SpaceDim> DomainNodeBC::m_loBC
protected
Tuple<FaceNodeBC*, SpaceDim> DomainNodeBC::m_hiBC
protected

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