MATH-1566: Fix CheckStyle Issues
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/MidPointIntegrator.java b/src/main/java/org/apache/commons/math4/analysis/integration/MidPointIntegrator.java
index d010fbd..757e92d 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/MidPointIntegrator.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/MidPointIntegrator.java
@@ -16,12 +16,7 @@
*/
package org.apache.commons.math4.analysis.integration;
-import org.apache.commons.math4.exception.MathIllegalArgumentException;
-import org.apache.commons.math4.exception.MaxCountExceededException;
-import org.apache.commons.math4.exception.NotStrictlyPositiveException;
import org.apache.commons.math4.exception.NumberIsTooLargeException;
-import org.apache.commons.math4.exception.NumberIsTooSmallException;
-import org.apache.commons.math4.exception.TooManyEvaluationsException;
import org.apache.commons.math4.util.FastMath;
/**
@@ -47,9 +42,9 @@
* @param absoluteAccuracy absolute accuracy of the result
* @param minimalIterationCount minimum number of iterations
* @param maximalIterationCount maximum number of iterations
- * @exception NotStrictlyPositiveException if minimal number of iterations
+ * @exception org.apache.commons.math4.exception.NotStrictlyPositiveException if minimal number of iterations
* is not strictly positive
- * @exception NumberIsTooSmallException if maximal number of iterations
+ * @exception org.apache.commons.math4.exception.NumberIsTooSmallException if maximal number of iterations
* is lesser than or equal to the minimal number of iterations
* @exception NumberIsTooLargeException if maximal number of iterations
* is greater than 39.
@@ -69,9 +64,9 @@
* Build a midpoint integrator with given iteration counts.
* @param minimalIterationCount minimum number of iterations
* @param maximalIterationCount maximum number of iterations
- * @exception NotStrictlyPositiveException if minimal number of iterations
+ * @exception org.apache.commons.math4.exception.NotStrictlyPositiveException if minimal number of iterations
* is not strictly positive
- * @exception NumberIsTooSmallException if maximal number of iterations
+ * @exception org.apache.commons.math4.exception.NumberIsTooSmallException if maximal number of iterations
* is lesser than or equal to the minimal number of iterations
* @exception NumberIsTooLargeException if maximal number of iterations
* is greater than 39.
@@ -109,7 +104,7 @@
* @param diffMaxMin Difference between the lower bound and upper bound
* of the integration interval.
* @return the value of n-th stage integral
- * @throws TooManyEvaluationsException if the maximal number of evaluations
+ * @throws org.apache.commons.math4.exception.TooManyEvaluationsException if the maximal number of evaluations
* is exceeded.
*/
private double stage(final int n,
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/RombergIntegrator.java b/src/main/java/org/apache/commons/math4/analysis/integration/RombergIntegrator.java
index 50179df..5e81c01 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/RombergIntegrator.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/RombergIntegrator.java
@@ -16,11 +16,7 @@
*/
package org.apache.commons.math4.analysis.integration;
-import org.apache.commons.math4.exception.MaxCountExceededException;
-import org.apache.commons.math4.exception.NotStrictlyPositiveException;
import org.apache.commons.math4.exception.NumberIsTooLargeException;
-import org.apache.commons.math4.exception.NumberIsTooSmallException;
-import org.apache.commons.math4.exception.TooManyEvaluationsException;
import org.apache.commons.math4.util.FastMath;
/**
@@ -47,9 +43,9 @@
* @param minimalIterationCount minimum number of iterations
* @param maximalIterationCount maximum number of iterations
* (must be less than or equal to {@link #ROMBERG_MAX_ITERATIONS_COUNT})
- * @exception NotStrictlyPositiveException if minimal number of iterations
+ * @exception org.apache.commons.math4.exception.NotStrictlyPositiveException if minimal number of iterations
* is not strictly positive
- * @exception NumberIsTooSmallException if maximal number of iterations
+ * @exception org.apache.commons.math4.exception.NumberIsTooSmallException if maximal number of iterations
* is lesser than or equal to the minimal number of iterations
* @exception NumberIsTooLargeException if maximal number of iterations
* is greater than {@link #ROMBERG_MAX_ITERATIONS_COUNT}
@@ -70,9 +66,9 @@
* @param minimalIterationCount minimum number of iterations
* @param maximalIterationCount maximum number of iterations
* (must be less than or equal to {@link #ROMBERG_MAX_ITERATIONS_COUNT})
- * @exception NotStrictlyPositiveException if minimal number of iterations
+ * @exception org.apache.commons.math4.exception.NotStrictlyPositiveException if minimal number of iterations
* is not strictly positive
- * @exception NumberIsTooSmallException if maximal number of iterations
+ * @exception org.apache.commons.math4.exception.NumberIsTooSmallException if maximal number of iterations
* is lesser than or equal to the minimal number of iterations
* @exception NumberIsTooLargeException if maximal number of iterations
* is greater than {@link #ROMBERG_MAX_ITERATIONS_COUNT}
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/SimpsonIntegrator.java b/src/main/java/org/apache/commons/math4/analysis/integration/SimpsonIntegrator.java
index 554be75..0e85f72 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/SimpsonIntegrator.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/SimpsonIntegrator.java
@@ -16,9 +16,7 @@
*/
package org.apache.commons.math4.analysis.integration;
-import org.apache.commons.math4.exception.NotStrictlyPositiveException;
import org.apache.commons.math4.exception.NumberIsTooLargeException;
-import org.apache.commons.math4.exception.NumberIsTooSmallException;
import org.apache.commons.math4.util.FastMath;
/**
@@ -44,9 +42,9 @@
* @param minimalIterationCount minimum number of iterations
* @param maximalIterationCount maximum number of iterations
* (must be less than or equal to {@link #SIMPSON_MAX_ITERATIONS_COUNT})
- * @exception NotStrictlyPositiveException if minimal number of iterations
+ * @exception org.apache.commons.math4.exception.NotStrictlyPositiveException if minimal number of iterations
* is not strictly positive
- * @exception NumberIsTooSmallException if maximal number of iterations
+ * @exception org.apache.commons.math4.exception.NumberIsTooSmallException if maximal number of iterations
* is lesser than or equal to the minimal number of iterations
* @exception NumberIsTooLargeException if maximal number of iterations
* is greater than {@link #SIMPSON_MAX_ITERATIONS_COUNT}
@@ -67,9 +65,9 @@
* @param minimalIterationCount minimum number of iterations
* @param maximalIterationCount maximum number of iterations
* (must be less than or equal to {@link #SIMPSON_MAX_ITERATIONS_COUNT})
- * @exception NotStrictlyPositiveException if minimal number of iterations
+ * @exception org.apache.commons.math4.exception.NotStrictlyPositiveException if minimal number of iterations
* is not strictly positive
- * @exception NumberIsTooSmallException if maximal number of iterations
+ * @exception org.apache.commons.math4.exception.NumberIsTooSmallException if maximal number of iterations
* is lesser than or equal to the minimal number of iterations
* @exception NumberIsTooLargeException if maximal number of iterations
* is greater than {@link #SIMPSON_MAX_ITERATIONS_COUNT}
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/TrapezoidIntegrator.java b/src/main/java/org/apache/commons/math4/analysis/integration/TrapezoidIntegrator.java
index 5a7e0e8..87239c7 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/TrapezoidIntegrator.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/TrapezoidIntegrator.java
@@ -16,12 +16,7 @@
*/
package org.apache.commons.math4.analysis.integration;
-import org.apache.commons.math4.exception.MathIllegalArgumentException;
-import org.apache.commons.math4.exception.MaxCountExceededException;
-import org.apache.commons.math4.exception.NotStrictlyPositiveException;
import org.apache.commons.math4.exception.NumberIsTooLargeException;
-import org.apache.commons.math4.exception.NumberIsTooSmallException;
-import org.apache.commons.math4.exception.TooManyEvaluationsException;
import org.apache.commons.math4.util.FastMath;
/**
@@ -48,9 +43,9 @@
* @param absoluteAccuracy absolute accuracy of the result
* @param minimalIterationCount minimum number of iterations
* @param maximalIterationCount maximum number of iterations
- * @exception NotStrictlyPositiveException if minimal number of iterations
+ * @exception org.apache.commons.math4.exception.NotStrictlyPositiveException if minimal number of iterations
* is not strictly positive
- * @exception NumberIsTooSmallException if maximal number of iterations
+ * @exception org.apache.commons.math4.exception.NumberIsTooSmallException if maximal number of iterations
* is lesser than or equal to the minimal number of iterations
* @exception NumberIsTooLargeException if maximal number of iterations
* is greater than 63.
@@ -70,9 +65,9 @@
* Build a trapezoid integrator with given iteration counts.
* @param minimalIterationCount minimum number of iterations
* @param maximalIterationCount maximum number of iterations
- * @exception NotStrictlyPositiveException if minimal number of iterations
+ * @exception org.apache.commons.math4.exception.NotStrictlyPositiveException if minimal number of iterations
* is not strictly positive
- * @exception NumberIsTooSmallException if maximal number of iterations
+ * @exception org.apache.commons.math4.exception.NumberIsTooSmallException if maximal number of iterations
* is lesser than or equal to the minimal number of iterations
* @exception NumberIsTooLargeException if maximal number of iterations
* is greater than 63.
@@ -106,7 +101,7 @@
* @param baseIntegrator integrator holding integration parameters
* @param n the stage of 1/2 refinement, n = 0 is no refinement
* @return the value of n-th stage integral
- * @throws TooManyEvaluationsException if the maximal number of evaluations
+ * @throws org.apache.commons.math4.exception.TooManyEvaluationsException if the maximal number of evaluations
* is exceeded.
*/
double stage(final BaseAbstractUnivariateIntegrator baseIntegrator, final int n) {
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/UnivariateIntegrator.java b/src/main/java/org/apache/commons/math4/analysis/integration/UnivariateIntegrator.java
index 994985c..97dd416 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/UnivariateIntegrator.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/UnivariateIntegrator.java
@@ -17,10 +17,6 @@
package org.apache.commons.math4.analysis.integration;
import org.apache.commons.math4.analysis.UnivariateFunction;
-import org.apache.commons.math4.exception.MathIllegalArgumentException;
-import org.apache.commons.math4.exception.MaxCountExceededException;
-import org.apache.commons.math4.exception.NullArgumentException;
-import org.apache.commons.math4.exception.TooManyEvaluationsException;
/**
* Interface for univariate real integration algorithms.
@@ -65,13 +61,13 @@
* @param min the lower bound for the interval
* @param max the upper bound for the interval
* @return the value of integral
- * @throws TooManyEvaluationsException if the maximum number of function
+ * @throws org.apache.commons.math4.exception.TooManyEvaluationsException if the maximum number of function
* evaluations is exceeded
- * @throws MaxCountExceededException if the maximum iteration count is exceeded
+ * @throws org.apache.commons.math4.exception.MaxCountExceededException if the maximum iteration count is exceeded
* or the integrator detects convergence problems otherwise
- * @throws MathIllegalArgumentException if {@code min > max} or the endpoints do not
+ * @throws org.apache.commons.math4.exception.MathIllegalArgumentException if {@code min > max} or the endpoints do not
* satisfy the requirements specified by the integrator
- * @throws NullArgumentException if {@code f} is {@code null}.
+ * @throws org.apache.commons.math4.exception.NullArgumentException if {@code f} is {@code null}.
*/
double integrate(int maxEval, UnivariateFunction f, double min, double max);
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/GaussIntegrator.java b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/GaussIntegrator.java
index de86f48..9e0213a 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/GaussIntegrator.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/GaussIntegrator.java
@@ -18,7 +18,6 @@
import org.apache.commons.math4.analysis.UnivariateFunction;
import org.apache.commons.math4.exception.DimensionMismatchException;
-import org.apache.commons.math4.exception.NonMonotonicSequenceException;
import org.apache.commons.math4.util.MathArrays;
import org.apache.commons.math4.util.Pair;
@@ -42,7 +41,7 @@
*
* @param points Integration points.
* @param weights Weights of the corresponding integration nodes.
- * @throws NonMonotonicSequenceException if the {@code points} are not
+ * @throws org.apache.commons.math4.exception.NonMonotonicSequenceException if the {@code points} are not
* sorted in increasing order.
* @throws DimensionMismatchException if points and weights don't have the same length
*/
@@ -64,7 +63,7 @@
* the pair) and weights (second element of the pair.
*
* @param pointsAndWeights Integration points and corresponding weights.
- * @throws NonMonotonicSequenceException if the {@code points} are not
+ * @throws org.apache.commons.math4.exception.NonMonotonicSequenceException if the {@code points} are not
* sorted in increasing order.
*
* @see #GaussIntegrator(double[], double[])
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/GaussIntegratorFactory.java b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/GaussIntegratorFactory.java
index 3b1c2eb..e65124c 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/GaussIntegratorFactory.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/GaussIntegratorFactory.java
@@ -16,11 +16,8 @@
*/
package org.apache.commons.math4.analysis.integration.gauss;
-import java.math.BigDecimal;
-
-import org.apache.commons.math4.exception.DimensionMismatchException;
-import org.apache.commons.math4.exception.NotStrictlyPositiveException;
import org.apache.commons.math4.util.Pair;
+import java.math.BigDecimal;
/**
* Class that provides different ways to compute the nodes and weights to be
@@ -81,7 +78,7 @@
* @param lowerBound Lower bound of the integration interval.
* @param upperBound Upper bound of the integration interval.
* @return a Gauss-Legendre integrator.
- * @throws NotStrictlyPositiveException if number of points is not positive
+ * @throws org.apache.commons.math4.exception.NotStrictlyPositiveException if number of points is not positive
*/
public GaussIntegrator legendre(int numberOfPoints,
double lowerBound,
@@ -99,7 +96,7 @@
*
* @param numberOfPoints Order of the integration rule.
* @return a Gauss-Legendre integrator.
- * @throws NotStrictlyPositiveException if number of points is not positive
+ * @throws org.apache.commons.math4.exception.NotStrictlyPositiveException if number of points is not positive
*/
public GaussIntegrator legendreHighPrecision(int numberOfPoints) {
return new GaussIntegrator(getRule(legendreHighPrecision, numberOfPoints));
@@ -114,7 +111,7 @@
* @param lowerBound Lower bound of the integration interval.
* @param upperBound Upper bound of the integration interval.
* @return a Gauss-Legendre integrator.
- * @throws NotStrictlyPositiveException if number of points is not positive
+ * @throws org.apache.commons.math4.exception.NotStrictlyPositiveException if number of points is not positive
*/
public GaussIntegrator legendreHighPrecision(int numberOfPoints,
double lowerBound,
@@ -145,8 +142,8 @@
* @param factory Integration rule factory.
* @param numberOfPoints Order of the integration rule.
* @return the integration nodes and weights.
- * @throws NotStrictlyPositiveException if number of points is not positive
- * @throws DimensionMismatchException if the elements of the rule pair do not
+ * @throws org.apache.commons.math4.exception.NotStrictlyPositiveException if number of points is not positive
+ * @throws org.apache.commons.math4.exception.DimensionMismatchException if the elements of the rule pair do not
* have the same length.
*/
private static Pair<double[], double[]> getRule(BaseRuleFactory<? extends Number> factory,
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/HermiteRuleFactory.java b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/HermiteRuleFactory.java
index c680ed9..2d5a3e1 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/HermiteRuleFactory.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/HermiteRuleFactory.java
@@ -16,7 +16,6 @@
*/
package org.apache.commons.math4.analysis.integration.gauss;
-import org.apache.commons.math4.exception.DimensionMismatchException;
import org.apache.commons.math4.util.FastMath;
import org.apache.commons.math4.util.Pair;
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LaguerreRuleFactory.java b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LaguerreRuleFactory.java
index fc9eb3b..23e45df 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LaguerreRuleFactory.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LaguerreRuleFactory.java
@@ -20,7 +20,6 @@
import org.apache.commons.math4.analysis.polynomials.PolynomialFunction;
import org.apache.commons.math4.analysis.polynomials.PolynomialsUtils;
-import org.apache.commons.math4.exception.DimensionMismatchException;
import org.apache.commons.math4.linear.EigenDecomposition;
import org.apache.commons.math4.linear.MatrixUtils;
import org.apache.commons.math4.linear.RealMatrix;
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LegendreHighPrecisionRuleFactory.java b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LegendreHighPrecisionRuleFactory.java
index 811f6d1..a982deb 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LegendreHighPrecisionRuleFactory.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LegendreHighPrecisionRuleFactory.java
@@ -16,12 +16,11 @@
*/
package org.apache.commons.math4.analysis.integration.gauss;
+import org.apache.commons.math4.util.Pair;
+
import java.math.BigDecimal;
import java.math.MathContext;
-import org.apache.commons.math4.exception.DimensionMismatchException;
-import org.apache.commons.math4.util.Pair;
-
/**
* Factory that creates Gauss-type quadrature rule using Legendre polynomials.
* In this implementation, the lower and upper bounds of the natural interval
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LegendreRuleFactory.java b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LegendreRuleFactory.java
index 657f594..cbc1e7d 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LegendreRuleFactory.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/LegendreRuleFactory.java
@@ -16,7 +16,6 @@
*/
package org.apache.commons.math4.analysis.integration.gauss;
-import org.apache.commons.math4.exception.DimensionMismatchException;
import org.apache.commons.math4.util.Pair;
/**
diff --git a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/SymmetricGaussIntegrator.java b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/SymmetricGaussIntegrator.java
index 083b848..1230a1d 100644
--- a/src/main/java/org/apache/commons/math4/analysis/integration/gauss/SymmetricGaussIntegrator.java
+++ b/src/main/java/org/apache/commons/math4/analysis/integration/gauss/SymmetricGaussIntegrator.java
@@ -17,8 +17,6 @@
package org.apache.commons.math4.analysis.integration.gauss;
import org.apache.commons.math4.analysis.UnivariateFunction;
-import org.apache.commons.math4.exception.DimensionMismatchException;
-import org.apache.commons.math4.exception.NonMonotonicSequenceException;
import org.apache.commons.math4.util.Pair;
/**
@@ -36,9 +34,9 @@
*
* @param points Integration points.
* @param weights Weights of the corresponding integration nodes.
- * @throws NonMonotonicSequenceException if the {@code points} are not
+ * @throws org.apache.commons.math4.exception.NonMonotonicSequenceException if the {@code points} are not
* sorted in increasing order.
- * @throws DimensionMismatchException if points and weights don't have the same length
+ * @throws org.apache.commons.math4.exception.DimensionMismatchException if points and weights don't have the same length
*/
public SymmetricGaussIntegrator(double[] points,
double[] weights) {
@@ -50,7 +48,7 @@
* the pair) and weights (second element of the pair.
*
* @param pointsAndWeights Integration points and corresponding weights.
- * @throws NonMonotonicSequenceException if the {@code points} are not
+ * @throws org.apache.commons.math4.exception.NonMonotonicSequenceException if the {@code points} are not
* sorted in increasing order.
*
* @see #SymmetricGaussIntegrator(double[], double[])