Graph Coloring
Graph Coloring
Graph coloring is the procedure of assignment of colors to each vertex of a graph G such
that any vertices connected with an edge have different colors.
The objective is to minimize the number of colors while coloring a graph.
The smallest number of colors required to color a graph G is called its chromatic number of
that graph and is denoted by χ ( G ) .
THEOREM: FOUR-COLORING THEOREM
A planar graph has a coloring number less than or equal to 4.
STEPS IN GRAPH COLORING:
The steps required to color a graph G with n number of vertices are as follows −
Step 1 – Prepare different coloring pens.
Step 2 − Choose the first vertex and color it with the first color.
Step 3 − Choose the next vertex and color it with the lowest numbered color that has not been
colored on any vertices adjacent to it. If all the adjacent vertices are colored with this color,
assign a new color to it. Repeat this step until all the vertices are colored.
EXAMPLE 1:
EXAMPLE 2:
EXAMPLE 3:
Observe that the graph in Example 3 is not planar, that is why its chromatic number is
greater than 4.
EXAMPLE 4:
EXAMPLE 5: