commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From er...@apache.org
Subject svn commit: r1345803 - in /commons/proper/math/trunk/src: main/java/org/apache/commons/math3/optimization/ main/java/org/apache/commons/math3/optimization/direct/ main/java/org/apache/commons/math3/optimization/general/ main/java/org/apache/commons/mat...
Date Sun, 03 Jun 2012 23:24:43 GMT
Author: erans
Date: Sun Jun  3 23:24:43 2012
New Revision: 1345803

URL: http://svn.apache.org/viewvc?rev=1345803&view=rev
Log:
MATH-799
Deprecated default values for thresholds, and constructors that use
them. Scheduled for removal in CM 4.0.

Modified:
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/AbstractConvergenceChecker.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimplePointChecker.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimpleValueChecker.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimpleVectorValueChecker.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BOBYQAOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateSimpleBoundsOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateVectorOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/CMAESOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/SimplexOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/AbstractScalarDifferentiableOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/GaussNewtonOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/LevenbergMarquardtOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/NonLinearConjugateGradientOptimizer.java
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/univariate/SimpleUnivariateValueChecker.java
    commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/direct/SimplexOptimizerMultiDirectionalTest.java
    commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizerTest.java
    commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizerTestValidation.java

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/AbstractConvergenceChecker.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/AbstractConvergenceChecker.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/AbstractConvergenceChecker.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/AbstractConvergenceChecker.java
Sun Jun  3 23:24:43 2012
@@ -31,10 +31,14 @@ public abstract class AbstractConvergenc
     implements ConvergenceChecker<PAIR> {
     /**
      * Default relative threshold.
+     * @deprecated in 3.1 (to be removed in 4.0) because this value is too small
+     * to be useful as a default (cf. MATH-798).
      */
     private static final double DEFAULT_RELATIVE_THRESHOLD = 100 * Precision.EPSILON;
     /**
      * Default absolute threshold.
+     * @deprecated in 3.1 (to be removed in 4.0) because this value is too small
+     * to be useful as a default (cf. MATH-798).
      */
     private static final double DEFAULT_ABSOLUTE_THRESHOLD = 100 * Precision.SAFE_MIN;
     /**
@@ -48,7 +52,13 @@ public abstract class AbstractConvergenc
 
     /**
      * Build an instance with default thresholds.
+     * @deprecated in 3.1 (to be removed in 4.0). Convergence thresholds are
+     * problem-dependent. As this class is intended for users who want to set
+     * their own convergence criterion instead of relying on an algorithm's
+     * default procedure, they should also set the thresholds appropriately
+     * (cf. MATH-798).
      */
+    @Deprecated
     public AbstractConvergenceChecker() {
         this.relativeThreshold = DEFAULT_RELATIVE_THRESHOLD;
         this.absoluteThreshold = DEFAULT_ABSOLUTE_THRESHOLD;

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimplePointChecker.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimplePointChecker.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimplePointChecker.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimplePointChecker.java
Sun Jun  3 23:24:43 2012
@@ -39,7 +39,9 @@ public class SimplePointChecker<PAIR ext
     extends AbstractConvergenceChecker<PAIR> {
     /**
      * Build an instance with default threshold.
+     * @deprecated See {@link AbstractConvergenceChecker#AbstractConvergenceChecker()}
      */
+    @Deprecated
     public SimplePointChecker() {}
 
     /**

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimpleValueChecker.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimpleValueChecker.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimpleValueChecker.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimpleValueChecker.java
Sun Jun  3 23:24:43 2012
@@ -35,7 +35,9 @@ public class SimpleValueChecker
     extends AbstractConvergenceChecker<PointValuePair> {
     /**
      * Build an instance with default thresholds.
+     * @deprecated See {@link AbstractConvergenceChecker#AbstractConvergenceChecker()}
      */
+    @Deprecated
     public SimpleValueChecker() {}
 
     /** Build an instance with specified thresholds.

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimpleVectorValueChecker.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimpleVectorValueChecker.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimpleVectorValueChecker.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/SimpleVectorValueChecker.java
Sun Jun  3 23:24:43 2012
@@ -35,7 +35,9 @@ public class SimpleVectorValueChecker
     extends AbstractConvergenceChecker<PointVectorValuePair> {
     /**
      * Build an instance with default thresholds.
+     * @deprecated See {@link AbstractConvergenceChecker#AbstractConvergenceChecker()}
      */
+    @Deprecated
     public SimpleVectorValueChecker() {}
 
     /**

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BOBYQAOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BOBYQAOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BOBYQAOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BOBYQAOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -225,6 +225,7 @@ public class BOBYQAOptimizer
     public BOBYQAOptimizer(int numberOfInterpolationPoints,
                            double initialTrustRegionRadius,
                            double stoppingTrustRegionRadius) {
+        super(null); // No custom convergence criterion.
         this.numberOfInterpolationPoints = numberOfInterpolationPoints;
         this.initialTrustRegionRadius = initialTrustRegionRadius;
         this.stoppingTrustRegionRadius = stoppingTrustRegionRadius;

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -53,9 +53,10 @@ public abstract class BaseAbstractMultiv
 
     /**
      * Simple constructor with default settings.
-     * The convergence check is set to a {@link SimpleValueChecker} and
-     * the allowed number of evaluations is set to {@link Integer#MAX_VALUE}.
+     * The convergence check is set to a {@link SimpleValueChecker}.
+     * @deprecated See {@link SimpleValueChecker#SimpleValueChecker()}
      */
+    @Deprecated
     protected BaseAbstractMultivariateOptimizer() {
         this(new SimpleValueChecker());
     }

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateSimpleBoundsOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateSimpleBoundsOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateSimpleBoundsOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateSimpleBoundsOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -51,11 +51,12 @@ public abstract class BaseAbstractMultiv
     /**
      * Simple constructor with default settings.
      * The convergence checker is set to a
-     * {@link org.apache.commons.math3.optimization.SimpleValueChecker} and
-     * the allowed number of evaluations is set to {@link Integer#MAX_VALUE}.
+     * {@link org.apache.commons.math3.optimization.SimpleValueChecker}.
      *
      * @see BaseAbstractMultivariateOptimizer#BaseAbstractMultivariateOptimizer()
+     * @deprecated See {@link org.apache.commons.math3.optimization.SimpleValueChecker#SimpleValueChecker()}
      */
+    @Deprecated
     protected BaseAbstractMultivariateSimpleBoundsOptimizer() {}
 
     /**

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateVectorOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateVectorOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateVectorOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/BaseAbstractMultivariateVectorOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -55,9 +55,10 @@ public abstract class BaseAbstractMultiv
 
     /**
      * Simple constructor with default settings.
-     * The convergence check is set to a {@link SimpleVectorValueChecker} and
-     * the allowed number of evaluations is set to {@link Integer#MAX_VALUE}.
+     * The convergence check is set to a {@link SimpleVectorValueChecker}.
+     * @deprecated See {@link SimpleVectorValueChecker#SimpleVectorValueChecker()}
      */
+    @Deprecated
     protected BaseAbstractMultivariateVectorOptimizer() {
         this(new SimpleVectorValueChecker());
     }

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/CMAESOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/CMAESOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/CMAESOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/CMAESOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -270,7 +270,9 @@ public class CMAESOptimizer
      * generated in case they are out of bounds.
      * @param random Random generator.
      * @param generateStatistics Whether statistic data is collected.
+     * @deprecated See {@link SimpleValueChecker#SimpleValueChecker()}
      */
+    @Deprecated
     public CMAESOptimizer(int lambda, double[] inputSigma,
                           int maxIterations, double stopFitness,
                           boolean isActiveCMA, int diagonalOnly, int checkFeasableCount,

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/SimplexOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/SimplexOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/SimplexOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/direct/SimplexOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -92,7 +92,9 @@ public class SimplexOptimizer
     /**
      * Constructor using a default {@link SimpleValueChecker convergence
      * checker}.
+     * @deprecated See {@link SimpleValueChecker#SimpleValueChecker()}
      */
+    @Deprecated
     public SimplexOptimizer() {
         this(new SimpleValueChecker());
     }

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -82,8 +82,11 @@ public abstract class AbstractLeastSquar
      * Simple constructor with default settings.
      * The convergence check is set to a {@link
      * org.apache.commons.math3.optimization.SimpleVectorValueChecker}.
+     * @deprecated See {@link org.apache.commons.math3.optimization.SimpleValueChecker#SimpleValueChecker()}
      */
+    @Deprecated
     protected AbstractLeastSquaresOptimizer() {}
+
     /**
      * @param checker Convergence checker.
      */

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/AbstractScalarDifferentiableOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/AbstractScalarDifferentiableOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/AbstractScalarDifferentiableOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/AbstractScalarDifferentiableOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -46,8 +46,11 @@ public abstract class AbstractScalarDiff
      * The convergence check is set to a
      * {@link org.apache.commons.math3.optimization.SimpleValueChecker
      * SimpleValueChecker}.
+     * @deprecated See {@link org.apache.commons.math3.optimization.SimpleValueChecker#SimpleValueChecker()}
      */
+    @Deprecated
     protected AbstractScalarDifferentiableOptimizer() {}
+
     /**
      * @param checker Convergence checker.
      */

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/GaussNewtonOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/GaussNewtonOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/GaussNewtonOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/GaussNewtonOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -53,7 +53,9 @@ public class GaussNewtonOptimizer extend
      * The normal equations will be solved using LU decomposition and the
      * convergence check is set to a {@link SimpleVectorValueChecker}
      * with default tolerances.
+     * @deprecated See {@link SimpleVectorValueChecker#SimpleVectorValueChecker()}
      */
+    @Deprecated
     public GaussNewtonOptimizer() {
         this(true);
     }
@@ -76,7 +78,9 @@ public class GaussNewtonOptimizer extend
      * @param useLU If {@code true}, the normal equations will be solved
      * using LU decomposition, otherwise they will be solved using QR
      * decomposition.
+     * @deprecated See {@link SimpleVectorValueChecker#SimpleVectorValueChecker()}
      */
+    @Deprecated
     public GaussNewtonOptimizer(final boolean useLU) {
         this(useLU, new SimpleVectorValueChecker());
     }

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/LevenbergMarquardtOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/LevenbergMarquardtOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/LevenbergMarquardtOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/LevenbergMarquardtOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -260,6 +260,7 @@ public class LevenbergMarquardtOptimizer
                                        double parRelativeTolerance,
                                        double orthoTolerance,
                                        double threshold) {
+        super(null); // No custom convergence criterion.
         this.initialStepBoundFactor = initialStepBoundFactor;
         this.costRelativeTolerance = costRelativeTolerance;
         this.parRelativeTolerance = parRelativeTolerance;

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/NonLinearConjugateGradientOptimizer.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/NonLinearConjugateGradientOptimizer.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/NonLinearConjugateGradientOptimizer.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/general/NonLinearConjugateGradientOptimizer.java
Sun Jun  3 23:24:43 2012
@@ -61,7 +61,9 @@ public class NonLinearConjugateGradientO
      * @param updateFormula formula to use for updating the &beta; parameter,
      * must be one of {@link ConjugateGradientFormula#FLETCHER_REEVES} or {@link
      * ConjugateGradientFormula#POLAK_RIBIERE}.
+     * @deprecated See {@link SimpleValueChecker#SimpleValueChecker()}
      */
+    @Deprecated
     public NonLinearConjugateGradientOptimizer(final ConjugateGradientFormula updateFormula)
{
         this(updateFormula,
              new SimpleValueChecker());

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/univariate/SimpleUnivariateValueChecker.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/univariate/SimpleUnivariateValueChecker.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/univariate/SimpleUnivariateValueChecker.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/optimization/univariate/SimpleUnivariateValueChecker.java
Sun Jun  3 23:24:43 2012
@@ -37,7 +37,9 @@ public class SimpleUnivariateValueChecke
     extends AbstractConvergenceChecker<UnivariatePointValuePair> {
     /**
      * Build an instance with default thresholds.
+     * @deprecated See {@link AbstractConvergenceChecker#AbstractConvergenceChecker()}
      */
+    @Deprecated
     public SimpleUnivariateValueChecker() {}
 
     /** Build an instance with specified thresholds.

Modified: commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/direct/SimplexOptimizerMultiDirectionalTest.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/direct/SimplexOptimizerMultiDirectionalTest.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/direct/SimplexOptimizerMultiDirectionalTest.java
(original)
+++ commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/direct/SimplexOptimizerMultiDirectionalTest.java
Sun Jun  3 23:24:43 2012
@@ -141,7 +141,7 @@ public class SimplexOptimizerMultiDirect
     public void testMath283() {
         // fails because MultiDirectional.iterateSimplex is looping forever
         // the while(true) should be replaced with a convergence check
-        SimplexOptimizer optimizer = new SimplexOptimizer();
+        SimplexOptimizer optimizer = new SimplexOptimizer(1e-14, 1e-14);
         optimizer.setSimplex(new MultiDirectionalSimplex(2));
         final Gaussian2D function = new Gaussian2D(0, 0, 1);
         PointValuePair estimate = optimizer.optimize(1000, function,

Modified: commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizerTest.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizerTest.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizerTest.java
(original)
+++ commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizerTest.java
Sun Jun  3 23:24:43 2012
@@ -25,7 +25,7 @@ import org.junit.Test;
 public class AbstractLeastSquaresOptimizerTest {
 
     public static AbstractLeastSquaresOptimizer createOptimizer() {
-        return new AbstractLeastSquaresOptimizer() {
+        return new AbstractLeastSquaresOptimizer(null) {
 
             @Override
             protected PointVectorValuePair doOptimize() {

Modified: commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizerTestValidation.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizerTestValidation.java?rev=1345803&r1=1345802&r2=1345803&view=diff
==============================================================================
--- commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizerTestValidation.java
(original)
+++ commons/proper/math/trunk/src/test/java/org/apache/commons/math3/optimization/general/AbstractLeastSquaresOptimizerTestValidation.java
Sun Jun  3 23:24:43 2012
@@ -305,6 +305,10 @@ public class AbstractLeastSquaresOptimiz
  * Used for computing the covariance matrix.
  */
 class DummyOptimizer extends AbstractLeastSquaresOptimizer {
+    public DummyOptimizer() {
+        super(null);
+    }
+
     /**
      * This method does nothing and returns a dummy value.
      */



Mime
View raw message