Maps the moving particles into the simulation domain and updates the mapping.
Cells that are inside a particle, will be marked with the 'obstacle' flag. 'Inside' means that the cell center is contained in the particle. Thus, a containsPoint function has to be available for all particles/shapes.
Cells that in the last time step were inside the particle but are now outside of it, i.e. the particle has moved, will be marked with the 'formerObstacle' flag. The 'formerObstacle' flag is used in a second step by the PDFReconstruction class (see PDFReconstruction.h) to re-initialize the missing PDFs. Afterwards, the 'formerObstacle' flag is removed and the 'fluid' flag is set.
It is not strictly required that the mapping has been initialized with the mapping kernel from below.
The 'mappingParticleSelector' can be used to include/exclude certain particles from the mapping.
#include <MovingParticleMapping.h>
Public Types | |
using | FlagField_T = typename BoundaryHandling_T::FlagField |
using | flag_t = typename BoundaryHandling_T::flag_t |
Public Member Functions | |
MovingParticleMapping (const shared_ptr< StructuredBlockStorage > &blockStorage, const BlockDataID &pdfFieldID, const BlockDataID &boundaryHandlingID, const BlockDataID &particleFieldID, const shared_ptr< ParticleAccessor_T > &ac, const FlagUID &obstacle, const FlagUID &formerObstacle, const ParticleSelector_T &mappingParticleSelector, bool conserveMomentumWhenMapping) | |
void | operator() (IBlock *const block) |
Private Member Functions | |
void | mapParticleAndUpdateMapping (const size_t particleIdx, IBlock *const block, PdfField_T *pdfField, BoundaryHandling_T *boundaryHandling, FlagField_T *flagField, ParticleField_T *particleField, const flag_t &obstacle, const flag_t &formerObstacle, real_t dx, real_t dy, real_t dz) |
Private Attributes | |
shared_ptr< StructuredBlockStorage > | blockStorage_ |
const BlockDataID | pdfFieldID_ |
const BlockDataID | boundaryHandlingID_ |
const BlockDataID | particleFieldID_ |
shared_ptr< ParticleAccessor_T > | ac_ |
const FlagUID | obstacle_ |
const FlagUID | formerObstacle_ |
ParticleSelector_T | mappingParticleSelector_ |
bool | conserveMomentumWhenMapping_ |
using walberla::lbm_mesapd_coupling::MovingParticleMapping< PdfField_T, BoundaryHandling_T, ParticleAccessor_T, ParticleSelector_T >::flag_t = typename BoundaryHandling_T::flag_t |
using walberla::lbm_mesapd_coupling::MovingParticleMapping< PdfField_T, BoundaryHandling_T, ParticleAccessor_T, ParticleSelector_T >::FlagField_T = typename BoundaryHandling_T::FlagField |
|
inline |
|
inlineprivate |
|
inline |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |