Skip to content

Commit

Permalink
Fix all checkstyle issues (missing javadocs params and trailing white…
Browse files Browse the repository at this point in the history
… space)
  • Loading branch information
kinow committed May 10, 2017
1 parent 60fdd5f commit 1b80dc4
Show file tree
Hide file tree
Showing 12 changed files with 21 additions and 19 deletions.
Expand Up @@ -32,7 +32,6 @@
/**
* Implementation of {@link RealMatrix} using a {@code double[][]} array to
* store entries.
*
*/
public class Array2DRowRealMatrix extends AbstractRealMatrix implements Serializable {
/** Serializable version identifier. */
Expand Down Expand Up @@ -390,7 +389,7 @@ public double[] preMultiply(final double[] v)

/** {@inheritDoc} */
@Override
public RealMatrix getSubMatrix(final int startRow, final int endRow,
public RealMatrix getSubMatrix(final int startRow, final int endRow,
final int startColumn, final int endColumn)
throws OutOfRangeException, NumberIsTooSmallException {
MatrixUtils.checkSubMatrixIndex(this, startRow, endRow, startColumn, endColumn);
Expand All @@ -400,7 +399,7 @@ public RealMatrix getSubMatrix(final int startRow, final int endRow,
for (int i = 0; i < rowCount; ++i) {
System.arraycopy(data[startRow + i], startColumn, outData[i], 0, columnCount);
}

Array2DRowRealMatrix subMatrix = new Array2DRowRealMatrix();
subMatrix.data = outData;
return subMatrix;
Expand Down
Expand Up @@ -55,7 +55,7 @@
* <li>key {@code "vector"} points to the offending vector, say x, such that
* x<sup>T</sup> &middot; L &middot; x &lt; 0.</li>
* </ul>
*
*
* <h3>References</h3>
* <dl>
* <dt><a id="BARR1994">Barret et al. (1994)</a></dt>
Expand Down
Expand Up @@ -39,7 +39,7 @@
* while matrix-vector products of the type M &middot; y remain comparatively
* easy to compute. In this library, M (not M<sup>-1</sup>!) is called the
* <em>preconditionner</em>.
*
*
* <p>
* Concrete implementations of this abstract class must be provided with the
* preconditioner M, as a {@link RealLinearOperator}.
Expand Down
6 changes: 3 additions & 3 deletions src/main/java/org/apache/commons/math4/linear/SymmLQ.java
Expand Up @@ -113,7 +113,7 @@
* initial phase. If x<sub>0</sub> is known to be a good approximation to x, one
* should compute r<sub>0</sub> = b - A &middot; x, solve A &middot; dx = r0,
* and set x = x<sub>0</sub> + dx.
*
*
* <h3><a id="context">Exception context</a></h3>
* <p>
* Besides standard {@link DimensionMismatchException}, this class might throw
Expand All @@ -127,7 +127,7 @@
* that x<sup>T</sup> &middot; L &middot; y &ne; y<sup>T</sup> &middot; L
* &middot; x (within a certain accuracy).</li>
* </ul>
*
*
* <p>
* {@link NonPositiveDefiniteOperatorException} might also be thrown in case the
* preconditioner is not positive definite. The relevant keys to the
Expand All @@ -138,7 +138,7 @@
* <li>key {@code "vector"}, which points to the offending vector, say x, such
* that x<sup>T</sup> &middot; L &middot; x &lt; 0.</li>
* </ul>
*
*
* <h3>References</h3>
* <dl>
* <dt><a id="PAIG1975">Paige and Saunders (1975)</a></dt>
Expand Down
Expand Up @@ -45,7 +45,7 @@
* state vector and relTol_i is the relative tolerance for the same
* component. The user can also use only two scalar values absTol and
* relTol which will be used for all components.
*
*
* <p>
* Note that <em>only</em> the {@link FieldODEState#getState() main part}
* of the state vector is used for stepsize control. The {@link
Expand Down
Expand Up @@ -40,7 +40,7 @@
* state vector and relTol_i is the relative tolerance for the same
* component. The user can also use only two scalar values absTol and
* relTol which will be used for all components.
*
*
* <p>
* If the Ordinary Differential Equations is an {@link ExpandableStatefulODE
* extended ODE} rather than a {@link
Expand Down
Expand Up @@ -84,7 +84,7 @@ public LinearConstraint(final double[] coefficients,
* <li>c<sub>1</sub>x<sub>1</sub> + ... c<sub>n</sub>x<sub>n</sub> &lt;= v</li>
* <li>c<sub>1</sub>x<sub>1</sub> + ... c<sub>n</sub>x<sub>n</sub> &gt;= v</li>
* </ul>
*
*
* @param coefficients The coefficients of the constraint (left hand side)
* @param relationship The type of (in)equality used in the constraint
* @param value The value of the constraint (right hand side)
Expand All @@ -109,7 +109,7 @@ public LinearConstraint(final RealVector coefficients,
* <li>l<sub>1</sub>x<sub>1</sub> + ... l<sub>n</sub>x<sub>n</sub> + l<sub>cst</sub> &gt;=
* r<sub>1</sub>x<sub>1</sub> + ... r<sub>n</sub>x<sub>n</sub> + r<sub>cst</sub></li>
* </ul>
*
*
* @param lhsCoefficients The coefficients of the linear expression on the left hand side of the constraint
* @param lhsConstant The constant term of the linear expression on the left hand side of the constraint
* @param relationship The type of (in)equality used in the constraint
Expand Down Expand Up @@ -140,7 +140,7 @@ public LinearConstraint(final double[] lhsCoefficients, final double lhsConstant
* <li>l<sub>1</sub>x<sub>1</sub> + ... l<sub>n</sub>x<sub>n</sub> + l<sub>cst</sub> &gt;=
* r<sub>1</sub>x<sub>1</sub> + ... r<sub>n</sub>x<sub>n</sub> + r<sub>cst</sub></li>
* </ul>
*
*
* @param lhsCoefficients The coefficients of the linear expression on the left hand side of the constraint
* @param lhsConstant The constant term of the linear expression on the left hand side of the constraint
* @param relationship The type of (in)equality used in the constraint
Expand Down
Expand Up @@ -84,7 +84,7 @@ public LeastSquaresConverter(final MultivariateVectorFunction function,
* <div style="white-space: pre"><code>
* objective = &sum;weight<sub>i</sub>(observation<sub>i</sub>-objective<sub>i</sub>)<sup>2</sup>
* </code></div>
*
*
* <p>
* Weights can be used for example to combine residuals with different standard
* deviations. As an example, consider a residuals array in which even elements
Expand Down Expand Up @@ -127,7 +127,7 @@ public LeastSquaresConverter(final MultivariateVectorFunction function,
* <div style="white-space: pre"><code>
* objective = y<sup>T</sup>y with y = scale&times;(observation-objective)
* </code></div>
*
*
* <p>
* The array computed by the objective function, the observations array and the
* the scaling matrix must have consistent sizes or a {@link DimensionMismatchException}
Expand Down
Expand Up @@ -89,7 +89,7 @@ public class MultivariateFunctionPenaltyAdapter
* penalty(point) = offset + &sum;<sub>i</sub>[scale[i] * &radic;|point[i]-boundary[i]|]
* </code></div>
* where indices i correspond to all the components that violates their boundaries.
*
*
* <p>
* So when attempting a function minimization, offset should be larger than
* the maximum expected value of the underlying function and scale components
Expand Down
Expand Up @@ -51,7 +51,6 @@
* Note: This implementation is not synchronized and produces an approximate
* result. For small samples, where data can be stored and processed in memory,
* {@link Percentile} should be used.</p>
*
*/
public class PSquarePercentile extends AbstractStorelessUnivariateStatistic
implements StorelessUnivariateStatistic, Serializable {
Expand Down Expand Up @@ -875,6 +874,8 @@ public String toString() {
* A simple fixed capacity list that has an upper bound to growth.
* Once its capacity is reached, {@code add} is a no-op, returning
* {@code false}.
*
* @param <E> type for fixed capacity list
*/
private static class FixedCapacityList<E> extends ArrayList<E> implements Serializable {

Expand Down
Expand Up @@ -379,7 +379,7 @@ public boolean chiSquareTest(final long[][] counts, final double alpha)
* &sum;[(K * observed1[i] - observed2[i]/K)<sup>2</sup> / (observed1[i] + observed2[i])]
* </code> where
* <br><code>K = &radic;[&sum;(observed2 / &sum;(observed1)]</code>
*
*
* <p>This statistic can be used to perform a Chi-Square test evaluating the
* null hypothesis that both observed counts follow the same distribution.</p>
* <p>
Expand Down
Expand Up @@ -142,6 +142,7 @@ public class KolmogorovSmirnovTest {
@Deprecated
protected static final int MONTE_CARLO_ITERATIONS = 1000000;

/** No longer used. */
@Deprecated
private final UniformRandomProvider rng;

Expand Down Expand Up @@ -1184,7 +1185,8 @@ private static boolean hasTies(double[] x, double[] y) {
* values are overwritten with the result of applying jitter.</p>
*
* @param data input/output data array - entries overwritten by the method
* @param sampler probability distribution to sample for jitter values
* @param rng probability distribution to sample for jitter values
* @param ulp ulp used when generating random numbers
* @throws NullPointerException if either of the parameters is null
*/
private static void jitter(double[] data,
Expand Down

0 comments on commit 1b80dc4

Please sign in to comment.