Click or drag to resize
Accord.NET (logo)

CholeskyDecomposition Class

Cholesky Decomposition of a symmetric, positive definite matrix.
Inheritance Hierarchy
SystemObject
  Accord.Math.DecompositionsCholeskyDecomposition

Namespace:  Accord.Math.Decompositions
Assembly:  Accord.Math (in Accord.Math.dll) Version: 3.8.0
Syntax
[SerializableAttribute]
public sealed class CholeskyDecomposition : ICloneable, 
	ISolverMatrixDecomposition<double>
Request Example View Source

The CholeskyDecomposition type exposes the following members.

Constructors
  NameDescription
Public methodCholeskyDecomposition
Constructs a new Cholesky Decomposition.
Top
Properties
  NameDescription
Public propertyDeterminant
Gets the determinant of the decomposed matrix.
Public propertyDiagonal
Gets the one-dimensional array of diagonal elements in a LDLt decomposition.
Public propertyDiagonalMatrix
Gets the block diagonal matrix of diagonal elements in a LDLt decomposition.
Public propertyIsPositiveDefinite
Gets whether the decomposed matrix was positive definite.
Public propertyIsUndefined
Gets a value indicating whether the LDLt factorization has been computed successfully or if it is undefined.
Public propertyLeftTriangularFactor
Gets the left (lower) triangular factor L so that A = L * D * L'.
Public propertyLogDeterminant
If the matrix is positive-definite, gets the log-determinant of the decomposed matrix.
Public propertyNonsingular
Gets a value indicating whether the decomposed matrix is non-singular (i.e. invertible).
Top
Methods
  NameDescription
Public methodClone
Creates a new object that is a copy of the current instance.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodStatic memberFromLeftTriangularMatrix
Creates a new Cholesky decomposition directly from an already computed left triangular matrix L.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetInformationMatrix
Computes (Xt * X)^1 (the inverse of the covariance matrix). This matrix can be used to determine standard errors for the coefficients when solving a linear set of equations through any of the Solve(Double) methods.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodInverse
Solves a set of equation systems of type A * X = I.
Public methodInverseDiagonal(Boolean)
Computes the diagonal of the inverse of the decomposed matrix.
Public methodInverseDiagonal(Double, Boolean)
Computes the diagonal of the inverse of the decomposed matrix.
Public methodInverseTrace
Computes the trace of the inverse of the decomposed matrix.
Public methodReverse
Reverses the decomposition, reconstructing the original matrix X.
Public methodSolve(Double)
Solves a set of equation systems of type A * X = B.
Public methodSolve(Double)
Solves a set of equation systems of type A * x = b.
Public methodSolve(Double, Boolean)
Solves a set of equation systems of type A * X = B.
Public methodSolve(Double, Boolean)
Solves a set of equation systems of type A * x = b.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
Extension Methods
  NameDescription
Public Extension MethodHasMethod
Checks whether an object implements a method with the given name.
(Defined by ExtensionMethods.)
Public Extension MethodIsEqual
Compares two objects for equality, performing an elementwise comparison if the elements are vectors or matrices.
(Defined by Matrix.)
Public Extension MethodTo(Type)Overloaded.
Converts an object into another type, irrespective of whether the conversion can be done at compile time or not. This can be used to convert generic types to numeric types during runtime.
(Defined by ExtensionMethods.)
Public Extension MethodToTOverloaded.
Converts an object into another type, irrespective of whether the conversion can be done at compile time or not. This can be used to convert generic types to numeric types during runtime.
(Defined by ExtensionMethods.)
Top
Remarks

For a symmetric, positive definite matrix A, the Cholesky decomposition is a lower triangular matrix L so that A = L * L'. If the matrix is not positive definite, the constructor returns a partial decomposition and sets two internal variables that can be queried using the IsUndefined and IsPositiveDefinite properties.

Any square matrix A with non-zero pivots can be written as the product of a lower triangular matrix L and an upper triangular matrix U; this is called the LU decomposition. However, if A is symmetric and positive definite, we can choose the factors such that U is the transpose of L, and this is called the Cholesky decomposition. Both the LU and the Cholesky decomposition are used to solve systems of linear equations.

When it is applicable, the Cholesky decomposition is twice as efficient as the LU decomposition.

See Also