A topic in the Open Knowledge Graph — a free, open map of 15,290 topics and the order to learn them in.

Graph Coloring and the Chromatic Number

College Depth 77 in the knowledge graph ☐ I know this ☆ Set as goal
28topics build on this
391prerequisites beneath it
See this on the map →
Graph Paths, Cycles, and ConnectivityBipartite Graphs and Matchings+2 more→→Chromatic Number: Bounds and AlgorithmsChromatic Polynomials and Deletion-Contraction+5 more
graph-coloring chromatic-number four-color-theorem brooks-theorem

Core Idea

A proper k-coloring assigns one of k colors to each vertex so that no two adjacent vertices share a color. The chromatic number χ(G) is the minimum k for which a proper coloring exists. Bipartite graphs have χ = 2; complete graphs Kₙ require n colors. The greedy coloring algorithm gives an upper bound of Δ(G)+1, and Brook's theorem tightens this to χ(G) ≤ Δ(G) except for complete graphs and odd cycles. The celebrated four-color theorem states every planar graph satisfies χ ≤ 4.

How It's Best Learned

Color progressively complex graphs by hand — trees, even cycles, odd cycles, wheel graphs — and determine the chromatic number by finding both a valid coloring (upper bound) and an argument why fewer colors fail (lower bound). Scheduling problems (exam timetabling, register allocation) make the applications tangible.

Common Misconceptions

Explainer

Graph coloring asks for the minimum number of colors needed to paint the vertices of a graph so that no two adjacent vertices share a color. That minimum is the chromatic number χ(G). The problem appears in disguise everywhere: scheduling exams so no student has two at once, assigning radio frequencies so nearby towers don't interfere, and allocating registers in a compiler so no two live variables share the same register — all reduce to graph coloring.

To determine χ(G) precisely, you need both an upper bound and a lower bound. The upper bound comes from exhibiting an explicit valid coloring: "here is a k-coloring, so χ(G) ≤ k." The lower bound comes from an argument that fewer colors cannot work: "any (k−1)-coloring fails because…" The most common lower bound argument is finding a clique — a set of mutually adjacent vertices — of size k, since every pair in the clique must receive a different color. However, the clique number ω(G) is only a lower bound. There exist graphs where χ(G) is much larger than ω(G); the Mycielski construction builds triangle-free graphs (ω = 2) that require arbitrarily many colors. Do not assume χ = ω without proof.

Special structures give clean answers. Bipartite graphs — those whose vertices split into two groups with all edges going between groups — have χ = 2: just assign one color to each side. An equivalent characterization: bipartite graphs have no odd cycles. Odd cycles themselves need exactly 3 colors (try 2-coloring a pentagon and you will get stuck at the last vertex). Complete graphs Kₙ need exactly n colors, one per vertex.

Two useful theorems bound χ from above. The greedy algorithm — color each vertex with the smallest color not used by any of its already-colored neighbors — uses at most Δ(G) + 1 colors, where Δ(G) is the maximum degree. Brook's theorem sharpens this: χ(G) ≤ Δ(G) for every graph except complete graphs and odd cycles, which achieve χ = Δ + 1. These theorems guarantee that coloring is rarely as expensive as the worst case suggests.

The four-color theorem — every planar graph satisfies χ ≤ 4 — is one of the most famous results in mathematics. It was conjectured in 1852 and not proved until 1976, when Appel and Haken verified it by reducing the problem to checking roughly 1,500 configurations by computer. It directly implies that any flat map, with countries as vertices and shared borders as edges, can be colored with four colors so no neighboring countries share a color.

Practice Questions 3 questions

Prerequisite Chain

Understanding Zero → The Number Zero → Counting to Five → Counting to 10 → Counting to 20 → Counting a Set of Objects Up to 20 → Cardinality: The Last Number Counted → Matching Numerals to Quantities → Subitizing Small Quantities → Addition Within 10 → Number Bonds to 10 → Addition Within 20 → Doubles and Near Doubles → Doubles Facts Within 10 → Near Doubles Facts Within 20 → Mental Math Strategies for Addition → Mental Math: Adding and Subtracting Tens → Addition Within 100 → Repeated Addition as Multiplication → Multiplication as Equal Groups → Multiplication: Arrays → Basic Multiplication Facts (0s, 1s, 2s, 5s, 10s) → Multiplication Facts Within 100 → Division as Equal Sharing → Division as Grouping (Measurement Division) → Division: Grouping (Repeated Subtraction) Model → Division: Fair Sharing Model → Division as Equal Sharing → Division as Grouping → Basic Division Facts → Division Facts Within 100 → Multiplication and Division Fact Families → Relationship Between Multiplication and Division → Division Facts as Inverse of Multiplication → Remainders and Quotients in Division → Division Word Problems → Multi-Step Word Problems → Solving Multi-Step Word Problems → Multiplication Word Problems → Division Word Problems → Introduction to Long Division → Factors and Multiples → Prime and Composite Numbers → Equivalent Fractions → Relating Fractions and Decimals → Decimal Place Value → Integers and the Number Line → Comparing and Ordering Integers → Absolute Value → Adding Integers → Subtracting Integers → Multiplying Integers → Introduction to Exponents → Order of Operations → Integer Order of Operations → Variable Expressions → The Distributive Property → Variables and Expressions Review → Introduction to Polynomials → Adding and Subtracting Polynomials → Multiplying Polynomials → Factorial → Permutations → Combinations → Counting Principles: Addition and Multiplication Rules → Introduction to Graph Theory → Propositional Logic Foundations → Logical Equivalences → Set Operations: Union, Intersection, and Complement → Proof by Cases → Proving by Cases and Exhaustion → Vacuous Truth and Trivial Cases → Proof by Cases (Proof by Exhaustion) → Mathematical Induction → Graph Paths, Cycles, and Connectivity → Trees and Spanning Trees → Planar Graphs and Euler's Formula → Graph Coloring and the Chromatic Number

Longest path: 78 steps · 391 total prerequisite topics

Prerequisites (4)

Leads To (7)