Chombo + EB  3.2
Classes | Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | List of all members
EBStenVarCoef Class Reference

#include <EBStenVarCoef.H>

Classes

struct  destTerm_t
 
struct  stencilTerm
 
struct  varcsten_t
 

Public Member Functions

 ~EBStenVarCoef ()
 
 EBStenVarCoef (const Vector< VolIndex > &a_srcVofs, const BaseIVFAB< VoFStencil > &a_vofstencil, const Box &a_validBox, const EBISBox &a_ebisbox, const IntVect &a_ghostVect, int a_varDest)
 
void apply (EBCellFAB &a_lofphi, const EBCellFAB &a_phi, const EBCellFAB &a_alphaWeight, const Real &a_alpha, const EBCellFAB &a_betaWeight, const Real &a_beta)
 
void relax (EBCellFAB &a_phi, const EBCellFAB &a_rhs, const EBCellFAB &a_alphaWeight, const EBCellFAB &a_betaWeight, const EBCellFAB &a_lambda, Real a_alpha, Real a_beta) const
 
void cache (const EBCellFAB &a_phi, int ivar)
 
void uncache (EBCellFAB &a_phi, int ivar) const
 

Protected Member Functions

void computeOffsets (const Vector< VolIndex > &a_srcVoFs, const BaseIVFAB< VoFStencil > &a_vofstencil)
 

Protected Attributes

Box m_box
 
EBISBox m_ebisBox
 
Box m_grownBox
 
IntVect m_ghostVect
 
int m_destVar
 
Vector< varcsten_t > m_stencil
 
Vector< destTerm_t > m_destTerms
 
Vector< destTerm_t > m_sourTerms
 
Vector< Real > m_cache
 
Vector< Real > m_cachePhi
 
Vector< VolIndex > m_srcVoFs
 

Private Member Functions

 EBStenVarCoef ()
 weak construction is bad More...
 
void operator= (const EBStenVarCoef &stenin)
 object contains pointered data. assignment is a bad idea More...
 
 EBStenVarCoef (const EBStenVarCoef &stenin)
 object contains pointered data. copy construction is a bad idea More...
 

Detailed Description

EBStencil variant specifically for the needs of single-level variable coefficent elliptic operators. There is only one way to make it. Everyone has to have the same number of ghost cells. There is only one way to use it. If you want something more flexible, use EBStencil.

Constructor & Destructor Documentation

◆ ~EBStenVarCoef()

EBStenVarCoef::~EBStenVarCoef ( )
inline

Destructor

References apply(), cache(), EBStenVarCoef(), relax(), and uncache().

◆ EBStenVarCoef() [1/3]

EBStenVarCoef::EBStenVarCoef ( const Vector< VolIndex > &  a_srcVofs,
const BaseIVFAB< VoFStencil > &  a_vofstencil,
const Box &  a_validBox,
const EBISBox &  a_ebisbox,
const IntVect &  a_ghostVect,
int  a_varDest 
)

srcVofs = list of vofs for which the stencil will be applied vofstencil = stencil for the divergence(F) validBox = valid cells (box from the DBL) ghostVect = number of ghost cells (for both phi, L(phi), rho, lambda, everything) ebisbox = geometric information varDest = variable of lphi

◆ EBStenVarCoef() [2/3]

EBStenVarCoef::EBStenVarCoef ( )
inlineprivate

weak construction is bad

References MayDay::Error().

Referenced by ~EBStenVarCoef().

◆ EBStenVarCoef() [3/3]

EBStenVarCoef::EBStenVarCoef ( const EBStenVarCoef &  stenin)
inlineprivate

object contains pointered data. copy construction is a bad idea

References MayDay::Error().

Member Function Documentation

◆ apply()

void EBStenVarCoef::apply ( EBCellFAB &  a_lofphi,
const EBCellFAB &  a_phi,
const EBCellFAB &  a_alphaWeight,
const Real &  a_alpha,
const EBCellFAB &  a_betaWeight,
const Real &  a_beta 
)

lphi = alpha*alphaWeight*phi + beta*betaWeight*(div(F)) The offsets of this object compute divF. lofphi = result phi = phi alphaWeight = variable coefficient factor of the identity term alpha = constant coefficient factor of the identity term betaWeight = variable coefficient factor of the div(F) term beta = constant coefficient factor of the div(F) term

Referenced by ~EBStenVarCoef().

◆ relax()

void EBStenVarCoef::relax ( EBCellFAB &  a_phi,
const EBCellFAB &  a_rhs,
const EBCellFAB &  a_alphaWeight,
const EBCellFAB &  a_betaWeight,
const EBCellFAB &  a_lambda,
Real  a_alpha,
Real  a_beta 
) const

phi := phi + lambda*(lphi-rhs) where lphi = alpha*alphaWeight*phi + beta*betaWeight*(div(F)) The offsets of this object compute divF. lofphi = result phi = phi alphaWeight = variable coefficient factor of the identity term alpha = constant coefficient factor of the identity term betaWeight = variable coefficient factor of the div(F) term beta = constant coefficient factor of the div(F) term lambda = relaxation coefficient

Referenced by ~EBStenVarCoef().

◆ cache()

void EBStenVarCoef::cache ( const EBCellFAB &  a_phi,
int  ivar 
)

Cache the irregular values of the input

Referenced by ~EBStenVarCoef().

◆ uncache()

void EBStenVarCoef::uncache ( EBCellFAB &  a_phi,
int  ivar 
) const

take values of internal cache and put them into phi

Referenced by ~EBStenVarCoef().

◆ computeOffsets()

void EBStenVarCoef::computeOffsets ( const Vector< VolIndex > &  a_srcVoFs,
const BaseIVFAB< VoFStencil > &  a_vofstencil 
)
protected

◆ operator=()

void EBStenVarCoef::operator= ( const EBStenVarCoef &  stenin)
inlineprivate

object contains pointered data. assignment is a bad idea

References MayDay::Error().

Member Data Documentation

◆ m_box

Box EBStenVarCoef::m_box
protected

◆ m_ebisBox

EBISBox EBStenVarCoef::m_ebisBox
protected

◆ m_grownBox

Box EBStenVarCoef::m_grownBox
protected

◆ m_ghostVect

IntVect EBStenVarCoef::m_ghostVect
protected

◆ m_destVar

int EBStenVarCoef::m_destVar
protected

◆ m_stencil

Vector<varcsten_t> EBStenVarCoef::m_stencil
protected

◆ m_destTerms

Vector<destTerm_t> EBStenVarCoef::m_destTerms
protected

◆ m_sourTerms

Vector<destTerm_t> EBStenVarCoef::m_sourTerms
protected

◆ m_cache

Vector<Real> EBStenVarCoef::m_cache
mutableprotected

◆ m_cachePhi

Vector<Real> EBStenVarCoef::m_cachePhi
mutableprotected

◆ m_srcVoFs

Vector<VolIndex> EBStenVarCoef::m_srcVoFs
protected

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