Author: luc
Date: Sun Jul 10 11:28:31 2011
New Revision: 1144838

URL: http://svn.apache.org/viewvc?rev=1144838&view=rev
Log:
fixed checkstyle warnings

Modified:
    
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/BaseSecantSolver.java
    
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/BracketedUnivariateRealSolver.java
    
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/UnivariateRealSolverUtils.java

Modified: 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/BaseSecantSolver.java
URL: 
http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/BaseSecantSolver.java?rev=1144838&r1=1144837&r2=1144838&view=diff
==============================================================================
--- 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/BaseSecantSolver.java
 (original)
+++ 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/BaseSecantSolver.java
 Sun Jul 10 11:28:31 2011
@@ -53,7 +53,7 @@ public abstract class BaseSecantSolver
     protected static final double DEFAULT_ABSOLUTE_ACCURACY = 1e-6;
 
     /** The kinds of solutions that the algorithm may accept. */
-    private AllowedSolutions allowedSolutions;
+    private AllowedSolutions allowed;
 
     /** The <em>Secant</em>-based root-finding method to use. */
     private final Method method;
@@ -66,7 +66,7 @@ public abstract class BaseSecantSolver
      */
     protected BaseSecantSolver(final double absoluteAccuracy, final Method 
method) {
         super(absoluteAccuracy);
-        this.allowedSolutions = AllowedSolutions.ANY_SIDE;
+        this.allowed = AllowedSolutions.ANY_SIDE;
         this.method = method;
     }
 
@@ -81,7 +81,7 @@ public abstract class BaseSecantSolver
                                final double absoluteAccuracy,
                                final Method method) {
         super(relativeAccuracy, absoluteAccuracy);
-        this.allowedSolutions = AllowedSolutions.ANY_SIDE;
+        this.allowed = AllowedSolutions.ANY_SIDE;
         this.method = method;
     }
 
@@ -96,7 +96,7 @@ public abstract class BaseSecantSolver
     public double solve(final int maxEval, final UnivariateRealFunction f,
                         final double min, final double max, final double 
startValue,
                         final AllowedSolutions allowedSolutions) {
-        this.allowedSolutions = allowedSolutions;
+        this.allowed = allowedSolutions;
         return super.solve(maxEval, f, min, max, startValue);
     }
 
@@ -176,7 +176,7 @@ public abstract class BaseSecantSolver
             // given the function value accuracy, then we can't get closer to
             // the root than we already are.
             if (FastMath.abs(f1) <= ftol) {
-                switch (allowedSolutions) {
+                switch (allowed) {
                 case ANY_SIDE:
                     return x1;
                 case LEFT_SIDE:
@@ -208,7 +208,7 @@ public abstract class BaseSecantSolver
             // are satisfied with the current approximation.
             if (FastMath.abs(x1 - x0) < FastMath.max(rtol * FastMath.abs(x1),
                                                      atol)) {
-                switch (allowedSolutions) {
+                switch (allowed) {
                 case ANY_SIDE:
                     return x1;
                 case LEFT_SIDE:

Modified: 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/BracketedUnivariateRealSolver.java
URL: 
http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/BracketedUnivariateRealSolver.java?rev=1144838&r1=1144837&r2=1144838&view=diff
==============================================================================
--- 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/BracketedUnivariateRealSolver.java
 (original)
+++ 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/BracketedUnivariateRealSolver.java
 Sun Jul 10 11:28:31 2011
@@ -38,6 +38,7 @@ import org.apache.commons.math.analysis.
  * <p>For backwards compatibility, all root-finding algorithms must have
  * {@link AllowedSolutions#ANY_SIDE ANY_SIDE} as default for the allowed
  * solutions.</p>
+ * @param <FUNC> Type of function to solve.
  *
  * @see AllowedSolutions
  * @since 3.0

Modified: 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/UnivariateRealSolverUtils.java
URL: 
http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/UnivariateRealSolverUtils.java?rev=1144838&r1=1144837&r2=1144838&view=diff
==============================================================================
--- 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/UnivariateRealSolverUtils.java
 (original)
+++ 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/solvers/UnivariateRealSolverUtils.java
 Sun Jul 10 11:28:31 2011
@@ -89,6 +89,7 @@ public class UnivariateRealSolverUtils {
      * @param max maximal bound of the search interval
      * @param allowedSolutions the kind of solutions that the root-finding 
algorithm may
      * accept as solutions.
+     * @return a root approximation, on the specified side of the exact root
      */
     public static double forceSide(final int maxEval, final 
UnivariateRealFunction f,
                                    final 
BracketedUnivariateRealSolver<UnivariateRealFunction> bracketing,


Reply via email to