18template <
class Particle_T>
37 double interactionLength,
const TraversalOption vlcTraversalOpt,
67 template <
class TFunctor>
74 std::vector<size_t> offsets(cells.size() + 1);
76 cells.begin(), cells.end(), offsets.begin() + 1,
77 [](
const size_t &partialSum,
const auto &cell) { return partialSum + cell.size(); }, 0);
81 for (
size_t i = 0; i < cells.size(); ++i) {
82 f->SoALoader(cells[i],
_soa, offsets[i],
true);
93 template <
class TFunctor>
97 f->SoAExtractor(cell,
_soa, offset);
98 offset += cell.size();
139 double interactionLength,
const TraversalOption &vlcTraversalOpt,
#define AUTOPAS_OPENMP(args)
Empty macro to throw away any arguments.
Definition: WrapOpenMP.h:126
LinkedCells class.
Definition: LinkedCells.h:40
Structur of the array class.
Definition: SoA.h:28
void resizeArrays(size_t length)
Resizes all Vectors to the given length.
Definition: SoA.h:45
void clear()
delete all particles in the soa
Definition: SoA.h:186
This interface serves as a common parent class for all traversals.
Definition: TraversalInterface.h:18
Interface of neighbor lists to be used with VerletListsCells container.
Definition: VLCNeighborListInterface.h:19
void setLinkedCellsPointer(LinkedCells< Particle_T > *linkedCells)
Set the Linked Cells Pointer for this List.
Definition: VLCNeighborListInterface.h:115
virtual void generateSoAFromAoS(LinkedCells< Particle_T > &linkedCells)=0
Generates neighbor list in SoA layout from available neighbor list in AoS layout.
SoA< typename Particle_T::SoAArraysType > _soa
Structure of arrays necessary for SoA data layout.
Definition: VLCNeighborListInterface.h:126
void extractSoA(TFunctor *f)
Extracts cells from structure of arrays.
Definition: VLCNeighborListInterface.h:94
virtual ContainerOption getContainerType() const =0
Returns the container type of this neighbor list and the container it belongs to.
virtual void applyBuildFunctor(LinkedCells< Particle_T > &linkedCells, bool useNewton3, double cutoff, double skin, double interactionLength, const TraversalOption &vlcTraversalOpt, typename VerletListsCellsHelpers::VLCBuildType buildType)=0
Creates and applies a generator functor for the building of the neighbor list.
virtual size_t getNumberOfPartners(const Particle_T *particle) const =0
Gets the number of neighbors over all neighbor lists that belong to this particle.
virtual ~VLCNeighborListInterface()=default
Virtual default destructor.
auto * loadSoA(TFunctor *f)
Loads cells into structure of arrays.
Definition: VLCNeighborListInterface.h:68
virtual void buildAoSNeighborList(LinkedCells< Particle_T > &linkedCells, bool useNewton3, double cutoff, double skin, double interactionLength, const TraversalOption vlcTraversalOpt, typename VerletListsCellsHelpers::VLCBuildType buildType)=0
Builds AoS neighbor list from underlying linked cells object.
LinkedCells< Particle_T > * _internalLinkedCells
Internal linked cells structure.
Definition: VLCNeighborListInterface.h:121
virtual void setUpTraversal(TraversalInterface *traversal)=0
Assigns the current traversal to the correct traversal interface.
VLCBuildType
Indicates which build functor should be used for the generation of the neighbor list.
Definition: VerletListsCellsHelpers.h:44
This is the main namespace of AutoPas.
Definition: AutoPasDecl.h:32