IAE Academy

GATE 2024 CS2 Q.60: solution and answer

GATE 2024 · CS2Q.60 · 2 marks · NAT

The chromatic number of a graph is the minimum number of colours used in a proper colouring of the graph. The chromatic number of the following graph is ______.

GATE 2024 CS2 question 60: A graph on 8 vertices drawn at the corners of an octagon, labelled in order around the outline: v0 top-left, v1…Tap to open full size
Figure from the GATE 2024 CS2 paper. It is part of the question.
Figure description

A graph on 8 vertices drawn at the corners of an octagon, labelled in order around the outline: v0 top-left, v1 top-right, v2 right-upper, v3 right-lower, v4 bottom-right, v5 bottom-left, v6 left-lower, v7 left-upper. Edges: the slanted and side outline edges v1-v2, v2-v3, v3-v4, v5-v6, v6-v7, v7-v0; the two verticals v0-v5 and v1-v4; the two horizontals v7-v2 and v6-v3; and the four diagonals v0-v3, v1-v6, v7-v4, v2-v5. The short edges between the two top vertices (v0-v1) and between the two bottom vertices (v4-v5) do not clearly appear in the picture; the answer is the same whether or not they are present.

Answer and solution

ANSWER

The chromatic number of the graph is 2.

Official answer: 2Source: Official answer key, GATE 2024 CS2 (IISc Bengaluru)

  1. Label the vertices around the octagon as in the figure. The edges seen are the outline edges (indices mod 8), and the chords , , , , , , , . The short top and bottom edges and are hard to make out, but the argument below holds whether or not they are present.

  2. Check the index difference of every edge. The outline edges differ by (or ), and the chords differ by (or ): , , , give , and , , , give . So every edge joins two vertices whose indices differ by an odd number.

  3. Hence every edge joins an even-indexed vertex to an odd-indexed vertex. With and , no edge lies inside and none lies inside . So the graph is bipartite (it is a subgraph of , and equals when all 16 edges are present).

  4. The graph has at least one edge, so one colour is not enough and .

  5. Give every vertex of colour 1 and every vertex of colour 2. No edge joins two vertices of the same set, so this is a proper colouring with 2 colours, and .

  6. Therefore .

KEY IDEA

A graph is 2-colourable exactly when it has no odd cycle, that is, when it is bipartite. Here the vertices split into even-indexed and odd-indexed ones, and every edge goes between the two groups.

WATCH OUT FOR

Seeing the many crossing lines and assuming a dense graph needs 3 or 4 colours. Density does not matter. The check is whether the vertices split into two groups with no edge inside a group.

From the GATE 2024 CS2 paper. Every question of this paper · Download the full paper · All 14 Graph theory questions, with notes

More Graph theory questions