## Class CholeskyDecompositionCommonsResult

• java.lang.Object
• com.opengamma.strata.math.impl.linearalgebra.CholeskyDecompositionCommonsResult
• All Implemented Interfaces:
CholeskyDecompositionResult, DecompositionResult

public class CholeskyDecompositionCommonsResult
extends Object
implements CholeskyDecompositionResult
Wrapper for results of the Commons implementation of Cholesky decomposition (CholeskyDecompositionCommons).
• ### Constructor Summary

Constructors
Constructor Description
CholeskyDecompositionCommonsResult​(org.apache.commons.math3.linear.CholeskyDecomposition ch)
Constructor.
• ### Method Summary

All Methods
Modifier and Type Method Description
double getDeterminant()
Return the determinant of the matrix.
DoubleMatrix getL()
Returns the $\mathbf{L}$ matrix of the decomposition.
DoubleMatrix getLT()
Returns the transpose of the matrix $\mathbf{L}$ of the decomposition.
double[] solve​(double[] b)
Solves $\mathbf{A}x = b$ where $\mathbf{A}$ is a (decomposed) matrix and $b$ is a vector.
DoubleArray solve​(DoubleArray b)
Solves $\mathbf{A}x = b$ where $\mathbf{A}$ is a (decomposed) matrix and $b$ is a vector.
DoubleMatrix solve​(DoubleMatrix b)
Solves $\mathbf{A}x = \mathbf{B}$ where $\mathbf{A}$ is a (decomposed) matrix and $\mathbf{B}$ is a matrix.
• ### Methods inherited from class java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
• ### Constructor Detail

• #### CholeskyDecompositionCommonsResult

public CholeskyDecompositionCommonsResult​(org.apache.commons.math3.linear.CholeskyDecomposition ch)
Constructor.
Parameters:
ch - The result of the Cholesky decomposition.
• ### Method Detail

• #### solve

public DoubleArray solve​(DoubleArray b)
Solves $\mathbf{A}x = b$ where $\mathbf{A}$ is a (decomposed) matrix and $b$ is a vector.
Specified by:
solve in interface DecompositionResult
Parameters:
b - the vector to calculate with
Returns:
the vector x
• #### solve

public double[] solve​(double[] b)
Solves $\mathbf{A}x = b$ where $\mathbf{A}$ is a (decomposed) matrix and $b$ is a vector.
Specified by:
solve in interface DecompositionResult
Parameters:
b - the vector to calculate with
Returns:
the vector x
• #### solve

public DoubleMatrix solve​(DoubleMatrix b)
Solves $\mathbf{A}x = \mathbf{B}$ where $\mathbf{A}$ is a (decomposed) matrix and $\mathbf{B}$ is a matrix.
Specified by:
solve in interface DecompositionResult
Parameters:
b - the matrix to calculate with
Returns:
the matrix x
• #### getL

public DoubleMatrix getL()
Description copied from interface: CholeskyDecompositionResult
Returns the $\mathbf{L}$ matrix of the decomposition.

$\mathbf{L}$ is a lower-triangular matrix.

Specified by:
getL in interface CholeskyDecompositionResult
Returns:
the $\mathbf{L}$ matrix
• #### getLT

public DoubleMatrix getLT()
Description copied from interface: CholeskyDecompositionResult
Returns the transpose of the matrix $\mathbf{L}$ of the decomposition.

$\mathbf{L}^T$ is a upper-triangular matrix.

Specified by:
getLT in interface CholeskyDecompositionResult
Returns:
the $\mathbf{L}^T$ matrix
• #### getDeterminant

public double getDeterminant()
Description copied from interface: CholeskyDecompositionResult
Return the determinant of the matrix.
Specified by:
getDeterminant in interface CholeskyDecompositionResult
Returns:
determinant of the matrix