0% found this document useful (0 votes)
61 views

Module 1

This document introduces some key concepts in graph theory, including: - A graph G consists of a set of vertices V connected by edges E. - Common representations include diagrams showing vertices as points and edges as line segments. - Terms defined include loops, parallel edges, simple graphs, and more. - The degree of a vertex is the number of edges incident to it. - The fundamental theorem of graphs states the sum of degrees equals twice the number of edges. - Examples are provided to illustrate different graph types and properties.

Uploaded by

Adarsh Pradeep
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
61 views

Module 1

This document introduces some key concepts in graph theory, including: - A graph G consists of a set of vertices V connected by edges E. - Common representations include diagrams showing vertices as points and edges as line segments. - Terms defined include loops, parallel edges, simple graphs, and more. - The degree of a vertex is the number of edges incident to it. - The fundamental theorem of graphs states the sum of degrees equals twice the number of edges. - Examples are provided to illustrate different graph types and properties.

Uploaded by

Adarsh Pradeep
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 33

1

MODULE I
Introduction to Graphs
Graph
A graph 𝐺 = (𝑉, 𝐸) consists of a set of objects
𝑉 = {𝑣1 , 𝑣2 , 𝑣3 , ⋯ ⋯ ⋯ } called vertices (points, nodes) and
𝐸 = {𝑒1 , 𝑒2 , 𝑒3 , ⋯ ⋯ ⋯ } whose elements are called edges;
such that each edge e in E is assigned an unordered pair of vertices (𝑢, 𝑣) called
the end vertices of e.

The most common representation of a graph is by means of


a diagram in which the vertices are represented as points and each edge as a line
segment joining its end vertices.

Example: -
1) 𝑣1 𝑒1 𝑣2 2) 𝑣1
𝑉 = {𝑣1 }
𝑒4 𝑒5 𝑒2 𝐸=∅

𝑣4 𝑒3 𝑣3

𝐺 = (𝑉, 𝐸)
where 𝑉 = {𝑣1 , 𝑣2 , 𝑣3 , 𝑣4 }
𝐸 = {𝑒1 , 𝑒2 , 𝑒3 , 𝑒4 , 𝑒5 }
Notes: -
1) In drawing a graph it is immaterial whether the lines are drawn straight or

curved, long or short: what is important is the incident between the edges and

vertices. Hence the different diagrams may represent the same graph.
2

Example: -
𝒗𝟏 𝒗𝟏 𝒗𝟏
𝒆𝟓 𝒆𝟏 𝒆𝟓 𝒆𝟏 𝒆𝟓 𝒆𝟏
𝒗𝟒 𝒆𝟐 𝒗𝟐 𝒗𝟒 𝒆𝟐 𝒗𝟐 𝒗𝟒 𝒗𝟐
𝒆𝟒 𝒆𝟑 𝒆𝟒 𝒆𝟑
𝒆𝟒 𝒆𝟑
𝒗𝟑 𝒗𝟑 𝒗𝟑
2) In diagram of a graph, sometimes two edges may seem to intersect at a point
that does not represent a vector.

Example: -
𝒂
𝒆 Here intersecting point of 𝑒 & 𝑓 is
𝒅 𝒃 not a vertex.
𝒇
c
3) An edge is said to be incident with its end vertices and vice versa.
Example: -
𝒗𝟏 Here 𝒆𝟏 is incident with 𝒗𝟏 & 𝒗𝟐 ,
𝒆𝟏 𝒆𝟐 is incident with 𝒗𝟐 & 𝒗𝟑
𝒗𝟐 Also 𝑣1 is incident with 𝒆𝟏 ,
𝒆𝟐 𝒗𝟑 𝑣2 is incident with 𝒆𝟏 & 𝒆𝟐 ,
𝑣3 is incident with 𝒆𝟐

Self-Loop / Loop
It is an edge whose both ends are same.
Example: -
1) 𝒗𝟏 𝒆𝟏 Here 𝒆𝟏 is the self loop.
3

2) 𝒆𝟏 𝒆𝟐 Here 𝒆𝟏 & 𝒆𝟐 are self loops.


Parallel edges / Multiple edges
If any pair of vertices are joined by more than one edge, then such edges are
called parallel edges.

Example: -
𝒗𝟏
𝒆𝟏 𝒆𝟒 𝒆𝟏 & 𝒆𝟐 are parallel edges
𝒆𝟐 𝒆𝟑 𝒆𝟑 & 𝒆𝟒 are parallel edges
𝒗𝟐 𝒗𝟑
Simple Graph
If the graph with no loops and multiple edges are called simple graph.
𝒗𝟏 𝒗𝟐
G: Here G is a simple graph.

𝒗𝟒 𝒗𝟑

Multi Graph
A graph having parallel edge is known as a multi graph.
𝒗𝟏 𝒗𝟐
G: Here G is a multi-graph.

𝒗𝟒 𝒗𝟑
4

Pseudo graph
A graph with at least one loop is a pseudo graph.
Finite Graph
A graph consisting of finite number of vertices and edges is called as a finite
graph.

Example: -
𝒗𝟏
𝒆𝟏 𝒆𝟑

𝒗𝟐 𝒆𝟐 𝒗𝟑
This graph consists of finite number of vertices and edges. Therefore, it is a
finite graph.

Infinite Graph
A graph consisting of infinite number of vertices and edges is called as an
infinite graph.

Example: -

This graph consists of infinite number of vertices and edges. Therefore, it is an


infinite graph.

Adjacent vertices
Two vertices 𝑢&𝑣 in a graph 𝐺 are said to be adjacent if they are connected by
an edge.
5

