From 0880b26977b06ae75cce7b12af8ab1af550af603 Mon Sep 17 00:00:00 2001 From: Giovanni Bussi <giovanni.bussi@gmail.com> Date: Tue, 24 Mar 2015 16:27:42 +0100 Subject: [PATCH] Changed FitToTemplate::apply() It does not shift anymore the atoms to their original positions. Notice that this makes its behavior consistent with WHOLEMOLECULES where atoms are not restored in the backward loop. This implies that (consistently) one cannot rely that shared atoms (those accessed with modifyAtoms()) are in their original position in the ::apply() methods. --- src/generic/FitToTemplate.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/generic/FitToTemplate.cpp b/src/generic/FitToTemplate.cpp index e28f5cb5a..2e00b9e65 100644 --- a/src/generic/FitToTemplate.cpp +++ b/src/generic/FitToTemplate.cpp @@ -163,8 +163,6 @@ void FitToTemplate::calculate(){ void FitToTemplate::apply(){ Vector totForce; for(unsigned i=0;i<getTotAtoms();i++){ - Vector & ato (modifyPosition(AtomNumber::index(i))); - ato-=shift; totForce+=modifyForce(AtomNumber::index(i)); } for(unsigned i=0;i<aligned.size();++i){ -- GitLab