-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathold_colamd.h
86 lines (65 loc) · 2.87 KB
/
old_colamd.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
/*! \file
Copyright (c) 2003, The Regents of the University of California, through
Lawrence Berkeley National Laboratory (subject to receipt of any required
approvals from U.S. Dept. of Energy)
All rights reserved.
The source code is distributed under BSD license, see the file License.txt
at the top-level directory.
*/
/*! @file
* \brief colamd include file
*/
/* ========================================================================== */
/* === colamd prototypes and definitions ==================================== */
/* ========================================================================== */
/*
This is the colamd include file,
http://www.cise.ufl.edu/~davis/colamd/colamd.h
for use in the colamd.c, colamdmex.c, and symamdmex.c files located at
http://www.cise.ufl.edu/~davis/colamd/
See those files for a description of colamd and symamd, and for the
copyright notice, which also applies to this file.
August 3, 1998. Version 1.0.
*/
/* ========================================================================== */
/* === Definitions ========================================================== */
/* ========================================================================== */
/* size of the knobs [ ] array. Only knobs [0..1] are currently used. */
#define COLAMD_KNOBS 20
/* number of output statistics. Only A [0..2] are currently used. */
#define COLAMD_STATS 20
/* knobs [0] and A [0]: dense row knob and output statistic. */
#define COLAMD_DENSE_ROW 0
/* knobs [1] and A [1]: dense column knob and output statistic. */
#define COLAMD_DENSE_COL 1
/* A [2]: memory defragmentation count output statistic */
#define COLAMD_DEFRAG_COUNT 2
/* A [3]: whether or not the input columns were jumbled or had duplicates */
#define COLAMD_JUMBLED_COLS 3
/* ========================================================================== */
/* === Prototypes of user-callable routines ================================= */
/* ========================================================================== */
#ifdef _CRAY
#define int short
#elif defined (_LONGINT)
#define int long
#endif
int colamd_recommended /* returns recommended value of Alen */
(
int nnz, /* nonzeros in A */
int n_row, /* number of rows in A */
int n_col /* number of columns in A */
) ;
void colamd_set_defaults /* sets default parameters */
( /* knobs argument is modified on output */
double knobs [COLAMD_KNOBS] /* parameter settings for colamd */
) ;
int colamd /* returns TRUE if successful, FALSE otherwise*/
( /* A and p arguments are modified on output */
int n_row, /* number of rows in A */
int n_col, /* number of columns in A */
int Alen, /* size of the array A */
int A [], /* row indices of A, of size Alen */
int p [], /* column pointers of A, of size n_col+1 */
double knobs [COLAMD_KNOBS] /* parameter settings for colamd */
) ;