Example: - 𝒗𝟏
𝒆𝟏 Here, 𝑣1 &𝑣2 are adjacent vertices
𝒗𝟐 𝑰𝑰𝑰𝒍𝒚 𝑣2 &𝑣3 are adjacent vertices
𝒆𝟐 𝒗𝟑
Adjacent edges
Two non-parallel edges are said to be adjacent if they are incident on a common
vertex.

Example: - 𝒗𝟏
𝒆𝟏 Here, 𝒆𝟏 &𝒆𝟐 are adjacent edges
𝒗𝟐
𝒆𝟐 𝒗𝟑
Degree of a vertex
The number of edges incident on a vertex 𝑣, self loop counted twice is called
degree of a vertex 𝑣 and is denoted by 𝑑𝑒𝑔(𝑣) or 𝑑(𝑣).

Example: -
𝒆𝟏
𝒗𝟏 𝒆𝟑 𝒗𝟐
𝒆𝟓
𝒆𝟒 𝒆𝟐 𝒗𝟓
𝒗𝟑 𝒆𝟔 𝒗𝟒

Here, 𝑑(𝒗𝟏 ) = 𝑑(𝒗𝟑 ) = 𝑑(𝒗𝟒 ) = 3 , 𝑑(𝒗𝟐 ) = 4 , 𝑑(𝒗𝟓 ) = 1


Fundamental theorem of Graph theory (Handshaking theorem)
If any graph the sum of degrees of its vertices is equal to twice the number of
edges.

i.e. ∑𝑛𝑖=1 𝑑(𝑣𝑖 ) = 2𝑒 𝑜𝑟 2|𝐸|


6

Proof:
Let 𝐺 be any graph with ‘e’ edges and ‘n’ vertices such as 𝑣1 , 𝑣2 , 𝑣3 , ⋯ ⋯ 𝑣𝑛 .

Since each edge contributes two degrees, 𝑣1 𝑒1 𝑣2

then the sum of degrees of all vertices in 𝐺 is twice the number of edges in 𝐺.

i.e. ∑𝑛𝑖=1 𝑑(𝑣𝑖 ) = 2𝑒

Hence the proof

Example: -
𝑣5 𝑣1 𝑣2
𝑒4 𝑒5 𝑒1 𝑒2
𝑣4 𝑒3 𝑣3
𝑑(𝑣1 ) = 2, 𝑑(𝑣2 ) = 1, 𝑑(𝑣3 ) = 3, 𝑑(𝑣4 ) = 3, 𝑑(𝑣5 ) = 1
Number of edges= 5
Here, sum of degrees of each vertex= 10 = 2 × 𝑛𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 𝑒𝑑𝑔𝑒𝑠
Theorem
The number of vertices of odd degree in a graph is always even.
Proof:
Let 𝐺(𝑉, 𝐸) be any graph with ′𝑛′ number of vertices and ‘𝑒’ number of edges.

Let as 𝑣1 , 𝑣2 , 𝑣3 , ⋯ ⋯ 𝑣𝑘 be the odd degree vertices

and 𝑣1 ′ , 𝑣2 ′ , 𝑣3 ′ , ⋯ ⋯ , 𝑣𝑚 ′ be the even degree vertices.

By fundamental theorem,

∑𝑛𝑖=1 𝑑(𝑣𝑖 ) = 2𝑒

∑𝑘𝑖=1 𝑑(𝑣𝑖 ) + ∑𝑚 ′
𝑗=1 𝑑(𝑣𝑗 ) = 2𝑒

∑𝑘𝑖=1 𝑑(𝑣𝑖 ) + 𝑒𝑣𝑒𝑛 𝑛𝑢𝑚𝑏𝑒𝑟 = 𝑒𝑣𝑒𝑛 𝑛𝑢𝑚𝑏𝑒𝑟

∑𝑘𝑖=1 𝑑(𝑣𝑖 ) = 𝑒𝑣𝑒𝑛 𝑛𝑢𝑚𝑏𝑒𝑟 − 𝑒𝑣𝑒𝑛 𝑛𝑢𝑚𝑏𝑒𝑟


7

𝑘 = 𝑒𝑣𝑒𝑛 𝑛𝑢𝑚𝑏𝑒𝑟

∴ The number of vertices of odd degree is always even.

Hence proved

Regular graph
A graph in which all vertices are of same degree.
Example: -
1) 𝑣1
Here 𝑑(𝑣1 ) = 𝑑(𝑣2 ) = 𝑑(𝑣3 ) = 2
So, it is a regular graph
𝑣2 𝑣3

2) 𝑢 𝑣 Here 𝑑(𝑢) = 𝑑(𝑣) = 1, so it is a regular graph

3) 𝑣1 𝑣2
Here 𝑑(𝑣1 ) = 𝑑(𝑣4 ) = 2
𝑣3 𝑣4 𝑑(𝑣2 ) = 𝑑(𝑣3 ) = 1
So, it is not a regular graph
Note: -
If every vertex in regular graph has degree ‘𝑛’ then this graph is called
𝑛 −regular graph.

Example: -

𝐺1 : 𝐺2 :
2-regular graph 3-regular graph
Degree Sequence
If 𝑣1 , 𝑣2 , 𝑣3 , … … … , 𝑣𝑛 are the 𝑛 vertices of 𝐺, then the sequence
8

(𝑑1 , 𝑑2 , 𝑑3 , … … … , 𝑑𝑛 ) where 𝑑𝑖 = deg (𝑣𝑖 ) is the degree sequence of 𝐺.

In general, we order the vertices so that the degree sequence is monotonically


