--- trunk/src/integrators/Velocitizer.cpp 2005/05/30 14:01:52 555 +++ trunk/src/integrators/Velocitizer.cpp 2006/05/17 21:51:42 963 @@ -83,7 +83,7 @@ namespace oopse { delete randNumGen_; } - void Velocitizer::velocitize(double temperature) { + void Velocitizer::velocitize(RealType temperature) { Vector3d aVel; Vector3d aJ; Mat3x3d I; @@ -91,11 +91,11 @@ namespace oopse { int m; int n; Vector3d vdrift; - double vbar; + RealType vbar; /**@todo refactory kb */ - const double kb = 8.31451e-7; // kb in amu, angstroms, fs, etc. - double av2; - double kebar; + const RealType kb = 8.31451e-7; // kb in amu, angstroms, fs, etc. + RealType av2; + RealType kebar; Globals * simParams = info_->getSimParams(); @@ -157,7 +157,7 @@ namespace oopse { removeComDrift(); // Remove angular drift if we are not using periodic boundary conditions. - if(simParams->getPBC()) removeAngularDrift(); + if(!simParams->getUsePeriodicBoundaryConditions()) removeAngularDrift(); } @@ -202,14 +202,18 @@ namespace oopse { info_->getInertiaTensor(inertiaTensor,angularMomentum); // We now need the inverse of the inertia tensor. - + /* std::cerr << "Angular Momentum before is " - << angularMomentum << std::endl; - + << angularMomentum << std::endl; + std::cerr << "Inertia Tensor before is " + << inertiaTensor << std::endl; + */ - inertiaTensor.inverse(); - - + inertiaTensor =inertiaTensor.inverse(); + /* + std::cerr << "Inertia Tensor after inverse is " + << inertiaTensor << std::endl; + */ omega = inertiaTensor*angularMomentum; SimInfo::MoleculeIterator i; @@ -231,9 +235,10 @@ namespace oopse { } angularMomentum = info_->getAngularMomentum(); + /* std::cerr << "Angular Momentum after is " << angularMomentum << std::endl; - + */ }