Chombo + EB
3.2
|
EBFastFR-A class to encapsulate a levels worth of flux registers. More...
#include <EBFastFR.H>
Public Member Functions | |
EBFastFR () | |
EBFastFR (const EBLevelGrid &a_eblgFine, const EBLevelGrid &a_eblgCoar, const int &a_nref, const int &a_nvar, bool a_forceNoEBCF=false) | |
virtual | ~EBFastFR () |
virtual void | define (const EBLevelGrid &a_eblgFine, const EBLevelGrid &a_eblgCoar, const int &a_nref, const int &a_nvar, bool a_forceNoEBCF=false) |
virtual void | setToZero () |
virtual void | incrementCoarseBoth (const EBFaceFAB &a_coarseFlux, const Real &a_scale, const DataIndex &a_coarseDataIndex, const Interval &a_variables, const int &a_dir, const Side::LoHiSide &a_sd) |
virtual void | incrementFineBoth (const EBFaceFAB &a_fineFlux, const Real &a_scale, const DataIndex &a_fineDataIndex, const Interval &a_variables, const int &a_dir, const Side::LoHiSide &a_sd) |
void | compareFineSparse (const EBFaceFAB &a_fluxOld, const EBFaceFAB &a_fluxNew, const DataIndex &a_fineDatInd, const int &a_dir, const Side::LoHiSide &a_sd) |
virtual void | incrementFineSparse (const EBFaceFAB &a_fineFlux, const Real &a_scale, const DataIndex &a_fineDatInd, const Interval &a_variables, const int &a_dir, const Side::LoHiSide &a_sd, bool a_doingFineRegular) |
to support baseiffab approach More... | |
virtual void | reflux (LevelData< EBCellFAB > &a_uCoarse, const Interval &a_variables, const Real &a_scale, bool a_multByKappaOneMinusKappa=false) |
virtual void | reflux (LevelData< EBCellFAB > &a_uCoarse, const Interval &a_solutionvariables, const Interval &a_fluxvariables, const Real &a_scale, bool a_multByKappaOneMinusKappa=false) |
void | incrementDensityArray (LevelData< EBCellFAB > &a_coarMass, const Interval &a_variables, const Real &a_scale) |
bool | isDefined () const |
void | incrementFineIrreg (const EBFaceFAB &a_fineFlux, const Real &a_newScale, const DataIndex &a_fineDatInd, const Interval &a_variables, const int &a_dir, const Side::LoHiSide &a_sd) |
void | incrementCoarIrreg (const EBFaceFAB &a_coarFlux, const Real &a_scale, const DataIndex &a_coarDatInd, const Interval &a_variables, const int &a_dir, const Side::LoHiSide &a_sd) |
void | incrementFineRegul (const EBFaceFAB &a_fineFlux, const Real &a_newScale, const DataIndex &a_fineDatInd, const Interval &a_variables, const int &a_dir, const Side::LoHiSide &a_sd) |
void | incrementCoarRegul (const EBFaceFAB &a_coarFlux, const Real &a_scale, const DataIndex &a_coarDatInd, const Interval &a_variables, const int &a_dir, const Side::LoHiSide &a_sd) |
bool | hasEBCF () const |
void | clear () |
undefines object More... | |
Vector< VoFIterator > & | getVoFItCoar (const DataIndex &a_dit, const int &a_idir, const Side::LoHiSide &a_sd) |
VoFIterator & | getVoFItCoFi (const DataIndex &a_dit, const int &a_idir, const Side::LoHiSide &a_sd) |
const EBLevelGrid & | getEBLGCoFi () const |
Static Public Member Functions | |
static int | index (int a_dir, Side::LoHiSide a_side) |
Static Public Attributes | |
static bool | s_verbose |
Protected Member Functions | |
void | irregSetToZero () |
void | defineSetsAndIterators () |
void | defineBuffers () |
void | cacheOldSolution (const LevelData< EBCellFAB > &a_uCoar, const Interval &a_variables) |
void | restoreOldSolution (LevelData< EBCellFAB > &a_uCoar, const Interval &a_variables) |
void | irregReflux (LevelData< EBCellFAB > &a_uCoar, const Interval &a_variables, const Real &a_scale, bool a_multByKappaOneMinusKappa=false) |
void | incrementByRefluxDivergence (LevelData< EBCellFAB > &a_uCoar, LevelData< EBCellFAB > &a_fluxDiff, const Interval &a_variables, const Real &a_newScale, bool a_multByOneMinusKappa, bool a_multByKappaOneMinusKappa) |
void | setDefaultValues () |
bool | computeHasEBCF () |
Protected Attributes | |
LevelFluxRegister * | m_levelFluxReg |
bool | m_isDefined |
EBLevelGrid | m_eblgFine |
EBLevelGrid | m_eblgCoar |
EBLevelGrid | m_eblgCoFi |
int | m_refRat |
int | m_nComp |
Real | m_nrefdmo |
bool | m_hasEBCF |
LayoutData< VoFIterator > | m_vofiCoFi [2 *SpaceDim] |
LayoutData< IntVectSet > | m_setsCoFi [2 *SpaceDim] |
LayoutData< Vector< IntVectSet > > | m_setsCoar [2 *SpaceDim] |
LayoutData< Vector< VoFIterator > > | m_vofiCoar [2 *SpaceDim] |
Copier | m_reverseCopier |
LevelData< EBCellFAB > | m_saveCoar |
LevelData< EBCellFAB > | m_delUCoFi |
LevelData< EBCellFAB > | m_delUCoar |
LevelData< EBCellFAB > | m_delUDiff |
Private Member Functions | |
void | operator= (const EBFastFR &out) |
EBFastFR (const EBFastFR &out) | |
EBFastFR-A class to encapsulate a levels worth of flux registers.
A EBFastFR handles all the data choreography necessary to create a levels worth of flux registers. This only does the elliptic flux register stuff for now (no interacting with redistribution, no RZ, no regular and regular separate).
EBFastFR::EBFastFR | ( | ) |
Default constructor. Leaves object undefined.
EBFastFR::EBFastFR | ( | const EBLevelGrid & | a_eblgFine, |
const EBLevelGrid & | a_eblgCoar, | ||
const int & | a_nref, | ||
const int & | a_nvar, | ||
bool | a_forceNoEBCF = false |
||
) |
Full constructor. Calls the define function which creates a levels worth of flux registers. noebcf forces no coarse-fine intersection with EB
|
virtual |
|
inlineprivate |
References MayDay::Error().
|
virtual |
Full define function. Creates a levels worth of flux registers.
|
virtual |
Initialize values of registers to zero.
|
virtual |
The irregular part of this is just register = input flux (instead of increment) To avoid double-counting.
Referenced by EBFluxRegister::incrementCoarse().
|
virtual |
Referenced by EBFluxRegister::incrementFine().
void EBFastFR::compareFineSparse | ( | const EBFaceFAB & | a_fluxOld, |
const EBFaceFAB & | a_fluxNew, | ||
const DataIndex & | a_fineDatInd, | ||
const int & | a_dir, | ||
const Side::LoHiSide & | a_sd | ||
) |
|
virtual |
to support baseiffab approach
|
virtual |
Referenced by reflux().
|
inlinevirtual |
References Interval::begin(), CH_assert, BoxLayout::dataIterator(), EBLevelGrid::getDBL(), EBLevelGrid::getEBISL(), incrementCoarIrreg(), incrementCoarRegul(), incrementDensityArray(), incrementFineIrreg(), incrementFineRegul(), index(), isDefined(), m_eblgCoar, m_nComp, LayoutIterator::ok(), reflux(), EBLevelDataOps::setToZero(), Interval::size(), and IntVect::Zero.
void EBFastFR::incrementDensityArray | ( | LevelData< EBCellFAB > & | a_coarMass, |
const Interval & | a_variables, | ||
const Real & | a_scale | ||
) |
Increments mass array with left-over mass from reflux divergence. this is to test this pig. Ordinarily this mass would go into redistribution. this is used in the test suite to check whether a constant flux refluxed and then unrefluxed (this function) ends up with a constant solution. Correction at each cell = (1-kappa)refluxCorrection.
Referenced by reflux().
bool EBFastFR::isDefined | ( | ) | const |
Referenced by reflux().
|
static |
Referenced by getVoFItCoar(), getVoFItCoFi(), and reflux().
void EBFastFR::incrementFineIrreg | ( | const EBFaceFAB & | a_fineFlux, |
const Real & | a_newScale, | ||
const DataIndex & | a_fineDatInd, | ||
const Interval & | a_variables, | ||
const int & | a_dir, | ||
const Side::LoHiSide & | a_sd | ||
) |
Referenced by EBFluxRegister::incrementFineIrregular(), and reflux().
void EBFastFR::incrementCoarIrreg | ( | const EBFaceFAB & | a_coarFlux, |
const Real & | a_scale, | ||
const DataIndex & | a_coarDatInd, | ||
const Interval & | a_variables, | ||
const int & | a_dir, | ||
const Side::LoHiSide & | a_sd | ||
) |
The irregular part of this is just register = input flux (instead of increment) To avoid double-counting. The side argument is ignored.
Referenced by EBFluxRegister::incrementCoarseIrregular(), and reflux().
void EBFastFR::incrementFineRegul | ( | const EBFaceFAB & | a_fineFlux, |
const Real & | a_newScale, | ||
const DataIndex & | a_fineDatInd, | ||
const Interval & | a_variables, | ||
const int & | a_dir, | ||
const Side::LoHiSide & | a_sd | ||
) |
Referenced by EBFluxRegister::incrementFineRegular(), and reflux().
void EBFastFR::incrementCoarRegul | ( | const EBFaceFAB & | a_coarFlux, |
const Real & | a_scale, | ||
const DataIndex & | a_coarDatInd, | ||
const Interval & | a_variables, | ||
const int & | a_dir, | ||
const Side::LoHiSide & | a_sd | ||
) |
Referenced by EBFluxRegister::incrementCoarseRegular(), and reflux().
void EBFastFR::clear | ( | ) |
undefines object
Referenced by hasEBCF().
|
inline |
Gets the set of vofs to fill a flux for on a particular side and direction that correspond to an EB/CF interface. You still need to fill all the other fluxes at the interface but you do not have to do all the fancy interpolation to face centroids that is needed at these key points since all the other C/F points are treated as regular anyway. Do not use this unless you really know what you are doing. Really. Yes this breaks encapsulation but we do some pretty ugly things for performance reasons, do we not?
References index(), and m_vofiCoar.
|
inline |
Gets the set of vofs to fill a flux for on a particular side and direction that correspond to an EB/CF interface. You still need to fill all the other fluxes at the interface but you do not have to do all the fancy interpolation to face centroids that is needed at these key points since all the other C/F points are treated as regular anyway. Do not use this unless you really know what you are doing. Really. Yes this breaks encapsulation but we do some pretty ugly things for performance reasons, do we not?
References index(), and m_vofiCoFi.
|
inline |
|
protected |
Referenced by getEBLGCoFi().
|
protected |
Referenced by getEBLGCoFi().
|
protected |
Referenced by getEBLGCoFi().
|
protected |
Referenced by getEBLGCoFi().
|
protected |
Referenced by getEBLGCoFi().
|
protected |
Referenced by getEBLGCoFi().
|
protected |
Referenced by getEBLGCoFi().
|
protected |
|
protected |
|
inlineprivate |
References MayDay::Error().
|
static |
|
protected |
|
protected |
|
protected |
|
protected |
Referenced by reflux().
|
protected |
Referenced by getEBLGCoFi().
|
protected |
|
protected |
Referenced by reflux().
|
protected |
|
protected |
Referenced by hasEBCF().
|
protected |
Referenced by getVoFItCoFi().
|
protected |
|
protected |
|
protected |
Referenced by getVoFItCoar().
|
protected |