chombo-discharge
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
MFHelmholtzDirichletEBBC Class Reference

Class for making Dirichlet boundary conditions on the EB in a multifluid context. More...

#include <CD_MFHelmholtzDirichletEBBC.H>

Inheritance diagram for MFHelmholtzDirichletEBBC:
Inheritance graph
[legend]
Collaboration diagram for MFHelmholtzDirichletEBBC:
Collaboration graph
[legend]

Public Member Functions

 MFHelmholtzDirichletEBBC (const int a_phase, const RefCountedPtr< MFHelmholtzJumpBC > &a_jumpBC)
 Constructor. Must subsequently set value, order, and weight. More...
 
virtual ~MFHelmholtzDirichletEBBC ()
 Default constructor.
 
virtual void setValue (const Real a_value)
 Set the value on the EB. More...
 
virtual void setValue (const std::function< Real(const RealVect &a_pos)> &a_value)
 Set the value on the EB. More...
 
void setOrder (const int a_order)
 Set stencil order. More...
 
void setWeight (const int a_weight)
 Set stencil weight. More...
 
virtual void setDomainDropOrder (const int a_domainSize)
 Drop BC order if domain size is equal or below this.
 
- Public Member Functions inherited from MFHelmholtzEBBC
 MFHelmholtzEBBC ()=delete
 Disallowed weak constructor. Factory must call the other version.
 
 MFHelmholtzEBBC (const MFHelmholtzEBBC &a_other)=delete
 Disallowed copy constructor. Factory must call the other version.
 
 MFHelmholtzEBBC (const int a_phase, const RefCountedPtr< MFHelmholtzJumpBC > &a_jumpBC)
 Full constructor.
 
virtual ~MFHelmholtzEBBC ()
 Default constructor.
 
virtual void applyEBFlux (VoFIterator &a_vofit, EBCellFAB &a_Lphi, const EBCellFAB &a_phi, const BaseIVFAB< Real > &a_Bcoef, const DataIndex &a_dit, const Real &a_beta, const bool &a_homogeneousPhysBC) const override
 Apply the EB flux. This is the version that is called by EBHelmholtzOp. More...
 
- Public Member Functions inherited from EBHelmholtzEBBC
 EBHelmholtzEBBC ()
 Default constructor.
 
virtual ~EBHelmholtzEBBC ()
 Destructor.
 
 EBHelmholtzEBBC (const EBHelmholtzEBBC &a_other)=delete
 Disallowed – don't see why you would need it.
 
EBHelmholtzEBBCoperator= (const EBHelmholtzEBBC &a_other)=delete
 Disallowed - don't see why you would need it.
 
void define (const Location::Cell a_dataLocation, const EBLevelGrid &a_eblg, const RealVect &a_probLo, const Real &a_dx, const int a_ghostCF)
 Define function that is called by EBHelmholtzOp. More...
 
const LayoutData< BaseIVFAB< VoFStencil > > & getGradPhiStencils () const
 Get the stencil for computing the finite-volume approximation to kappa*Div(F). More...
 

Protected Member Functions

virtual void defineSinglePhase () override
 User define function.
 
virtual void applyEBFluxSinglePhase (VoFIterator &a_singlePhaseVofs, EBCellFAB &a_Lphi, const EBCellFAB &a_phi, const BaseIVFAB< Real > &a_Bcoef, const DataIndex &a_dit, const Real &a_beta, const bool &a_homogeneousPhysBC) const override
 Apply flux single phase. More...
 
- Protected Member Functions inherited from MFHelmholtzEBBC
void define () override final
 User define function.
 
void defineMultiPhase ()
 Define stuff for multi-phase.
 
void applyEBFluxMultiPhase (VoFIterator &a_multiPhaseVofs, EBCellFAB &a_Lphi, const EBCellFAB &a_phi, const BaseIVFAB< Real > &a_Bcoef, const DataIndex &a_dit, const Real &a_beta, const bool &a_homogeneousPhysBC) const
 Apply flux in multiphase cells. More...
 
virtual bool getLeastSquaresBoundaryGradStencil (std::pair< Real, VoFStencil > &a_stencil, const VolIndex &a_vof, const VofUtils::Neighborhood a_neighborhood, const DataIndex &a_dit, const int a_order, const int a_weight) const
 Get stencil with specified order. More...
 
