public class DenseCholesky
extends java.lang.Object
Constructor and Description |
---|
DenseCholesky(int n,
boolean upper)
Constructor for DenseCholesky
|
Modifier and Type | Method and Description |
---|---|
DenseCholesky |
factor(LowerSPDDenseMatrix A)
Calculates a Cholesky decomposition
|
DenseCholesky |
factor(UpperSPDDenseMatrix A)
Calculates a Cholesky decomposition
|
static DenseCholesky |
factorize(Matrix A)
Calculates a Cholesky decomposition
|
LowerTriangDenseMatrix |
getL()
Returns the decomposition matrix.
|
UpperTriangDenseMatrix |
getU()
Returns the decomposition matrix.
|
boolean |
isSPD()
Returns true if the matrix decomposed is symmetrical, positive definite
|
double |
rcond(Matrix A)
Computes the reciprocal condition number
|
DenseMatrix |
solve(DenseMatrix B)
Solves for
B , overwriting it on return |
public DenseCholesky(int n, boolean upper)
n
- Matrix sizeupper
- True for decomposing an upper symmetrical matrix, false for a
lower symmetrical matrixpublic static DenseCholesky factorize(Matrix A)
A
- Matrix to decompose. Not modifiedpublic DenseCholesky factor(LowerSPDDenseMatrix A)
A
- Matrix to decompose. Overwritten on returnpublic DenseCholesky factor(UpperSPDDenseMatrix A)
A
- Matrix to decompose. Overwritten on returnpublic boolean isSPD()
public LowerTriangDenseMatrix getL()
public UpperTriangDenseMatrix getU()
public DenseMatrix solve(DenseMatrix B) throws MatrixNotSPDException
B
, overwriting it on returnMatrixNotSPDException
public double rcond(Matrix A)
A
- The matrix this is a decomposition of