Graph Representation
GIAN Tutorials
11:02 PM
Graph Representation By Graph representation, we simply mean the technique which is to be used in order to store some graph into the computer's memory. There are two ways to store Graph into the computer's memory. In this part of this tutorial, we discuss each one of them in detail. 1. Sequential Representation In sequential representation, we use adjacency matrix to store the mapping represented by vertices and edges. In adjacency matrix, the rows and columns are represented by the graph vertices. A graph having n vertices, will have a dimension n x n . An entry M ij in the adjacency matrix representation of an undirected graph G will be 1 if there exists an edge between V i and V j . An undirected graph and its adjacency matrix representation is shown in the following figure. in the above figure, we can see the mapping among the vertices (A, B, C, D, E) is represented by using the adjacency matrix which is also shown in the figure. There exists differe