Message Boards Message Boards

How do I color a DIMACS graph ?

Here is my code.

g = Import["", 


O/p is

MinimumVertexColoring[ "The whole graph is displayed here"]

Please let me know. I have just started using Mathematica

POSTED BY: Rushang Karia

MinimumVertexColoring is a Combinatorica function available in the Combinatorica package. To use it, you will need to

  1. Load the combinatorica package (<<Combinatorica`)
  2. Convert your graph into a combinatorica graph. (

The default kind of Graph in Mathematica is a different object than the combinatorica graph. So the function won't know what to do with the graph unless it's a combinatorica graph.

POSTED BY: Sean Clarke
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
or Discard

Group Abstract Group Abstract