increasing.

i.e. 𝑑1 ≤ 𝑑2 ≤ 𝑑3 ≤ ⋯ … … ≤ 𝑑𝑛
Example: -
𝑣1

G: 𝑣2 𝑣3
𝑣4
Degree sequence of 𝐺 ∶ ( 2 ,2, 3, 5)
Question
Is there a graph with degree sequence ( 2 ,3, 3,4,4, 5)
Solution: -
No, here sum of degrees is odd.

We know that, ∑𝑛𝑖=1 𝑑(𝑣𝑖 ) = 2𝑒 = 𝑒𝑣𝑒𝑛 𝑛𝑢𝑚𝑏𝑒𝑟

Isolated vertex

A vertex of degree zero is called an isolated vertex. In other words, a vertex


having no incident edge is called an isolated vertex.

Pendant vertex / end vertex


A vertex of degree 1 is called a pendant vertex.
Notes: -
1) The number of vertices (|𝑉|) in a graph 𝐺 is represented by 𝒏(𝑮) and it is
called order of 𝑮.

2) The number of edges (|𝐸|) in a graph 𝐺 is represented by 𝒎(𝑮) and it is


called the size of 𝑮.
9

Questions

1) Find the degree of each vertex for the below graph. Identify the isolated
vertices, loops, parallel edges, order of the graph & size of the graph.

𝑣2 𝑒2
𝑒1 𝑒3 𝑒5 𝑣3
𝑒6 𝑣5 𝑣4
𝑣1 𝑒7 𝑒4
𝑒8 𝑣6
Solution: -
𝑑(𝑣1 ) = 3, 𝑑(𝑣2 ) = 5, 𝑑(𝑣3 ) = 1 𝑑(𝑣4 ) = 0, 𝑑(𝑣5 ) = 3, 𝑑(𝑣6 ) = 4
Isolated vertex - 𝑣4

Loop - 𝑒2

Parallel edges - 𝑒7 & 𝑒8

Order of the graph, 𝑛(𝐺) = Number of vertices = 6

Size of the graph, 𝑛(𝐺) = Number of edges = 8

2) Find the order, size and the degree of each vertex in the following graphs.
Verify also the fundamental theorem in each case.

i) B E

A C D F

Solution: -
Order of the graph = |𝑉| = 6
Size of the graph = |𝐸| = 9
10

𝑑(𝐴) = 2, 𝑑(𝐵) = 4, 𝑑(𝐶) = 4, 𝑑(𝐷) = 3, 𝑑(𝐸) = 4, 𝑑(𝐹) = 1


.𝐷𝑒𝑔𝑟𝑒𝑒 𝑠𝑢𝑚 = 2 + 4 + 4 + 3 + 4 + 1
= 18 = 2 × 𝑛𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 𝑒𝑑𝑔𝑒𝑠
Hence the theorem is verified.

ii)
A B C

E D
Solution: -
Order of the graph = Number of vertices = 5
Size of the graph = Number of edges = 13
𝑑(𝐴) = 6, 𝑑(𝐵) = 6, 𝑑(𝐶) = 6, 𝑑(𝐷) = 5, 𝑑(𝐸) = 3
.𝐷𝑒𝑔𝑟𝑒𝑒 𝑠𝑢𝑚 = 6 + 6 + 6 + 5 + 3
= 26 = 2 × 𝑛𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 𝑒𝑑𝑔𝑒𝑠
Hence the theorem is verified.
3) Find the adjacent vertices and vertices incident on each edges in the following
graph.

𝑣1 𝑒1 𝑣2
𝑒2 𝑒3 𝑒6

𝑒5 𝑣4 𝑒4 𝑣3
Solution: -
adjacent vertices - {(𝑣1 , 𝑣2 ), (𝑣2 , 𝑣3 ), (𝑣3 , 𝑣4 ), (𝑣4 , 𝑣1 ), (𝑣4 , 𝑣4 )}

The edge 𝑒1 is incident on 𝑣1 & 𝑣2

The edge 𝑒2 is incident on 𝑣1 & 𝑣4


11

The edge 𝑒3 is incident on 𝑣2 & 𝑣3

The edge 𝑒4 is incident on 𝑣4 & 𝑣3

The edge 𝑒5 is incident on 𝑣4

The edge 𝑒6 is incident on 𝑣2 & 𝑣3

4) How many edges are there in a graph with 10 vertices each of degree 6?

Solution: -
Number of vertices = 10

Degree of each vertex = 6

Sum of the degree of vertices = 6 × 10 = 60

From fundamental theorem,

Sum of the degree of vertices= 2𝑒

2𝑒 = 60
60
.𝑒 = = 30
2

i.e. Number of edges = 30

Null graph / Empty graph


A graph with only isolated vertices is called a null graph. That is, in a null graph
the edge set is empty.

Example: -
𝑣1

𝑣2 𝑣3 𝑣4 𝑣5
𝑣6
Null graph of 6 vertices
12

Complete Graph
A complete graph is a simple graph in which each pair of distinct vertices is
joined by an edge.

The complete graph of 𝑛 vertices is denoted by 𝐾𝑛 .


Example: -
𝐾1

Notes: - |𝑣|=4 → n
1) Degree of all vertices of 𝐾𝑛 = 𝑛 − 1 𝑑(𝑣) = 3 → 𝑛 − 1

Hence, the maximum degree of each vertex in a simple graph with 𝑛 vertices
is (𝒏 − 𝟏)

.𝑃𝑟𝑜𝑜𝑓: −

Let 𝑛 be the number of vertices in 𝐺.

