AutoPas  3.0.0
Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes | List of all members
autopas::VLTraversalInterface< LinkedParticleCell > Class Template Reference

This class provides the Traversal Interface for the verlet lists container. More...

#include <VLTraversalInterface.h>

Inheritance diagram for autopas::VLTraversalInterface< LinkedParticleCell >:
Inheritance graph
[legend]
Collaboration diagram for autopas::VLTraversalInterface< LinkedParticleCell >:
Collaboration graph
[legend]

Public Member Functions

virtual ~VLTraversalInterface ()=default
 Destructor.
 
virtual void setCellsAndNeighborLists (std::vector< LinkedParticleCell > &cells, VerletListHelpers< ParticleType >::NeighborListCRS &neighborList, const std::unordered_map< const ParticleType *, size_t > &particleToIndex, const std::vector< ParticleType * > &indexToParticle)
 Sets the information the traversal needs for the iteration.
 

Protected Attributes

std::vector< LinkedParticleCell > * _cells = nullptr
 The cells of the underlying linked cells container of the verlet lists container.
 
VerletListHelpers< ParticleType >::NeighborListCRS * _neighborList = nullptr
 The flat CRS neighbor list.
 
const std::unordered_map< const ParticleType *, size_t > * _particleToIndex = nullptr
 Map from particle pointers to their dense SoA index.
 
const std::vector< ParticleType * > * _indexToParticle = nullptr
 Vector mapping SoA indices to particle pointers.
 

Detailed Description

template<class LinkedParticleCell>
class autopas::VLTraversalInterface< LinkedParticleCell >

This class provides the Traversal Interface for the verlet lists container.

The container only accepts traversals in its computeInteractions() method that implements this interface.

Template Parameters
LinkedParticleCellthe type of cells

Member Function Documentation

◆ setCellsAndNeighborLists()

template<class LinkedParticleCell >
virtual void autopas::VLTraversalInterface< LinkedParticleCell >::setCellsAndNeighborLists ( std::vector< LinkedParticleCell > &  cells,
VerletListHelpers< ParticleType >::NeighborListCRS &  neighborList,
const std::unordered_map< const ParticleType *, size_t > &  particleToIndex,
const std::vector< ParticleType * > &  indexToParticle 
)
inlinevirtual

Sets the information the traversal needs for the iteration.

Parameters
cellsThe cells of the underlying LinkedCells container.
neighborListThe flat CRS neighbor list.
particleToIndexMap from particle pointers to their dense SoA index.
indexToParticleVector mapping SoA indices to particle pointers.

Member Data Documentation

◆ _indexToParticle

template<class LinkedParticleCell >
const std::vector<ParticleType *>* autopas::VLTraversalInterface< LinkedParticleCell >::_indexToParticle = nullptr
protected

Vector mapping SoA indices to particle pointers.

Used by the AoS traversal path to resolve indices back to particle references.

◆ _particleToIndex

template<class LinkedParticleCell >
const std::unordered_map<const ParticleType *, size_t>* autopas::VLTraversalInterface< LinkedParticleCell >::_particleToIndex = nullptr
protected

Map from particle pointers to their dense SoA index.

Used by the rebuild traversal to create index-based neighbor lists.


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