16#define CS_DATE "Mar 6, 2006"
17#define CS_COPYRIGHT "Copyright (c) Timothy A. Davis, 2006"
31cs *cs_add (
const cs *A,
const cs *B,
double alpha,
double beta) ;
32int cs_cholsol (
const cs *A,
double *b,
int order) ;
34int cs_entry (
cs *T,
int i,
int j,
double x) ;
35int cs_lusol (
const cs *A,
double *b,
int order,
double tol) ;
36int cs_gaxpy (
const cs *A,
const double *x,
double *y) ;
37cs *cs_multiply (
const cs *A,
const cs *B) ;
38int cs_qrsol (
const cs *A,
double *b,
int order) ;
39cs *cs_transpose (
const cs *A,
int values) ;
40cs *cs_triplet (
const cs *T) ;
41cs *cs_compress_LLM(
const double *ele,
int lda,
int m,
int n,
int nz,
int I1,
int TwoD);
42double cs_norm (
const cs *A) ;
43int cs_print (
const cs *A,
int brief) ;
44cs *cs_load (FILE *f) ;
46void *cs_calloc (
int n,
size_t size) ;
47void *cs_free (
void *p) ;
48void *cs_realloc (
void *p,
int n,
size_t size,
int *ok) ;
49cs *cs_spalloc (
int m,
int n,
int nzmax,
int values,
int triplet) ;
50cs *cs_spfree (
cs *A) ;
51int cs_sprealloc (
cs *A,
int nzmax) ;
52void *cs_malloc (
int n,
size_t size) ;
85int *cs_amd (
const cs *A,
int order) ;
86csn *cs_chol (
const cs *A,
const css *S) ;
87csd *cs_dmperm (
const cs *A) ;
88int cs_droptol (
cs *A,
double tol) ;
89int cs_dropzeros (
cs *A) ;
90int cs_happly (
const cs *V,
int i,
double beta,
double *x) ;
91int cs_ipvec (
int n,
const int *P,
const double *b,
double *x) ;
92int cs_lsolve (
const cs *L,
double *x) ;
93int cs_ltsolve (
const cs *L,
double *x) ;
94csn *cs_lu (
const cs *A,
const css *S,
double tol) ;
95cs *cs_permute (
const cs *A,
const int *Pinv,
const int *Q,
int values) ;
96int *cs_pinv (
const int *P,
int n) ;
97int cs_pvec (
int n,
const int *P,
const double *b,
double *x) ;
98csn *cs_qr (
const cs *A,
const css *S) ;
99css *cs_schol (
const cs *A,
int order) ;
100css *cs_sqr (
const cs *A,
int order,
int qr) ;
101cs *cs_symperm (
const cs *A,
const int *Pinv,
int values) ;
102int cs_usolve (
const cs *U,
double *x) ;
103int cs_utsolve (
const cs *U,
double *x) ;
104int cs_updown (
cs *L,
int sigma,
const cs *C,
const int *parent) ;
111int *cs_counts (
const cs *A,
const int *parent,
const int *post,
int ata) ;
112int cs_cumsum (
int *p,
int *c,
int n) ;
113int cs_dfs (
int j,
cs *L,
int top,
int *xi,
int *pstack,
const int *Pinv) ;
114int *cs_etree (
const cs *A,
int ata) ;
115int cs_fkeep (
cs *A,
int (*fkeep) (
int,
int,
double,
void *),
void *other) ;
116double cs_house (
double *x,
double *beta,
int n) ;
117int *cs_maxtrans (
const cs *A) ;
118int *cs_post (
int n,
const int *parent) ;
119int cs_reach (
cs *L,
const cs *B,
int k,
int *xi,
const int *Pinv) ;
121int cs_scatter (
const cs *A,
int j,
double beta,
int *w,
double *x,
int mark,
123int cs_splsolve (
cs *L,
const cs *B,
int k,
int *xi,
double *x,
125int cs_tdfs (
int j,
int k,
int *head,
const int *next,
int *post,
128csd *cs_dalloc (
int m,
int n) ;
129cs *cs_done (
cs *C,
void *w,
void *x,
int ok) ;
130int *cs_idone (
int *p,
cs *C,
void *w,
int ok) ;
131csn *cs_ndone (
csn *N,
cs *C,
void *w,
void *x,
int ok) ;
132csd *cs_ddone (
csd *D,
cs *C,
void *w,
int ok) ;
134#define CS_MAX(a,b) (((a) > (b)) ? (a) : (b))
135#define CS_MIN(a,b) (((a) < (b)) ? (a) : (b))
136#define CS_FLIP(i) (-(i)-2)
137#define CS_UNFLIP(i) (((i) < 0) ? CS_FLIP(i) : (i))
138#define CS_MARKED(Ap,j) ((Ap) [j] < 0)
139#define CS_MARK(Ap,j) { (Ap) [j] = CS_FLIP ((Ap) [j]) ; }
140#define CS_OVERFLOW(n,size) ((n) > INT_MAX / (int) (size))