fixed adjacency matrix representation