Given 𝐺 is a simple graph i.e.; a graph with no loops and parallel edges.

Let us consider a complete graph, then degree of each vertex = 𝑛 − 1

Then for a simple graph, G may have a maximum degree is at most 𝑛 − 1

i.e. 𝑑(𝑣) ≤ 𝑛 − 1
13

𝑛(𝑛−1)
2) The number of edges in 𝐾𝑛 is 𝑛𝑐2 or .
2

Hence, the maximum number of edges in a simple graph with 𝑛 vertices is


𝒏(𝒏−𝟏)
.
𝟐

.𝑃𝑟𝑜𝑜𝑓: −

By fundamental theorem,

∑𝑛𝑖=1 𝑑(𝑣𝑖 ) = 2𝑒, where 𝑒 is the number of edges with 𝑛 vertices in the graph.

𝑑(𝑣1 ) + 𝑑(𝑣2 ) + 𝑑(𝑣3 ) + ⋯ ⋯ ⋯ + 𝑑(𝑣𝑛 ) = 2𝑒 (1)

We know that, the maximum degree of each vertex in a c graph is (𝑛 − 1).

∴ Equation (1) becomes,

.(𝑛 − 1) + (𝑛 − 1) + (𝑛 − 1) + ⋯ ⋯ ⋯ 𝑡𝑜 𝑛 𝑡𝑖𝑚𝑒𝑠 = 2𝑒

. 𝑛(𝑛 − 1) = 2𝑒

𝑛(𝑛−1)
.𝑒 =
2

𝑛(𝑛−1)
The maximum number of edges in a simple graph with 𝑛 vertices is .
2

Hence proved.

Questions

1) Suppose 𝐺(𝑉, 𝐸) has 5 vertices. Find the maximum number of edges &
maximum degree of each vertex.

Solution: -
𝑛(𝑛−1) 5×4
Maximum number of edges = = = 10
2 2

maximum degree of each vertex= (𝑛 − 1) = (5 − 1) = 4


14

Bipartite Graph
If the vertex set 𝑉 of a simple graph 𝐺 = (𝑉, 𝐸) can be split into two disjoint
sets 𝑉1 and 𝑉2 , such that every edge of 𝐺 connects a vertex in 𝑉1 and a vertex in

𝑉2 (so that no edge in 𝐺 connects either 2 vertices in 𝑉1 or 2 vertices in 𝑉2 ),


then 𝐺 is called a bipartite graph.

Complete Bipartite Graph


A complete bipartite graph is a bipartite graph in which each vertex in the first

set is joined to every single vertex in the second set. The complete bipartite

graph is denoted by 𝐾𝑥,𝑦 where the graph 𝐺 contains 𝑥 vertices in the first set

and 𝑦 vertices in the second set.


15

Note: -
Number of edges of the complete bipartite graph 𝐾𝑥,𝑦 = 𝑥𝑦

Directed Graph (Digraph)


A graph 𝐺 = (𝑉, 𝐸) is said to be directed graph in which directions are given to
each edge.

Example: -
𝑣1 𝑣2

𝑣4 𝑣3
16

Undirected Graph
A graph in which the directions are not given for the edges is called undirected
graph.

Example: -
a

b c d

Two graphs 𝐺 and 𝐺′ are said to be isomorphic to each other if there is a


one-to-one correspondence between their vertices and between their edges such
that the incidence relationship is preserved.

Example: -
a 𝑣5
Graph 𝐺: e Graph 𝐺′: 𝑒1
5 2 1 𝑣4 𝑒3 𝑣3
6 c 3 𝑒2 𝑒4
b d 𝑒6
𝑣1 𝑒5 𝑣2
Correspondence of vertices Correspondence of edges
.𝑓(𝑎) = 𝑣1 𝑓(1) = 𝑒1
.𝑓(𝑏) = 𝑣2 𝑓(2) = 𝑒2
.𝑓(𝑐) = 𝑣3 𝑓(3) = 𝑒3
.𝑓(𝑑) = 𝑣4 𝑓(4) = 𝑒4
.𝑓(𝑒) = 𝑣5 𝑓(5) = 𝑒5
Adjacency also preserved. Therefore, 𝐺 and 𝐺′ are said to be isomorphic.
Note: -
Isomorphic graph must have
17

1) The same number of vertices


2) The same number of edges
3) An equal number of vertices with a given degree
In the above example
𝑮 𝑮′
|𝑉| 5 5
|𝐸| 6 6
𝑣𝑒𝑟𝑡𝑖𝑐𝑒𝑠 𝑜𝑓𝑑𝑒𝑔𝑟𝑒𝑒 − 3 𝑎, 𝑐, 𝑑 𝑣1 , 𝑣3 , 𝑣4
𝑣𝑒𝑟𝑡𝑖𝑐𝑒𝑠 𝑜𝑓𝑑𝑒𝑔𝑟𝑒𝑒 − 2 𝑏 𝑣2
𝑣𝑒𝑟𝑡𝑖𝑐𝑒𝑠 𝑜𝑓𝑑𝑒𝑔𝑟𝑒𝑒 − 1 𝑒 𝑣5

Questions

Determine whether the following graphs are isomorphic or not

i) A B 𝑣1 𝑣2

D C 𝑣4 𝑣3

𝐺𝑟𝑎𝑝ℎ 𝐺 𝐺𝑟𝑎𝑝ℎ 𝐺′

