ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/OpenMD/branches/development/src/math/RMSD.cpp
(Generate patch)

Comparing:
trunk/src/math/RMSD.cpp (file contents), Revision 1390 by gezelter, Wed Nov 25 20:02:06 2009 UTC vs.
branches/development/src/math/RMSD.cpp (file contents), Revision 1668 by gezelter, Fri Jan 6 19:03:05 2012 UTC

# Line 72 | Line 72 | RealType RMSD::calculate_rmsd(std::vector<Vector3d> mo
72    stmp.getSubVector(0,s);
73    wtmp.getSubMatrix(0,0,w);
74      
75 <  int is_reflection = (v.determinant() * w.determinant()) < 0.0;
75 >  int is_reflection = (v.determinant() * w.determinant()) < RealType(0.0);
76    if (is_reflection)
77      s(2) = -s(2);
78  
79    RealType rmsd_sq = (E0 - 2.0 * s.sum() )/ (RealType)n_vec;
80 <  rmsd_sq = max(rmsd_sq,0.0);
80 >  rmsd_sq = max(rmsd_sq, RealType(0.0));
81    RealType rmsd = sqrt(rmsd_sq);
82    return rmsd;
83   }

Comparing:
trunk/src/math/RMSD.cpp (property svn:keywords), Revision 1390 by gezelter, Wed Nov 25 20:02:06 2009 UTC vs.
branches/development/src/math/RMSD.cpp (property svn:keywords), Revision 1668 by gezelter, Fri Jan 6 19:03:05 2012 UTC

# Line 0 | Line 1
1 + Author Id Revision Date

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines