void reflectParticle(Particle &p, Cell &fromCell, Cell &toCell, CellContainer *lc, int direction)
Reflects a particle by mirroring its position and moving it to a new cell.
void handleOutflowCondition(Particle &p, Cell &targetCell, CellContainer *lc)
Handles the outflow condition where the particle is deleted upon entering a halo cell.
void handlePeriodicCondition(Particle &p, Cell &targetCell, CellContainer *lc)
Handles the periodic condition where the particle is moved from the halo cell to the appropriate bord...
void mirrorGhostParticles(CellContainer *lc)
Adds ghost particles to the proper halo cells for periodic conditions.
void deleteGhostParticles(CellContainer *lc)
Deletes references to ghost particles from the halo cells (i.e all particle references in halo cells)...
bool handleHaloCell(Particle &p, Cell &targetCell, CellContainer *lc)
Handles the scenario where a particle enters a halo cell. Returns true if the particle is handled and...
void handleReflectiveCondition(Particle &p, Cell &fromCell, HaloLocation location, CellContainer *lc)
Handles the reflective condition where the particle is mirrored and moved to the opposite cell.
std::pair< HaloLocation, BoundaryCondition > determineBoundaryCondition(Particle &p, Cell &targetCell, CellContainer *lc)
Determines the correct halo location and boundary condition for a particle entering a halo cell.
Class for holding a vector of Cells that divide a domain of Particle objects.
Utility functions for Cell and CellContainer objects.
HaloLocation
Enum containing the possible corner and edge directions of halo cells.
Definition CellUtils.h:22
A single Cell in a CellContainer, for use with the linked cells method.
Model of a single particle.
Cell encapsulation class for implementing the linked cell method.
Definition CellContainer.h:31
Class for storing data of a single Cell in a domain split into cells.
Definition Cell.h:23
Particle class modeling a particle's position, velocity, force, mass and type.
Definition Particle.h:46