Solution: -
𝐺 and 𝐺′ have 4 vertices and 5 edges
In each graph two vertices have degree 2 and two have degree 3.
Correspondence of vertices
.𝑓(𝐴) = 𝑣1 , 𝑓(𝐵) = 𝑣2 , 𝑓(𝐶) = 𝑣4 , 𝑓(𝐷) = 𝑣3
Adjacency also preserved. Therefore, 𝐺 and 𝐺′ are said to be isomorphic.
18

ii) 𝑣2 𝑣2 ′

.𝐺: 𝑣1 𝑣3 𝐺 ′: 𝑣1 ′ 𝑣3 ′

𝑣5 𝑣4 𝑣5 ′ 𝑣4 ′
Solution: -
𝐺 and 𝐺 ′ have 5 vertices.
But number of edges in 𝐺 is 6 and number of edges in 𝐺 ′ is 5.
∴ The two graphs are not isomorphic.

iii) 𝑎 𝑏 𝑜 𝑝

𝑮𝟏 : 𝑒 𝑓 𝑮𝟐 : 𝑠 𝑡

ℎ 𝑔 𝑣 𝑢

𝑑 𝑐 𝑟 𝑞

Solution: -

𝐺1 and 𝐺2 have 8 vertices and 10 edges.


In 𝐺1 and 𝐺2 four vertices have degree 2 and four have degree 3.
Now consider 𝑑𝑒𝑔(𝑎) = 2 in 𝐺1
∴ ‘𝑎’ must correspond to either 𝑝, 𝑞, 𝑡, 𝑢 ; since these are the vertices of
degree 2 in 𝐺2 .
In 𝐺1 adjacent vertices of ′𝑎′ = ′𝑏′ 𝑎𝑛𝑑 ′𝑑′, both have degree 3
But in 𝐺2 each of the 4 vertices 𝑝, 𝑞, 𝑡, 𝑢 is adjacent to another vertex of
degree 2.
Which is not true for ′𝑎′ in 𝐺1 .
So, there is no possible one-to-one correspondence between 𝐺1 and 𝐺2 .
19

Hence the two graphs 𝐺1 and 𝐺2 are not isomorphic.


iv) 𝑒 𝑝

𝑎 𝑏 𝑐 𝑑 𝑞 𝑟 𝑠 𝑡 𝑢
𝑮𝒓𝒂𝒑𝒉 𝑮𝟏 𝑓 𝑮𝒓𝒂𝒑𝒉 𝑮𝟐
𝐺1 and 𝐺2 have 6 vertices and 5 edges.
In 𝐺1 and 𝐺2 : 2 vertices have degree 2, 3 vertices have degree 1 and 1 has
degree 3.
Now consider 𝑑𝑒𝑔(𝑏) = 2 in 𝐺1
∴ ‘𝑏’ must correspond to either 𝑟, 𝑡 ; since these are the vertices of degree 2
in 𝐺2 .
In 𝐺1 adjacent vertices of ′𝑏′ = ′𝑎′ 𝑎𝑛𝑑 ′𝑐′, 𝑑𝑒𝑔(𝑎) = 1 & 𝑑𝑒𝑔(𝑐) = 2
But in 𝐺2 each of the 2 vertices 𝑟, 𝑡 is adjacent to another vertex of
degree 3.
Which is not true for ′𝑏′ in 𝐺1 .
So, there is no possible one-to-one correspondence between 𝐺1 and 𝐺2 .
Hence the two graphs 𝐺1 and 𝐺2 are not isomorphic.
Subgraph
A graph 𝑔 is said to be a subgraph of a graph 𝐺, if all the vertices and all the
edges of 𝑔 are in 𝐺, and each edge of 𝑔 has the same end vertices in 𝑔 as in 𝐺.

𝑣1 𝑒1 𝑣2 𝑒2 𝑣3 𝑣1 𝑒1 𝑣2 𝑒2 𝑣3
.
𝑒3 𝑒4 𝑒5 𝑒4
.𝑣4 𝑒6 𝑣5 𝑒7 𝑣6 𝑣5 𝑒7 𝑣6
.𝑮𝒓𝒂𝒑𝒉 𝑮 𝑺𝒖𝒃𝒈𝒓𝒂𝒑𝒉 𝒈 𝒐𝒇 𝑮

If 𝑔 is a subgraph of 𝐺, then 𝐺 is a super graph of 𝑔.


20

Remark: -
𝑔 ⊂ 𝐺 is used in stating “ 𝑔 is a subgraph of 𝐺”.
Notes: -
1) Every graph is its own subgraph.
2) A single vertex in a graph 𝐺 is a subgraph of 𝐺.
3) A single edge in 𝐺, together with its end vertices, is also a subgraph of 𝐺.

Spanning subgraphs:- A subgraph 𝑔 of 𝐺 is called a spanning subgraph of 𝐺


if and only if .𝑉(𝑔) = 𝑉(𝐺).
Example: -
𝑎 b
𝐺: e

c 𝑑
spanning subgraphs
𝑎 𝑏 𝑎 𝑏 𝑎 𝑏
(1) 𝑒 (2) 𝑒 (3) 𝒆

𝑐 𝑑 𝑐 𝑑 𝑐 𝑑
Edge disjoint subgraphs: - Two (or more) subgraphs 𝑔1 and 𝑔2 of a graph 𝐺
are said to be edge disjoint if 𝑔1 and 𝑔2 do not have any edge in common.
Example: -
𝑎 1 𝑏 𝑎 1 𝑏
𝐺: 2 3 4 𝒈𝟏 : 3 4 𝒈𝟐 : 𝑐 5 𝑑

𝑐 5 𝑑 𝑑
21

Vertex disjoint subgraphs: - Two subgraphs 𝑔1 and 𝑔2 of a graph 𝐺 are said to


