The adjacency matrix of a graph is a boolean matrix whose (i, j)th entry is true iff there is an edge from the ith vertex to the jth vertex.