| 44 |
|
#include "utils/simError.h" |
| 45 |
|
namespace oopse { |
| 46 |
|
Integrator::Integrator(SimInfo* info) |
| 47 |
< |
: info_(info), forceMan_(NULL) , needPotential(false), needStress(false), needReset(false), velocitizer_(NULL), |
| 48 |
< |
needVelocityScaling(false), dumpWriter(NULL), statWriter(NULL), thermo(info), |
| 47 |
> |
: info_(info), forceMan_(NULL) , needPotential(false), needStress(false), |
| 48 |
> |
needReset(false), velocitizer_(NULL), needVelocityScaling(false), |
| 49 |
> |
dumpWriter(NULL), statWriter(NULL), thermo(info), |
| 50 |
|
currentSnapshot_(info->getSnapshotManager()->getCurrentSnapshot()) { |
| 51 |
|
|
| 52 |
|
simParams = info->getSimParams(); |
| 96 |
|
resetTime = simParams->getResetTime(); |
| 97 |
|
} |
| 98 |
|
|
| 99 |
< |
//create a default ForceManager |
| 100 |
< |
//if the subclass wants to use a different ForceManager, use setForceManager |
| 99 |
> |
// Create a default ForceManager: If the subclass wants to use |
| 100 |
> |
// a different ForceManager, use setForceManager |
| 101 |
|
forceMan_ = new ForceManager(info); |
| 102 |
|
|
| 102 |
– |
//set the force manager for thermodynamic integration if specified |
| 103 |
– |
if (simParams->getUseSolidThermInt() || simParams->getUseLiquidThermInt()){ |
| 104 |
– |
ThermoIntegrationForceManager* thermoForce_ |
| 105 |
– |
= new ThermoIntegrationForceManager(info); |
| 106 |
– |
setForceManager(thermoForce_); |
| 107 |
– |
} |
| 108 |
– |
|
| 103 |
|
// check for the temperature set flag (velocity scaling) |
| 104 |
|
if (simParams->haveTempSet()) { |
| 105 |
|
needVelocityScaling = simParams->getTempSet(); |
| 116 |
|
} |
| 117 |
|
} |
| 118 |
|
|
| 119 |
< |
//create a default a velocitizer |
| 120 |
< |
//if the subclass want to using different velocitizer, use setVelocitizer |
| 119 |
> |
// Create a default a velocitizer: If the subclass wants to use |
| 120 |
> |
// a different velocitizer, use setVelocitizer |
| 121 |
|
velocitizer_ = new Velocitizer(info); |
| 122 |
|
|
| 123 |
|
} |