ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/OpenMD/trunk/src/brains/ForceManager.cpp
(Generate patch)

Comparing trunk/src/brains/ForceManager.cpp (file contents):
Revision 1215 by xsun, Wed Jan 23 21:22:37 2008 UTC vs.
Revision 1245 by chuckv, Tue May 27 16:39:06 2008 UTC

# Line 83 | Line 83 | namespace oopse {
83      
84      // forces are zeroed here, before any are accumulated.
85      // NOTE: do not rezero the forces in Fortran.
86 <
86 >    
87      for (mol = info_->beginMolecule(mi); mol != NULL;
88           mol = info_->nextMolecule(mi)) {
89        for(atom = mol->beginAtom(ai); atom != NULL; atom = mol->nextAtom(ai)) {
90          atom->zeroForcesAndTorques();
91        }
92 <      
92 >          
93        //change the positions of atoms which belong to the rigidbodies
94        for (rb = mol->beginRigidBody(rbIter); rb != NULL;
95             rb = mol->nextRigidBody(rbIter)) {
96          rb->zeroForcesAndTorques();
97        }        
98 +          
99      }
100      
101      // Zero out the stress tensor
# Line 201 | Line 202 | namespace oopse {
202      RealType* A;
203      RealType* electroFrame;
204      RealType* rc;
205 +    RealType* particlePot;
206      
207      //get current snapshot from SimInfo
208      curSnapshot = info_->getSnapshotManager()->getCurrentSnapshot();
# Line 212 | Line 214 | namespace oopse {
214      trq = config->getArrayPointer(DataStorage::dslTorque);
215      A   = config->getArrayPointer(DataStorage::dslAmat);
216      electroFrame = config->getArrayPointer(DataStorage::dslElectroFrame);
217 +    particlePot = config->getArrayPointer(DataStorage::dslParticlePot);
218  
219      //calculate the center of mass of cutoff group
220      SimInfo::MoleculeIterator mi;
# Line 259 | Line 262 | namespace oopse {
262                  trq,
263                  tau.getArrayPointer(),
264                  longRangePotential,
265 <                &passedCalcPot,
265 >                particlePot,
266 >                &passedCalcPot,
267                  &passedCalcStress,
268                  &isError );
269      

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines