A class for handling particle deposition clouds that hang over refinement boundaries. This class does not include any deposition functionality but provides buffers for moving mass between two levels.
More...
#include <CD_EBCoarseFineParticleMesh.H>
|
| enum | Average { Arithmetic
, Conservative
} |
| | Simple enum for switch between arithmetic and conservative averaging.
|
| |
|
|
| EBCoarseFineParticleMesh () noexcept |
| | Default constructor. Leaves object in undefined state and subsequently requires a call to define.
|
| |
| | EBCoarseFineParticleMesh (const EBLevelGrid &a_eblgCoar, const EBLevelGrid &a_eblgFine, const int a_refRat, const IntVect a_ghost) noexcept |
| | Full constructor. Calls define.
|
| |
|
virtual | ~EBCoarseFineParticleMesh () noexcept |
| | Destructor (does nothing)
|
| |
| virtual void | define (const EBLevelGrid &a_eblgCoar, const EBLevelGrid &a_eblgFine, const int a_refRat, const IntVect a_ghost) noexcept |
| | Define function.
|
| |
| virtual void | addFineGhostsToCoarse (LevelData< EBCellFAB > &a_coarData, const LevelData< EBCellFAB > &a_fineData) const noexcept |
| | Coarsen the fine-level ghost cells and add them to the coarse level.
|
| |
| virtual void | addFiCoDataToFine (LevelData< EBCellFAB > &a_fineData, const LevelData< EBCellFAB > &a_fiCoData) const noexcept |
| | Add the valid+ghost cells on the refined coarse level to the valid cells on the fine level.
|
| |
| virtual void | addInvalidCoarseToFine (LevelData< EBCellFAB > &a_fineData, const LevelData< EBCellFAB > &a_coarData) const noexcept |
| | Function which piecewise interpolates the data underneath the fine grid and adds it to the fine grid.
|
| |
| virtual void | exchangeAndAddFiCoData (LevelData< EBCellFAB > &a_fiCoData) const noexcept |
| | Function which performs an exchange+add operation on the refined coarse data.
|
| |
| virtual void | restrictAndAddFiCoDataToCoar (LevelData< EBCellFAB > &a_coarData, const LevelData< EBCellFAB > &a_fiCoData, const EBCoarseFineParticleMesh::Average a_average) const noexcept |
| | Coarsen the data on the refined coarse grid to the coarse grid. The grids must be defined over the same layout.
|
| |
| const EBLevelGrid & | getEblgFiCo () const |
| | Get the refined version of the coarse eblevelgrid.
|
| |
| template<int NCOMP> |
| LevelData< EBCellFAB > & | getBufferFiCo () const noexcept |
| | Get buffer storage on the refined coarse level.
|
| |
|
|
void | defineVoFIterators () noexcept |
| | Define the vof iterators.
|
| |
|
void | defineStencils () noexcept |
| | Define the vof iterators.
|
| |
|
void | defineBufferFiCo () noexcept |
| | Define the buffer storages.
|
| |
| void | conservativeAverageAndAdd (EBCellFAB &a_coarData, const EBCellFAB &a_fineData, const DataIndex &a_din) const noexcept |
| | Conservatively average and add data from the refined coarse data to the coarse data.
|
| |
| void | arithmeticAverageAndAdd (EBCellFAB &a_coarData, const EBCellFAB &a_fineData, const DataIndex &a_din) const noexcept |
| | Arithmetically average and add data from the refined coarse data to the coarse data.
|
| |
|
|
bool | m_isDefined |
| | Is defined or not.
|
| |
|
bool | m_verbose |
| | Verbose or not. Useful for debugging.
|
| |
|
EBLevelGrid | m_eblgCoar |
| | Coarse EBLevelGrid.
|
| |
|
EBLevelGrid | m_eblgFine |
| | Fine EBLevelGrid.
|
| |
|
EBLevelGrid | m_eblgFiCo |
| | Refined coarse EBLevelGrid.
|
| |
|
EBLevelGrid | m_eblgCoFi |
| | Coarsening of m_eblgFine.
|
| |
| Copier | m_copierFiCoToFineIncludeGhosts |
| | Copier for copying data from the refined coarse level to the fine level.
|
| |
| Copier | m_copierCoFiToCoarIncludeGhosts |
| | Copier for copying data from the coarsened fine level to the coarse level.
|
| |
| Copier | m_copierFiCoToFineNoGhosts |
| | Copier for copying data from the refined coarse level to the fine level.
|
| |
| Copier | m_copierFiCoToFiCo |
| | Copier for that moves data from valid+ghost -> valid on the refined coarse level.
|
| |
|
LevelData< EBCellFAB > | m_bufferFiCoReal |
| | Buffer storage on the refined coarse level. One component only.
|
| |
|
LevelData< EBCellFAB > | m_bufferFiCoRealVect |
| | Buffer storage on the refined coarse level. One component only.
|
| |
|
LayoutData< VoFIterator > | m_vofIterFineGhosts |
| | VoFIterator for fine-grid irregular ghost cells.
|
| |
| LayoutData< VoFIterator > | m_vofIterCoFiGhosts |
| | VoFIterator for coarse grid cells that are coarsenings of fine-grid ghost irregular cells.
|
| |
|
LayoutData< VoFIterator > | m_vofIterCoar |
| | VoFIterator for coarse cells.
|
| |
| LayoutData< BaseIVFAB< VoFStencil > > | m_cellArithmeticStencils |
| | Stencils for arithmetic coarsening of volume data.
|
| |
| LayoutData< BaseIVFAB< VoFStencil > > | m_cellConservativeStencils |
| | Stencils for conservative coarsening of volume data.
|
| |
|
int | m_refRat |
| | Refinement ratio between the two levels.
|
| |
|
IntVect | m_ghost |
| | Number of ghost cells in data holders.
|
| |
|
|
static constexpr int | m_comp = 0 |
| | Default component.
|
| |
|
static constexpr int | m_nComp = 1 |
| | Maximum number of components.
|
| |
A class for handling particle deposition clouds that hang over refinement boundaries. This class does not include any deposition functionality but provides buffers for moving mass between two levels.
To use this class, the user can directly some functions:
- addFineGhostsToCoarse which adds the contribution of the fine level's particles to the coarse level. This will add the part of the particle clouds that hang over the refinement boundary to the coarse level. Likewise, the user can get a buffer (getFiCoBuffer) for getting a temporary data holder on which he can use special deposition procedures.
- addFiCoDataToFine where the user will have deposited coarse-level particles on a fine-grid buffer, and he/she wants to add the result back to the fine grid.
- addInvalidCoarseToFine where the coarse-grid deposition clouds are interpolated to the fine grid. This is the case when e.g. the coarse-grid clouds deposit underneath the fine level but the mass should end up on the fine level.
- exchangeAndAddFiCoData where deposited particles on the refined coarse grids have their masses synchronized (ghost cells are added across patches).
◆ EBCoarseFineParticleMesh()
| EBCoarseFineParticleMesh::EBCoarseFineParticleMesh |
( |
const EBLevelGrid & |
a_eblgCoar, |
|
|
const EBLevelGrid & |
a_eblgFine, |
|
|
const int |
a_refRat, |
|
|
const IntVect |
a_ghost |
|
) |
| |
|
noexcept |
Full constructor. Calls define.
- Parameters
-
| [in] | a_eblgCoar | Coarse grids |
| [in] | a_eblgFine | Fine grids |
| [in] | a_refRat | Refinement factory between levels |
| [in] | a_ghost | Number of ghost cells in mesh data holders. |
◆ addFiCoDataToFine()
| void EBCoarseFineParticleMesh::addFiCoDataToFine |
( |
LevelData< EBCellFAB > & |
a_fineData, |
|
|
const LevelData< EBCellFAB > & |
a_fiCoData |
|
) |
| const |
|
virtualnoexcept |
Add the valid+ghost cells on the refined coarse level to the valid cells on the fine level.
This routine is used when the user have deposited coarse-level particles into a_fiCoData (which is a refinement of the coarse level). This routine then adds that data to the fine level. The motion plan defines the computation region as valid+ghost -> valid, which is what we want.
- Parameters
-
| [in,out] | a_fineData | Fine mesh data |
| [in] | a_fiCoData | Refined coarse data buffer. Users will have deposited the mesh data onto this |
◆ addFineGhostsToCoarse()
| void EBCoarseFineParticleMesh::addFineGhostsToCoarse |
( |
LevelData< EBCellFAB > & |
a_coarData, |
|
|
const LevelData< EBCellFAB > & |
a_fineData |
|
) |
| const |
|
virtualnoexcept |
Coarsen the fine-level ghost cells and add them to the coarse level.
On output, the contents in the ghost cells on the refinement boundary are added from the fine level to the coarse level. This routine is used when the fine-level particles have particle clouds that deposit into the ghost cells outside the fine level, i.e. over the refinement boundary. This routine coarsens that data and adds the mass to the coarse level.
- Parameters
-
| [in,out] | a_coarData | Coarse mesh data. |
| [in] | a_fineData | Fine mesh data. |
◆ addInvalidCoarseToFine()
| void EBCoarseFineParticleMesh::addInvalidCoarseToFine |
( |
LevelData< EBCellFAB > & |
a_fineData, |
|
|
const LevelData< EBCellFAB > & |
a_coarData |
|
) |
| const |
|
virtualnoexcept |
Function which piecewise interpolates the data underneath the fine grid and adds it to the fine grid.
The data-motion plan is to use the valid+ghost cells on the coarse level and add it into the valid region on the fine level. However, the buffers' ghost regions are set to zero so this should only add non-ghosted data between the levels.
- Parameters
-
| [in,out] | a_fineData | Fine-level data. |
| [in] | a_coarData | Coarse-level data. |
◆ arithmeticAverageAndAdd()
| void EBCoarseFineParticleMesh::arithmeticAverageAndAdd |
( |
EBCellFAB & |
a_coarData, |
|
|
const EBCellFAB & |
a_fineData, |
|
|
const DataIndex & |
a_din |
|
) |
| const |
|
protectednoexcept |
Arithmetically average and add data from the refined coarse data to the coarse data.
- Parameters
-
| [in,out] | a_coarData | Coarse-grid data |
| [in] | a_fineData | Fine-grid data (must be on a refined layout of the coarse grid) |
| [in] | a_din | Grid idnex |
◆ conservativeAverageAndAdd()
| void EBCoarseFineParticleMesh::conservativeAverageAndAdd |
( |
EBCellFAB & |
a_coarData, |
|
|
const EBCellFAB & |
a_fineData, |
|
|
const DataIndex & |
a_din |
|
) |
| const |
|
protectednoexcept |
Conservatively average and add data from the refined coarse data to the coarse data.
- Parameters
-
| [in,out] | a_coarData | Coarse-grid data |
| [in] | a_fineData | Fine-grid data (must be on a refined layout of the coarse grid) |
| [in] | a_din | Grid index |
◆ define()
| void EBCoarseFineParticleMesh::define |
( |
const EBLevelGrid & |
a_eblgCoar, |
|
|
const EBLevelGrid & |
a_eblgFine, |
|
|
const int |
a_refRat, |
|
|
const IntVect |
a_ghost |
|
) |
| |
|
virtualnoexcept |
Define function.
- Parameters
-
| [in] | a_eblgCoar | Coarse grids |
| [in] | a_eblgFine | Fine grids |
| [in] | a_refRat | Refinement factory between levels |
| [in] | a_ghost | Number of ghost cells in mesh data holders. |
◆ exchangeAndAddFiCoData()
| void EBCoarseFineParticleMesh::exchangeAndAddFiCoData |
( |
LevelData< EBCellFAB > & |
a_fiCoData | ) |
const |
|
virtualnoexcept |
Function which performs an exchange+add operation on the refined coarse data.
- Parameters
-
| [in,out] | a_fiCoData | Description |
◆ getBufferFiCo()
template<int NCOMP>
| LevelData< EBCellFAB > & EBCoarseFineParticleMesh::getBufferFiCo |
( |
| ) |
const |
|
noexcept |
Get buffer storage on the refined coarse level.
- Returns
- Buffer fi co
◆ getEblgFiCo()
| const EBLevelGrid & EBCoarseFineParticleMesh::getEblgFiCo |
( |
| ) |
const |
Get the refined version of the coarse eblevelgrid.
- Returns
- Eblg fi co
◆ restrictAndAddFiCoDataToCoar()
| void EBCoarseFineParticleMesh::restrictAndAddFiCoDataToCoar |
( |
LevelData< EBCellFAB > & |
a_coarData, |
|
|
const LevelData< EBCellFAB > & |
a_fiCoData, |
|
|
const EBCoarseFineParticleMesh::Average |
a_average |
|
) |
| const |
|
virtualnoexcept |
Coarsen the data on the refined coarse grid to the coarse grid. The grids must be defined over the same layout.
- Parameters
-
| [in,out] | a_coarData | Coarse-grid data |
| [in] | a_average | Averaging method. Either arithmetic or conservative. |
| [in] | a_fiCoData | Fi co data |
◆ m_cellArithmeticStencils
| LayoutData<BaseIVFAB<VoFStencil> > EBCoarseFineParticleMesh::m_cellArithmeticStencils |
|
protected |
Stencils for arithmetic coarsening of volume data.
This is defined on the coarse grid, and indexes into the refined coarse grid.
◆ m_cellConservativeStencils
| LayoutData<BaseIVFAB<VoFStencil> > EBCoarseFineParticleMesh::m_cellConservativeStencils |
|
protected |
Stencils for conservative coarsening of volume data.
This is defined on the coarse grid, and indexes into the refined coarse grid.
◆ m_copierCoFiToCoarIncludeGhosts
| Copier EBCoarseFineParticleMesh::m_copierCoFiToCoarIncludeGhosts |
|
protected |
Copier for copying data from the coarsened fine level to the coarse level.
- Note
- This copier moves from valid+ghost in the source to valid+ghost in the destination.
◆ m_copierFiCoToFiCo
| Copier EBCoarseFineParticleMesh::m_copierFiCoToFiCo |
|
protected |
Copier for that moves data from valid+ghost -> valid on the refined coarse level.
Needed for some of the deposition methods that deposit on the refined coarse level and then later needs to synchronize their data
◆ m_copierFiCoToFineIncludeGhosts
| Copier EBCoarseFineParticleMesh::m_copierFiCoToFineIncludeGhosts |
|
protected |
Copier for copying data from the refined coarse level to the fine level.
- Note
- This copier moves from valid+ghost in the source to valid+ghost in the destination.
◆ m_copierFiCoToFineNoGhosts
| Copier EBCoarseFineParticleMesh::m_copierFiCoToFineNoGhosts |
|
protected |
Copier for copying data from the refined coarse level to the fine level.
This copier moves from valid+ghost in the source to valid in the destination (as opposed to m_copierCOFiToCoarIncludeGhosts which adds mass into the ghost cells).
◆ m_vofIterCoFiGhosts
| LayoutData<VoFIterator> EBCoarseFineParticleMesh::m_vofIterCoFiGhosts |
|
mutableprotected |
VoFIterator for coarse grid cells that are coarsenings of fine-grid ghost irregular cells.
Essentially a coarsening of m_vofIterFineGhosts.
The documentation for this class was generated from the following files: