removed unused variable

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1141882 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Luc Maisonobe 2011-07-01 09:08:38 +00:00
parent 46dfce79a4
commit 5dadec877b
1 changed files with 0 additions and 2 deletions

View File

@ -134,12 +134,10 @@ public abstract class AbstractLeastSquaresOptimizer
final double[] residualsWeights = getWeightRef();
cost = 0;
int index = 0;
for (int i = 0; i < rows; i++) {
final double residual = targetValues[i] - objective[i];
weightedResiduals[i]= residual*FastMath.sqrt(residualsWeights[i]);
cost += residualsWeights[i] * residual * residual;
index += cols;
}
cost = FastMath.sqrt(cost);
}