Package org.jblas

Class Decompose

java.lang.Object
org.jblas.Decompose

public class Decompose extends Object
Matrix which collects all kinds of decompositions.
  • Constructor Details

  • Method Details

    • lu

      Compute LU Decomposition of a general matrix. Computes the LU decomposition using GETRF. Returns three matrices L, U, P, where L is lower diagonal, U is upper diagonal, and P is a permutation matrix such that A = P * L * U.
      Parameters:
      A - general matrix
      Returns:
      An LUDecomposition object.
    • cholesky

      public static FloatMatrix cholesky(FloatMatrix A)
      if (info ) Compute Cholesky decomposition of A
      Parameters:
      A - symmetric, positive definite matrix (only upper half is used)
      Returns:
      upper triangular matrix U such that A = U' * U
    • lu

      Compute LU Decomposition of a general matrix. Computes the LU decomposition using GETRF. Returns three matrices L, U, P, where L is lower diagonal, U is upper diagonal, and P is a permutation matrix such that A = P * L * U.
      Parameters:
      A - general matrix
      Returns:
      An LUDecomposition object.
    • cholesky

      public static DoubleMatrix cholesky(DoubleMatrix A)
      Compute Cholesky decomposition of A
      Parameters:
      A - symmetric, positive definite matrix (only upper half is used)
      Returns:
      upper triangular matrix U such that A = U' * U
    • qr

      QR decomposition. Decomposes (m,n) matrix A into a (m,m) matrix Q and an (m,n) matrix R such that Q is orthogonal, R is upper triangular and Q * R = A Note that if A has more rows than columns, then the lower rows of R will contain only zeros, such that the corresponding later columns of Q do not enter the computation at all. For some reason, LAPACK does not properly normalize those columns.
      Parameters:
      A - matrix
      Returns:
      QR decomposition
    • qr

      QR decomposition. Decomposes (m,n) matrix A into a (m,m) matrix Q and an (m,n) matrix R such that Q is orthogonal, R is upper triangular and Q * R = A
      Parameters:
      A - matrix
      Returns:
      QR decomposition