|
kusano |
7d535a |
|
|
kusano |
7d535a |
<meta content="text/html;charset=UTF-8" http-equiv="Content-Type">
|
|
kusano |
7d535a |
<title>SuperLU: SRC/colamd.h File Reference</title>
|
|
kusano |
7d535a |
<link href="doxygen.css" rel="stylesheet" type="text/css">
|
|
kusano |
7d535a |
<link href="tabs.css" rel="stylesheet" type="text/css">
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Main Page
|
|
kusano |
7d535a |
Data Structures
|
|
kusano |
7d535a |
Files
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
SRC/colamd.h File ReferenceColamd prototypes and definitions. More...
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#include <stdlib.h>
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Go to the source code of this file.
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Data Structures
|
|
kusano |
7d535a |
struct Colamd_Col_struct
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
struct Colamd_Row_struct
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Defines
|
|
kusano |
7d535a |
#define COLAMD_KNOBS 20
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_STATS 20
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_DENSE_ROW 0
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_DENSE_COL 1
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_DEFRAG_COUNT 2
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_STATUS 3
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_INFO1 4
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_INFO2 5
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_INFO3 6
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_OK (0)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_OK_BUT_JUMBLED (1)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_A_not_present (-1)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_p_not_present (-2)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_nrow_negative (-3)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_ncol_negative (-4)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_nnz_negative (-5)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_p0_nonzero (-6)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_A_too_small (-7)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_col_length_negative (-8)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_row_index_out_of_bounds (-9)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_out_of_memory (-10)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_internal_error (-999)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_C(n_col) ((int) (((n_col) + 1) * sizeof (Colamd_Col) / sizeof (int)))
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_R(n_row) ((int) (((n_row) + 1) * sizeof (Colamd_Row) / sizeof (int)))
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_RECOMMENDED(nnz, n_row, n_col)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Typedefs
|
|
kusano |
7d535a |
typedef struct Colamd_Col_struct Colamd_Col
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
typedef struct Colamd_Row_struct Colamd_Row
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Functions
|
|
kusano |
7d535a |
int colamd_recommended (int nnz, int n_row, int n_col)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
void colamd_set_defaults (double knobs[COLAMD_KNOBS])
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
int colamd (int n_row, int n_col, int Alen, int A[], int p[], double knobs[COLAMD_KNOBS], int stats[COLAMD_STATS])
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
int symamd (int n, int A[], int p[], int perm[], double knobs[COLAMD_KNOBS], int stats[COLAMD_STATS], void *(*allocate)(size_t, size_t), void(*release)(void *))
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
void colamd_report (int stats[COLAMD_STATS])
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
void symamd_report (int stats[COLAMD_STATS])
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Detailed Description
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
==========================================================================
|
|
kusano |
7d535a |
=== colamd/symamd prototypes and definitions =============================
|
|
kusano |
7d535a |
==========================================================================
|
|
kusano |
7d535a |
You must include this file (colamd.h) in any routine that uses colamd,
|
|
kusano |
7d535a |
symamd, or the related macros and definitions.
|
|
kusano |
7d535a |
Authors:
|
|
kusano |
7d535a |
The authors of the code itself are Stefan I. Larimore and Timothy A.
|
|
kusano |
7d535a |
Davis (davis@cise.ufl.edu), University of Florida. The algorithm was
|
|
kusano |
7d535a |
developed in collaboration with John Gilbert, Xerox PARC, and Esmond
|
|
kusano |
7d535a |
Ng, Oak Ridge National Laboratory.
|
|
kusano |
7d535a |
Date:
|
|
kusano |
7d535a |
September 8, 2003. Version 2.3.
|
|
kusano |
7d535a |
Acknowledgements:
|
|
kusano |
7d535a |
This work was supported by the National Science Foundation, under
|
|
kusano |
7d535a |
grants DMS-9504974 and DMS-9803599.
|
|
kusano |
7d535a |
Notice:
|
|
kusano |
7d535a |
Copyright (c) 1998-2003 by the University of Florida.
|
|
kusano |
7d535a |
All Rights Reserved.
|
|
kusano |
7d535a |
THIS MATERIAL IS PROVIDED AS IS, WITH ABSOLUTELY NO WARRANTY
|
|
kusano |
7d535a |
EXPRESSED OR IMPLIED. ANY USE IS AT YOUR OWN RISK.
|
|
kusano |
7d535a |
Permission is hereby granted to use, copy, modify, and/or distribute
|
|
kusano |
7d535a |
this program, provided that the Copyright, this License, and the
|
|
kusano |
7d535a |
Availability of the original version is retained on all copies and made
|
|
kusano |
7d535a |
accessible to the end-user of any code or package that includes COLAMD
|
|
kusano |
7d535a |
or any modified version of COLAMD.
|
|
kusano |
7d535a |
Availability:
|
|
kusano |
7d535a |
The colamd/symamd library is available at
|
|
kusano |
7d535a |
http://www.cise.ufl.edu/research/sparse/colamd/
|
|
kusano |
7d535a |
This is the http://www.cise.ufl.edu/research/sparse/colamd/colamd.h
|
|
kusano |
7d535a |
file. It is required by the colamd.c, colamdmex.c, and symamdmex.c
|
|
kusano |
7d535a |
files, and by any C code that calls the routines whose prototypes are
|
|
kusano |
7d535a |
listed below, or that uses the colamd/symamd definitions listed below.
|
|
kusano |
7d535a |
Define Documentation
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_C
|
|
kusano |
7d535a |
(
|
|
kusano |
7d535a |
n_col
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
)
|
|
kusano |
7d535a |
((int) (((n_col) + 1) * sizeof (Colamd_Col) / sizeof (int)))
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_DEFRAG_COUNT 2
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_DENSE_COL 1
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_DENSE_ROW 0
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_A_not_present (-1)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_A_too_small (-7)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_col_length_negative (-8)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_internal_error (-999)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_ncol_negative (-4)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_nnz_negative (-5)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_nrow_negative (-3)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_out_of_memory (-10)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_p0_nonzero (-6)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_p_not_present (-2)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_ERROR_row_index_out_of_bounds (-9)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_INFO1 4
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_INFO2 5
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_INFO3 6
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_KNOBS 20
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_OK (0)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_OK_BUT_JUMBLED (1)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_R
|
|
kusano |
7d535a |
(
|
|
kusano |
7d535a |
n_row
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
)
|
|
kusano |
7d535a |
((int) (((n_row) + 1) * sizeof (Colamd_Row) / sizeof (int)))
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
#define COLAMD_RECOMMENDED
|
|
kusano |
7d535a |
(
|
|
kusano |
7d535a |
nnz,
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
n_row,
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
n_col
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Value:
|
|
kusano |
7d535a |
((nnz) < 0 || (n_row) < 0 || (n_col) < 0) \
|
|
kusano |
7d535a |
? \
|
|
kusano |
7d535a |
(-1) \
|
|
kusano |
7d535a |
: \
|
|
kusano |
7d535a |
(2 * (nnz) + COLAMD_C (n_col) + COLAMD_R (n_row) + (n_col) + ((nnz) / 5)) \
|
|
kusano |
7d535a |
)
|