Questions: Graph Representation: Adjacency and Incidence Matrices

5 questions to test your understanding

Score: 0 / 5
Question 1 Multiple Choice

For a graph G with adjacency matrix A, the entry (A²)[i][j] = 3. What does this tell you about the graph?

AThere are 3 edges directly connecting vertex i to vertex j
BThere are 3 distinct walks of length exactly 2 from vertex i to vertex j — meaning 3 different intermediate vertices k such that edges i→k and k→j both exist
CVertex i and vertex j are 3 hops apart in the shortest path
DThere are 3 triangles (3-cycles) in the graph that include both vertex i and vertex j
Question 2 Multiple Choice

For which type of graph is an adjacency list representation generally preferred over an adjacency matrix, and why?

ADense graphs, because adjacency lists enumerate all edges explicitly while matrices require index lookups
BSmall graphs, because adjacency lists fit in a single array while matrix construction is computationally expensive
CSparse graphs, because the adjacency matrix is mostly zeros and wastes O(n²) space to represent O(n) or O(m) edges
DDirected graphs, because adjacency lists naturally represent asymmetric relationships while matrices require separate row/column logic
Question 3 True / False

The adjacency matrix of an undirected graph is always symmetric because every edge {i, j} contributes entries in both A[i][j] and A[j][i].

TTrue
FFalse
Question 4 True / False

If A[i][j] = 1 in the adjacency matrix of a directed graph, then A[j][i] should also equal 1.

TTrue
FFalse
Question 5 Short Answer

Explain what information is encoded in the matrix A² (A squared), and describe why this result connects matrix algebra to graph reachability.

Think about your answer, then reveal below.