Presentation is loading. Please wait.

Presentation is loading. Please wait.

Matrix Representation of Graph

Similar presentations


Presentation on theme: "Matrix Representation of Graph"— Presentation transcript:

1

2 Matrix Representation of Graph

3 CONTENTS Definition Types of Matrices Adjacency Matrix

4 Definition: A pictorial representation of a graph is very convenient for a visual study. A matrix is a convenient and useful way of representing a graph to a computer. In many applications of graph theory, such as in electrical network analysis and operations research, matrices also turn out to e the natural way of expressing the problem.

5 In this chapter, we study various types of matrices associated with a graph, namely.
Incidence Matrix Path matrix Cut-set matrix Cycle matrix Circuit Matrix . Types of Matrices:

6 The matrix element aij is defined as;
Incidence Matrix: Defn : let G be a graph with n-vertices and e - edges and no self loop, defines on n by e matrix A=[aij] whose n rows corresponds to the n vertices and e columns corresponds to e edges in called incidence matrix. The matrix element aij is defined as; Aij = 1 if jth edge ej is incident on the ith vertex vi 0, otherwise  Incidence matrix of graph G is denoted as A [G]. F

7 Path Matrix: Let us consider a graph G and let us also consider a vertex pair (a, b) = [Pij] for (a, b) is defined as Pij = 1 if jth edge in the ith path. 0 otherwise. Ex. Find the path matrix between vertices v1 & v4 The different paths are (a, g) (a, f, d) (e, f, g) (e, d) Then P (v1 v4) =

8 Adjacency Matrix: Alternative to incidence matrix, it is sometimes more convenient to represent a graph by adjacency matrix or connection matrix. The adjacency matrix of graph G with n vertex and no parallel edges is an n by n symmetric binary matrix X=[Xij]. X ij = 1 if there is an edge between ith and jth 0 if there is no edge between them.

9 ‘0’ diagram means no self loop

10 Cycle Matrix: The cycle matrix C=[Cij]of g has a row for each cycle and a column for each line with Cij =1 if the ith cycle contains lines xj and Cij =0 otherwise. In contrast to the adjacency and incidence matrices, the cycle matrix does not determine a graph up to isomorphism. The graph G1 has four different cycle Z1 = {e1, e2}, Z2 = {e3, e5, e7}, Z3= {e4, e6, e7,} & Z4 = {e3, e4, e5, e6} The cycle matrix is

11 Circuit Matrix: Let no. of different circuit in a graph G be q and the number of edges in g be c. Then the circuit matrix is denoted and defined by. B=[Bij] = 1 if ith circuit includes jth edges 0 otherwise.

12 Ex: Draw the circuit matrix for the following figure.
Soln: Graph has four different circuits; C1 = {e1, e2} F C2 = {e3, e5, e7} C3= {e4, e6, e7,} C4 = {e3, e4, e5, e6}

13


Download ppt "Matrix Representation of Graph"

Similar presentations


Ads by Google