The ldl command computes the
LDL decomposition of the given symmetric (real or complex)
or Hermitian matrix A.
ldl takes one mandatory argument and a sequence of optional arguments:
A, a symmetric or Hermitian matrix.
Optionally, opts, a sequence of options, each of which is one of the following:
hermite, which must be passed alongside a Hermitian matrix A since
no check is performed.
zip, which forces merging the output matrices L and D into matrix M.
ldl(A ⟨,opts ⟩)
returns the sequence p,L,D or p,M (if the option zip is passed), where
p is the permutation defining the permutation matrix P (using permu2mat command),
L is a unit lower triangular matrix and D is a tridiagonal matrix with 1- or 2-blocks on the
diagonal. Matrix M is obtained by merging L and D together which saves the space while allowing
unambiguous reconstruction of L and D. The following relation holds: