Matrix representation of Graph, Edge Sequence, Walk, Path and Circuit

 Matrix Representation of Graphs

When G is a simple graph with n vertices V1,V2,V3…Vn the matrix A (or AG)=Aij.

Where,Aij is called the adjacency matrix of G.

Properties of an Adjacency Matrix

  • Since a simple graph has no loops, each diagonal entry of A, viz., Aij=0, for i=1,2,…n.
  • The adjacency matrix of simple graph is symmetric, viz. Aij= Aji, since both of these entries are 1 when vi, vare adjacent and both are 0 otherwise.
  • Note: The given any symmetric zero-one matrix A which contains only 0’s on its diagonal there exists a simple graph G whose adjacency matrix is A.
  • deg(vi) is equal to the number of 1’s in the ith row and ith column.

Examples

1.Adjacency Matrix of a Simple Graph

2.Adjacency Matrix of a Weighted Graph

3.Adjacency Matrix of a Directed Graph

EDGE SEQUENCE, WALKS, PATHS AND CIRCUITS

Edge Sequence

An edge is the mathematical term for a line that connects two vertices.

Many edges can be formed from a single vertex.

Without a vertex, an edge cannot be formed.

There must be a starting vertex and an ending vertex for an edge.


Here, ‘a’ and ‘b’ are the two vertices and the link between them is called an edge.

Example

1. Edge Sequence for Undirected Graph



In this graph,

There are six vertices (A, B, C, D, E, F)

Edges or edge sequences are (A,B), (B,C), (C,D), (D,E), (E,F) and (F,A)

2. Edge Sequence for Directed Graph

 

In this graph,

There are four vertices (A, B, C, D)

Edges or edge sequences are (A,C), (B,A), (B,D) and (D,C)

Walks

A walk is a sequence of vertices and edges of a graph that is if we traverse a graph then we get a walk.

Vertex can be repeated

Edges can be repeated

Walk can be open or closed

Here, B→C→D→E→F→G→H→C→D→A is Walk

The edge (C,D) is repeated

The vertices C, D is repeated

 

Trail

Trail is a walk in which no edge is repeated.

Vertex can be repeated.

Trail can be open or closed.

From the above graph,

A→D→E→F→G→H→C→B is Open Trail

B→C→D→E→F→G→H→C→B is Closed Trail

 

Path 

  • Path is a trail in which neither vertices nor edges are repeated.

  • Vertex not repeated.

  • Edges not repeated.

  • Path can be open.

  • From the above graph,

A→B→C→D→E→F→G→H  is a path

 

Circuit

  • Traversing a graph such that not an edge is repeated but vertex can be repeated and it is closed.

  • Vertex can be repeated.

  • Edges cannot be repeated.

  • Circuit can be closed.

A→B→C→D→E→H→G→F→A  is a circuit

Degree Sequence of a Graph

  • The degree of a vertex in an undirected graph is the number of edges incident with it.

  • If the degrees of all vertices in a graph are arranged in ascending or descending order, then the sequence obtained is known as the degree sequence of the graph.

Example


Vertex

A

B

C

D

E

F

G

H

Connecting to

B,D,F

A,C

B,D,H

A,C,E

D,F,H

A,E,G

F,H

C,E,G

Degree

3

2

3

3

3

3

2

3

In the above graph, for the vertices {A,C,D,E,F,H,C,G}, the degree sequence is {3,3,3,3,3,3,2,2}


Comments

Popular posts from this blog

Backtracking - N-Queens Problem, Sum of Subsets, Graph Colouring, Hamiltonian Cycle

Divide and Conquer Technique - Binary Search, Quick Sort, Merge Sort

GRAPH THEORY