k
-coloring of undirected graphs.
A k
-coloring of a graph g
is a mapping c
from nodes to {1,...,k}
such that c(u) <> c(v)
for any edge u-v
in g
.
Provide a function for k
-coloring a graph.
Provide a function for k
-coloring a graph with integer marks.
The provided function is more efficient that the one provided by functor
Make above.
coloring g k
colors the nodes of graph g
using k colors,
assigning the marks integer values between 1 and k.
raises NoColoring
when there is no possible coloring.
The graph marks may be partially set before starting; the meaning of initial values is as follows:
NoColoring
if g
cannot be k
-colored.