This class provides base for locked- and colored sliced traversals. More...
#include <SlicedBasedTraversal.h>


Public Member Functions | |
| SlicedBasedTraversal (const std::array< unsigned long, 3 > &dims, Functor *functor, const double interactionLength, const std::array< double, 3 > &cellLength, DataLayoutOption dataLayout, bool useNewton3, bool spaciallyForward) | |
| Constructor of the sliced traversal. | |
| bool | isApplicable () const override |
| Checks if the traversal is applicable to the current state of the domain. | |
| virtual void | initSliceThickness (unsigned long minSliceThickness) |
| Sets up the slice thicknesses to create as many slices as possible while respecting minSliceThickness. | |
| void | initTraversal () override |
| Load Data Layouts and sets up slice thicknesses. | |
| void | endTraversal () override |
| Write Data to AoS if cells have been set through setCellsToTraverse(). | |
Public Member Functions inherited from autopas::CellTraversal< ParticleCell > | |
| CellTraversal (const std::array< unsigned long, 3 > &dims) | |
| Constructor of CellTraversal. | |
| virtual | ~CellTraversal ()=default |
| Destructor of CellTraversal. | |
| virtual void | setCellsToTraverse (std::vector< ParticleCell > &cells) |
| Sets the cells to iterate over. | |
| virtual void | setSortingThreshold (size_t sortingThreshold)=0 |
| Set the sorting-threshold for traversals that use the CellFunctor If the sum of the number of particles in two cells is greater or equal to that value, the CellFunctor creates a sorted view of the particles to avoid unnecessary distance checks. | |
Public Member Functions inherited from autopas::TraversalInterface | |
| virtual | ~TraversalInterface ()=default |
| Destructor of TraversalInterface. | |
| TraversalInterface (DataLayoutOption dataLayout, bool useNewton3) | |
| Constructor of the TraversalInterface. | |
| virtual TraversalOption | getTraversalType () const =0 |
| Return a enum representing the name of the traversal class. | |
| virtual bool | isApplicable () const =0 |
| Checks if the traversal is applicable to the current state of the domain. | |
| virtual void | initTraversal ()=0 |
| Initializes the traversal. | |
| virtual void | traverseParticles ()=0 |
| Traverse the particles by pairs, triplets etc. | |
| virtual void | endTraversal ()=0 |
| Finalizes the traversal. | |
| bool | getUseNewton3 () const |
| Return whether the traversal uses newton 3. | |
| DataLayoutOption | getDataLayout () const |
| Return the data layout option. | |
Protected Member Functions | |
| void | init () |
| Resets the cell structure of the traversal. | |
| virtual void | loadDataLayout () |
| Load Data Layouts required for this Traversal if cells have been set through setCellsToTraverse(). | |
| void | reinitForVCL (const VerletClusterLists< typename ParticleCell::ParticleType > *vcl) |
| Update cell information based on VerletClusterLists. | |
Protected Attributes | |
| std::array< unsigned long, 3 > | _overlap |
| Overlap of interacting cells. | |
| std::array< int, 3 > | _dimsSortedByLength |
| Store ids of dimensions (0, 1, 2 = x, y, z) sorted by in decreasing order of number of cells in that dimension. | |
| unsigned long | _overlapLongestAxis |
| Overlap of interacting cells along the longest axis. | |
| std::vector< unsigned long > | _sliceThickness |
| The number of cells per slice in the dimension that was sliced. | |
| bool | _spaciallyForward |
| Whether the base step only covers neigboring cells tha are spacially forward (for example c08). | |
| std::array< double, 3 > | _cellLength |
| Cell length in CellBlock3D. | |
Protected Attributes inherited from autopas::CellTraversal< ParticleCell > | |
| std::array< unsigned long, 3 > | _cellsPerDimension |
| The dimensions of the cellblock. | |
| std::vector< ParticleCell > * | _cells |
| The cells to traverse. | |
Protected Attributes inherited from autopas::TraversalInterface | |
| DataLayoutOption | _dataLayout |
| The datalayout used by this traversal. | |
| bool | _useNewton3 |
| If this traversal makes use of newton3. | |
This class provides base for locked- and colored sliced traversals.
These traversals find the longest dimension of the simulation domain and cut the domain into multiple slices along this dimension. Slices are assigned to the threads in a round robin fashion.
| ParticleCell | The type of cells. |
| Functor | The functor that defines the interaction between particles. |
|
inlineexplicit |
Constructor of the sliced traversal.
| dims | The dimensions of the cellblock, i.e. the number of cells in x, y and z direction. |
| functor | The functor that defines the interaction between particles. |
| interactionLength | Interaction length (cutoff + skin). |
| cellLength | cell length. |
| dataLayout | The data layout with which this traversal should be initialized. |
| useNewton3 | Parameter to specify whether the traversal makes use of newton3 or not. |
| spaciallyForward | Whether the base step only covers neighboring cells that are spacially forward (for example c08). |
|
inlineoverridevirtual |
Write Data to AoS if cells have been set through setCellsToTraverse().
Implements autopas::TraversalInterface.
Reimplemented in autopas::VCLSlicedBalancedTraversal< ParticleCell, PairwiseFunctor >, autopas::VCLSlicedC02Traversal< ParticleCell, PairwiseFunctor >, and autopas::VCLSlicedTraversal< ParticleCell, PairwiseFunctor >.
|
inlinevirtual |
Sets up the slice thicknesses to create as many slices as possible while respecting minSliceThickness.
| minSliceThickness |
Reimplemented in autopas::SlicedBalancedBasedTraversal< ParticleCell, Functor >, and autopas::SlicedBalancedBasedTraversal< ParticleCell, PairwiseFunctor >.
|
inlineoverridevirtual |
Load Data Layouts and sets up slice thicknesses.
Implements autopas::TraversalInterface.
Reimplemented in autopas::SlicedC02BasedTraversal< ParticleCell, Functor >, autopas::SlicedC02BasedTraversal< ParticleCell, PairwiseFunctor >, autopas::VCLSlicedBalancedTraversal< ParticleCell, PairwiseFunctor >, autopas::VCLSlicedC02Traversal< ParticleCell, PairwiseFunctor >, and autopas::VCLSlicedTraversal< ParticleCell, PairwiseFunctor >.
|
inlineoverridevirtual |
Checks if the traversal is applicable to the current state of the domain.
Implements autopas::TraversalInterface.
Reimplemented in autopas::SlicedC02BasedTraversal< ParticleCell, Functor >, autopas::SlicedC02BasedTraversal< ParticleCell, PairwiseFunctor >, autopas::VLCSlicedBalancedTraversal< ParticleCell, PairwiseFunctor, NeighborList >, autopas::VLCSlicedC02Traversal< ParticleCell, PairwiseFunctor, NeighborList >, and autopas::VLCSlicedTraversal< ParticleCell, PairwiseFunctor, NeighborList >.
|
inlineprotectedvirtual |
Load Data Layouts required for this Traversal if cells have been set through setCellsToTraverse().
Reimplemented in autopas::VCLSlicedBalancedTraversal< ParticleCell, PairwiseFunctor >, autopas::VCLSlicedC02Traversal< ParticleCell, PairwiseFunctor >, and autopas::VCLSlicedTraversal< ParticleCell, PairwiseFunctor >.
|
inlineprotected |
Update cell information based on VerletClusterLists.
| vcl | Pointer to the VerletClusterLists object from which cell information is extracted. |
|
protected |
Overlap of interacting cells.
Array allows asymmetric cell sizes.