chapter
    Graph Coloring, Covers, Matrices and Special Graphs PYQs for GATE CS

    Solve 8+ Graph Coloring, Covers, Matrices and Special Graphs previous year questions for GATE CS with answers and detailed solutions. Free sample questions be

    Try a question

    Answer it here to see how it works. Nothing is recorded until you sign in.

    Question 1
    2026 Slot Set1 PYQ
    Level 3: Exam Standard
    Let be a simple, undirected graph. A vertex cover of is a subset such that for every , or . Let the size of the smallest vertex cover in be . Let be any vertex cover of size .

    For a vertex , which of the following constraints will always ensure that ?
    Question 2
    2026 Slot Set1 PYQ
    Level 3: Exam Standard
    An undirected, unweighted, simple graph is said to be 2-colorable if there exists a function such that for every , .

    Which of the following statements about 2-colorable graphs is/are true?
    Question 3
    2024 Slot Set2 PYQ
    Level 3: Exam Standard

    Let be the adjacency matrix of a simple undirected graph . Suppose is its own inverse. Which one of the following statements is always TRUE?

    Question 4
    2024 Slot Set2 PYQ
    Level 3: Exam Standard
    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 __________

    Question 5
    2024 Slot Set1 PYQ
    Level 3: Exam Standard

    The chromatic number of a graph is the minimum number of colours used in a <i>proper</i> colouring of the graph. Let be any graph with vertices and chromatic number . Which of the following statements is/are always TRUE?

    Question 6
    2022 PYQ
    Level 3: Exam Standard

    Which of the properties hold for the adjacency matrix of a simple undirected unweighted graph having vertices?

    Question 7
    2022 PYQ
    Level 3: Exam Standard

    Consider a simple undirected unweighted graph with at least three vertices. If is the adjacency matrix of the graph, then the number of 3-cycles in the graph is given by the trace of

    Question 8
    2022 PYQ
    Level 3: Exam Standard
    The following simple undirected graph is referred to as the Peterson graph.



    Which of the following statements is/are TRUE?
    Free preview ends here

    Login to view the complete previous-year questions and solutions

    Creating an account is free. You get the rest of this chapter, step-by-step solutions, and a study plan built around the topics you are actually weak at.

    Why MastersUp

    Personalised first. High quality throughout.

    Most platforms hand everyone the same content. Here the content moves with your performance, topic by topic.

    Built around you, not around a syllabus PDF

    Every answer you give moves your topic-level intelligence rate. The next question, the next revision card and tomorrow's plan all change with it.

    Revision that hits your weak spots

    We only revise topics you have actually attempted and are still below the safe bar on — never the same chapter on repeat.

    Questions calibrated to the real exam

    Each question carries a measured toughness. You are served a rung above your current level, so practice keeps stretching you.

    Notes written for recall, not for volume

    Full lesson cards for first study, curated short-note cards for the last mile — with derivations, traps and exam patterns marked.

    One place for everything

    Notes, chapter practice, previous-year questions, test series and full-length papers — all feeding one picture of your preparation.

    Honest progress

    No vanity streaks. Progress here means chapters mastered and accuracy that held up on harder questions.

    Unlock the whole course

    Full notes and short notes, the complete question bank with worked solutions, mock tests, full-length papers, and an adaptive plan that rebuilds itself as you improve.

    Graph Coloring, Covers, Matrices and Special Graphs PYQs for GATE CS

    Solve 8+ Graph Coloring, Covers, Matrices and Special Graphs previous year questions for GATE CS with answers and detailed solutions. Free sample questions below.

    Chapter Roadmap: Discrete Mathematics Graph Theory

    Chapter Journey: Graph Structures & Algorithms

    1
    Graph Coloring & Bipartite Graphs Current Topic
    • Focus: Chromatic number, proper coloring, bipartiteness.
    • Goal: Determine minimum colors needed; identify 2-colorable graphs.
    • Weight: High frequency in logic-based questions.
    2
    Adjacency Matrices & Walk Counting
    • Focus: Matrix representation, matrix powers for paths, trace for cycles.
    • Goal: Link algebraic properties to graph topology.
    3
    Minimum Vertex Covers
    • Focus: Covering all edges with a minimal set of vertices.
    • Goal: Understand structural constraints and approximation bounds.
    4
    Special Graphs & Isomorphism
    • Focus: Petersen graph properties, Hamiltonian and Eulerian paths.
    • Goal: Recognize standard counter-examples and structural equivalence.

    Hero Concept: Proper Graph Coloring

    What is Graph Coloring?

    A proper coloring of a graph is an assignment of colors to vertices such that no two adjacent vertices share the same color.

    Formally, a function is a proper -coloring if:

    Chromatic Number

    The smallest integer for which has a proper -coloring.

    • If , the graph is -chromatic.
    • If , the graph is -colorable.
    Intuition: Think of colors as "resources" or "time slots." Adjacent vertices compete for resources. tells you the minimum resource pool size required to satisfy all constraints simultaneously.

    Graph Coloring, Covers, Matrices and Special Graphs: Solved Questions with Step-by-Step Explanations (8 Problems)

    Question 1 · Engineering Mathematics · 2026_Set1 MSQ
    Let be a simple, undirected graph. A vertex cover of is a subset such that for every , or . Let the size of the smallest vertex cover in be . Let be any vertex cover of size .

    For a vertex , which of the following constraints will always ensure that ?
    1. A.

      The degree of is at least

    2. B.

      The vertex is on a path of length

    3. C.

      The vertex is on a cycle of length

    4. D.

      The vertex is a part of a clique of size

    Correct Answer:

    ["A"]

    Step-by-Step Solution

    Insight: If a vertex has degree , excluding it from the vertex cover forces all its neighbors into the cover, requiring at least vertices, which contradicts the cover size being .

    Exam route: Test the degree condition. If is not in , its neighbors must be. If , , a contradiction. Thus must be in .

    Learning route:

    1. Option A: True. If , all neighbors must be in to cover the edges incident to . Since , this requires , contradicting . Thus, must be in .
    2. Option B: False. Consider a path of length 3 (4 vertices: ). The minimum vertex cover size is (e.g., ). Vertex is on the path but not in .
    3. Option C: False. Consider a cycle of length 3 (). The minimum vertex cover size is (e.g., ). Vertex is on the cycle but not in .
    4. Option D: False. Consider a clique of size 3 (). The minimum vertex cover size is (e.g., ). Vertex is part of the clique but not in .
    Question 2 · Engineering Mathematics · 2026_Set1 MSQ
    An undirected, unweighted, simple graph is said to be 2-colorable if there exists a function such that for every , .

    Which of the following statements about 2-colorable graphs is/are true?
    1. A.

      If is 2-colorable, then may contain cycles of odd length

    2. B.

      If is 2-colorable, then may contain cycles of even length

    3. C.

      An optimal algorithm for testing whether is 2-colorable runs in time , if is represented as an adjacency list

    4. D.

      An optimal algorithm for testing whether is 2-colorable runs in time , if is represented as an adjacency list

    Correct Answer:

    ["B","C"]

    Step-by-Step Solution

    Insight: 2-colorable graphs are exactly bipartite graphs, which have no odd cycles and can be tested in linear time using BFS/DFS.

    Exam route: Recall the definition of bipartite graphs (no odd cycles) and the standard linear-time BFS algorithm for bipartiteness testing.

    Learning route:

    1. Option A: False. By definition, a graph is 2-colorable if and only if it is bipartite, which means it contains NO odd-length cycles.
    2. Option B: True. Bipartite graphs can contain even-length cycles (e.g., ).
    3. Option C: True. Testing bipartiteness via BFS or DFS takes time, which is optimal for adjacency list representation.
    4. Option D: False. is strictly faster than for connected graphs, making the latter non-optimal.
    Question 3 · Engineering Mathematics · 2024_Set2 MCQ

    Let be the adjacency matrix of a simple undirected graph . Suppose is its own inverse. Which one of the following statements is always TRUE?

    1. A.

      is a cycle

    2. B.

      is a perfect matching

    3. C.

      is a complete graph

    4. D.

      There is no such graph

    Correct Answer:

    B

    Step-by-Step Solution

    Insight: implies . The diagonal entries of represent the degrees of the vertices, so every vertex must have a degree of exactly 1.

    Exam route: means for all . Since is the degree of vertex , every vertex has degree 1. This uniquely defines a perfect matching.

    Learning route:

    1. The condition is equivalent to , where is the identity matrix.
    2. This means that for every vertex , the diagonal entry .
    3. From the properties of adjacency matrices, equals the number of walks of length 2 from vertex to itself, which is exactly the degree of vertex in a simple graph.
    4. Therefore, every vertex in the graph must have a degree of exactly 1.
    5. A simple undirected graph where every vertex has degree exactly 1 is, by definition, a perfect matching (a disjoint union of components).
    6. Checking the options: A cycle has degree 2. A complete graph has degree . A perfect matching has degree 1.
    Question 4 · Engineering Mathematics · 2024_Set2 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 __________

    Correct Answer:

    2.00

    Step-by-Step Solution

    Insight: The graph is bipartite if and only if it can be 2-colored without adjacent vertices sharing a color, meaning no odd cycles exist.

    Exam route: Attempt a BFS 2-coloring. If no conflicts arise, .

    Learning route:

    1. Assign Color 1 (Red) to an arbitrary starting vertex, say the top-left vertex .
    2. All neighbors of must be Color 2 (Blue).
    3. All neighbors of those Blue vertices must be Red.
    4. Continue this alternating assignment. Tracing the provided graph, we find a valid partition: Red = {}, Blue = {}.
    5. Verify no edges exist between two Red or two Blue vertices. Since a valid 2-coloring exists and the graph has edges, .
    Question 5 · Engineering Mathematics · 2024_Set1 MSQ

    The chromatic number of a graph is the minimum number of colours used in a <i>proper</i> colouring of the graph. Let be any graph with vertices and chromatic number . Which of the following statements is/are always TRUE?

    1. A.

      contains a complete subgraph with vertices

    2. B.

      contains an independent set of size at least

    3. C.

      contains at least edges

    4. D.

      contains a vertex of degree at least

    Correct Answer:

    ["B","C"]

    Step-by-Step Solution

    Insight: Chromatic number guarantees a -critical subgraph (dictating minimum edges) and partitions vertices into independent sets (bounding maximum independent set size via Pigeonhole Principle).

    Exam route: Use Pigeonhole Principle for Option B. Recall -critical subgraph minimum degree for Option C. Disprove A and D with standard counterexamples ( and ).

    Learning route:

    1. Option A: False. A graph with does not necessarily contain a . Counterexample: has but no (triangle).
    2. Option B: True. A proper -coloring partitions vertices into independent sets (color classes). By the Pigeonhole Principle, at least one color class must have size .
    3. Option C: True. Any graph with contains a -critical subgraph. A -critical graph has a minimum degree of at least and at least vertices. Thus, the number of edges is at least .
    4. Option D: False. A graph with must have a vertex of degree at least , but not necessarily . Counterexample: has , but every vertex has degree exactly .
    Question 6 · Engineering Mathematics · 2022 MSQ

    Which of the properties hold for the adjacency matrix of a simple undirected unweighted graph having vertices?

    1. A.

      The diagonal entries of are the degrees of the vertices of the graph.

    2. B.

      If the graph is connected, then none of the entries of can be zero.

    3. C.

      If the sum of all the elements of is at most , then the graph must be acyclic.

    4. D.

      If there is at least a 1 in each of ’s rows and columns, then the graph must be connected.

    Correct Answer:

    ["A"]

    Step-by-Step Solution

    Insight: The diagonal entries of count the number of walks of length 2 from a vertex to itself, which equals its degree in a simple undirected graph.

    Exam route: Evaluate . Since is symmetric and binary, this simplifies to , which is the degree of vertex . Disprove B, C, D with counterexamples.

    Learning route:

    1. Option A: True. . Since is undirected, is symmetric (). Since is simple, , so . Thus, .
    2. Option B: False. Consider a star graph with (center 1, leaves 2, 3, 4). . The number of walks of length 3 between leaves 2 and 3 is 0. Thus, .
    3. Option C: False. Consider a triangle plus an isolated vertex (, ). The sum of all elements in is . However, the graph contains a cycle (the triangle).
    4. Option D: False. Consider two disjoint triangles (). Every vertex has degree 2, so every row and column has at least one 1. However, the graph is disconnected.
    Question 7 · Engineering Mathematics · 2022 MCQ

    Consider a simple undirected unweighted graph with at least three vertices. If is the adjacency matrix of the graph, then the number of 3-cycles in the graph is given by the trace of

    1. A.

    2. B.

      divided by 2

    3. C.

      divided by 3

    4. D.

      divided by 6

    Correct Answer:

    D

    Step-by-Step Solution

    Insight: The trace of counts all closed walks of length 3. Each triangle is counted exactly 6 times (3 starting vertices 2 directions).

    Exam route: Recall the formula for counting triangles using the adjacency matrix: .

    Learning route:

    1. The entry of represents the number of walks of length from vertex to vertex .
    2. The trace of is the sum of its diagonal entries, . This represents the total number of closed walks of length 3 in the graph.
    3. In a simple graph, any closed walk of length 3 must be a triangle (a 3-cycle), as there are no self-loops or multiple edges.
    4. Each 3-cycle consists of 3 vertices. A closed walk of length 3 can start at any of these 3 vertices and traverse the cycle in 2 directions (clockwise or counter-clockwise).
    5. Therefore, each distinct 3-cycle is counted exactly times in the trace of . To find the number of unique 3-cycles, we must divide the trace by 6.
    Question 8 · Engineering Mathematics · 2022 MSQ
    The following simple undirected graph is referred to as the Peterson graph.



    Which of the following statements is/are TRUE?
    1. A.

      The chromatic number of the graph is 3.

    2. B.

      The graph has a Hamiltonian path.

    3. C. The following graph is isomorphic to the Peterson graph.

    4. D.

      The size of the largest independent set of the given graph is 3. (A subset of vertices of a graph form an independent set if no two vertices of the subset are adjacent.)

    Correct Answer:

    ["A","B","C"]

    Step-by-Step Solution

    Insight: The Petersen graph is a famous 3-regular, non-planar graph with , independence number 4, a Hamiltonian path, but no Hamiltonian cycle.

    Exam route: Recall the standard invariant cheat sheet for the Petersen graph: 10 vertices, 15 edges, girth 5, , , Hamiltonian path (yes), Hamiltonian cycle (no).

    Learning route:

    1. Option A: True. The Petersen graph contains 5-cycles (odd), so . It is 3-colorable, so .
    2. Option B: True. While it lacks a Hamiltonian cycle, it is well-known to possess a Hamiltonian path.
    3. Option C: True. The second graph is a standard alternative drawing of the Petersen graph (it is 3-regular, has 10 vertices, 15 edges, and girth 5).
    4. Option D: False. The independence number (largest independent set) of the Petersen graph is 4, not 3.

    More previous year questions (pyqs) in this unit