Chromatic Polynomial Calculator

Calculate P(G,k) - the number of proper k-colorings of a graph.

Graph Parameters

Chromatic Polynomial

P(K_4, k) = k(k-1)(k-2)(k-3)

Falling factorial: each vertex needs a different color from all previous.

P(G,k) Values

k=1

0

k=2

0

k=3

0

k=4

24

k=5

120

k=6

360

k=7

840

Number of 5-colorings

P(G,5) = 120

Chromatic Number
chi = 4
Vertices
4

Properties

Smallest k with P(G,k) > 04
Polynomial degree4

About Chromatic Polynomial

  • P(G,k) counts proper k-colorings of graph G
  • Chromatic number is smallest k where P(G,k) > 0
  • The polynomial has degree n (number of vertices)
  • Leading coefficient is always 1
  • Deletion-contraction: P(G,k) = P(G-e,k) - P(G/e,k)