Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
-
Economics & Finance
Finding the chromatic number of complete graph
The chromatic number of a graph is the minimum number of colors needed to color its vertices such that no two adjacent vertices share the same color. For a complete graph Kn, every vertex is connected to every other vertex, which makes it a special and straightforward case for graph coloring.
Problem Statement
What is the chromatic number of the complete graph Kn?
Solution
The following diagram shows a properly colored complete graph K4, where each of the 4 vertices requires a different color −
In a complete graph Kn, each vertex is adjacent to all remaining (n − 1) vertices. Since every pair of vertices is connected by an edge, no two vertices can share the same color. Hence, each vertex requires its own unique color.
Therefore, the chromatic number of Kn is −
χ(Kn) = n
Examples for Small Complete Graphs
The following SVG shows the coloring for K1 through K4 −
The chromatic numbers for small complete graphs −
| Graph | Vertices | Edges | Chromatic Number |
|---|---|---|---|
| K1 | 1 | 0 | 1 |
| K2 | 2 | 1 | 2 |
| K3 | 3 | 3 | 3 |
| K4 | 4 | 6 | 4 |
| K5 | 5 | 10 | 5 |
In every case, the chromatic number equals the number of vertices, confirming that χ(Kn) = n.
Why Fewer Colors Won't Work
Suppose we try to color Kn with fewer than n colors. Since every vertex is adjacent to every other vertex, if any two vertices share the same color, they would violate the coloring rule (adjacent vertices must have different colors). Therefore, it is impossible to use fewer than n colors, and n colors are always sufficient.
Conclusion
The chromatic number of a complete graph Kn is always equal to n, because every vertex is adjacent to every other vertex and no two vertices can share a color.
