Class for restricting multigrid residual onto a coarser grid. More...
#include <CD_EBMGRestrict.H>
Public Member Functions | |
EBMGRestrict () noexcept | |
Default constructor. User must subsequently call the define function. | |
EBMGRestrict (const EBLevelGrid &a_eblgFine, const EBLevelGrid &a_eblgCoar, const int &a_refRat) noexcept | |
Full constructor. Calls the define fucntion. | |
virtual | ~EBMGRestrict () noexcept |
Destructor. | |
virtual void | define (const EBLevelGrid &a_eblgFine, const EBLevelGrid &a_eblgCoar, const int &a_refRat) noexcept |
Define function. | |
virtual void | restrictResidual (LevelData< EBCellFAB > &a_coarData, const LevelData< EBCellFAB > &a_fineData, const Interval a_variables) const noexcept |
Restrict residual onto the coarse grid. | |
Protected Attributes | |
bool | m_isDefined |
Defined or not. | |
int | m_refRat |
Refinement ratio. | |
IntVect | m_ghostPhi |
Number of ghost cells in data holders. | |
EBLevelGrid | m_eblgFine |
Fine grid. | |
EBLevelGrid | m_eblgCoar |
Coarse grid. | |
EBLevelGrid | m_eblgCoFi |
Coarsened fine grids. | |
Copier | m_copier |
Copier for making copying from the coarsened fine grids to the coarse grid go faster. | |
LayoutData< VoFIterator > | m_vofitCoar |
Iterator for iterating over cut-cells on the coarse level. | |
LayoutData< BaseIVFAB< VoFStencil > > | m_restrictStencils |
Restriction stencils near the EB. | |
Class for restricting multigrid residual onto a coarser grid.
This class defines an operator for setting phiC = 1/Nref^D * sum(phiFine). This assumes that the input data has already been scaled by the volume fraction (which is what the EB multigrid operators do anyways).
|
noexcept |
Full constructor. Calls the define fucntion.
[in] | a_eblgFine | Fine level |
[in] | a_eblgCoar | Coarse level |
[in] | a_refRat | Refinement factor between levels. |
|
virtualnoexcept |
Define function.
[in] | a_eblgFine | Fine level |
[in] | a_eblgCoar | Coarse level |
[in] | a_refRat | Refinement factor between levels. |
|
virtualnoexcept |
Restrict residual onto the coarse grid.
This replaces the coarse-grid residual by an average of the fine-grid residual. Only affects the invalid region of the coarse grid.
[in,out] | a_coarData | Coarse-grid residual. |
[in] | a_fineData | Fine-grid residual |
[in] | a_variables | Variables to restrict |
|
protected |
Restriction stencils near the EB.
The stencils are defined on the coarse-grid, but reach into the fine grid.