ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE-4/src/integrators/Velocitizer.cpp
(Generate patch)

Comparing trunk/OOPSE-4/src/integrators/Velocitizer.cpp (file contents):
Revision 2256 by chuckv, Tue May 31 22:31:54 2005 UTC vs.
Revision 2759 by tim, Wed May 17 21:51:42 2006 UTC

# Line 83 | Line 83 | namespace oopse {
83      delete randNumGen_;
84    }
85    
86 <  void Velocitizer::velocitize(double temperature) {
86 >  void Velocitizer::velocitize(RealType temperature) {
87      Vector3d aVel;
88      Vector3d aJ;
89      Mat3x3d I;
# Line 91 | Line 91 | namespace oopse {
91      int m;
92      int n;
93      Vector3d vdrift;
94 <    double vbar;
94 >    RealType vbar;
95      /**@todo refactory kb */
96 <    const double kb = 8.31451e-7; // kb in amu, angstroms, fs, etc.
97 <    double av2;
98 <    double kebar;
96 >    const RealType kb = 8.31451e-7; // kb in amu, angstroms, fs, etc.
97 >    RealType av2;
98 >    RealType kebar;
99      
100      Globals * simParams = info_->getSimParams();
101      
# Line 157 | Line 157 | namespace oopse {
157      
158      removeComDrift();
159      // Remove angular drift if we are not using periodic boundary conditions.
160 <    if(!simParams->getPBC()) removeAngularDrift();
160 >    if(!simParams->getUsePeriodicBoundaryConditions()) removeAngularDrift();
161      
162    }
163    
# Line 202 | Line 202 | namespace oopse {
202        
203        info_->getInertiaTensor(inertiaTensor,angularMomentum);
204        // We now need the inverse of the inertia tensor.
205 <      
205 >      /*      
206        std::cerr << "Angular Momentum before is "
207                  << angularMomentum <<  std::endl;
208        std::cerr << "Inertia Tensor before is "
209                  << inertiaTensor <<  std::endl;
210 +      */
211        
211      
212        inertiaTensor =inertiaTensor.inverse();
213 +      /*
214         std::cerr << "Inertia Tensor after inverse is "
215                  << inertiaTensor <<  std::endl;
216 <      
216 >      */
217        omega = inertiaTensor*angularMomentum;
218        
219        SimInfo::MoleculeIterator i;
# Line 234 | Line 235 | namespace oopse {
235        }
236        
237        angularMomentum = info_->getAngularMomentum();
238 +      /*
239        std::cerr << "Angular Momentum after is "
240           << angularMomentum <<  std::endl;
241 <
241 >      */
242        
243     }
244    

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines