Concrete colorings of common graphs #
This file defines colorings for some common graphs.
Main declarations #
SimpleGraph.pathGraph.bicoloring: Bicoloring of a path graph.
Bicoloring of a path graph
Equations
- SimpleGraph.pathGraph.bicoloring n = SimpleGraph.Coloring.mk (fun (u : Fin n) => decide (↑u % 2 = 0)) ⋯
Instances For
theorem SimpleGraph.Walk.three_le_chromaticNumber_of_odd_loop {α : Type u_1} {G : SimpleGraph α} {u : α} (p : G.Walk u u) (hOdd : Odd p.length) :
Bicoloring of a cycle graph of even size
Equations
- SimpleGraph.cycleGraph.bicoloring_of_even n h = SimpleGraph.Coloring.mk (fun (u : Fin n) => decide (↑u % 2 = 0)) ⋯
Instances For
Tricoloring of a cycle graph
Equations
Instances For
def SimpleGraph.Coloring.completeEquipartiteGraph {r t : ℕ} :
(SimpleGraph.completeEquipartiteGraph r t).Coloring (Fin r)
The injection (x₁, x₂) ↦ x₁ is always an r-coloring of a completeEquipartiteGraph r ·.
Equations
- SimpleGraph.Coloring.completeEquipartiteGraph = { toFun := Prod.fst, map_rel' := ⋯ }
Instances For
theorem SimpleGraph.completeEquipartiteGraph_colorable {r t : ℕ} :
(completeEquipartiteGraph r t).Colorable r
The completeEquipartiteGraph r t is always r-colorable.
Taking the remainder upon dividing by r produces an r-coloring of turanGraph n r for
nonzero r.
Equations
Instances For
@[simp]