Tuesday, August 27, 2013

representation of graphs



                                             ADJACENCY MATRIX AND GRAPHS 

Any graphs can be represented as adjacency matrices without even drawing the vertices and edges.
6n-graph2.svg                                                                                 \begin{pmatrix}
1 & 1 & 0 & 0 & 1 & 0\\
1 & 0 & 1 & 0 & 1 & 0\\
0 & 1 & 0 & 1 & 0 & 0\\
0 & 0 & 1 & 0 & 1 & 1\\
1 & 1 & 0 & 1 & 0 & 0\\
0 & 0 & 0 & 1 & 0 & 0\\
\end{pmatrix}



Here the graph itself is represented using the adjacency matrix.Vertices connected to each other by edges are denoted as 1 and otherwise 0.This matrix is enough to identify the graph.

                                                         INCIDENCE RELATION


                       
\begin{pmatrix}
  1 & 1 & 1 & 0 \\
  1 & 0 & 0 & 0 \\
  0 & 1 & 0 & 1 \\
  0 & 0 & 1 & 1 \\
\end{pmatrix}



                               Entry of an incidence matrix is set to 1 if an edge incidence on a vertex otherwise it is set to zero.


                                                            ADJACENCY LIST



                          In this representation,every vertexes connected to a particular edge is plotted.











No comments:

Post a Comment