3
LDL: factorization of a real sparse symmetric matrix.
5
[L, D, Parent, fl] = ldl (A)
6
[L, D, Parent, fl] = ldl (A, P)
7
[x, fl] = ldl (A, [ ], b)
8
[x, fl] = ldl (A, P, b)
10
Let I = speye (size (A,1)). The factorization is (L+I)*D*(L+I)' = A or A(P,P).
11
A must be sparse, square, and real. Only the diagonal and upper triangular
12
part of A or A(P,P) are accessed. L is lower triangular with unit diagonal,
13
but the diagonal is not returned. D is a diagonal sparse matrix. P is either
14
a permutation of 1:n, or an empty vector, where n = size (A,1). If not
15
present, or empty, then P=1:n is assumed. Parent is the elimination tree of
16
A or A(P,P). If positive, fl is the floating point operation count, or
17
negative if any entry on the diagonal of D is zero.
19
In the x = ldl (A, P, b) usage, the LDL' factorization is not returned.
20
Instead, the system A*x=b is solved for x, where both b and x are dense.
22
If a zero entry on the diagonal of D is encountered, the LDL' factorization is
23
terminated at that point. If there is no fl output argument, an error occurs.
24
Otherwise, fl is negative, and let d=-fl. D(d,d) is the first zero entry on
25
the diagonal of D. A partial factorization is returned. Let B = A, or A(P,P)
26
if P is present. Let F = (L+I)*D*(L+I)'. Then F (1:d,1:d) = B (1:d,1:d).
27
Rows d+1 to n of L and D are all zero.
29
See also CHOL, LDLSYMBOL, SYMBFACT, ETREE
31
LDL Version 1.3, Copyright (c) 2006 by Timothy A Davis,
32
University of Florida. All Rights Reserved. See README for the License.
36
err: 4.44089e-16 fl: 61
41
err: 5.68989e-16 fl: 123
42
err: 4.57967e-16 fl: 57
47
err: 6.36644e-16 fl: 119