commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From er...@apache.org
Subject svn commit: r994988 - in /commons/proper/math/trunk/src/main/java/org/apache/commons/math: ./ exception/util/ linear/ optimization/ optimization/direct/ optimization/fitting/ optimization/general/ optimization/univariate/ stat/descriptive/ stat/descrip...
Date Wed, 08 Sep 2010 11:22:43 GMT
Author: erans
Date: Wed Sep  8 11:22:41 2010
New Revision: 994988

URL: http://svn.apache.org/viewvc?rev=994988&view=rev
Log:
Fixed "checkstyle" errors.

Modified:
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/ConvergingAlgorithm.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/util/ArgUtils.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/linear/AbstractRealVector.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/AbstractConvergenceChecker.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultiStartMultivariateRealOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultiStartMultivariateVectorialOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultivariateRealOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultivariateVectorialOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/DifferentiableMultivariateVectorialOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/MultiStartDifferentiableMultivariateRealOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleRealPointChecker.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleScalarValueChecker.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleVectorialPointChecker.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleVectorialValueChecker.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/direct/DirectSearchOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/direct/MultiDirectional.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/CurveFitter.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/GaussianDerivativeFunction.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/GaussianFunction.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/PolynomialFitter.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractLeastSquaresOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractScalarDifferentiableOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/BaseAbstractScalarOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/BaseAbstractVectorialOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/GaussNewtonOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/LevenbergMarquardtOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/PowellOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/AbstractUnivariateRealOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/BaseUnivariateRealOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/BrentOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/UnivariateRealOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/AbstractUnivariateStatistic.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/summary/Sum.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/util/Incrementor.java

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/ConvergingAlgorithm.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/ConvergingAlgorithm.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/ConvergingAlgorithm.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/ConvergingAlgorithm.java Wed Sep  8 11:22:41 2010
@@ -26,8 +26,7 @@ package org.apache.commons.math;
  * @see ConvergenceException
  * @version $Revision$ $Date$
  * @since 2.0