- Protected Member Functions inherited from EBHelmholtzEBBC
bool isStencilValidCF (const VoFStencil &a_stencil, const DataIndex &a_dit) const
 Check if stencil is valid. More...
 
RealVect getBoundaryPosition (const VolIndex &a_vof, const DataIndex &a_dit) const
 Returns physical position at the boundary.
 
Real applyStencil (const VoFStencil &a_stencil, const EBCellFAB &a_phi) const
 Apply stencil to data holder and return result.
 

Protected Attributes

bool m_useConstant
 Use constant for BC.
 
bool m_useFunction
 Use function for BC value.
 
Real m_constantValue
 Value on EB.
 
int m_order
 Stencil order.
 
int m_weight
 Stencil weight.
 
int m_domainDropOrder
 Special flag for dropping stencil order when domains become coarser than this.
 
std::function< Real(const RealVect &a_pos)> m_functionValue
 Value on the EB. Does not apply to matching cells.
 
- Protected Attributes inherited from MFHelmholtzEBBC
RefCountedPtr< MFHelmholtzJumpBCm_jumpBC
 Jump bc object.
 
int m_phase
 Phase.
 
LayoutData< BaseIVFAB< Real > > m_boundaryWeights
 Weights for matching cells.
 
- Protected Attributes inherited from EBHelmholtzEBBC
Location::Cell m_dataLocation
 Data centering.
 
int m_ghostCF
 Number of ghost cells that were filled across CF interface.
 
Real m_dx
 Grid resolution.
 
RealVect m_probLo
 Lower-left corner of computational domain.
 
EBLevelGrid m_eblg
 Level grid.
 
LayoutData< BaseIVFAB< VoFStencil > > m_gradPhiStencils
 Stencils for computing the flux on a single level. This is a single-level object.
 

Additional Inherited Members

- Static Protected Attributes inherited from EBHelmholtzEBBC
constexpr static int m_comp = 0
 Component that everything is defined for. Always have m_comp = 0.
 
constexpr static int m_nComp = 1
 Number of components. Always have m_nComp = 1.
 

Detailed Description

Class for making Dirichlet boundary conditions on the EB in a multifluid context.

Constructor & Destructor Documentation

◆ MFHelmholtzDirichletEBBC()

MFHelmholtzDirichletEBBC::MFHelmholtzDirichletEBBC ( const int  a_phase,
const RefCountedPtr< MFHelmholtzJumpBC > &  a_jumpBC 
)

Constructor. Must subsequently set value, order, and weight.

Parameters
[in]a_phasePhase
[in]a_jumpBCJump BC object

Member Function Documentation

◆ applyEBFluxSinglePhase()

void MFHelmholtzDirichletEBBC::applyEBFluxSinglePhase ( VoFIterator &  a_singlePhaseVofs,
EBCellFAB &  a_Lphi,
const EBCellFAB &  a_phi,
const BaseIVFAB< Real > &  a_Bcoef,
const DataIndex &  a_dit,
const Real &  a_beta,
const bool &  a_homogeneousPhysBC 
) const
overrideprotectedvirtual

Apply flux single phase.

Parameters
[in,out]a_singlePhaseVofsIterator for single-phase cut-cells
[in,out]a_LphiOperator kappa*L(phi)
[in]a_phiPhi, cell-centered.
[in]a_BcoefEB-centered B-coefficient
[in]a_ditData index
[in]a_betaBeta. Passed in from operator.
[in]a_homogeneousPhysBCHomogeneous BC or not.

Implements MFHelmholtzEBBC.

◆ setOrder()

void MFHelmholtzDirichletEBBC::setOrder ( const int  a_order)

Set stencil order.

Parameters
[in]a_orderStencil order. Must be > 0

◆ setValue() [1/2]

void MFHelmholtzDirichletEBBC::setValue ( const Real  a_value)
virtual

Set the value on the EB.

Parameters
[in]a_valueConstant value on EB

◆ setValue() [2/2]

void MFHelmholtzDirichletEBBC::setValue ( const std::function< Real(const RealVect &a_pos)> &  a_value)
virtual

Set the value on the EB.

Parameters
[in]a_valueSpatially dependent value on EB

◆ setWeight()

void MFHelmholtzDirichletEBBC::setWeight ( const int  a_weight)

Set stencil weight.

Parameters
[in]a_orderStencil weight. Must be >= 0

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