commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From l..@apache.org
Subject svn commit: r1141882 - /commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractLeastSquaresOptimizer.java
Date Fri, 01 Jul 2011 09:08:39 GMT
Author: luc
Date: Fri Jul  1 09:08:38 2011
New Revision: 1141882

URL: http://svn.apache.org/viewvc?rev=1141882&view=rev
Log:
removed unused variable

Modified:
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractLeastSquaresOptimizer.java

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractLeastSquaresOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractLeastSquaresOptimizer.java?rev=1141882&r1=1141881&r2=1141882&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractLeastSquaresOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractLeastSquaresOptimizer.java
Fri Jul  1 09:08:38 2011
@@ -134,12 +134,10 @@ public abstract class AbstractLeastSquar
         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);
     }



Mime
View raw message