- * @deprecated in 2.2 (to be removed in 3.0). Please use
- * {@link IterativeAlgorithm} instead.
+ * @deprecated in 2.2 (to be removed in 3.0).
  */
 public interface ConvergingAlgorithm {
 

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/util/ArgUtils.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/util/ArgUtils.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/util/ArgUtils.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/util/ArgUtils.java Wed Sep  8 11:22:41 2010
@@ -19,8 +19,19 @@ package org.apache.commons.math.exceptio
 import java.util.List;
 import java.util.ArrayList;
 
+/**
+ * Utility class for trensforming the list of arguments passed to
+ * constructors of exceptions.
+ *
+ * @version $Revision$ $Date$
+ */
 public class ArgUtils {
     /**
+     * Class contains only static methods.
+     */
+    private ArgUtils() {}
+
+    /**
      * Transform a multidimensional array into a one-dimensional list.
      *
      * @param array Array (possibly multidimensional).

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/linear/AbstractRealVector.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/linear/AbstractRealVector.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/linear/AbstractRealVector.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/linear/AbstractRealVector.java Wed Sep  8 11:22:41 2010
@@ -51,7 +51,7 @@ public abstract class AbstractRealVector
      * Check if instance dimension is equal to some expected value.
      *
      * @param n expected dimension.
-     * @exception IllegalArgumentException if the dimension is
+     * @throws DimensionMismatchException if the dimension is
      * inconsistent with vector size
      */
     protected void checkVectorDimensions(int n)

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/AbstractConvergenceChecker.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/AbstractConvergenceChecker.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/AbstractConvergenceChecker.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/AbstractConvergenceChecker.java Wed Sep  8 11:22:41 2010
@@ -22,7 +22,7 @@ import org.apache.commons.math.util.Math
 /**
  * Base class for all convergence checker implementations.
  *
- * <PAIR> Type of (point, value) pair.
+ * @param <PAIR> Type of (point, value) pair.
  *
  * @version $Revision$ $Date$
  * @since 3.0

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultiStartMultivariateRealOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultiStartMultivariateRealOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultiStartMultivariateRealOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultiStartMultivariateRealOptimizer.java Wed Sep  8 11:22:41 2010
@@ -131,10 +131,7 @@ public class BaseMultiStartMultivariateR
     }
 
     /**
-     * @param f Function to optimize.
-     * @param goal Goal type ({@link GoalType#MINIMIZE} or
-     * {@link GoalType#MAXIMIZE}).
-     * @param startPoint Start point.
+     * {@inheritDoc}
      */
     public RealPointValuePair optimize(final FUNC f,
                                        final GoalType goal,
@@ -147,8 +144,7 @@ public class BaseMultiStartMultivariateR
 
             try {
                 optima[i] = optimizer.optimize(f, goal,
-                                               (i == 0 ? startPoint :
-                                                generator.nextVector()));
+                                               i == 0 ? startPoint : generator.nextVector());
             } catch (FunctionEvaluationException fee) {
                 optima[i] = null;
             } catch (ConvergenceException oe) {

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultiStartMultivariateVectorialOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultiStartMultivariateVectorialOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultiStartMultivariateVectorialOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultiStartMultivariateVectorialOptimizer.java Wed Sep  8 11:22:41 2010
@@ -146,8 +146,7 @@ public class BaseMultiStartMultivariateV
 
             try {
                 optima[i] = optimizer.optimize(f, target, weights,
-                                               (i == 0 ? startPoint :
-                                                generator.nextVector()));
+                                               i == 0 ? startPoint : generator.nextVector());
             } catch (FunctionEvaluationException fee) {
                 optima[i] = null;
             } catch (ConvergenceException oe) {

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultivariateRealOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultivariateRealOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultivariateRealOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultivariateRealOptimizer.java Wed Sep  8 11:22:41 2010
@@ -45,12 +45,14 @@ public interface BaseMultivariateRealOpt
      * @param startPoint Start point for optimization.
      * @return the point/value pair giving the optimal value for objective
      * function.
-     * @throws FunctionEvaluationException if the objective function throws one
-     * during the search.
-     * @throws DimensionMismatchException if the start point dimension is wrong.
-     * @throws TooManyEvaluationsException if the maximal number of evaluations is
-     * exceeded.
-     * @throws NullArgumentException if any argument is {@code null}.
+     * @throws org.apache.commons.math.FunctionEvaluationException if the
+     * objective function throws one during the search.
+     * @throws org.apache.commons.math.exception.DimensionMismatchException
+     * if the start point dimension is wrong.
+     * @throws org.apache.commons.math.exception.TooManyEvaluationsException
+     * if the maximal number of evaluations is exceeded.
+     * @throws org.apache.commons.math.exception.NullArgumentException if
+     * any argument is {@code null}.
      */
     RealPointValuePair optimize(FUNC f, GoalType goalType, double[] startPoint)
         throws FunctionEvaluationException;

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultivariateVectorialOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultivariateVectorialOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultivariateVectorialOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseMultivariateVectorialOptimizer.java Wed Sep  8 11:22:41 2010
@@ -49,10 +49,12 @@ public interface BaseMultivariateVectori
      * function.
      * @throws FunctionEvaluationException if the objective function throws one
      * during the search.
-     * @throws DimensionMismatchException if the start point dimension is wrong.
-     * @throws TooManyEvaluationsException if the maximal number of evaluations is
-     * exceeded.
-     * @throws NullArgumentException if any argument is {@code null}.
+     * @throws org.apache.commons.math.exception.DimensionMismatchException
+     * if the start point dimension is wrong.
+     * @throws org.apache.commons.math.exception.TooManyEvaluationsException
+     * if the maximal number of evaluations is exceeded.
+     * @throws org.apache.commons.math.exception.NullArgumentException if
+     * any argument is {@code null}.
      */
     VectorialPointValuePair optimize(FUNC f, double[] target, double[] weight,
                                      double[] startPoint)

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/BaseOptimizer.java Wed Sep  8 11:22:41 2010
@@ -17,9 +17,6 @@
 
 package org.apache.commons.math.optimization;
 
-import org.apache.commons.math.FunctionEvaluationException;
-import org.apache.commons.math.analysis.MultivariateRealFunction;
-
 /**
  * This interface is mainly intended to enforce the internal coherence of
  * Commons-Math. Users of the API are advised to base their code on

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/DifferentiableMultivariateVectorialOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/DifferentiableMultivariateVectorialOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/DifferentiableMultivariateVectorialOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/DifferentiableMultivariateVectorialOptimizer.java Wed Sep  8 11:22:41 2010
@@ -17,7 +17,6 @@
 
 package org.apache.commons.math.optimization;
 
-import org.apache.commons.math.FunctionEvaluationException;
 import org.apache.commons.math.analysis.DifferentiableMultivariateVectorialFunction;
 
 /**

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/MultiStartDifferentiableMultivariateRealOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/MultiStartDifferentiableMultivariateRealOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/MultiStartDifferentiableMultivariateRealOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/MultiStartDifferentiableMultivariateRealOptimizer.java Wed Sep  8 11:22:41 2010
@@ -17,14 +17,7 @@
 
 package org.apache.commons.math.optimization;
 
-import java.util.Arrays;
-import java.util.Comparator;
-
-import org.apache.commons.math.FunctionEvaluationException;
-import org.apache.commons.math.exception.MathIllegalStateException;
-import org.apache.commons.math.exception.ConvergenceException;
 import org.apache.commons.math.analysis.DifferentiableMultivariateRealFunction;
-import org.apache.commons.math.exception.util.LocalizedFormats;
 import org.apache.commons.math.random.RandomVectorGenerator;
 
 /**

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleRealPointChecker.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleRealPointChecker.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleRealPointChecker.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleRealPointChecker.java Wed Sep  8 11:22:41 2010
@@ -17,13 +17,12 @@
 
 package org.apache.commons.math.optimization;
 
-import org.apache.commons.math.util.MathUtils;
 import org.apache.commons.math.util.FastMath;
 
 /**
  * Simple implementation of the {@link ConvergenceChecker} interface using
  * only point coordinates.
- * 
+ *
  * Convergence is considered to have been reached if either the relative
  * difference between each point coordinate are smaller than a threshold
  * or if either the absolute difference between the point coordinates are

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleScalarValueChecker.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleScalarValueChecker.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleScalarValueChecker.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleScalarValueChecker.java Wed Sep  8 11:22:41 2010
@@ -17,7 +17,6 @@
 
 package org.apache.commons.math.optimization;
 
-import org.apache.commons.math.util.MathUtils;
 import org.apache.commons.math.util.FastMath;
 
 /**
@@ -76,7 +75,7 @@ public class SimpleScalarValueChecker
         final double c = current.getValue();
         final double difference = FastMath.abs(p - c);
         final double size = FastMath.max(FastMath.abs(p), FastMath.abs(c));
-        return (difference <= size * getRelativeThreshold() ||
-                difference <= getAbsoluteThreshold());
+        return difference <= size * getRelativeThreshold() ||
+            difference <= getAbsoluteThreshold();
     }
 }

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleVectorialPointChecker.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleVectorialPointChecker.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleVectorialPointChecker.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleVectorialPointChecker.java Wed Sep  8 11:22:41 2010
@@ -17,8 +17,6 @@
 
 package org.apache.commons.math.optimization;
 
-import org.apache.commons.math.util.MathUtils;
-
 /**
  * Simple implementation of the {@link ConvergenceChecker} interface using
  * only point coordinates.

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleVectorialValueChecker.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleVectorialValueChecker.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleVectorialValueChecker.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/SimpleVectorialValueChecker.java Wed Sep  8 11:22:41 2010
@@ -18,7 +18,6 @@
 package org.apache.commons.math.optimization;
 
 import org.apache.commons.math.util.FastMath;
-import org.apache.commons.math.util.MathUtils;
 
 /**
  * Simple implementation of the {@link ConvergenceChecker} interface using

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/direct/DirectSearchOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/direct/DirectSearchOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/direct/DirectSearchOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/direct/DirectSearchOptimizer.java Wed Sep  8 11:22:41 2010
@@ -22,15 +22,10 @@ import java.util.Comparator;
 
 import org.apache.commons.math.FunctionEvaluationException;
 import org.apache.commons.math.MathRuntimeException;
-import org.apache.commons.math.util.Incrementor;
-import org.apache.commons.math.analysis.MultivariateRealFunction;
-import org.apache.commons.math.exception.MaxCountExceededException;
-import org.apache.commons.math.exception.TooManyEvaluationsException;
 import org.apache.commons.math.exception.DimensionMismatchException;
 import org.apache.commons.math.exception.util.LocalizedFormats;
 import org.apache.commons.math.optimization.GoalType;
 import org.apache.commons.math.optimization.MultivariateRealOptimizer;
-import org.apache.commons.math.optimization.OptimizationException;
 import org.apache.commons.math.optimization.ConvergenceChecker;
 import org.apache.commons.math.optimization.RealPointValuePair;
 import org.apache.commons.math.optimization.SimpleScalarValueChecker;
@@ -212,8 +207,8 @@ public abstract class DirectSearchOptimi
             Arrays.fill(unit, 1.0);
             setStartConfiguration(unit);
         }
-        
-        final boolean isMinim = (getGoalType() == GoalType.MINIMIZE);
+
+        final boolean isMinim = getGoalType() == GoalType.MINIMIZE;
         final Comparator<RealPointValuePair> comparator
             = new Comparator<RealPointValuePair>() {
             public int compare(final RealPointValuePair o1,
@@ -256,8 +251,10 @@ public abstract class DirectSearchOptimi
      * @param comparator Comparator to use to sort simplex vertices from best to worst.
      * @throws FunctionEvaluationException if the function cannot be evaluated at
      * some point.
-     * @throws TooManyEvaluationsException if the algorithm fails to converge.
-     * @throws DimensionMismatchException if the start point dimension is wrong.
+     * @throws org.apache.commons.math.exception.TooManyEvaluationsException if
+     * the algorithm fails to converge.
+     * @throws org.apache.commons.math.exception.DimensionMismatchException if
+     * the start point dimension is wrong.
      */
     protected abstract void iterateSimplex(final Comparator<RealPointValuePair> comparator)
         throws FunctionEvaluationException;
@@ -296,7 +293,8 @@ public abstract class DirectSearchOptimi
      *
      * @param comparator Comparator to use to sort simplex vertices from best to worst.
      * @throws FunctionEvaluationException if no value can be computed for the parameters.
-     * @throws TooManyEvaluationsException if the maximal number of evaluations is exceeded.
+     * @throws org.apache.commons.math.exception.TooManyEvaluationsException
+     * if the maximal number of evaluations is exceeded.
      */
     protected void evaluateSimplex(final Comparator<RealPointValuePair> comparator)
         throws FunctionEvaluationException {

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/direct/MultiDirectional.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/direct/MultiDirectional.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/direct/MultiDirectional.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/direct/MultiDirectional.java Wed Sep  8 11:22:41 2010
@@ -110,14 +110,14 @@ public class MultiDirectional extends Di
      * @param comparator Comparator to use to sort simplex vertices from best
      * to poorest.
      * @return the best point in the transformed simplex.
-     * @exception FunctionEvaluationException if the function cannot be
+     * @throws FunctionEvaluationException if the function cannot be
      * evaluated at some point.
-     * @exception TooManyEvaluationsException if the maximal number of
-     * evaluations is exceeded.
+     * @throws org.apache.commons.math.exception.TooManyEvaluationsException
+     * if the maximal number of evaluations is exceeded.
      */
     private RealPointValuePair evaluateNewSimplex(final RealPointValuePair[] original,
-                                              final double coeff,
-                                              final Comparator<RealPointValuePair> comparator)
+                                                  final double coeff,
+                                                  final Comparator<RealPointValuePair> comparator)
         throws FunctionEvaluationException {
 
         final double[] xSmallest = original[0].getPointRef();

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/CurveFitter.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/CurveFitter.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/CurveFitter.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/CurveFitter.java Wed Sep  8 11:22:41 2010
@@ -119,8 +119,10 @@ public class CurveFitter {
      * @return fitted parameters
      * @exception FunctionEvaluationException if the objective function throws one during
      * the search
-     * @exception ConvergenceException if the algorithm failed to converge
-     * @exception IllegalArgumentException if the start point dimension is wrong.
+     * @exception org.apache.commons.math.exception.ConvergenceException
+     * if the algorithm failed to converge.
+     * @exception org.apache.commons.math.exception.DimensionMismatchException
+     * if the start point dimension is wrong.
      */
     public double[] fit(final ParametricRealFunction f,
                         final double[] initialGuess)

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/GaussianDerivativeFunction.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/GaussianDerivativeFunction.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/GaussianDerivativeFunction.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/GaussianDerivativeFunction.java Wed Sep  8 11:22:41 2010
@@ -20,7 +20,6 @@ package org.apache.commons.math.optimiza
 import java.io.Serializable;
 
 import org.apache.commons.math.FunctionEvaluationException;
-import org.apache.commons.math.MathRuntimeException;
 import org.apache.commons.math.analysis.UnivariateRealFunction;
 import org.apache.commons.math.exception.DimensionMismatchException;
 import org.apache.commons.math.exception.util.LocalizedFormats;

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/GaussianFunction.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/GaussianFunction.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/GaussianFunction.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/GaussianFunction.java Wed Sep  8 11:22:41 2010
@@ -20,7 +20,6 @@ package org.apache.commons.math.optimiza
 import java.io.Serializable;
 
 import org.apache.commons.math.FunctionEvaluationException;
-import org.apache.commons.math.MathRuntimeException;
 import org.apache.commons.math.analysis.DifferentiableUnivariateRealFunction;
 import org.apache.commons.math.analysis.UnivariateRealFunction;
 import org.apache.commons.math.exception.DimensionMismatchException;

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/PolynomialFitter.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/PolynomialFitter.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/PolynomialFitter.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/fitting/PolynomialFitter.java Wed Sep  8 11:22:41 2010
@@ -21,7 +21,6 @@ import org.apache.commons.math.FunctionE
 import org.apache.commons.math.MathRuntimeException;
 import org.apache.commons.math.analysis.polynomials.PolynomialFunction;
 import org.apache.commons.math.optimization.DifferentiableMultivariateVectorialOptimizer;
-import org.apache.commons.math.exception.ConvergenceException;
 
 /** This class implements a curve fitting specialized for polynomials.
  * <p>Polynomial fitting is a very simple case of curve fitting. The
@@ -32,14 +31,14 @@ import org.apache.commons.math.exception
  */
 
 public class PolynomialFitter {
-
     /** Fitter for the coefficients. */
     private final CurveFitter fitter;
-
     /** Polynomial degree. */
     private final int degree;
 
-    /** Simple constructor.
+    /**
+     * Simple constructor.
+     *
      * <p>The polynomial fitter built this way are complete polynomials,
      * ie. a n-degree polynomial has n+1 coefficients.</p>
      * @param degree maximal degree of the polynomial
@@ -50,7 +49,9 @@ public class PolynomialFitter {
         this.degree = degree;
     }
 
-    /** Add an observed weighted (x,y) point to the sample.
+    /**
+     * Add an observed weighted (x,y) point to the sample.
+     *
      * @param weight weight of the observed point in the fit
      * @param x abscissa of the point
      * @param y observed value of the point at x, after fitting we should
@@ -67,9 +68,12 @@ public class PolynomialFitter {
         fitter.clearObservations();
     }
 
-    /** Get the polynomial fitting the weighted (x, y) points.
+    /**
+     * Get the polynomial fitting the weighted (x, y) points.
+     *
      * @return polynomial function best fitting the observed points
-     * @exception ConvergenceException if the algorithm failed to converge
+     * @throws org.apache.commons.math.exception.ConvergenceException
+     * if the algorithm failed to converge.
      */
     public PolynomialFunction fit() {
         try {
@@ -80,7 +84,9 @@ public class PolynomialFitter {
         }
     }
 
-    /** Dedicated parametric polynomial class. */
+    /**
+     * Dedicated parametric polynomial class.
+     */
     private static class ParametricPolynomial implements ParametricRealFunction {
 
         /** {@inheritDoc} */
@@ -103,7 +109,5 @@ public class PolynomialFitter {
             }
             return y;
         }
-
     }
-
 }

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=994988&r1=994987&r2=994988&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 Wed Sep  8 11:22:41 2010
@@ -26,7 +26,6 @@ import org.apache.commons.math.linear.In
 import org.apache.commons.math.linear.LUDecompositionImpl;
 import org.apache.commons.math.linear.MatrixUtils;
 import org.apache.commons.math.linear.RealMatrix;
-import org.apache.commons.math.optimization.SimpleVectorialValueChecker;
 import org.apache.commons.math.optimization.ConvergenceChecker;
 import org.apache.commons.math.optimization.DifferentiableMultivariateVectorialOptimizer;
 import org.apache.commons.math.optimization.VectorialPointValuePair;

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractScalarDifferentiableOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractScalarDifferentiableOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractScalarDifferentiableOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/AbstractScalarDifferentiableOptimizer.java Wed Sep  8 11:22:41 2010
@@ -64,8 +64,8 @@ public abstract class AbstractScalarDiff
      * @return the gradient at the specified point.
      * @throws FunctionEvaluationException if the function gradient cannot be
      * evaluated.
-     * @throws TooManyEvaluationsException if the allowed number of evaluations
-     * is exceeded.
+     * @throws org.apache.commons.math.exception.TooManyEvaluationsException
+     * if the allowed number of evaluations is exceeded.
      */
     protected double[] computeObjectiveGradient(final double[] evaluationPoint)
         throws FunctionEvaluationException {

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/BaseAbstractScalarOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/BaseAbstractScalarOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/BaseAbstractScalarOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/BaseAbstractScalarOptimizer.java Wed Sep  8 11:22:41 2010
@@ -25,7 +25,6 @@ import org.apache.commons.math.exception
 import org.apache.commons.math.analysis.MultivariateRealFunction;
 import org.apache.commons.math.optimization.BaseMultivariateRealOptimizer;
 import org.apache.commons.math.optimization.GoalType;
-import org.apache.commons.math.optimization.OptimizationException;
 import org.apache.commons.math.optimization.ConvergenceChecker;
 import org.apache.commons.math.optimization.RealPointValuePair;
 import org.apache.commons.math.optimization.SimpleScalarValueChecker;
@@ -107,8 +106,8 @@ public abstract class BaseAbstractScalar
      * @param point Point at which the objective function must be evaluated.
      * @return the objective function value at the specified point.
      * @throws FunctionEvaluationException if the function cannot be evaluated.
-     * @throws TooManyEvaluationsException if the maximal number of evaluations is
-     * exceeded.
+     * @throws TooManyEvaluationsException if the maximal number of
+     * evaluations is exceeded.
      */
     protected double computeObjectiveValue(double[] point)
         throws FunctionEvaluationException {

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/BaseAbstractVectorialOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/BaseAbstractVectorialOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/BaseAbstractVectorialOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/BaseAbstractVectorialOptimizer.java Wed Sep  8 11:22:41 2010
@@ -25,8 +25,6 @@ import org.apache.commons.math.exception
 import org.apache.commons.math.exception.NullArgumentException;
 import org.apache.commons.math.analysis.MultivariateVectorialFunction;
 import org.apache.commons.math.optimization.BaseMultivariateVectorialOptimizer;
-import org.apache.commons.math.optimization.GoalType;
-import org.apache.commons.math.optimization.OptimizationException;
 import org.apache.commons.math.optimization.ConvergenceChecker;
 import org.apache.commons.math.optimization.VectorialPointValuePair;
 import org.apache.commons.math.optimization.SimpleVectorialValueChecker;
@@ -120,24 +118,24 @@ public abstract class BaseAbstractVector
 
     /** {@inheritDoc} */
     public VectorialPointValuePair optimize(FUNC f,
-                                            double[] target, double[] weight,
+                                            double[] t, double[] w,
                                             double[] startPoint)
         throws FunctionEvaluationException {
         // Checks.
         if (f == null) {
             throw new NullArgumentException();
         }
-        if (target == null) {
+        if (t == null) {
             throw new NullArgumentException();
         }
-        if (weight == null) {
+        if (w == null) {
             throw new NullArgumentException();
         }
         if (startPoint == null) {
             throw new NullArgumentException();
         }
-        if (target.length != weight.length) {
-            throw new DimensionMismatchException(target.length, weight.length);
+        if (t.length != w.length) {
+            throw new DimensionMismatchException(t.length, w.length);
         }
 
         // Reset.
@@ -145,8 +143,8 @@ public abstract class BaseAbstractVector
 
         // Store optimization problem characteristics.
         function = f;
-        this.target = target.clone();
-        this.weight = weight.clone();
+        target = t.clone();
+        weight = w.clone();
         start = startPoint.clone();
 
         // Perform computation.

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/GaussNewtonOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/GaussNewtonOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/GaussNewtonOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/GaussNewtonOptimizer.java Wed Sep  8 11:22:41 2010
@@ -27,6 +27,7 @@ import org.apache.commons.math.linear.QR
 import org.apache.commons.math.linear.RealMatrix;
 import org.apache.commons.math.exception.ConvergenceException;
 import org.apache.commons.math.optimization.VectorialPointValuePair;
+import org.apache.commons.math.optimization.ConvergenceChecker;
 
 /**
  * Gauss-Newton least-squares solver.
@@ -64,6 +65,9 @@ public class GaussNewtonOptimizer extend
     public VectorialPointValuePair doOptimize()
         throws FunctionEvaluationException {
 
+        final ConvergenceChecker<VectorialPointValuePair> checker
+            = getConvergenceChecker();
+
         // iterate until convergence is reached
         VectorialPointValuePair current = null;
         int iter = 0;
@@ -121,8 +125,10 @@ public class GaussNewtonOptimizer extend
             }
 
             // check convergence
-            if (previous != null) {
-                converged = getConvergenceChecker().converged(iter, previous, current);
+            if (checker != null) {
+                if (previous != null) {
+                    converged = checker.converged(iter, previous, current);
+                }
             }
         }
         // we have converged

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/LevenbergMarquardtOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/LevenbergMarquardtOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/LevenbergMarquardtOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/LevenbergMarquardtOptimizer.java Wed Sep  8 11:22:41 2010
@@ -409,9 +409,9 @@ public class LevenbergMarquardtOptimizer
                     // tests for convergence.
                     if (checker != null) {
                         // we use the vectorial convergence checker
-                    	if (checker.converged(iter, previous, current)) {
-                    		return current;
-                    	}
+                        if (checker.converged(iter, previous, current)) {
+                            return current;
+                        }
                     }
                 } else {
                     // failed iteration, reset the previous values

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/PowellOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/PowellOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/PowellOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/general/PowellOptimizer.java Wed Sep  8 11:22:41 2010
@@ -27,7 +27,6 @@ import org.apache.commons.math.exception
 import org.apache.commons.math.optimization.GoalType;
 import org.apache.commons.math.optimization.RealPointValuePair;
 import org.apache.commons.math.optimization.ConvergenceChecker;
-import org.apache.commons.math.optimization.univariate.AbstractUnivariateRealOptimizer;
 import org.apache.commons.math.optimization.univariate.BracketFinder;
 import org.apache.commons.math.optimization.univariate.BrentOptimizer;
 import org.apache.commons.math.optimization.univariate.UnivariateRealPointValuePair;
@@ -100,7 +99,7 @@ public class PowellOptimizer
         super.setMaxEvaluations(maxEvaluations);
 
         // We must allow at least as many iterations to the underlying line
-        // search optimizer. Because the line search inner class will call 
+        // search optimizer. Because the line search inner class will call
         // "computeObjectiveValue" in this class, we ensure that this class
         // will be the first to eventually throw "TooManyEvaluationsException".
         line.setMaxEvaluations(maxEvaluations);
@@ -153,9 +152,9 @@ public class PowellOptimizer
             }
 
             // Default convergence check.
-            boolean stop = 2 * (fX - fVal) <= (relativeThreshold * (FastMath.abs(fX)
-                                                                    + FastMath.abs(fVal))
-                                               + absoluteThreshold);
+            boolean stop = 2 * (fX - fVal) <=
+                (relativeThreshold * (FastMath.abs(fX) + FastMath.abs(fVal)) +
+                 absoluteThreshold);
 
             final RealPointValuePair previous = new RealPointValuePair(x1, fX);
             final RealPointValuePair current = new RealPointValuePair(x, fVal);
@@ -245,7 +244,7 @@ public class PowellOptimizer
 
         /**
          * @param rel Relative threshold.
-         * @param rel Absolute threshold.
+         * @param abs Absolute threshold.
          */
         LineSearch(double rel,
                    double abs) {
@@ -260,8 +259,8 @@ public class PowellOptimizer
          * @return the optimum.
          * @throws FunctionEvaluationException if the function evaluation
          * fails.
-         * @throws TooManyEvaluationsException if the number of evaluations is
-         * exceeded.
+         * @throws org.apache.commons.math.exception.TooManyEvaluationsException
+         * if the number of evaluations is exceeded.
          */
         public UnivariateRealPointValuePair search(final double[] p,
                                                    final double[] d)
@@ -271,7 +270,6 @@ public class PowellOptimizer
             final UnivariateRealFunction f = new UnivariateRealFunction() {
                     public double value(double alpha)
                         throws FunctionEvaluationException {
-                        
                         final double[] x = new double[n];
                         for (int i = 0; i < n; i++) {
                             x[i] = p[i] + alpha * d[i];
@@ -280,7 +278,7 @@ public class PowellOptimizer
                         return obj;
                     }
                 };
-            
+
             final GoalType goal = PowellOptimizer.this.getGoalType();
             bracket.search(f, goal, 0, 1);
             return optimize(f, goal, bracket.getLo(), bracket.getHi(),

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/AbstractUnivariateRealOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/AbstractUnivariateRealOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/AbstractUnivariateRealOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/AbstractUnivariateRealOptimizer.java Wed Sep  8 11:22:41 2010
@@ -138,17 +138,17 @@ public abstract class AbstractUnivariate
 
     /** {@inheritDoc} */
     public UnivariateRealPointValuePair optimize(UnivariateRealFunction f,
-                                                 GoalType goal,
+                                                 GoalType goalType,
                                                  double min, double max)
         throws FunctionEvaluationException {
-        return optimize(f, goal, min, max, min + 0.5 * (max - min));
+        return optimize(f, goalType, min, max, min + 0.5 * (max - min));
     }
 
     /**
      * {@inheritDoc}
      */
-    public void setConvergenceChecker(ConvergenceChecker<UnivariateRealPointValuePair> checker) {
-        this.checker = checker;
+    public void setConvergenceChecker(ConvergenceChecker<UnivariateRealPointValuePair> c) {
+        checker = c;
     }
 
     /**

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/BaseUnivariateRealOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/BaseUnivariateRealOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/BaseUnivariateRealOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/BaseUnivariateRealOptimizer.java Wed Sep  8 11:22:41 2010
@@ -19,7 +19,6 @@ package org.apache.commons.math.optimiza
 
 import org.apache.commons.math.FunctionEvaluationException;
 import org.apache.commons.math.analysis.UnivariateRealFunction;
-import org.apache.commons.math.exception.NullArgumentException;
 import org.apache.commons.math.optimization.BaseOptimizer;
 import org.apache.commons.math.optimization.GoalType;
 
@@ -49,9 +48,9 @@ public interface BaseUnivariateRealOptim
      * @param min Lower bound for the interval.
      * @param max Upper bound for the interval.
      * @return a (point, value) pair where the function is optimum.
-     * @throws {@link org.apache.commons.math.exception.TooManyEvaluationsException}
+     * @throws org.apache.commons.math.exception.TooManyEvaluationsException
      * if the maximum evaluation count is exceeded.
-     * @throws {@link org.apache.commons.math.exception.ConvergenceException}
+     * @throws org.apache.commons.math.exception.ConvergenceException
      * if the optimizer detects a convergence problem.
      * @throws FunctionEvaluationException if an error occurs evaluating the
      * function.
@@ -73,15 +72,16 @@ public interface BaseUnivariateRealOptim
      * @param max Upper bound for the interval.
      * @param startValue Start value to use.
      * @return a (point, value) pair where the function is optimum.
-     * @throws {@link org.apache.commons.math.exception.TooManyEvaluationsException}
+     * @throws org.apache.commons.math.exception.TooManyEvaluationsException
      * if the maximum evaluation count is exceeded.
-     * @throws {@link org.apache.commons.math.exception.ConvergenceException}
-     * if the optimizer detects a convergence problem.
+     * @throws org.apache.commons.math.exception.ConvergenceException if the
+     * optimizer detects a convergence problem.
      * @throws FunctionEvaluationException if an error occurs evaluating the
      * function.
      * @throws IllegalArgumentException if {@code min > max} or the endpoints
      * do not satisfy the requirements specified by the optimizer.
-     * @throws NullArgumentException if any argument is {@code null}.
+     * @throws org.apache.commons.math.exception.NullArgumentException if any
+     * argument is {@code null}.
      */
     UnivariateRealPointValuePair optimize(FUNC f, GoalType goalType,
                                           double min, double max,

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/BrentOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/BrentOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/BrentOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/BrentOptimizer.java Wed Sep  8 11:22:41 2010
@@ -17,13 +17,10 @@
 package org.apache.commons.math.optimization.univariate;
 
 import org.apache.commons.math.FunctionEvaluationException;
-import org.apache.commons.math.util.MathUtils;
 import org.apache.commons.math.util.FastMath;
 import org.apache.commons.math.exception.NumberIsTooSmallException;
 import org.apache.commons.math.exception.NotStrictlyPositiveException;
-import org.apache.commons.math.exception.MathUnsupportedOperationException;
 import org.apache.commons.math.optimization.ConvergenceChecker;
-import org.apache.commons.math.optimization.AbstractConvergenceChecker;
 import org.apache.commons.math.optimization.GoalType;
 
 /**
@@ -89,7 +86,7 @@ public class BrentOptimizer extends Abst
     /** {@inheritDoc} */
     protected UnivariateRealPointValuePair doOptimize()
         throws FunctionEvaluationException {
-        final boolean isMinim = (getGoalType() == GoalType.MINIMIZE);
+        final boolean isMinim = getGoalType() == GoalType.MINIMIZE;
         final double lo = getMin();
         final double mid = getStartValue();
         final double hi = getMax();
@@ -122,7 +119,7 @@ public class BrentOptimizer extends Abst
 
         UnivariateRealPointValuePair previous = null;
         UnivariateRealPointValuePair current
-            = new UnivariateRealPointValuePair(x, (isMinim ? fx : -fx));
+            = new UnivariateRealPointValuePair(x, isMinim ? fx : -fx);
 
         int iter = 0;
         while (true) {
@@ -234,7 +231,7 @@ public class BrentOptimizer extends Abst
                 }
 
                 previous = current;
-                current = new UnivariateRealPointValuePair(x, (isMinim ? fx : -fx));
+                current = new UnivariateRealPointValuePair(x, isMinim ? fx : -fx);
 
                 // User-defined convergence checker.
                 if (checker != null) {

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/UnivariateRealOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/UnivariateRealOptimizer.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/UnivariateRealOptimizer.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/optimization/univariate/UnivariateRealOptimizer.java Wed Sep  8 11:22:41 2010
@@ -24,5 +24,5 @@ import org.apache.commons.math.analysis.
  * @version $Revision$ $Date$
  * @since 3.0
  */
-public interface UnivariateRealOptimizer 
+public interface UnivariateRealOptimizer
     extends BaseUnivariateRealOptimizer<UnivariateRealFunction> {}

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/AbstractUnivariateStatistic.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/AbstractUnivariateStatistic.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/AbstractUnivariateStatistic.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/AbstractUnivariateStatistic.java Wed Sep  8 11:22:41 2010
@@ -188,13 +188,14 @@ public abstract class AbstractUnivariate
      * <code>length</code> is 0 unless <code>allowEmpty</code> is <code>true</code>.
      * </ul></p>
      *
-     * @param values the input array
-     * @param weights the weights array
-     * @param begin index of the first array element to include
-     * @param length the number of elements to include
-     * @param allowEmpty if <code>true</code> than allow zero length arrays to pass
-     * @return true if the parameters are valid 
-     * @throws IllegalArgumentException if the indices are invalid or the array is null
+     * @param values the input array.
+     * @param weights the weights array.
+     * @param begin index of the first array element to include.
+     * @param length the number of elements to include.
+     * @param allowEmpty if {@code true} than allow zero length arrays to pass.
+     * @return {@code true} if the parameters are valid.
+     * @throws IllegalArgumentException if the indices are invalid or the array
+     * is {@code null}.
      * @since 3.0
      */
     protected boolean test(final double[] values, final double[] weights, final int begin, final int length, final boolean allowEmpty){

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/summary/Sum.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/summary/Sum.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/summary/Sum.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/summary/Sum.java Wed Sep  8 11:22:41 2010
@@ -24,7 +24,7 @@ import org.apache.commons.math.stat.desc
 /**
   * Returns the sum of the available values.
  * <p>
- * If there are no values in the dataset, then 0 is returned. 
+ * If there are no values in the dataset, then 0 is returned.
  * If any of the values are
  * <code>NaN</code>, then <code>NaN</code> is returned.</p>
  * <p>

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/util/Incrementor.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/util/Incrementor.java?rev=994988&r1=994987&r2=994988&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/util/Incrementor.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/util/Incrementor.java Wed Sep  8 11:22:41 2010
@@ -38,10 +38,10 @@ public class Incrementor {
     /**
      * Set the upper limit for the counter.
      *
-     * @param count Upper limit of the counter.
+     * @param max Upper limit of the counter.
      */
-    public void setMaximalCount(int count) {
-        maximalCount = count;
+    public void setMaximalCount(int max) {
+        maximalCount = max;
     }
 
     /**



Mime
View raw message