diff --git a/optimise.cc b/optimise.cc index 9c6f24c0c2d4b3ca12062e339d09910419d07a59..75ac5aa34b80f0a6305c0bdc9b19aad055997575 100644 --- a/optimise.cc +++ b/optimise.cc @@ -247,7 +247,7 @@ namespace MISCMATHS { float optimise(ColumnVector &pt, int numopt, const ColumnVector &tol, float (*func)(const ColumnVector &), int &iterations_done, - int max_iter, const ColumnVector& boundguess, const bool in_slice) + int max_iter, const ColumnVector& boundguess) { // Calculate dot product of dir by tol // st (x1-x2)*dir_tol = average number of tolerances between x1 and x2 @@ -270,11 +270,8 @@ namespace MISCMATHS { for (int n=1; n<=numopt; n++) { dir = 0.0; dir(n) = 1.0; - // if the in_slice flag has been set, only correct in z_rot, x_trans and y_trans - if ((!in_slice) || (n == 3) || (n == 4) || (n == 5)) { - fval = optimise1d(pt,dir,tol,lit,func,100,fval,bndguess); - littot += lit; - } + fval = optimise1d(pt,dir,tol,lit,func,100,fval,bndguess); + littot += lit; } // check to see if the point has moved more than one average tolerance float avtol = SP((initpt - pt),inv_tol).SumAbsoluteValue();