For AI agents: use /llms.txt for the Nakafa content index.
For positive definite matrices, there is a special property that makes decomposition much simpler. LU decomposition can be performed without using a permutation matrix P because Gaussian elimination can proceed without row swapping, and all pivot elements generated are guaranteed to be positive.
This means we obtain factorization in the form A=L⋅U, where the diagonal elements of are positive pivot elements for all diagonal indices.
Since A=AT, we also have:
where U~ is a matrix whose main diagonal is normalized to 1, and D is a diagonal matrix:
Since LU decomposition without P is unique, then:
then D21⋅D21=D.
Positive definite matrices A∈Rn×n allow for Cholesky decomposition:
where L~=L⋅D21 is a regular lower triangular matrix. This matrix can be computed using the Cholesky algorithm.
The computation of matrix L~ is performed with:
based on the relationship L~⋅L~T=A. The following algorithm produces the Cholesky factor.
Given a positive definite matrix A∈Rn×n.
For i=2,…,n:
for j=i+1,…,n.
After running this algorithm, we will obtain the Cholesky factor which is a lower triangular matrix:
The Cholesky algorithm for computing the Cholesky factor L~ from A∈Rn×n requires:
This is half the number of operations required to compute LU decomposition, because the use of symmetry allows us to perform computations without row swapping in a different order.