Package org.encog.mathutil.matrices

Examples of org.encog.mathutil.matrices.MatrixError


public class TestException extends TestCase {
  public void testExceptions()
  {
    NullPointerException npe = new NullPointerException();
    new MatrixError(npe);
    new NeuralNetworkError(npe);
    new BotError(npe);
    new BotError("test");
    new BrowseError(npe);
    new BrowseError("test");
View Full Code Here


   *            A Matrix with as many rows as A and any number of columns.
   * @return X so that L*L'*X = b.
   */
  public final Matrix solve(final Matrix b) {
    if (b.getRows() != n) {
      throw new MatrixError(
          "Matrix row dimensions must agree.");
    }
    if (!isspd) {
      throw new RuntimeException(
          "Matrix is not symmetric positive definite.");
View Full Code Here

    return Xmat;
  }
 
  public double[] Solve(double[] value) {
    if (value == null) {
      throw new MatrixError("value");
    }

    if (value.length != this.LU.length) {
      throw new MatrixError("Invalid matrix dimensions.");
    }

    if (!this.isNonsingular()) {
      throw new MatrixError("Matrix is singular");
    }

    // Copy right hand side with pivoting
    int count = value.length;
    double[] b = new double[count];
View Full Code Here

     */
    public double[][] inverse()
    {
        if (!this.isNonsingular())
        {
            throw new MatrixError("Matrix is singular");
        }

        int rows = this.LU.length;
        int columns = LU[0].length;
        int count = rows;
View Full Code Here

   *            A Matrix with as many rows as A and any number of columns.
   * @return X so that L*L'*X = b.
   */
  public final Matrix solve(final Matrix b) {
    if (b.getRows() != n) {
      throw new MatrixError(
          "Matrix row dimensions must agree.");
    }
    if (!isspd) {
      throw new RuntimeException(
          "Matrix is not symmetric positive definite.");
View Full Code Here

    return Xmat;
  }
 
  public double[] Solve(double[] value) {
    if (value == null) {
      throw new MatrixError("value");
    }

    if (value.length != this.LU.length) {
      throw new MatrixError("Invalid matrix dimensions.");
    }

    if (!this.isNonsingular()) {
      throw new MatrixError("Matrix is singular");
    }

    // Copy right hand side with pivoting
    int count = value.length;
    double[] b = new double[count];
View Full Code Here

     */
    public double[][] inverse()
    {
        if (!this.isNonsingular())
        {
            throw new MatrixError("Matrix is singular");
        }

        int rows = this.LU.length;
        int columns = LU[0].length;
        int count = rows;
View Full Code Here

TOP

Related Classes of org.encog.mathutil.matrices.MatrixError

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.