Colorability of graph structures #
A structure for Mathlib's language of graphs FirstOrder.Language.graph is a directed graph,
possibly with loops. It is n-colorable (graph.Colorable) when its vertices can be colored with
n colors so that the two ends of every edge have different colors; a loop makes it uncolorable,
and on simple graphs this is SimpleGraph.Colorable. The classes graph.ThreeColorable of
three-colorable finite graph structures (3COL, loops allowed) and graph.SimpleThreeColorable of
three-colorable finite simple graphs (classical 3COL) are closed under isomorphism and invariant
under disjoint copies. Their existential second-order definability is in
Complexity.Logics.SecondOrder.Coloring, and the machine-level problem, on graphs encoded as lists
of vertices and edges, is Cslib.Complexity.ThreeColoring.
Main definitions #
Cslib.Logic.FO.graph.Colorable:n-colorability of a graph structure.Cslib.Logic.FO.graph.ThreeColorable,Cslib.Logic.FO.graph.SimpleThreeColorable: the classes of three-colorable graph structures and of three-colorable simple graphs.
Main results #
Cslib.Logic.FO.graph.isoClosed_ThreeColorable,Cslib.Logic.FO.graph.copyInvariant_ThreeColorableand their simple-graph versions.
References #
A graph structure is n-colorable when its vertices can be colored with n colors so
that the two ends of every edge have different colors.
Instances For
3COL: the class of three-colorable graph structures, loops allowed.
Instances For
Classical 3COL: the class of three-colorable simple graphs.
Instances For
Colorability is invariant under isomorphism.
3COL is closed under isomorphism.
Classical 3COL is closed under isomorphism.
The empty graph is colorable.
A positive number of disjoint copies of a graph is a simple graph exactly when the graph is.
3COL is invariant under copies.
Classical 3COL is invariant under copies.