36 |
|
* [1] Meineke, et al., J. Comp. Chem. 26, 252-271 (2005). |
37 |
|
* [2] Fennell & Gezelter, J. Chem. Phys. 124, 234104 (2006). |
38 |
|
* [3] Sun, Lin & Gezelter, J. Chem. Phys. 128, 24107 (2008). |
39 |
< |
* [4] Vardeman & Gezelter, in progress (2009). |
39 |
> |
* [4] Kuang & Gezelter, J. Chem. Phys. 133, 164101 (2010). |
40 |
> |
* [5] Vardeman, Stocker & Gezelter, J. Chem. Theory Comput. 7, 834 (2011). |
41 |
|
*/ |
42 |
|
|
43 |
|
/** |
65 |
|
#include "utils/LocalIndexManager.hpp" |
66 |
|
#include "nonbonded/SwitchingFunction.hpp" |
67 |
|
|
67 |
– |
//another nonsense macro declaration |
68 |
– |
#define __OPENMD_C |
69 |
– |
#include "brains/fSimulation.h" |
70 |
– |
|
68 |
|
using namespace std; |
69 |
|
namespace OpenMD{ |
70 |
< |
//forward decalration |
70 |
> |
//forward declaration |
71 |
|
class SnapshotManager; |
72 |
|
class Molecule; |
73 |
|
class SelectionManager; |
167 |
|
return nAtoms_; |
168 |
|
} |
169 |
|
|
170 |
+ |
/** Returns the number of effective cutoff groups on local processor */ |
171 |
+ |
unsigned int getNLocalCutoffGroups(); |
172 |
+ |
|
173 |
|
/** Returns the number of local bonds */ |
174 |
|
unsigned int getNBonds(){ |
175 |
|
return nBonds_; |
302 |
|
|
303 |
|
void update(); |
304 |
|
/** |
305 |
< |
* Setup Fortran Simulation |
305 |
> |
* Do final bookkeeping before Force managers need their data. |
306 |
|
*/ |
307 |
< |
void setupFortran(); |
307 |
> |
void prepareTopology(); |
308 |
|
|
309 |
|
|
310 |
|
/** Returns the local index manager */ |
355 |
|
* processor, these should be identical. |
356 |
|
*/ |
357 |
|
vector<int> getGlobalGroupIndices(); |
358 |
+ |
|
359 |
|
|
360 |
|
string getFinalConfigFileName() { |
361 |
|
return finalConfigFileName_; |
415 |
|
} |
416 |
|
|
417 |
|
|
418 |
< |
bool isFortranInitialized() { |
419 |
< |
return fortranInitialized_; |
418 |
> |
bool isTopologyDone() { |
419 |
> |
return topologyDone_; |
420 |
|
} |
421 |
|
|
422 |
|
bool getCalcBoxDipole() { |
555 |
|
private: |
556 |
|
/// Data structures holding primary simulation objects |
557 |
|
map<int, Molecule*> molecules_; /**< map holding pointers to LOCAL molecules */ |
557 |
– |
simtype fInfo_; /**< A dual struct shared by C++ |
558 |
– |
and Fortran to pass |
559 |
– |
information about what types |
560 |
– |
of calculation are |
561 |
– |
required */ |
558 |
|
|
559 |
|
/// Stamps are templates for objects that are then used to create |
560 |
|
/// groups of objects. For example, a molecule stamp contains |
591 |
|
public: |
592 |
|
vector<int> getIdentArray() { return identArray_; } |
593 |
|
private: |
594 |
+ |
|
595 |
+ |
/** |
596 |
+ |
* A vector which contains the fractional contribution of an |
597 |
+ |
* atom's mass to the total mass of the cutoffGroup that atom |
598 |
+ |
* belongs to. In the case of single atom cutoff groups, the mass |
599 |
+ |
* factor for that atom is 1. For massless atoms, the factor is |
600 |
+ |
* also 1. |
601 |
+ |
*/ |
602 |
+ |
vector<RealType> massFactors_; |
603 |
+ |
public: |
604 |
+ |
vector<RealType> getMassFactors() { return massFactors_; } |
605 |
+ |
|
606 |
+ |
PairList* getExcludedInteractions() { return &excludedInteractions_; } |
607 |
+ |
PairList* getOneTwoInteractions() { return &oneTwoInteractions_; } |
608 |
+ |
PairList* getOneThreeInteractions() { return &oneThreeInteractions_; } |
609 |
+ |
PairList* getOneFourInteractions() { return &oneFourInteractions_; } |
610 |
+ |
|
611 |
+ |
private: |
612 |
|
|
613 |
|
/// lists to handle atoms needing special treatment in the non-bonded interactions |
614 |
|
PairList excludedInteractions_; /**< atoms excluded from interacting with each other */ |
639 |
|
string restFileName_; |
640 |
|
|
641 |
|
|
642 |
< |
bool fortranInitialized_; /** flag to indicate whether the fortran side is initialized */ |
642 |
> |
bool topologyDone_; /** flag to indicate whether the topology has |
643 |
> |
been scanned and all the relevant |
644 |
> |
bookkeeping has been done*/ |
645 |
|
|
646 |
|
bool calcBoxDipole_; /**< flag to indicate whether or not we calculate |
647 |
|
the simulation box dipole moment */ |