StreakPeaked· Practice

ExamsGATETechnical

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

  1. A³ divided by 2
  2. A³ divided by 3
  3. A³ divided by 6

Correct answer: A³ divided by 6

Solution

The number of 3-cycles in an undirected graph can be found by calculating the trace of the cube of the adjacency matrix, A³, which counts each cycle three times (once for each vertex in the cycle). Therefore, to get the correct count of unique 3-cycles, we divide the trace of A³ by 6, accounting for the overcounting.

Related GATE Technical questions

⚔️ Practice GATE Technical free + battle 1v1 →