CGT CT2 2023 Answer
CGT CT2 2023 Answer
1. In an undirected connected planar graph G, there are eight vertices and five faces. The
number of edges in G is ______ [1]
a. 8 c. 11
b. b. 10 d. 13
Answer: c. 11
In a connected planar graph f = e - n + 2. Here, n = 8, f= 5, ∴ 5 = e - 8 + 2 => e = 11
3. Let G be the non-planar graph with minimum possible number of edges. Then G has
a. 9 edges and 5 vertices
b. 9 edges and 6 vertices
c. 10 edges and 5 vertices
d. 10 edges and 6 vertices [1]
K5 and K3,3 are the smallest non planar graphs. K5 has 5 vertices and 10 edges and K3,3 has
6 vertices and 3 × 3 = 9 edges. So, the non-planar graph with minimum number of edges
K3,3 with 9 edges and 6 vertices.
Answer: d. Euler.
After the transformation, all vertices in the graph are of even degree and graph is
connected, so it is an Euler graph.
Answer: c. n-k
The number of edges in a forest G with n vertices and k components = Rank of G = n - k.
Alternatively, each component will have n/k vertices (pigeonhole principle). Hence,
for each component there will be (n/k)-1 edges. Since there are k components, total
number of edges= k*((n/k)-1) = n-k.
6. Let G be a simple, finite, undirected graph with vertex set {v1, v2, …, vn}.
Let Δ(G) denote the maximum degree of G and let C={1,2,…} denote the set of all
possible colors. Color the vertices of G using the following greedy strategy:
for i=1,…,n color(vi)←min{i∈C : no neighbour of vi is colored j}
Which of the following statements is/are TRUE? [2]
Answer: a & b
Explanations:
a. The greedy coloring strategy ensures that each vertex is assigned the smallest possible
color that is not already used by its neighbors. Therefore, this procedure does result in a
proper vertex coloring of G.
b. Since the graph G is finite and simple, the maximum degree Δ(G) represents the highest
number of neighbors any vertex can have. In the worst-case scenario, when all neighbors of
NATIONAL INSTITUTE OF TECHNOLOGY, TIRUCHIRAPPALLI
Department Of Computer Science And Engineering
a vertex have distinct colors, the vertex itself will need one additional color not used by its
neighbors. Therefore, the number of colors used by this procedure is at most Δ(G) + 1.
7. An articulation point in a connected graph is a vertex such that removing the vertex and
its incident edges disconnects the graph into two or more connected components. Let T
be a DFS tree obtained by doing DFS in a connected undirected graph G. Which of the
following option is/are correct? [2]
Explanation:
We check all the options one by one:
(a): If u is an articulation point in G such that x is an ancestor of u in T and y is a descendant of
u in T, then all paths from x to y in G must pass through u.This option is FALSE.
Let us take an example of a graph G:
For this graph G, we can verify that in T (obtained by doing DFS): u is an articulation point in
G, x is an ancestor of u and y is a descendent of u. All the conditions are satisfied, yet we have
a path from x to y in G (x->w->v->y) that does not pass through u.
(b): Root of T is an articulation point in G if and only if it has 2 or more children. This option is
TRUE.
NATIONAL INSTITUTE OF TECHNOLOGY, TIRUCHIRAPPALLI
Department Of Computer Science And Engineering
The root of T has 1 child, and as such removing its corresponding vertex in G does not
disconnect the graph into two (or more) components. Thus the root can not be an articulation
point in this scenario. Therefore having at least 2 children is a compulsory condition for the root
of T to be an articulation point.
We can clearly see that removing the vertex corresponding to the root of T, will disconnect the
graph into two components. Thus the root of T can be an articulation point in G.
(d): A leaf of T can be an articulation point in G. This option is FALSE.
From the tree T below:
NATIONAL INSTITUTE OF TECHNOLOGY, TIRUCHIRAPPALLI
Department Of Computer Science And Engineering
We can understand that any leaf of T is connected to only one node, i.e. its parent. Thus
removing the vertex corresponding to T in the graph will not disconnect the graph into two or
more components. So, a leaf of T can never be an articulation point in G.
8. Graph G is obtained by adding vertex s to K3,4 and making s adjacent to every vertex of
K3,4. The minimum number of colours required to edge-colour G is _____. [2]
a. 5 c. 7
b. 6 d. 8
Answer: c. 7
Edge Coloring of a graph: the least number of colors needed to color the edges of so that
any two edges that share a vertex have different colors.
9. Consider an bidirectional graph G where self-loops are not allowed. The vertex set
of G is {(i,j):1≤i≤12,1≤j≤12}.
There is an edge between (a,b) and (c,d) if |a-c|≤1 and |b-d|≤1. The number of edges in
this graph is _____. [2]
a. 605 b. 506 c. 144 d. 132
Answer: b. 506
The given condition translates into the graph shown here where every vertex is connected
only with its neighbours. From this diagram:
(i) The four corner vertices each have 3 degrees
which gives 4 × 3 = 12 degrees.
(ii) The 40 side vertices have 5 degrees each
contributing a total of 40 × 5 = 200 degrees.
(iii) The 100 interior vertices each have 8
degrees contributing a total of 100 × 8 = 800
degrees.
So total degree of the graph = 12 + 200 + 800 =
1012 degrees
Now the number of edges in any undirected graph = Total degrees/2 = 1012/2 = 506.
10. Let G1=(V,E1) and G2=(V,E2) be connected graphs on the same vertex set V with more
than two vertices. If G1∩G2=(V,E1∩E2) is not a connected graph, then the
graph G1∪G2=(V, E1∪E2) [2]
a. cannot have a cut vertex
b. must have a cycle
c. must have a cut-edge (bridge)
d. has chromatic number strictly greater than those of G1 and G2
We are given that G1=(V,E1) and G2=(V,E2) are connected. So, if we take any two vertices,
there must be a path between them in both G1=(V,E1) and G2=(V,E2). Now, it is given that
G1∩G2=(V,E1∩E2) is disconnected. That is, we have at least two vertices 𝑣𝑖 and 𝑣𝑗 such that
there is no path between them in G1∩G2. This means the paths between them in G1 and in
NATIONAL INSTITUTE OF TECHNOLOGY, TIRUCHIRAPPALLI
Department Of Computer Science And Engineering
G2 are distinct. So, in G1∪G2, we have two distinct paths between a pair of vertices, so, it
forms a cycle.
11. The degree sequence of a simple graph is the sequence of the degrees of the nodes in the
graph in decreasing order. Which of the following sequences cannot be the degree
sequence of any graph? [3]
a. 7,6,5,4,4,3,2,1 c. 6,6,6,6,3,3,2,2
b. 7,6,6,4,4,3,2,2 d. 8, 7, 7, 6, 4, 2, 1, 1
Answer: c and d
Explanation:
Apply Havel–Hakimi Algorithm to given sequences:
a) 7,6,5,4,4,3,2,1 → 5,4,3,3,2,1,0 → 3,2,2,1,0,0 → 1,1,0,0,0 → 0,0,0,0. So it is graphical.
b) 7,6,6,4,4,3,2,2 → 5,5,3,3,2,1,1 → 4,2,2,1,0,1 (arrange in descending order) → 4,2,2,1,1,0
→ 1,1,0,0,0 → 0,0,0,0. So it is graphical.
c) 6, 6, 6, 6, 3, 3, 2, 2 → 5, 5, 5, 2, 2, 1, 2 (arrange in descending order) → 5, 5, 5, 2, 2, 2, 1 →
4, 4, 1, 1, 1, 1 → 3, 0, 0, 0, 1 (arrange in descending order) → 3, 1, 0, 0, 0 → 0, -1, -1, 0
(arrange in descending order) → 0, 0, -1, -1
Degree of a vertex can not be negative, so the sequence is not graphical.
d) 8,7,7,6,4,2,1,1 , here the degree of a vertex is 8 and total number of vertices are 8 , so it’s
impossible, hence it’s not graphical.
NATIONAL INSTITUTE OF TECHNOLOGY, TIRUCHIRAPPALLI
Department Of Computer Science And Engineering
12. Let G be a connected undirected weighted graph. Consider the following two statements.
S1: There exists a minimum weight edge in G which is present in every minimum
spanning tree of G.
S2: If every edge in G has distinct weight, then G has a unique minimum spanning tree.
Which one of the following options is correct? [2]
a. S1 is false and S2 is true.
b. S1: is true and S2 is false.
c. Both S1: and S2 are true.
d. Both S1: and S2 are false.
Explanation:
We can think of running Kruskal's algorithm for finding the Minimum Spanning Tree on a
graph. While doing that, we sort the edges based on their weight and start selecting edges
from the smallest weight).
Problem with S1: If we have multiple edges with the same minimum weight, then a specific
weighted edge is not guaranteed to be selected for MST.
S2 is Correct: If the sorted order of the edges contains only distinct values, Kruskal's
algorithm will always select a unique set of edges resulting in a unique minimum spanning
tree.