PetscErrorCode MatGetColoring(Mat mat,MatColoringType type,ISColoring *iscoloring)Collective on Mat
MATCOLORINGNATURAL - natural (one color for each column, very slow)
MATCOLORINGSL - smallest-last
MATCOLORINGLF - largest-first
MATCOLORINGID - incidence-degree
-mat_coloring_type natural, -mat_coloring_type sl, -mat_coloring_type lf,
-mat_coloring_type idTo see the coloring use
-mat_coloring_view
A graph coloring C(A) is a division of vertices so that two vertices of the same color do not share any common edges.
A suitable coloring for a smoother is simply C(A).
A suitable coloring for efficient Jacobian computation is a division of the columns so that two columns of the same color do not share any common rows.
This corresponds to C(A^{T} A). This is what MatGetColoring() computes.
The user can define additional colorings; see MatColoringRegister().
For parallel matrices currently converts to sequential matrix and uses the sequential coloring on that.
The colorings SL, LF, and ID are obtained via the Minpack software that was converted to C using f2c.
For BAIJ matrices this colors the blocks. The true number of colors would be block size times the number of colors returned here.
Thomas F. Coleman and Jorge J. More, Estimation of Sparse {J}acobian Matrices and Graph Coloring Problems,
SIAM Journal on Numerical Analysis, 1983, pages 187-209, volume 20
Jorge J. Mor\'{e} and Danny C. Sorenson and Burton S. Garbow and Kenneth E. Hillstrom, The {MINPACK} Project,
Sources and Development of Mathematical Software, Wayne R. Cowell editor, 1984, pages 88-111
Level:intermediate
Location:src/mat/color/color.c
Index of all MatOrderings routines
Table of Contents for all manual pages
Index of all manual pages