| 55 |
|
#include "restraints/ThermoIntegrationForceManager.hpp" |
| 56 |
|
#include "io/DumpWriter.hpp" |
| 57 |
|
#include "io/StatWriter.hpp" |
| 58 |
+ |
#include "integrators/RotationAlgorithm.hpp" |
| 59 |
+ |
#include "integrators/FluctuatingChargePropagator.hpp" |
| 60 |
|
#include "integrators/Velocitizer.hpp" |
| 61 |
|
#include "integrators/RNEMD.hpp" |
| 62 |
+ |
#include "constraints/Rattle.hpp" |
| 63 |
|
|
| 64 |
|
namespace OpenMD { |
| 65 |
|
|
| 79 |
|
doIntegrate(); |
| 80 |
|
} |
| 81 |
|
|
| 82 |
< |
void update() { |
| 83 |
< |
doUpdate(); |
| 82 |
> |
void updateSizes() { |
| 83 |
> |
doUpdateSizes(); |
| 84 |
> |
flucQ_->updateSizes(); |
| 85 |
|
} |
| 86 |
|
|
| 87 |
|
void setForceManager(ForceManager* forceMan) { |
| 99 |
|
velocitizer_ = velocitizer; |
| 100 |
|
} |
| 101 |
|
|
| 102 |
+ |
void setFluctuatingChargePropagator(FluctuatingChargePropagator* prop) { |
| 103 |
+ |
if (prop != flucQ_ && flucQ_ != NULL){ |
| 104 |
+ |
delete flucQ_; |
| 105 |
+ |
} |
| 106 |
+ |
flucQ_ = prop; |
| 107 |
+ |
} |
| 108 |
+ |
|
| 109 |
+ |
void setRotationAlgorithm(RotationAlgorithm* algo) { |
| 110 |
+ |
if (algo != rotAlgo_ && rotAlgo_ != NULL){ |
| 111 |
+ |
delete rotAlgo_; |
| 112 |
+ |
} |
| 113 |
+ |
|
| 114 |
+ |
rotAlgo_ = algo; |
| 115 |
+ |
} |
| 116 |
+ |
|
| 117 |
|
void setRNEMD(RNEMD* rnemd) { |
| 118 |
|
if (rnemd_ != rnemd && rnemd_ != NULL) { |
| 119 |
|
delete rnemd_; |
| 127 |
|
|
| 128 |
|
virtual void doIntegrate() = 0; |
| 129 |
|
|
| 130 |
< |
virtual void doUpdate() {} |
| 130 |
> |
virtual void doUpdateSizes() {} |
| 131 |
|
|
| 132 |
|
void saveConservedQuantity() { |
| 133 |
|
currentSnapshot_->statData[Stats::CONSERVED_QUANTITY] = calcConservedQuantity(); |
| 136 |
|
SimInfo* info_; |
| 137 |
|
Globals* simParams; |
| 138 |
|
ForceManager* forceMan_; |
| 139 |
+ |
RotationAlgorithm* rotAlgo_; |
| 140 |
+ |
FluctuatingChargePropagator* flucQ_; |
| 141 |
+ |
Rattle* rattle_; |
| 142 |
+ |
Velocitizer* velocitizer_; |
| 143 |
+ |
RNEMD* rnemd_; |
| 144 |
+ |
|
| 145 |
|
bool needPotential; |
| 146 |
|
bool needStress; |
| 147 |
|
bool needReset; |
| 123 |
– |
Velocitizer* velocitizer_; |
| 124 |
– |
RNEMD* rnemd_; |
| 148 |
|
bool needVelocityScaling; |
| 149 |
|
RealType targetScalingTemp; |
| 150 |
|
|