GATE / CS ARCHIVE

GATE CSE 2002 / QUESTION 1.4

Chromatic number of a cycle

Discrete Mathematics · Graph Theory · Full GATE CSE 2002 paper

GATE 2002, Q1.4 1 mark · MCQ
Report issue

Graph Theory

Question 1.4, GATE 2002: What is the fewest colors needed for the vertices of an n-node cycle if adjacent vertices must receive different colors?
(A) 2; (B) 3; (C) 4; (D) n − 2⌊n/2⌋ + 2.
Tap to enlarge
Your answer
Answer & solution

Answer: D (no official key was published)

Step 1: Separate even and odd cycle lengths.

Step 2: Label successive vertices alternately red and blue. When n is even the last vertex is blue and the first red, so the closing edge is legal. When n is odd both would be red; recolor the last vertex with a third color. The expression n−2floor(n/2) is exactly zero or one, so the option captures both cases rather than claiming one constant color count.

Conclusion: An even cycle alternates two colors. An odd cycle cannot alternate consistently around the closing edge and needs a third color, which suffices. Thus χ=2+(n mod2)=n−2floor(n/2)+2, D, for an ordinary cycle n≥3.

Original paper, page 1