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

Comparing trunk/src/primitives/Torsion.cpp (file contents):
Revision 963 by tim, Wed May 17 21:51:42 2006 UTC vs.
Revision 1309 by gezelter, Tue Oct 21 18:23:31 2008 UTC

# Line 77 | Line 77 | namespace oopse {
77  
78      RealType dVdcosPhi;
79      torsionType_->calcForce(cos_phi, potential_, dVdcosPhi);
80 <    Vector3d f1;
81 <    Vector3d f2;
82 <    Vector3d f3;
80 >    Vector3d f1 ;
81 >    Vector3d f2 ;
82 >    Vector3d f3 ;
83  
84      Vector3d dcosdA = (cos_phi * A - B) /rA;
85      Vector3d dcosdB = (cos_phi * B - A) /rB;
# Line 92 | Line 92 | namespace oopse {
92      atom2_->addFrc(f2 - f1);
93      atom3_->addFrc(f3 - f2);
94      atom4_->addFrc(-f3);
95 +
96 +    atom1_->addParticlePot(potential_);
97 +    atom2_->addParticlePot(potential_);
98 +    atom3_->addParticlePot(potential_);
99 +    atom4_->addParticlePot(potential_);
100 +
101      angle = acos(cos_phi) /M_PI * 180.0;
102    }
103  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines