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

Comparing trunk/src/restraints/ObjectRestraint.cpp (file contents):
Revision 1972 by gezelter, Sun Jun 16 15:15:42 2013 UTC vs.
Revision 1973 by gezelter, Thu Mar 6 19:34:22 2014 UTC

# Line 52 | Line 52 | namespace OpenMD {
52        RealType r = del.length();
53        Vector3d frc = -kDisp_ * del;
54        RealType p = 0.5 * kDisp_ * del.lengthSquare();
55 +
56        pot_ = p;
57        force_ = frc * scaleFactor_;
58        restInfo_[rtDisplacement] = std::make_pair(r,p);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines