Graph Coloring 1
Lecture Notes: Chromatic Number and
Chromatic Index
Graph Theory and Applications
Zamir Hussain, Lecturer Mathematics, UW
Date: May 17, 2025
Introduction
Graph coloring is a fundamental concept in graph theory with numerous applications
in various fields. At its core, graph coloring deals with assigning “colors” to elements
of a graph (vertices or edges) subject to certain constraints. The two primary types are:
• Vertex coloring: Assign colors to vertices such that no adjacent vertices share the
same color
• Edge coloring: Assign colors to edges such that no adjacent edges share the same
color
These lead to two key invariants:
• Chromatic number 𝜒(𝐺): Minimum colors for vertex coloring
• Chromatic index 𝜒 ′(𝐺): Minimum colors for edge coloring
Vertex Coloring and Chromatic Number
Basic Definitions
A proper vertex coloring of 𝐺 = (𝑉 , 𝐸) is a function 𝑐 : 𝑉 → {1, 2, . . . , 𝑘} where
𝑐(𝑢) ≠ 𝑐(𝑣) for every edge (𝑢, 𝑣) ∈ 𝐸.
The chromatic number 𝜒(𝐺) is the minimum 𝑘 for which 𝐺 has a proper 𝑘-coloring. If
𝜒(𝐺) = 𝑘, 𝐺 is 𝑘-colorable.
Graph Coloring 2
Bounds for Chromatic Number
Clique Number 𝜔(𝐺)
A clique is a subset of mutually adjacent vertices. The clique number 𝜔(𝐺) is the size
of the largest clique in 𝐺.
For any graph 𝐺, 𝜒(𝐺) ≥ 𝜔(𝐺).
In a clique of size 𝜔(𝐺), all vertices are mutually adjacent, requiring 𝜔(𝐺) distinct
colors.
Maximum Degree Δ(𝐺)
The maximum degree Δ(𝐺) is the maximum number of edges incident to any vertex.
[Brooks’ Theorem] If 𝐺 is connected and neither complete nor an odd cycle, then
𝜒(𝐺) ≤ Δ(𝐺). For 𝐾 𝑛 : 𝜒(𝐾 𝑛 ) = 𝑛, for 𝐶2𝑘+1 : 𝜒 = 3.
Examples
[Complete Graphs 𝐾 𝑛 ] 𝜒(𝐾 𝑛 ) = 𝑛 since all vertices are pairwise adjacent.
𝐾3 , 𝜒 = 3 𝐾4 , 𝜒 = 4
[Cube Graph] The 3D cube graph is bipartite with 𝜒 = 2:
3D Cube, 𝜒 = 2
Applications
Scheduling Problems
• Vertices: Tasks or events
• Edges: Conflicts between tasks
• Colors: Time slots or resources
Graph Coloring 3
• 𝜒(𝐺): Minimum time slots/resources needed
𝜒(𝐺) = min |{𝑐(𝑣) : 𝑣 ∈ 𝑉}|
colorings
Register Allocation
• Vertices: Variables in a program
• Edges: Variables live simultaneously
• Colors: CPU registers
• 𝜒(𝐺): Minimum registers required
Map Coloring
• Vertices: Geographical regions
• Edges: Adjacent regions
• Colors: Distinct region colors
D
C
B
A
Four Color Theorem: 𝜒(𝐺) ≤ 4 for planar graphs
Artificial Intelligence
• Constraint Satisfaction Problems (CSPs): Framework for solving AI problems
• Graph coloring as a prototype CSP
• Chromatic polynomial 𝑃(𝐺, 𝑘) counts proper 𝑘-colorings
𝑃(𝐾 𝑛 , 𝑘) = 𝑘(𝑘 − 1)(𝑘 − 2) · · · (𝑘 − 𝑛 + 1)
Chromatic Index (Edge Coloring)
The chromatic index 𝜒 ′(𝐺) is the minimum colors needed for a proper edge coloring
where adjacent edges have different colors.
Graph Coloring 4
[Vizing’s Theorem] For any simple graph 𝐺, Δ(𝐺) ≤ 𝜒 ′(𝐺) ≤ Δ(𝐺) + 1
𝐾 3 has 𝜒 ′ = 3:
𝜒′(𝐾 3 ) = 3
Conclusion
Key takeaways:
• Chromatic number 𝜒(𝐺): Vertex coloring invariant
• Chromatic index 𝜒 ′(𝐺): Edge coloring invariant
• Bounds: 𝜔(𝐺) ≤ 𝜒(𝐺) ≤ Δ(𝐺) + 1, Δ(𝐺) ≤ 𝜒′(𝐺) ≤ Δ(𝐺) + 1
• Applications in scheduling, compilers, cartography, and AI
Practice Problems
1. Find 𝜒 and 𝜒 ′ for 𝐾 3,3
2. Prove that 𝜒(𝐺) ≤ Δ(𝐺) for bipartite graphs
3. Design a class schedule using graph coloring (vertices = classes, edges = time
conflicts)
4. Implement the greedy coloring algorithm in Python
References
[1] Bondy, J. A., & Murty, U. S. R. (2008). Graph theory with applications. Elsevier.
[2] Diestel, R. (2017). Graph theory (5th ed.). Springer.
[3] West, D. B. (2001). Introduction to graph theory (2nd ed.). Prentice Hall.