27template <
class ParticleCell,
class PairwiseFunctor>
43 double interactionLength,
const std::array<double, 3> &cellLength,
44 const std::array<unsigned long, 3> &overlap, DataLayoutOption dataLayout,
bool useNewton3)
45 : _cellFunctor(pairwiseFunctor, interactionLength ,
46 dataLayout, useNewton3),
47 _interactionLength(interactionLength),
48 _cellLength(cellLength),
53 LCC08CellHandlerUtility::C08OffsetMode::c08CellPairsSorting>(cellsPerDimension, cellLength,
54 interactionLength)} {}
67 void setSortingThreshold(
size_t sortingThreshold) { _cellFunctor.setSortingThreshold(sortingThreshold); }
102 const double _interactionLength;
107 const std::array<double, 3> _cellLength;
110template <
class ParticleCell,
class PairwiseFunctor>
112 unsigned long baseIndex) {
113 for (
auto const &[offset1, offset2, r] : _cellPairOffsets) {
114 const unsigned long cellIndex1 = baseIndex + offset1;
115 const unsigned long cellIndex2 = baseIndex + offset2;
120 if (cellIndex1 == cellIndex2) {
121 this->_cellFunctor.processCell(cell1);
123 this->_cellFunctor.processCellPair(cell1, cell2, r);
This class provides the base for traversals using the c08 base step.
Definition: LCC08CellHandler.h:28
void setSortingThreshold(size_t sortingThreshold)
Set the sorting-threshold for traversals that use the CellFunctor If the sum of the number of particl...
Definition: LCC08CellHandler.h:67
LCC08CellHandler(PairwiseFunctor *pairwiseFunctor, const std::array< unsigned long, 3 > &cellsPerDimension, double interactionLength, const std::array< double, 3 > &cellLength, const std::array< unsigned long, 3 > &overlap, DataLayoutOption dataLayout, bool useNewton3)
Constructor of the LCC08CellHandler.
Definition: LCC08CellHandler.h:42
const std::array< unsigned long, 3 > _overlap
Overlap of interacting cells.
Definition: LCC08CellHandler.h:79
void processBaseCell(std::vector< ParticleCell > &cells, unsigned long baseIndex)
Computes one interaction for each spacial direction based on the lower left frontal corner (=base ind...
Definition: LCC08CellHandler.h:111
DataLayoutOption _dataLayout
The datalayout to be used.
Definition: LCC08CellHandler.h:84
std::vector< LCC08CellHandlerUtility::OffsetPairSorting > _cellPairOffsets
Pair sets for processBaseCell().
Definition: LCC08CellHandler.h:74
bool _useNewton3
If newton3 should be used or not.
Definition: LCC08CellHandler.h:89
PairwiseFunctor class.
Definition: PairwiseFunctor.h:31
Class for Cells of Particles.
Definition: ParticleCell.h:51
A cell functor.
Definition: CellFunctor.h:25
This is the main namespace of AutoPas.
Definition: AutoPasDecl.h:32