function [arg1, arg2, arg3, arg4] = ldl (A, P, b)
%
% LDL:  factorization of a real sparse symmetric matrix.
%
%	[L, D, Parent, fl] = ldl (A)
%	[L, D, Parent, fl] = ldl (A, P)
%	[x, fl] = ldl (A, [ ], b)
%	[x, fl] = ldl (A, P, b)
%
% Let I = speye (size (A,1)). The factorization is (L+I)*D*(L+I)' = A or A(P,P).
% A must be sparse, square, and real.  Only the diagonal and upper triangular
% part of A or A(P,P) are accessed.  L is lower triangular with unit diagonal,
% but the diagonal is not returned.  D is a diagonal sparse matrix.  P is either
% a permutation of 1:n, or an empty vector, where n = size (A,1).  If not
% present, or empty, then P=1:n is assumed.  Parent is the elimination tree of
% A or A(P,P).  If positive, fl is the floating point operation count, or
% negative if any entry on the diagonal of D is zero.
%
% In the x = ldl (A, P, b) usage, the LDL' factorization is not returned.
% Instead, the system A*x=b is solved for x, where both b and x are dense.
%
% If a zero entry on the diagonal of D is encountered, the LDL' factorization is
% terminated at that point.  If there is no fl output argument, an error occurs.
% Otherwise, fl is negative, and let d=-fl.  D(d,d) is the first zero entry on
% the diagonal of D.  A partial factorization is returned.  Let B = A, or A(P,P)
% if P is present.  Let F = (L+I)*D*(L+I)'.  Then F (1:d,1:d) = B (1:d,1:d).
% Rows d+1 to n of L and D are all zero.
%
% See also CHOL, LDLSYMBOL, SYMBFACT, ETREE
%
% LDL Version 1.0 (Dec. 31, 2003), Copyright (c) 2003 by Timothy A Davis,
% University of Florida.  All Rights Reserved.  See README for the License.

help ldl
error ('ldl mexFunction not found') ;