be vertex disjoint if 𝑔1 and 𝑔2 do not have any common vertex, there by cannot
have edges in common.
Example: -
𝑎 4 𝑑 𝑑 𝑎
𝐺: 𝒈𝟏 : 𝒈𝟐 :
1 2 5 2 5 1
𝑏 3 𝑐 6 𝑒 𝑐 6 𝑒 𝑏

Induced subgraph: - A subgraph obtained only when vertex deletion is called


an induced subgraph.
Example: -
𝑎 𝑑
𝐺:
𝑏 𝑐
Induced subgraphs
𝑎 𝑑 𝑑 𝑎 𝑎 𝑑

𝑐 𝑏 𝑐 𝑏 𝑐 𝑏
𝐺 -𝑣𝑒𝑟𝑡𝑒𝑥 𝑏 𝐺 -𝑣𝑒𝑟𝑡𝑒𝑥 𝑎 𝐺 -𝑣𝑒𝑟𝑡𝑒𝑥 𝑑 𝐺 -𝑣𝑒𝑟𝑡𝑒𝑥 𝑐
The following graph is not an induced subgraph of 𝐺
. 𝑎 𝑑
The vertices 𝑏 and 𝑑 are present but the edge
𝑏 𝑐 {𝑏, 𝑑} of 𝐺 is not present.
Walk
A walk is defined as a finite alternating sequence of vertices and edges
beginning and ending with vertices such that each edge is incident with the
vertices preceeding and following it.
22

If there is no repetition of edges in a walk then it is a trail.


In the following figure 𝒗𝟏 𝒂 𝒗𝟐 𝒃 𝒗𝟑 𝒄 𝒗𝟑 𝒅 𝒗𝟒 𝒆 𝒗𝟐 𝒇 𝒗𝟓 is a walk.
𝒗𝟏
𝑐 𝑔 𝑎
𝒗𝟑 𝑏 𝒗𝟐
𝑓
𝑑 𝑒
𝒗𝟒 ℎ 𝒗𝟓
Notes: -
• A walk is also reffered to as an edge train or a chain.
• A set of vertices and edges constituting a given walk in a graph 𝐺 is
clearly a subgraph of 𝑮.
• Vertices with which a walk begins and ends are called its terminal
vertices.

• If length of the walk = 0, then it is called as a Trivial Walk.

• A walk which begins and ends at the same vertex is called a closed walk.
• A walk which begins and ends at different vertices is called an open
walk.

Example: -

𝒗𝟐 𝒗𝟒

𝒂 𝒃 𝒄 𝒅

𝒗𝟏 𝒗𝟑 𝒆 𝒗𝟓

Walk − 𝑣1 𝑎 𝑣2 𝑏 𝑣3 𝑐 𝑣4 𝑑 𝑣5 𝑒 𝑣3
23

Open walk - (𝑎) 𝑣1 a 𝑣2 𝑏 𝑣3 𝑐 𝑣4 𝑑 𝑣5 𝑒 𝑣3


(b) 𝑣1 a 𝑣2 𝑏 𝑣3 𝑐 𝑣4 𝑑 𝑣5

Closed walk - 𝑣3 𝑐 𝑣4 𝑑 𝑣5 𝑒 𝑣3

Path
An open walk in which no vertex appears more than once is called path.
The number of edges in the path is called length of a path.
Notes: -
• A path doesnot intersect itself.
• Self loop can be included in a walk but not in a path.
• The terminal vertices of a path are of degree one, and the intermediate
vertices are of degree two.

Example: -

Path - 𝑉1 𝑒1 𝑉2 𝑒2 𝑉3 𝑒3 𝑉4 𝑒4 𝑉5 𝑒5 𝑉6 𝑒6 𝑉7
Length of the path = Number of edges = 6

Circuit (Cycle)
A closed walk in which no vertex (except initial and final vertex) appears more
than once is called a circuit. That is, a circuit is a closed, nonintersecting walk.
Note: -
• A circuit is also called a cycle, elementary cycle, circular path, and
polygon.
24

Example: -

Circuit or Cycle : 𝑉1 𝑒1 𝑉2 𝑒2 𝑉3 𝑒3 𝑉4 𝑒4 𝑉1

Connected graph
Connected graph
A graph G is said to be connected if there is at least one path between every
pair of vertices in G. Otherwise, G is disconnected.
Example: -

𝑣1 𝑒4 𝑣2 𝑒8 𝑣1 𝑣2
𝑒3 𝑒2 𝑒3
𝑒1 𝑒2 𝑒5 𝑒1 𝑒5 𝑣5
.𝑣3 𝑒6 𝑣4 𝑒7 𝑣5 𝑣3 𝑒6 𝑣6 𝑣4
Connected Graph G Disconnected Graph H
Components of graph
A disconnected graph consists of two or more connected graphs. Each of these
connected subgraphs is called a component.
Example: -

1) .𝑣1 𝑣2

𝑒1 𝑒2 𝑒3 𝑒5 𝑣5

𝑣3 𝑒6 𝑣6 𝑣4
Disconnected Graph H with 3 components
25

2) a
g h i){a, b, c}
d e ii){d, e, f}
j iii){g, h, i}
b c iv){j}
i f
Disconnected Graph contains 4 components
Questions

1) Suppose G is a non-directed graph with 12 edges. If G has 6 vertices each of

degree 3 and the rest have degree less than 3. What is the minimum number of

vertices that G can have?

