Use adjacency to return the adjacency matrix of the graph. Regardless of the form of adjacency matrix used to construct the graph, the adjacency function always returns a symmetric and sparse adjacency matrix containing only 1s and 0s.