ls1-MarDyn
ls1-MarDyn molecular dynamics code
|
#include <AutoPasContainer.h>
Public Member Functions | |
AutoPasContainer (double cutoff) | |
void | readXML (XMLfileUnits &xmlconfig) override |
bool | rebuild (double bBoxMin[3], double bBoxMax[3]) override |
rebuild the datastructure More... | |
void | update () override |
do necessary updates resulting from changed particle positions More... | |
bool | addParticle (Molecule &particle, bool inBoxCheckedAlready=false, bool checkWhetherDuplicate=false, const bool &rebuildCaches=false) override |
add a single Molecule to the ParticleContainer. More... | |
bool | addHaloParticle (Molecule &particle, bool inBoxCheckedAlready=false, bool checkWhetherDuplicate=false, const bool &rebuildCaches=false) override |
add a single Molecule to the ParticleContainer, ensures that it is added in the halo. More... | |
void | addParticles (std::vector< Molecule > &particles, bool checkWhetherDuplicate=false) override |
adds a whole vector of particles More... | |
void | traverseCells (CellProcessor &cellProcessor) override |
traverse pairs which are close to each other More... | |
void | traverseNonInnermostCells (CellProcessor &cellProcessor) override |
void | traversePartialInnermostCells (CellProcessor &cellProcessor, unsigned int stage, int stageCount) override |
ParticleIterator | iterator (ParticleIterator::Type t) override |
RegionParticleIterator | regionIterator (const double startCorner[3], const double endCorner[3], ParticleIterator::Type t) override |
unsigned long | getNumberOfParticles () override |
void | clear () override |
Delete all molecules in container. More... | |
void | deleteOuterParticles () override |
delete all Particles which are not within the bounding box More... | |
double | get_halo_L (int index) const override |
returns the width of the halo stripe (for the given dimension index) More... | |
double | getCutoff () const override |
double | getSkin () const override |
void | deleteMolecule (ParticleIterator &moleculeIter, const bool &rebuildCaches) override |
double | getEnergy (ParticlePairsHandler *particlePairsHandler, Molecule *m1, CellProcessor &cellProcessor) override |
void | updateInnerMoleculeCaches () override |
Update the caches of the molecules, that lie in inner cells. The caches of boundary and halo cells is not updated. This method is used for a multi-step scheme of overlapping mpi communication. More... | |
void | updateBoundaryAndHaloMoleculeCaches () override |
Update the caches of the molecules, that lie in the boundary or halo cells. The caches of boundary and halo cells is updated, the caches of the inner cells are not updated. This method is used for a multi-step scheme of overlapping mpi communication. More... | |
void | updateMoleculeCaches () override |
Update the caches of the molecules. More... | |
std::variant< ParticleIterator, SingleCellIterator< ParticleCell > > | getMoleculeAtPosition (const double pos[3]) override |
Gets a molecule by its position. More... | |
unsigned long | initCubicGrid (std::array< unsigned long, 3 > numMoleculesPerDimension, std::array< double, 3 > simBoxLength, size_t seed_offset) override |
double * | getCellLength () override |
double * | getHaloSize () override |
size_t | getTotalSize () override |
void | printSubInfo (int offset) override |
std::string | getName () override |
void | setCutoff (double cutoff) override |
std::vector< Molecule > | getInvalidParticles () override |
bool | isInvalidParticleReturner () override |
std::string | getConfigurationAsString () override |
![]() | |
ParticleContainer (double bBoxMin[3], double bBoxMax[3]) | |
The constructor. More... | |
ParticleContainer () | |
Default constructor. | |
virtual | ~ParticleContainer () |
The destructor. | |
virtual double | getBoundingBoxMin (int dimension) const |
returns one coordinate of the lower corner of the bounding box More... | |
virtual bool | isInBoundingBox (double r[3]) const |
checks, whether given coordinates are within the bounding box More... | |
virtual int | getHaloWidthNumCells () |
virtual double | getBoundingBoxMax (int dimension) const |
returns one coordinate of the higher corner of the bounding box More... | |
virtual bool | requiresForceExchange () const |
virtual std::vector< unsigned long > | getParticleCellStatistics () |
Additional Inherited Members | |
![]() | |
double | _boundingBoxMin [3] |
coordinates of the left, lower, front corner of the bounding box | |
double | _boundingBoxMax [3] |
coordinates of the right, upper, back corner of the bounding box | |
A wrapper for the AutoPas library.
|
overridevirtual |
add a single Molecule to the ParticleContainer, ensures that it is added in the halo.
Note: a copy of the particle is pushed. Destroying the argument is responsibility of the programmer.
particle | reference to the particle which has to be added |
inBoxCheckedAlready | - if true, spare check whether molecule is in bounding box |
checkWhetherDuplicate | - if true, check whether molecule already exists and don't insert it. |
rebuildCaches | specifies, whether the caches should be rebuild |
Reimplemented from ParticleContainer.
|
overridevirtual |
add a single Molecule to the ParticleContainer.
Note: a copy of the particle is pushed. Destroying the argument is responsibility of the programmer.
particle | reference to the particle which has to be added |
inBoxCheckedAlready | - if true, spare check whether molecule is in bounding box |
checkWhetherDuplicate | - if true, check whether molecule already exists and don't insert it. |
rebuildCaches | specifies, whether the caches should be rebuild |
Implements ParticleContainer.
|
overridevirtual |
adds a whole vector of particles
particles | reference to a vector of pointers to particles |
Implements ParticleContainer.
|
overridevirtual |
Delete all molecules in container.
Implements ParticleContainer.
|
overridevirtual |
Implements ParticleContainer.
|
overridevirtual |
delete all Particles which are not within the bounding box
Implements ParticleContainer.
|
overridevirtual |
returns the width of the halo stripe (for the given dimension index)
Implements ParticleContainer.
|
overridevirtual |
Implements ParticleContainer.
|
overridevirtual |
Return a string representation of the algorithmic configuration of the container. Only used for logging / output.
Implements ParticleContainer.
|
overridevirtual |
Implements ParticleContainer.
|
overridevirtual |
Implements ParticleContainer.
|
overridevirtual |
|
inlineoverridevirtual |
Reimplemented from ParticleContainer.
|
overridevirtual |
Gets a molecule by its position.
pos | Molecule position |
Implements ParticleContainer.
|
inlineoverridevirtual |
Implements MemoryProfilable.
|
overridevirtual |
This number may include particles which are outside of the bounding box
Implements ParticleContainer.
|
overridevirtual |
Reimplemented from ParticleContainer.
|
inlineoverridevirtual |
Implements MemoryProfilable.
|
overridevirtual |
Implements ParticleContainer.
|
inlineoverridevirtual |
Reimplemented from ParticleContainer.
|
overridevirtual |
Implements ParticleContainer.
|
inlineoverridevirtual |
Implements MemoryProfilable.
|
overridevirtual |
This function parses parameters for the AutoPas container. The following xml object structure is handled by this method:
If you are using MPI-parallel simulations, tuningSamples should be a multiple of rebuildFrequency! A list of the different Options can be found here: https://www5.in.tum.de/AutoPas/doxygen_doc/master/namespaceautopas_1_1options.html For multiple options, a comma separated list of strings is possible. Auto-Tuning is then performed on all possible combinations of those.
xmlconfig |
Implements ParticleContainer.
|
overridevirtual |
rebuild the datastructure
Load-balancing decompositions change the position and size of the local region during runtime. Therefore, the datastructure needs to be rebuild completely. This method basically does what the constructor does as well, with the difference, that there are already particles stored, and particles which don't belong to the new region have to be deleted after rebuild @parameter bBoxMin minimum of the box @parameter bBoxMax maximum of the box
Reimplemented from ParticleContainer.
|
overridevirtual |
Implements ParticleContainer.
|
inlineoverridevirtual |
|
overridevirtual |
traverse pairs which are close to each other
Only interactions between particles which have a distance which is not larger than the cutoff radius are to be considered.
This method has to be implemented in derived classes Precondition: All Particles of the process + halo molecules are stored Task: Run over all pairs (Each pair exactely once!) of particles (within cutoffradius) Important: Some pairs might be "duplicated": All pairs which cross the boundary occur twice (second time at the periodic image). Those pairs are from the point of view of the datastructure two different pairs, but they both times connect the same particles. For a pair which occurs twice, it has to be made sure, that one gets the status "original pair" and the other one "duplicated pair". For each pair found, there is an action executed, but it is a different action for original and duplicated pairs. Details about how to handle pairs can be found in the documentation for the class ParticlePairsHandler
particlePairsHandler | specified concrete action to be done for each pair |
Implements ParticleContainer.
|
overridevirtual |
Implements ParticleContainer.
|
overridevirtual |
Implements ParticleContainer.
|
overridevirtual |
do necessary updates resulting from changed particle positions
For some implementations of the interface ParticleContainer, the place where particles are stored might e.g. depend on the spacial position of the particle. So when some externel method (e.g. Leap-Frog) changes the spacial position of a particle, the representation within the particleContainer becomes invalid. This method restores a valid representation.
Implements ParticleContainer.
|
overridevirtual |
Update the caches of the molecules, that lie in the boundary or halo cells. The caches of boundary and halo cells is updated, the caches of the inner cells are not updated. This method is used for a multi-step scheme of overlapping mpi communication.
Implements ParticleContainer.
|
overridevirtual |
Update the caches of the molecules, that lie in inner cells. The caches of boundary and halo cells is not updated. This method is used for a multi-step scheme of overlapping mpi communication.
Implements ParticleContainer.
|
overridevirtual |
Update the caches of the molecules.
Implements ParticleContainer.