Solution: -
Given, 𝑒 = |𝐸| = 12
|𝑉| = 𝑛 (assume)
.∑ 𝑑𝑒𝑔(𝑣𝑖 ) ≤ 6 × 3 + (𝑛 − 6) × 2 𝑑𝑒𝑔 < 3 𝑑𝑒𝑔 ≤2

.≤ 18 + 2𝑛 − 12
.≤ 6 + 2𝑛 (1)
By fundamental theorem we know that,
∑ 𝑑𝑒𝑔(𝑣𝑖 ) = 2𝑒 = 2 × 12 = 24
Then from (1)

.24. ≤ 6 + 2𝑛

.24. −6 ≤ 2𝑛

.18 ≤ 2𝑛
18
.𝑛 ≥
2
26

.𝑛 ≥ 9

Thus, the minimum number of vertices of G is 9.

2) Does there exist a simple graph with 7 vertices having degrees 1,3,3,4,5,6,6.

Solution: -
Suppose there exist a graph with 7 vertices satisfying given properties. Since 2
vertices are having degree 6, each of these two vertices are adjacent to every other
vertex.

Solution: -
Given, 𝑒 = |𝐸| = 12
|𝑉| = 𝑛 (assume)
.∑ 𝑑𝑒𝑔(𝑣𝑖 ) ≤ 6 × 3 + (𝑛 − 6) × 2 𝑑𝑒𝑔 < 3 𝑑𝑒𝑔 ≤2

.≤ 18 + 2𝑛 − 12
.≤ 6 + 2𝑛 (1)
By fundamental theorem we know that,
∑ 𝑑𝑒𝑔(𝑣𝑖 ) = 2𝑒 = 2 × 12 = 24
Then from (1)

.24. ≤ 6 + 2𝑛

.24. −6 ≤ 2𝑛

.18 ≤ 2𝑛
18
.𝑛 ≥
2

.𝑛 ≥ 9

Thus, the minimum number of vertices of G is 9.

3) Does there exist a simple graph with 7 vertices having degrees 1,3,3,4,5,6,6.

Solution: -
27

Suppose there exist a graph with 7 vertices satisfying given properties. Since 2
vertices are having degree 6, each of these two vertices are adjacent to every other
vertex.

𝑣2 𝑣3 𝑣4

𝑣1 𝑣5

𝑣7 𝑣6
Here deg (𝑣1 ) = deg (𝑣5 ) = 6
Degree of all other vertices is 2, which mean that there is no vertex with
degree 1.
It is not possible.
Hence there does not exist a simple graph with the given properties.

Theorem 2.1
A graph G is disconnected if and only if its vertex set V can be partitioned into
two non-empty, disjoint subsets 𝑉1 & 𝑉2 such that there exists no edge in G
whose one end vertex is in subset 𝑉1 & the other in subset 𝑉2 .
Proof: -
Suppose that such a partitioning exists. Consider two arbitrary vertices a and b
in G, such that a ∈ 𝑽𝟏 and b ∈ 𝑽𝟐 . No path can be existing between vertices a
and b, otherwise there would be at least one edge whose one end vertex would
be in 𝑉1 and the other in 𝑉2. Hence if partition exists, G is not connected. i.e;
disconnected.
Conversely, let G be disconnected graph. Consider a vertex a in G. Let 𝑉1 be
the set of all vertices that are joined by the paths to a. Since G is disconnected
28

, 𝑉1 does not include all vertices of G. The remaining vertices will form a
nonempty set 𝑉2 . No vertex in 𝑉1 is joined to any in 𝑉2 by an edge. Hence the
partition.

Theorem 2.2
If a graph G (connected or disconnected) has exactly two vertices of odd degree,
there is a path joining these two vertices.
Proof: -
Let G be any graph with all even degree vertices except the two vertices 𝑢 and
𝑣 which are odd.
Case (i) Let G be connected.
A graph is said to be connected if every pair of vertices in
the graph is connected. This means that there is a path between every pair of
vertices. Thus, in this case there is a path exist between 𝑢 and 𝑣.
Case (ii) Let G be disconnected.
If G is disconnected, then at least two components exist. We know that each
components of G are connected. Let C be a connected component of G containing
the vertex 𝑢. Since, the number of vertices of odd degree in any graph is even, C
has to contain another vertex of odd degree. But, then 𝑣 is the only other vertex
in G of odd degree and hence 𝑣 lies in the component C. Thus, there is a path
from 𝑢 to 𝑣.
Theorem 2.3
The maximum number of edges in a simple disconnected graph G with n
(𝑛−𝑘)(𝑛−𝑘+1)
vertices and k components is .
2

Proof: -
Let the number of vertices in each of the k components of a graph be
𝑛1 , 𝑛2 , ………, 𝑛𝑘
Then 𝑛1 +𝑛2 + ………+ 𝑛𝑘 = 𝑛 or ∑𝑘𝑖=1 𝑛𝑖 = 𝑛 ………………. (1)
29

Hence, ( 𝑛1 − 1) + (𝑛2 − 1) + ………+ (𝑛𝑘 − 1) = 𝑛 − 𝑘


Squaring both sides,
[( 𝑛1 − 1) + (𝑛2 − 1) + … … … + (𝑛𝑘 − 1)]2 = (n − k )2

( 𝑛1 − 1)2 + (𝑛2 − 1)2 + (𝑛3 − 1)2 + (𝑛4 − 1)2 + ⋯ ⋯ ⋯ + 2( 𝑛1 − 1)(𝑛2 −


1) + 2 (𝑛1 − 1)(𝑛3 − 1) + 2( 𝑛1 − 1)(𝑛4 − 1) + ⋯ ⋯ ⋯
= 𝑛2 − 2𝑛𝑘 + 𝑘 2

