chombo-discharge
|
Class for handling particle-mesh operations with AMR. More...
#include <CD_EBAMRParticleMesh.H>
Public Member Functions | |
EBAMRParticleMesh () | |
Default constructor. Leaves object in undefined state and thus requires the user to call define. | |
EBAMRParticleMesh (const Vector< RefCountedPtr< EBLevelGrid >> &a_eblgs, const Vector< int > &a_refRat, const Vector< Real > &a_dx, const RealVect &a_probLo, const IntVect &a_ghost, const int a_maxParticleWidth, const int a_finestLevel) | |
Full constructor. Calls the define function. More... | |
virtual | ~EBAMRParticleMesh () |
Destructor (does nothing) | |
void | define (const Vector< RefCountedPtr< EBLevelGrid >> &a_eblgs, const Vector< int > &a_refRat, const Vector< Real > &a_dx, const RealVect &a_probLo, const IntVect &a_ghost, const int a_maxParticleWidth, const int a_finestLevel) |
Define function. More... | |
template<class P , const Real &(P::*)() const particleScalarField> | |
void | deposit (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const CoarseFineDeposition a_coarseFineDeposition, const bool a_forceIrregNGP=false) |
Class for deposition of particles of a type P to the mesh. This does scalar quantities. More... | |
template<class P , Real(P::*)() const particleScalarField> | |
void | deposit (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const CoarseFineDeposition a_coarseFineDeposition, const bool a_forceIrregNGP=false) |
Class for deposition of particles of a type P to the mesh. This does scalar quantities. More... | |
template<class P , const RealVect &(P::*)() const particleVectorField> | |
void | deposit (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const CoarseFineDeposition a_coarseFineDeposition, const bool a_forceIrregNGP=false) |
Class for deposition of particles of a type P to the mesh. This does vector quantities. More... | |
template<class P , RealVect(P::*)() const particleVectorField> | |
void | deposit (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const CoarseFineDeposition a_coarseFineDeposition, const bool a_forceIrregNGP=false) |
Class for deposition of particles of a type P to the mesh. This does vector quantities. More... | |
template<class P , Real &(P::*)() particleScalarField> | |
void | interpolate (ParticleContainer< P > &a_particles, const EBAMRCellData &a_meshVectorField, const DepositionType a_interpType, const bool a_forceIrregNGP=false) const |
Interpolate a scalar field onto the particle position. More... | |
template<class P , RealVect &(P::*)() particleVectorField> | |
void | interpolate (ParticleContainer< P > &a_particles, const EBAMRCellData &a_meshVectorField, const DepositionType a_interpType, const bool a_forceIrregNGP=false) const |
Interpolate a vector field onto the particle position. More... | |
Vector< RefCountedPtr< EBCoarseFineParticleMesh > > & | getEBCoarseFineParticleMesh () const |
Get buffers for handling deposition over refinement boundaries. More... | |
const EBParticleMesh & | getEBParticleMesh (const int a_lvl, const DataIndex &a_dit) const |
Get EBParticleMesh deposition/interpolation object for specified grid patch. More... | |
Protected Member Functions | |
void | defineLevelMotion () |
Define level copiers. More... | |
void | defineCoarseFineMotion () |
Define coarse-fine data motion operators. More... | |
void | defineEBParticleMesh () |
Define EBParticleMesh objects. | |
template<class P , const Real &(P::*)() const particleScalarField> | |
void | depositInterp (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "PVR" algorithm for handling refinement boundaries. More... | |
template<class P , Real(P::*)() const particleScalarField> | |
void | depositInterp (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "PVR" algorithm for handling refinement boundaries. More... | |
template<class P , const Real &(P::*)() const particleScalarField> | |
void | depositHalo (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "Halo" algorithm for handling refinement boundaries. More... | |
template<class P , Real(P::*)() const particleScalarField> | |
void | depositHalo (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "Halo" algorithm for handling refinement boundaries. More... | |
template<class P , const Real &(P::*)() const particleScalarField> | |
void | depositHaloNGP (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "HaloNGP" algorithm for handling refinement boundaries. More... | |
template<class P , Real(P::*)() const particleScalarField> | |
void | depositHaloNGP (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "HaloNGP" algorithm for handling refinement boundaries. More... | |
template<class P , const RealVect &(P::*)() const particleScalarField> | |
void | depositInterp (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "PVR" algorithm for handling refinement boundaries. More... | |
template<class P , RealVect(P::*)() const particleScalarField> | |
void | depositInterp (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "PVR" algorithm for handling refinement boundaries. More... | |
template<class P , const RealVect &(P::*)() const particleScalarField> | |
void | depositHalo (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "Halo" algorithm for handling refinement boundaries. More... | |
template<class P , RealVect(P::*)() const particleScalarField> | |
void | depositHalo (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "Halo" algorithm for handling refinement boundaries. More... | |
template<class P , const RealVect &(P::*)() const particleScalarField> | |
void | depositHaloNGP (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "HaloNGP" algorithm for handling refinement boundaries. More... | |
template<class P , RealVect(P::*)() const particleScalarField> | |
void | depositHaloNGP (EBAMRCellData &a_meshData, const ParticleContainer< P > &a_particles, const DepositionType a_depositionType, const bool a_forceIrregNGP=false) |
Just like the deposit function, but forced to use the "HaloNGP" algorithm for handling refinement boundaries. More... | |
Protected Attributes | |
bool | m_isDefined |
Is defined or not. | |
RealVect | m_probLo |
Lower-left corner of physical domain. | |
IntVect | m_ghost |
Number of ghost cells. | |
int | m_maxParticleWidth |
Maximum particle width that will ever be used. | |
int | m_finestLevel |
Finest AMR level. | |
Vector< RefCountedPtr< EBLevelGrid > > | m_eblgs |
Grids on each level. | |
Vector< int > | m_refRat |
Refinement ratios between levels. | |
Vector< Real > | m_dx |
Grid resolutions. | |
Vector< RefCountedPtr< LayoutData< EBParticleMesh > > > | m_ebParticleMesh |
Regular particle-mesh object on each grid level. | |
Vector< RefCountedPtr< LayoutData< EBParticleMesh > > > | m_ebParticleMeshFiCo |
Special particle-mesh objects for depositing on the coarsened fine grid. More... | |
Vector< RefCountedPtr< EBCoarseFineParticleMesh > > | m_coarseFinePM |
Buffers for handling arithmetic for mass moving from coarse to fine level and vice versa. More... | |
Vector< Copier > | m_levelCopiers |
Copier for moving data from valid+ghost to valid on each AMR level. More... | |
Class for handling particle-mesh operations with AMR.
This class contains templated functions for depositing particles with AMR. When depositing, the user must specify the deposition type (e.g., CIC) as well as how to handle coarse-fine boundary conditions and cut-cell deposition. Because of the many degrees of freedom in depositing particles with AMR (and EB), the user must expect to preprocess his particle data before solving. There are thus two "main" ways of handling deposition near refinement boundaries.
When specifying CoarseFineDeposition::Interp, the deposition is done by first depositing the data as usual on both levels. On the fine level, there may be mass that hangs over the refinement boundaries; that mass is added to the coarse level. On the coarse level some of the particles will deposit mass into cells that are covered by a finer level; that mass is interpolated with piece-wise constant interpolation and added to the fine level.
When specyfing CoarseFineDeposition::Halo, only the handling of the coarse-side deposition is different. As with PVR, the mass from the fine-level particles that hangs over refinement boundaries is put on the coarse mesh. However, the coarse-level particles are deposited in two separate steps so that the coarse-level particles have the same physical widths on the coarse and fine levels. We first deposit ALL the coarse-level particles on the coarse level. Some of these particles (halo particles) will have clouds that overlap with the fine level. We take the set of these particles and deposit them directly onto the fine level (via buffers) with 2x or 4x the original particle width (depending on the refinement ratios between the levels). Essentially, this differs CoarseFineDeposition::Interp in the sense that the original particle width is maintained on the fine level.
EBAMRParticleMesh::EBAMRParticleMesh | ( | const Vector< RefCountedPtr< EBLevelGrid >> & | a_eblgs, |
const Vector< int > & | a_refRat, | ||
const Vector< Real > & | a_dx, | ||
const RealVect & | a_probLo, | ||
const IntVect & | a_ghost, | ||
const int | a_maxParticleWidth, | ||
const int | a_finestLevel | ||
) |
Full constructor. Calls the define function.
[in] | a_eblgs | Grids |
[in] | a_refRat | Refinement factory between levels |
[in] | a_dx | Grid resolutions. @πaram[in] a_probLo Lower-left corner of physical domain. |
[in] | a_ghost | Ghost cells in data holders. |
[in] | a_maxParticleWidth | Maximum particle width that will be encountered. |
[in] | a_finestLevel | Finest grid level |
void EBAMRParticleMesh::define | ( | const Vector< RefCountedPtr< EBLevelGrid >> & | a_eblgs, |
const Vector< int > & | a_refRat, | ||
const Vector< Real > & | a_dx, | ||
const RealVect & | a_probLo, | ||
const IntVect & | a_ghost, | ||
const int | a_maxParticleWidth, | ||
const int | a_finestLevel | ||
) |
Define function.
[in] | a_eblgs | Grids |
[in] | a_refRat | Refinement factory between levels |
[in] | a_dx | Grid resolutions. @πaram[in] a_probLo Lower-left corner of physical domain. |
[in] | a_ghost | Ghost cells in data holders. |
[in] | a_maxParticleWidth | Maximum particle width that will be encountered. |
[in] | a_finestLevel | Finest grid level |
|
protected |
Define coarse-fine data motion operators.
This defines the necessary constructors for
|
protected |
Define level copiers.
void EBAMRParticleMesh::deposit | ( | EBAMRCellData & | a_meshData, |
const ParticleContainer< P > & | a_particles, | ||
const DepositionType | a_depositionType, | ||
const CoarseFineDeposition | a_coarseFineDeposition, | ||
const bool | a_forceIrregNGP = false |
||
) |
Class for deposition of particles of a type P to the mesh. This does scalar quantities.
This routine will switch between various algorithms depending on the user input. If the user chooses to deposit with "halos" near the refinement boundaries then this function requires the "halo" particles to be filled before entering this routine. Thus, if depositing with halos (which requires kernels with 2x or 4x the particle width), the user must first call ParticleContainer::copyMaskParticles(AMRMask). If the user does not do this, he will lose mass near the refinement boundaries. Other than that, this function is just like regular particle-mesh deposition. The mesh field should have exactly one component and the quantity to be deposited is fetched from the specified template parameter 'a_particleScalarField'. This should be a pointer to a member function with signature const Real& P::function() const. E.g. if we are depositing mass through a function const Real& P::mass() const we will specifiy
deposit<P, &P::mass> (...)
To deposit a different quantity, simply change the function pointer in the input parameter.
[out] | a_meshData | Mesh data. Must have exactly one compnent. @πaram[in] a_particles Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_coarseFineDeposition | Specification of handling of coarse-fine boundaries. |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
void EBAMRParticleMesh::deposit | ( | EBAMRCellData & | a_meshData, |
const ParticleContainer< P > & | a_particles, | ||
const DepositionType | a_depositionType, | ||
const CoarseFineDeposition | a_coarseFineDeposition, | ||
const bool | a_forceIrregNGP = false |
||
) |
Class for deposition of particles of a type P to the mesh. This does scalar quantities.
Just like the version above, except that the function signature is Real P::particleScalarField() const (C++ is not too smart about these things)
[out] | a_meshData | Mesh data. Must have exactly one compnent. @πaram[in] a_particles Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_coarseFineDeposition | Specification of handling of coarse-fine boundaries. |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
void EBAMRParticleMesh::deposit | ( | EBAMRCellData & | a_meshData, |
const ParticleContainer< P > & | a_particles, | ||
const DepositionType | a_depositionType, | ||
const CoarseFineDeposition | a_coarseFineDeposition, | ||
const bool | a_forceIrregNGP = false |
||
) |
Class for deposition of particles of a type P to the mesh. This does vector quantities.
This routine will switch between various algorithms depending on the user input. If the user chooses to deposit with "halos" near the refinement boundaries then this function requires the "halo" particles to be filled before entering this routine. Thus, if depositing with halos (which requires kernels with 2x or 4x the particle width), the user must first call ParticleContainer::copyMaskParticles(AMRMask). If the user does not do this, he will lose mass near the refinement boundaries. Other than that, this function is just like regular particle-mesh deposition. The mesh field should have exactly SpaceDim components and the quantity to be deposited is fetched from the specified template parameter 'a_particleVectorField'. This should be a pointer to a member function with signature const RealVect& P::function() const. E.g. if we are depositing current through a function const RealVect& P::current() const we will specifiy
deposit<P, &P::current> (...)
To deposit a different quantity, simply change the function pointer in the input parameter.
[out] | a_meshData | Mesh data. Must have exactly SpaceDim components. @πaram[in] a_particles Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_coarseFineDeposition | Specification of handling of coarse-fine boundaries. |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
void EBAMRParticleMesh::deposit | ( | EBAMRCellData & | a_meshData, |
const ParticleContainer< P > & | a_particles, | ||
const DepositionType | a_depositionType, | ||
const CoarseFineDeposition | a_coarseFineDeposition, | ||
const bool | a_forceIrregNGP = false |
||
) |
Class for deposition of particles of a type P to the mesh. This does vector quantities.
Just like the version above, except that the function signature is RealVect P::particleVectorField() const
[out] | a_meshData | Mesh data. Must have exactly SpaceDim components. @πaram[in] a_particles Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_coarseFineDeposition | Specification of handling of coarse-fine boundaries. |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "Halo" algorithm for handling refinement boundaries.
See deposit() for details regarding the template arguments. When calling this routine the user must have filled the "halo" particles for this routine to make any sense. This function will run special deposition routines with 2x or 4x the particle width near the refinement boundaries.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "Halo" algorithm for handling refinement boundaries.
Just like the above version, but with a different function signature.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "Halo" algorithm for handling refinement boundaries.
See deposit() for details regarding the template arguments. When calling this routine the user must have filled the "halo" particles for this routine to make any sense. This function will run special deposition routines with 2x or 4x the particle width near the refinement boundaries.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "Halo" algorithm for handling refinement boundaries.
See deposit() for details regarding the template arguments. When calling this routine the user must have filled the "halo" particles for this routine to make any sense. This function will run special deposition routines with 2x or 4x the particle width near the refinement boundaries.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "HaloNGP" algorithm for handling refinement boundaries.
See deposit() for details regarding the template arguments. When calling this routine the user must have filled the "halo" particles for this routine to make any sense. This function will deposit as usual, but force the particles on the refinement boundary to be deposited with an NGP scheme. Essentially, this means that the fine grid particles will deposit mass into the coarse grid but the coarse grid particles will NOT deposit mass into the fine grid.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "HaloNGP" algorithm for handling refinement boundaries.
Just like the above version, but with a different function signature.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "HaloNGP" algorithm for handling refinement boundaries.
See deposit() for details regarding the template arguments. When calling this routine the user must have filled the "halo" particles for this routine to make any sense. This function will deposit as usual, but force the particles on the refinement boundary to be deposited with an NGP scheme. Essentially, this means that the fine grid particles will deposit mass into the coarse grid but the coarse grid particles will NOT deposit mass into the fine grid.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "HaloNGP" algorithm for handling refinement boundaries.
See deposit() for details regarding the template arguments. When calling this routine the user must have filled the "halo" particles for this routine to make any sense. This function will deposit as usual, but force the particles on the refinement boundary to be deposited with an NGP scheme. Essentially, this means that the fine grid particles will deposit mass into the coarse grid but the coarse grid particles will NOT deposit mass into the fine grid.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "PVR" algorithm for handling refinement boundaries.
See deposit() for details regarding the template arguments. When calling this routine the user does NOT need to fill the "halo" particles. Rather, the mass that is deposited on the part of the coarse grid that lies underneath the fine grid (i.e., the invalid region) is interpolated to the fine level.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "PVR" algorithm for handling refinement boundaries.
Just like the above version, but with a different function signature.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "PVR" algorithm for handling refinement boundaries.
See deposit() for details regarding the template arguments. When calling this routine the user does NOT need to fill the "halo" particles. Rather, the mass that is deposited on the part of the coarse grid that lies underneath the fine grid (i.e., the invalid region) is interpolated to the fine level.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
|
protected |
Just like the deposit function, but forced to use the "PVR" algorithm for handling refinement boundaries.
See deposit() for details regarding the template arguments. When calling this routine the user does NOT need to fill the "halo" particles. Rather, the mass that is deposited on the part of the coarse grid that lies underneath the fine grid (i.e., the invalid region) is interpolated to the fine level.
[out] | a_meshData | Mesh data. Must have exactly one compnent. |
[in] | a_particles | Particle container. Must be in "usable state" for deposition. |
[in] | a_depositionType | Specification of deposition kernel (e.g., CIC) |
[in] | a_forceIrregNGP | Force NGP deposition in irregular cells or not. |
Vector<RefCountedPtr<EBCoarseFineParticleMesh> >& EBAMRParticleMesh::getEBCoarseFineParticleMesh | ( | ) | const |
Get buffers for handling deposition over refinement boundaries.
const EBParticleMesh & EBAMRParticleMesh::getEBParticleMesh | ( | const int | a_lvl, |
const DataIndex & | a_dit | ||
) | const |
Get EBParticleMesh deposition/interpolation object for specified grid patch.
This routine is used for when users want to interpolate on a per-patch basis. This is useful when the user has written his interpolation functions on a per-patch basis. I fail to see any other reason where this routine is useful.
[in] | a_lvl | Grid level |
[in] | a_dit | Grid index |
void EBAMRParticleMesh::interpolate | ( | ParticleContainer< P > & | a_particles, |
const EBAMRCellData & | a_meshVectorField, | ||
const DepositionType | a_interpType, | ||
const bool | a_forceIrregNGP = false |
||
) | const |
Interpolate a scalar field onto the particle position.
This is just like regular particle-mesh interpolation. The input field should have exactly one component and the the field will be interpolated onto the template parameter's input field. The template parameter 'particleScalarField' should be a pointer to a member function which will set the particle field. E.g. the function must have a signature Real& P::particleScalarField(). A valid expression is e.g.
interpolate<P, &P::mass> (...)
To interpolate onto a different field, replace ::mass by the other scalar field.
[in,out] | a_particles | Particles to be interpolated. |
[in] | a_meshScalarField | Scalar field on the mesh |
[in] | a_interpType | Interpolation type. |
[in] | a_forceIrregNGP | Force NGP interpolation in cut-cells. |
void EBAMRParticleMesh::interpolate | ( | ParticleContainer< P > & | a_particles, |
const EBAMRCellData & | a_meshVectorField, | ||
const DepositionType | a_interpType, | ||
const bool | a_forceIrregNGP = false |
||
) | const |
Interpolate a vector field onto the particle position.
This is just like regular particle-mesh interpolation. The input field should have exactly SpaceDim components and the the field will be interpolated onto the template parameter's input field. The template parameter 'particleVectorField' should be a pointer to a member function which will set the particle field. E.g. the function must have a signature RealVect& P::particleVectorField(). A valid expression is e.g.
interpolate<P, &P::velocity> (...)
To interpolate onto a different field, replace ::velocity by another vector field.
[in,out] | a_particles | Particles to be interpolated. |
[in] | a_meshScalarField | Scalar field on the mesh |
[in] | a_interpType | Interpolation type. |
[in] | a_coarseFineDeposition | Specification of handling of coarse-fine boundaries. |
[in] | a_forceIrregNGP | Force NGP interpolation in cut-cells. |
|
mutableprotected |
Buffers for handling arithmetic for mass moving from coarse to fine level and vice versa.
|
protected |
Special particle-mesh objects for depositing on the coarsened fine grid.
These are deposition/interpolation objects defined on the refined coarse grid. They are used when we need to deposit coarse-grid particles on the fine grid.
|
mutableprotected |
Copier for moving data from valid+ghost to valid on each AMR level.