~ubuntu-branches/ubuntu/natty/suitesparse/natty

« back to all changes in this revision

Viewing changes to CSparse/MATLAB/CSparse/cs_amd.m

  • Committer: Bazaar Package Importer
  • Author(s): Christophe Prud'homme
  • Date: 2006-12-22 10:16:15 UTC
  • Revision ID: james.westby@ubuntu.com-20061222101615-2ohaj8902oix2rnk
Tags: upstream-2.3.1
ImportĀ upstreamĀ versionĀ 2.3.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
function p = cs_amd (A,order)                                               %#ok
 
2
%CS_AMD approximate minimum degree ordering.
 
3
%   p = cs_amd(A) finds a minimum degree ordering of A+A'
 
4
%   p = cs_amd(A,order):
 
5
%       order = 1:  same as cs_amd(A)
 
6
%       order = 2:  minimum degree ordering of S'*S where S = A except that
 
7
%                   "dense" rows of A are removed from S (a dense row has
 
8
%                   10*sqrt(n) or more entries where n = size(A,2)).  Similar
 
9
%                   to p = colamd(A), except that colamd does not form A'*A
 
10
%                   explicitly.
 
11
%       order = 3:  minimum degree ordering of A'*A.  Similar to colamd(A,[n m])
 
12
%                   where [m n] = size(A), except that colamd does not form A'*A
 
13
%                   explicitly.
 
14
%   Example:
 
15
%       Prob = UFget ('HB/bcsstk01') ; A = Prob.A ;
 
16
%       p = cs_amd (A) ;
 
17
%       nnz (chol (A))
 
18
%       nnz (chol (A (p,p)))
 
19
%
 
20
%   See also AMD, COLAMD, SYMAMD.
 
21
 
 
22
%   Copyright 2006, Timothy A. Davis.
 
23
%   http://www.cise.ufl.edu/research/sparse
 
24
 
 
25
error ('cs_amd mexFunction not found') ;