Neglect 2( 𝑛1 − 1)(𝑛2 − 1) + 2 (𝑛1 − 1)(𝑛3 − 1) + 2( 𝑛1 − 1)(𝑛4 − 1) +


⋯ ⋯ ⋯ terms. Here all neglecting terms are positive.
Then,
( 𝑛1 − 1)2 + (𝑛2 − 1)2 + (𝑛3 − 1)2 + (𝑛4 − 1)2 + ⋯ ⋯ ⋯ ≤ 𝑛2 + 2𝑛𝑘 + 𝑘 2
(𝑛1 2 - 2𝑛1 +1) + (𝑛2 2 - 2𝑛2 +1) +(𝑛3 2 - 2𝑛3 +1) + ⋯ ⋯ ⋯ ≤ 𝑛2 + 2𝑛𝑘 + 𝑘 2
(𝑛1 2 + 𝑛2 2 + 𝑛3 2 +⋯ ⋯)−2 (𝑛1 + 𝑛2 +𝑛3 + ⋯ ⋯ ) + (1+1+1⋯ ⋯ ⋯k times) ≤
.𝑛2 + 2𝑛𝑘 + 𝑘 2
∑𝒌𝒊=𝟏 𝑛𝑖 2 - 2 ∑𝒌𝒊=𝟏 𝑛𝑖 +∑𝒌𝒊=𝟏(1) ≤ 𝑛2 − 2𝑛𝑘 + 𝑘 2
∑𝑘𝑖=1 𝑛𝑖 2 - 2 𝑛 +𝑘 ≤ 𝑛2 − 2𝑛𝑘 + 𝑘 2
∑𝑘𝑖=1 𝑛𝑖 2 ≤ 𝑛2 − 2𝑛𝑘 + 𝑘 2 + 2 𝑛 - 𝑘 ……………. (2)
1
Now the maximum number of edges in the 𝑖 𝑡ℎ component of G = 𝑛𝑖 (𝑛𝑖 − 1)
2
1
∴ Maximum number of edges of G = ∑𝑘𝑖=1 𝑛𝑖 (𝑛𝑖 − 1)
2
1 1
= ∑𝑘𝑖=1 𝑛𝑖 2 - ∑𝑘𝑖=1 𝑛𝑖
2 2
1 1
= ∑𝑘𝑖=1 𝑛𝑖 2 - 𝑛 by (1)
2 2
1 1
≤ [𝑛2 − 2𝑛𝑘 + 𝑘 2 + 2 𝒏 - 𝒌 ] - 𝑛 , by (2)
2 2
1
≤ [𝑛2 − 2𝑛𝑘 + 𝑘 2 + 2 𝒏 - 𝒌 -n]
2
1
≤ [𝒏𝟐 − 𝟐𝒏𝒌 + 𝒌𝟐 + 𝒏 - 𝒌 ]
2
𝟏
≤ [(𝒏 − 𝒌)𝟐+ 𝒏 - 𝒌 ]
𝟐
𝟏
≤ (𝒏 - 𝒌) (n - k+ 1)
𝟐
30

Application of Graph theory


Graph theory has a wide range of appplications in Engineering, in physical, social
and biological sciences and numerous other areas because of its simplicity.

A graph can be used to represent almost any physical situation involving discrete
objects and can draw a relationship among them. Few examples of such
applications are :

1) Konigsberg Bridge Problem

Konigsberg bridge problem is the best known example in graph theory .

It was a long-standing problem until solved by Euler in 1976. The problem is


depicted in thefollowing figure.

Two islands C ans D formed by Pregel river in Konigsberg were connected


to each other and to the banks A and B with 7 bridges. The problem was : To start
at any 4 land areas of the city A,B,C or D and walk over each the 7 bridges exactly
once, and returned to the starting point (without swimming across the river).

Euler represented this situation by means of a graph. The vertices


represents the land areas and the edges represent the bridges. Euler proved that a
solution for this problem doesn’t exist .
31

2) Utilities Problem

There are 3 houses 𝐻1 , 𝐻2 and 𝐻3 . Each to be connected to each of the 3 utilities


– Water(W),gas (G), and electricity(E ) by means of conduits.

The problem is “ Is it possible to make such connection without any crossovers


of the conduits, the problem is depicted in the following figure.

The problem can be represented by means of a graph. The conduits are shown as
edges and the houses, utilities are represented as vertices.
32

The graph cannot be drawn in the plane without edges crossing over, thus the
answer to the problem is “No”.

3) Seating Problem
Nine members of a new club meet each day for lunch at a round table. They
decided to sit such that every member has different neighbours at each lunch.
How many ways can these arrangement possible.
This situation can be represented by means of a graph with 9 vertices such at each
vertex represents a member,and an edge joining two vertices represents the
relationship of siting next to each other.

Given figure shows two different arrangements. They are 1234567891 (solid
lines) and 1352749681 (dashed lines).
It can be represented by graph- theoretic considerations that there are only two
more arrangements possible. They are 1573928461 and 1795836241. Ingeneral it
𝑛−1
can be shown that for n people the number of such arrangements is when is
2
𝑛−2
odd and when n is even.
2

4) Electrical Network Problem:


The Electrical network analysis and synthesis is based on network topology. The
topology of the network is connecting the elements- resistor, inductor, capacitor,
etc.together to form the network. The advantages of this approch is applying
graph theory to electrical network. The topology of this network is studied by
33

means of its graph. In drawing the graph of an electical network, the juctions are
represented by vertices and branches are represented by edges.

An electrical network and its graph is shown below.

You might also like