99 virtual void setSnapshot(
Snapshot* snap) { snap_ = snap; }
101 virtual void distributeInitialData() = 0;
102 virtual void distributeData() = 0;
103 virtual void zeroWorkArrays() = 0;
104 virtual void collectIntermediateData() = 0;
105 virtual void distributeIntermediateData() = 0;
106 virtual void collectData() = 0;
107 virtual void collectSelfData() = 0;
108 virtual potVec getSelfPotential() {
return selfPot; }
109 virtual potVec getPairwisePotential() {
return pairwisePot; }
110 virtual potVec getExcludedPotential() {
return excludedPot; }
111 virtual potVec getSelectedPotential() {
return selectedPot; }
112 virtual potVec getExcludedSelfPotential() {
return excludedSelfPot; }
113 virtual potVec getSelectedSelfPotential() {
return selectedSelfPot; }
116 virtual bool checkNeighborList(vector<Vector3d> savedPositions);
117 virtual void buildNeighborList(vector<int>& neighborList,
119 vector<Vector3d>& savedPositions) = 0;
121 void setCutoffRadius(RealType rCut);
124 virtual Vector3d& getGroupVelocityColumn(
int atom2) = 0;
127 virtual vector<int>& getAtomsInGroupRow(
int cg1) = 0;
128 virtual vector<int>& getAtomsInGroupColumn(
int cg2) = 0;
130 virtual Vector3d getAtomToGroupVectorRow(
int atom1,
int cg1) = 0;
131 virtual Vector3d getAtomToGroupVectorColumn(
int atom2,
int cg2) = 0;
132 virtual RealType& getMassFactorRow(
int atom1) = 0;
133 virtual RealType& getMassFactorColumn(
int atom2) = 0;
136 virtual Vector3d getIntergroupVector(
int cg1,
int cg2) = 0;
137 virtual Vector3d getInteratomicVector(
int atom1,
int atom2) = 0;
140 virtual int& getNAtomsInRow() = 0;
141 virtual vector<int>& getExcludesForAtom(
int atom1) = 0;
142 virtual bool skipAtomPair(
int atom1,
int atom2,
int cg1,
int cg2) = 0;
143 virtual bool excludeAtomPair(
int atom1,
int atom2) = 0;
144 virtual int getGlobalIDRow(
int atom1) = 0;
145 virtual int getGlobalIDCol(
int atom2) = 0;
146 virtual int getGlobalID(
int atom1) = 0;
148 virtual int getTopologicalDistance(
int atom1,
int atom2) = 0;
149 virtual void addForceToAtomRow(
int atom1,
Vector3d fg) = 0;
150 virtual void addForceToAtomColumn(
int atom2,
Vector3d fg) = 0;
151 virtual Vector3d& getAtomVelocityColumn(
int atom2) = 0;
155 int atom2,
bool newAtom1 =
true) = 0;
162 virtual void fillSelfData(
SelfData& sdat,
int atom);
163 virtual void unpackSelfData(
SelfData& sdat,
int atom);
165 virtual void fillPreForceData(
SelfData& sdat,
int atom);
166 virtual void unpackPreForceData(
SelfData& sdat,
int atom);
168 virtual void addToHeatFlux(
Vector3d hf);
169 virtual void setHeatFlux(
Vector3d hf);
178 int atomStorageLayout_;
179 int rigidBodyStorageLayout_;
180 int cutoffGroupStorageLayout_;
181 bool needVelocities_;
182 bool usePeriodicBoundaryConditions_;
206 vector<vector<int>> topoDist;
207 vector<vector<int>> excludesForAtom;
208 vector<vector<int>> groupList_;
209 vector<RealType> massFactors;
210 vector<AtomType*> atypesLocal;
212 vector<Vector3i> cellOffsets_;
214 vector<vector<int>> cellList_;