class nneigh::SkinNeighborList#

Overview#

Persistent neighbour list with a LAMMPS skin. More…

#include <src/include/internal/neighbours.hpp>
 
class SkinNeighborList {
public:
    // construction
 
    SkinNeighborList(double cutoff, double skin, int typeI, BondGraph graph = BondGraph::KnnMutual, int k = 4);
 
    // methods
 
    BondGraph graph() const;
    const std::vector<std::vector<int>>& update(const molSys::PointCloud<molSys::Point<double>, double>& yCloud);
    bool lastRebuilt() const;
    int lastChangedAtoms() const;
    const std::vector<std::vector<int>>& bonds() const;
};

Detailed Documentation#

Persistent neighbour list with a LAMMPS skin.

linkcell’s half rows are the candidates at cutoff+skin, which is the ghost halo: periodic images already sit in that shell. The cell list is rebuilt only when some atom has moved more than skin/2 from the last rebuild, the Verlet trigger. The bond graph for rings is the candidate pairs whose current distance is inside the analysis cutoff.

Construction#

SkinNeighborList(double cutoff, double skin, int typeI, BondGraph graph = BondGraph::KnnMutual, int k = 4)

graph selects cutoff vs k-nearest (mutual or union). k is the neighbour count for the knn graphs (default 4).

Methods#

const std::vector<std::vector<int>>& update(const molSys::PointCloud<molSys::Point<double>, double>& yCloud)

Refresh from a new frame. The returned list is ID-keyed with a leading self entry, the same shape as neighListO.

int lastChangedAtoms() const

Atoms whose cutoff bond set changed on the last update.