walberla::mesa_pd::data::LinkedCells Struct Reference

#include <LinkedCells.h>

Public Member Functions

 LinkedCells (const math::AABB &domain, const real_t cellDiameter)
 
 LinkedCells (const math::AABB &domain, const Vec3 &cellDiameter)
 
void clear ()
 
template<typename Selector , typename Accessor , typename Func , typename... Args>
void forEachParticlePair (const bool openmp, const Selector &selector, Accessor &acForLC, Func &&func, Args &&...args) const
 Calls the provided functor func for all particle pairs. More...
 
template<typename Selector , typename Accessor , typename Func , typename... Args>
void forEachParticlePairHalf (const bool openmp, const Selector &selector, Accessor &acForLC, Func &&func, Args &&...args) const
 Calls the provided functor func for all particle pairs. More...
 

Public Attributes

math::AABB domain_ {}
 
Vector3< int > numCellsPerDim_ {}
 
Vec3 cellDiameter_ {}
 
Vec3 invCellDiameter_ {}
 
std::atomic< int > infiniteParticles_ {}
 
std::vector< std::atomic< int > > cells_ {}
 

Constructor & Destructor Documentation

walberla::mesa_pd::data::LinkedCells::LinkedCells ( const math::AABB domain,
const real_t  cellDiameter 
)
inline
walberla::mesa_pd::data::LinkedCells::LinkedCells ( const math::AABB domain,
const Vec3 cellDiameter 
)
inline

Member Function Documentation

void walberla::mesa_pd::data::LinkedCells::clear ( )
template<typename Selector , typename Accessor , typename Func , typename... Args>
void walberla::mesa_pd::data::LinkedCells::forEachParticlePair ( const bool  openmp,
const Selector &  selector,
Accessor &  acForLC,
Func &&  func,
Args &&...  args 
) const
inline

Calls the provided functor func for all particle pairs.

Additional arguments can be provided. No pairs with twice the same particle. Call syntax for the provided functor

func( *this, i, j, std::forward<Args>(args)... );
Parameters
openmpenables/disables OpenMP parallelization of the kernel call

< current cell index

< current particle index

< particle to be checked against

< neighbor particle index

< neighbor cell index

< neighbor particle index

< neighbor particle index

template<typename Selector , typename Accessor , typename Func , typename... Args>
void walberla::mesa_pd::data::LinkedCells::forEachParticlePairHalf ( const bool  openmp,
const Selector &  selector,
Accessor &  acForLC,
Func &&  func,
Args &&...  args 
) const
inline

Calls the provided functor func for all particle pairs.

Additional arguments can be provided. No pairs with twice the same particle are generated. No pair is called twice! Call syntax for the provided functor

func( *this, i, j, std::forward<Args>(args)... );
Parameters
openmpenables/disables OpenMP parallelization of the kernel call

< current cell index

< current particle index

< particle to be checked against

< neighbor particle index

< neighbor cell index

< neighbor particle index

< neighbor particle index

Member Data Documentation

Vec3 walberla::mesa_pd::data::LinkedCells::cellDiameter_ {}
std::vector< std::atomic<int> > walberla::mesa_pd::data::LinkedCells::cells_ {}
math::AABB walberla::mesa_pd::data::LinkedCells::domain_ {}
std::atomic<int> walberla::mesa_pd::data::LinkedCells::infiniteParticles_ {}
Vec3 walberla::mesa_pd::data::LinkedCells::invCellDiameter_ {}
Vector3<int> walberla::mesa_pd::data::LinkedCells::numCellsPerDim_ {}

The documentation for this struct was generated from the following file: