Chapter Three
Elements of Graph Theory
Fikre Bogale
Addis Ababa University
Mathematics Department
January 23, 2023
1/59
Fikre Bogale Chapter Three Elements of Graph Theory
Outline
Outline
Introduction
Definitions and Examples of a Graph
Matrix Representations of a Graph
Isomorphic Graphs
Path and Connectivity of Graphs
Special Types of Graphs
Graph Coloring
2/59
Fikre Bogale Chapter Three Elements of Graph Theory
Outline
Outline
Introduction
Definitions and Examples of a Graph
Matrix Representations of a Graph
Isomorphic Graphs
Path and Connectivity of Graphs
Special Types of Graphs
Graph Coloring
2/59
Fikre Bogale Chapter Three Elements of Graph Theory
Outline
Outline
Introduction
Definitions and Examples of a Graph
Matrix Representations of a Graph
Isomorphic Graphs
Path and Connectivity of Graphs
Special Types of Graphs
Graph Coloring
2/59
Fikre Bogale Chapter Three Elements of Graph Theory
Outline
Outline
Introduction
Definitions and Examples of a Graph
Matrix Representations of a Graph
Isomorphic Graphs
Path and Connectivity of Graphs
Special Types of Graphs
Graph Coloring
2/59
Fikre Bogale Chapter Three Elements of Graph Theory
Outline
Outline
Introduction
Definitions and Examples of a Graph
Matrix Representations of a Graph
Isomorphic Graphs
Path and Connectivity of Graphs
Special Types of Graphs
Graph Coloring
2/59
Fikre Bogale Chapter Three Elements of Graph Theory
Outline
Outline
Introduction
Definitions and Examples of a Graph
Matrix Representations of a Graph
Isomorphic Graphs
Path and Connectivity of Graphs
Special Types of Graphs
Graph Coloring
2/59
Fikre Bogale Chapter Three Elements of Graph Theory
Outline
Outline
Introduction
Definitions and Examples of a Graph
Matrix Representations of a Graph
Isomorphic Graphs
Path and Connectivity of Graphs
Special Types of Graphs
Graph Coloring
2/59
Fikre Bogale Chapter Three Elements of Graph Theory
Introduction
Graph Theory is a branch of mathematics that deals with
arrangements of certain objects and relationships between
these objects.
Graph Theory is broadly classified into two: nondirected
graphs and directed graphs (digraphs).
Graph Theory, is an old subject with many model applications,
which has numerous applications to such diverse areas as
computer sciences, engineering, linguistics and management
science.
Graphs are discrete structure consisting of vertices and edges
that connect these vertices.
There are several different types of graphs that differ with
respect to the kind and number of edges that can connect a
pair of vertices.
3/59
Fikre Bogale Chapter Three Elements of Graph Theory
Introduction
Graph Theory is a branch of mathematics that deals with
arrangements of certain objects and relationships between
these objects.
Graph Theory is broadly classified into two: nondirected
graphs and directed graphs (digraphs).
Graph Theory, is an old subject with many model applications,
which has numerous applications to such diverse areas as
computer sciences, engineering, linguistics and management
science.
Graphs are discrete structure consisting of vertices and edges
that connect these vertices.
There are several different types of graphs that differ with
respect to the kind and number of edges that can connect a
pair of vertices.
3/59
Fikre Bogale Chapter Three Elements of Graph Theory
Introduction
Graph Theory is a branch of mathematics that deals with
arrangements of certain objects and relationships between
these objects.
Graph Theory is broadly classified into two: nondirected
graphs and directed graphs (digraphs).
Graph Theory, is an old subject with many model applications,
which has numerous applications to such diverse areas as
computer sciences, engineering, linguistics and management
science.
Graphs are discrete structure consisting of vertices and edges
that connect these vertices.
There are several different types of graphs that differ with
respect to the kind and number of edges that can connect a
pair of vertices.
3/59
Fikre Bogale Chapter Three Elements of Graph Theory
Introduction
Graph Theory is a branch of mathematics that deals with
arrangements of certain objects and relationships between
these objects.
Graph Theory is broadly classified into two: nondirected
graphs and directed graphs (digraphs).
Graph Theory, is an old subject with many model applications,
which has numerous applications to such diverse areas as
computer sciences, engineering, linguistics and management
science.
Graphs are discrete structure consisting of vertices and edges
that connect these vertices.
There are several different types of graphs that differ with
respect to the kind and number of edges that can connect a
pair of vertices.
3/59
Fikre Bogale Chapter Three Elements of Graph Theory
Introduction
Graph Theory is a branch of mathematics that deals with
arrangements of certain objects and relationships between
these objects.
Graph Theory is broadly classified into two: nondirected
graphs and directed graphs (digraphs).
Graph Theory, is an old subject with many model applications,
which has numerous applications to such diverse areas as
computer sciences, engineering, linguistics and management
science.
Graphs are discrete structure consisting of vertices and edges
that connect these vertices.
There are several different types of graphs that differ with
respect to the kind and number of edges that can connect a
pair of vertices.
3/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Definition
A Graph G is a pair (V , E ) of sets where
A set V = V (G ) whose elements are called vertices,
points or nodes of G
A set E = E (G ) called edges of G .
Edge is a line segment or arc which connecting either one
or two vertices, called its endpoints. The edge e
connecting vertices u and v is denoted by e = {u, v } or
e = uv , then u and v are said to be the endponts of e.
Graphs are represented pictorially by drawing dots(or
circles) for the vertices and joining two dots if the
corresponding vertices form an edge.
4/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Definition
A Graph G is a pair (V , E ) of sets where
A set V = V (G ) whose elements are called vertices,
points or nodes of G
A set E = E (G ) called edges of G .
Edge is a line segment or arc which connecting either one
or two vertices, called its endpoints. The edge e
connecting vertices u and v is denoted by e = {u, v } or
e = uv , then u and v are said to be the endponts of e.
Graphs are represented pictorially by drawing dots(or
circles) for the vertices and joining two dots if the
corresponding vertices form an edge.
4/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Example
Let V = {a, b, c, d} be set of vertices. Then the following are
examples of graphs with four vertices.
5/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Definition
An edge whose starting and ending vertex is the same is called
loop.
Definition
Two vertices vi and vj are said to be adjacent if there exists an
edge between (connecting) them.
Definition
Two edges ei and ej are said to be adjacent if they have a
common vertex (endpoint).
Definition
An isolated vertex is a vertex which is not adjacent to any
vertex. A vertex which isn’t connected to any vertex.
6/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Definition
An edge whose starting and ending vertex is the same is called
loop.
Definition
Two vertices vi and vj are said to be adjacent if there exists an
edge between (connecting) them.
Definition
Two edges ei and ej are said to be adjacent if they have a
common vertex (endpoint).
Definition
An isolated vertex is a vertex which is not adjacent to any
vertex. A vertex which isn’t connected to any vertex.
6/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Definition
An edge whose starting and ending vertex is the same is called
loop.
Definition
Two vertices vi and vj are said to be adjacent if there exists an
edge between (connecting) them.
Definition
Two edges ei and ej are said to be adjacent if they have a
common vertex (endpoint).
Definition
An isolated vertex is a vertex which is not adjacent to any
vertex. A vertex which isn’t connected to any vertex.
6/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Definition
An edge whose starting and ending vertex is the same is called
loop.
Definition
Two vertices vi and vj are said to be adjacent if there exists an
edge between (connecting) them.
Definition
Two edges ei and ej are said to be adjacent if they have a
common vertex (endpoint).
Definition
An isolated vertex is a vertex which is not adjacent to any
vertex. A vertex which isn’t connected to any vertex.
6/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Definition
An edge e is incident with a vertex v if v is an endpoint of the
edge e.
Definition
If there exist more than one edge between the same pair of
vertices, then the edges are called parallel (or multiple) edges.
Definition
The number of vertices in a graph G (V , E ) is called the order
of graph and denoted by |V | or |G |.
Definition
The number of edges in a graph G (V , E ) is called the size of
a graph and denoted by |E | or kG k.
7/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Definition
An edge e is incident with a vertex v if v is an endpoint of the
edge e.
Definition
If there exist more than one edge between the same pair of
vertices, then the edges are called parallel (or multiple) edges.
Definition
The number of vertices in a graph G (V , E ) is called the order
of graph and denoted by |V | or |G |.
Definition
The number of edges in a graph G (V , E ) is called the size of
a graph and denoted by |E | or kG k.
7/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Definition
An edge e is incident with a vertex v if v is an endpoint of the
edge e.
Definition
If there exist more than one edge between the same pair of
vertices, then the edges are called parallel (or multiple) edges.
Definition
The number of vertices in a graph G (V , E ) is called the order
of graph and denoted by |V | or |G |.
Definition
The number of edges in a graph G (V , E ) is called the size of
a graph and denoted by |E | or kG k.
7/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition and Examples of a Graph
Definition
An edge e is incident with a vertex v if v is an endpoint of the
edge e.
Definition
If there exist more than one edge between the same pair of
vertices, then the edges are called parallel (or multiple) edges.
Definition
The number of vertices in a graph G (V , E ) is called the order
of graph and denoted by |V | or |G |.
Definition
The number of edges in a graph G (V , E ) is called the size of
a graph and denoted by |E | or kG k.
7/59
Fikre Bogale Chapter Three Elements of Graph Theory
Definition
The degree of a vertex vi in a graph G is the number of edges
having the vertex vi as an end point (meeting at vi ) and
denoted by deg (vi ).
Example:Let V = {v1 , v2 , v3 , v4 , v5 } be set of vertices and
E = {e1 , e2 , e3 , e4 , e5 , e6 } be set of edges. Consider the graph
8/59
Fikre Bogale Chapter Three Elements of Graph Theory
Graph Theory
Then from the above graph we have
The order |G | of G is 5 and the size kG k of G is 6.
v1 and v2 , v2 and v4 , v4 and v3 are adjacent vertices.
e1 and e2 , e1 , e2 and e3 , e4 , e5 and e6 are adjacent edges.
e1 is incident with v1 .
e1 and e2 , e4 , e5 and e6 are parallel (multiple) edges.
deg (v1 ) = 2, deg (v2 ) = 3, deg (v3 ) = 3, deg (v4 ) = 4 and
deg (v5 ) = 0.
v5 is an isolated vertex.
A vertex is said to be even if its degree is even number and
odd if its degree is odd number. A vertex of degree zero is
called isolated vertex. A vertex of degree one is called pendant
vertex. 9/59
Fikre Bogale Chapter Three Elements of Graph Theory
Graph Theory
Then from the above graph we have
The order |G | of G is 5 and the size kG k of G is 6.
v1 and v2 , v2 and v4 , v4 and v3 are adjacent vertices.
e1 and e2 , e1 , e2 and e3 , e4 , e5 and e6 are adjacent edges.
e1 is incident with v1 .
e1 and e2 , e4 , e5 and e6 are parallel (multiple) edges.
deg (v1 ) = 2, deg (v2 ) = 3, deg (v3 ) = 3, deg (v4 ) = 4 and
deg (v5 ) = 0.
v5 is an isolated vertex.
A vertex is said to be even if its degree is even number and
odd if its degree is odd number. A vertex of degree zero is
called isolated vertex. A vertex of degree one is called pendant
vertex. 9/59
Fikre Bogale Chapter Three Elements of Graph Theory
Types of Graphs
Definition
A graph G without both loop and parallel edges is called
simple graph.
Definition
A graph G which consists of parallel (multiple edges) is called
a multi graph
Definition
A graph G is said to be Pseudo graph if it has a loop.
Definition
A simple graph with an edge between every two distinct
vertices is called a complete graph.
10/59
Fikre Bogale Chapter Three Elements of Graph Theory
Types of Graphs
Definition
A graph G without both loop and parallel edges is called
simple graph.
Definition
A graph G which consists of parallel (multiple edges) is called
a multi graph
Definition
A graph G is said to be Pseudo graph if it has a loop.
Definition
A simple graph with an edge between every two distinct
vertices is called a complete graph.
10/59
Fikre Bogale Chapter Three Elements of Graph Theory
Types of Graphs
Definition
A graph G without both loop and parallel edges is called
simple graph.
Definition
A graph G which consists of parallel (multiple edges) is called
a multi graph
Definition
A graph G is said to be Pseudo graph if it has a loop.
Definition
A simple graph with an edge between every two distinct
vertices is called a complete graph.
10/59
Fikre Bogale Chapter Three Elements of Graph Theory
Types of Graphs
Definition
A graph G without both loop and parallel edges is called
simple graph.
Definition
A graph G which consists of parallel (multiple edges) is called
a multi graph
Definition
A graph G is said to be Pseudo graph if it has a loop.
Definition
A simple graph with an edge between every two distinct
vertices is called a complete graph.
10/59
Fikre Bogale Chapter Three Elements of Graph Theory
Examples on Types of Graph
Example 1: Consider the following graphs
The graphs G1 and G2 are simple graphs. Moreover the graph
G2 is complete, but G1 is not complete graph.
11/59
Fikre Bogale Chapter Three Elements of Graph Theory
Types of Graphs
The graph G4 is complete, but G3 is not complete graph
because it is not simple graph. The graph G3 is a multi-graph.
Note
A complete graph with n vertices is denoted by Kn .
The Graph G2 can be denoted by K4 and G4 by K3 .
12/59
Fikre Bogale Chapter Three Elements of Graph Theory
Types of Graphs
The graph G4 is complete, but G3 is not complete graph
because it is not simple graph. The graph G3 is a multi-graph.
Note
A complete graph with n vertices is denoted by Kn .
The Graph G2 can be denoted by K4 and G4 by K3 .
12/59
Fikre Bogale Chapter Three Elements of Graph Theory
Types of Graphs
The graph G5 is pseudo graph, but not simple graph. Because
it has loop at the vertex v1 .
deg (v1 ) = 4, deg (v2 ) = 2 and deg (v3 ) = 2.
13/59
Fikre Bogale Chapter Three Elements of Graph Theory
The Handshaking Lemma
Let |E | denotes the number of edges of a graph G with n
n
P
vertices v1 , v2 , · · · , vn . Then deg (vi ) = 2|E |
i=1
The lemma follows from the fact that if we add the degrees of
all the vertices, every edge will be counted twice, since each
edge is incident to two vertices.
Corollary
In any graph G , the number of vertices of odd degree is even.
Example
1 How many edges are there in a graph with 10 vertices
each has degree 4.
2 If a graph G has 8 edges with 2 vertices of degree 4 each
and all others are of degree 2 each, and then find the
number of vertices |V |. 14/59
Fikre Bogale Chapter Three Elements of Graph Theory
The Handshaking Lemma
Let |E | denotes the number of edges of a graph G with n
n
P
vertices v1 , v2 , · · · , vn . Then deg (vi ) = 2|E |
i=1
The lemma follows from the fact that if we add the degrees of
all the vertices, every edge will be counted twice, since each
edge is incident to two vertices.
Corollary
In any graph G , the number of vertices of odd degree is even.
Example
1 How many edges are there in a graph with 10 vertices
each has degree 4.
2 If a graph G has 8 edges with 2 vertices of degree 4 each
and all others are of degree 2 each, and then find the
number of vertices |V |. 14/59
Fikre Bogale Chapter Three Elements of Graph Theory
The Handshaking Lemma
Let |E | denotes the number of edges of a graph G with n
n
P
vertices v1 , v2 , · · · , vn . Then deg (vi ) = 2|E |
i=1
The lemma follows from the fact that if we add the degrees of
all the vertices, every edge will be counted twice, since each
edge is incident to two vertices.
Corollary
In any graph G , the number of vertices of odd degree is even.
Example
1 How many edges are there in a graph with 10 vertices
each has degree 4.
2 If a graph G has 8 edges with 2 vertices of degree 4 each
and all others are of degree 2 each, and then find the
number of vertices |V |. 14/59
Fikre Bogale Chapter Three Elements of Graph Theory
Solution
1 Let |E | be number of edges and each vertices has degree
4. Then
10
X 10
X
2|E | = deg (vi ) = 4 = 4(10) = 40 ⇒ e = 20
i=1 i=1
2 Let k be the number of vertices with degree 2, then
4(2) + 2(k) = 2(8) = 16 ⇒ k = 4
Hence, there are |V | = 6 vertices in the graph.
Definition
Let G = (V , E ) be a graph with V = {v1 , v2 , · · · , vn }. The
degree sequence of G is a non-decreasing sequence of the
degrees of the verices.
15/59
Fikre Bogale Chapter Three Elements of Graph Theory
Note
The sum of degree of vertices of a graph must be even. Is
there a graph with degree sequence 2, 2, 3, 4, 5, 7?
Definition
A degree sequence is said to be graphic if it is a degree
sequence of a simple graph.
Definition
A graph is said to be regular if all its vertices have equal
degree. If the degree of each vertex is d, then we call the
graph d-regular graph (regular of degree d).
Note
Every complete graphs are regular graphs, but regular graphs
may not be complete.
16/59
Fikre Bogale Chapter Three Elements of Graph Theory
Note
The sum of degree of vertices of a graph must be even. Is
there a graph with degree sequence 2, 2, 3, 4, 5, 7?
Definition
A degree sequence is said to be graphic if it is a degree
sequence of a simple graph.
Definition
A graph is said to be regular if all its vertices have equal
degree. If the degree of each vertex is d, then we call the
graph d-regular graph (regular of degree d).
Note
Every complete graphs are regular graphs, but regular graphs
may not be complete.
16/59
Fikre Bogale Chapter Three Elements of Graph Theory
Note
The sum of degree of vertices of a graph must be even. Is
there a graph with degree sequence 2, 2, 3, 4, 5, 7?
Definition
A degree sequence is said to be graphic if it is a degree
sequence of a simple graph.
Definition
A graph is said to be regular if all its vertices have equal
degree. If the degree of each vertex is d, then we call the
graph d-regular graph (regular of degree d).
Note
Every complete graphs are regular graphs, but regular graphs
may not be complete.
16/59
Fikre Bogale Chapter Three Elements of Graph Theory
Regular and Complete graphs
Graphs G and H are regular graphs. Moreover, G is a
complete graph, but H not.
17/59
Fikre Bogale Chapter Three Elements of Graph Theory
Matrix Representation of Graphs
Graphs can be represented by two different types of matrices:
1 Adjacency matrix- a matrix that describes the adjacency
relationships between vertices of a graph.
2 Incidence matrix- a matrix that describes the incidence
relationships between edges and vertices of a graph.
Adjacency Matrix
Suppose G is a graph with n vertices and suppose the vertices
have been ordered, say {v1 , v2 , · · · , vn }. Then the adjacency
matrix A = [aij ] of the graph G is an n × n matrix defined by
(
m, if there are m edges joining vi and vj
aij =
0, otherwise
18/59
Fikre Bogale Chapter Three Elements of Graph Theory
Matrix Representation of Graphs
Graphs can be represented by two different types of matrices:
1 Adjacency matrix- a matrix that describes the adjacency
relationships between vertices of a graph.
2 Incidence matrix- a matrix that describes the incidence
relationships between edges and vertices of a graph.
Adjacency Matrix
Suppose G is a graph with n vertices and suppose the vertices
have been ordered, say {v1 , v2 , · · · , vn }. Then the adjacency
matrix A = [aij ] of the graph G is an n × n matrix defined by
(
m, if there are m edges joining vi and vj
aij =
0, otherwise
18/59
Fikre Bogale Chapter Three Elements of Graph Theory
Matrix Representation of Graphs
Graphs can be represented by two different types of matrices:
1 Adjacency matrix- a matrix that describes the adjacency
relationships between vertices of a graph.
2 Incidence matrix- a matrix that describes the incidence
relationships between edges and vertices of a graph.
Adjacency Matrix
Suppose G is a graph with n vertices and suppose the vertices
have been ordered, say {v1 , v2 , · · · , vn }. Then the adjacency
matrix A = [aij ] of the graph G is an n × n matrix defined by
(
m, if there are m edges joining vi and vj
aij =
0, otherwise
18/59
Fikre Bogale Chapter Three Elements of Graph Theory
Example
1 Write the adjacency matrix of the graphs
(a) (b)
2 Draw the graphs
with the
adjacency
matrix
0 1 1 1 0 3 0 2
1 0 0 1
(b) 3 0 1 1
(a)
1 0 0 1 0 1 1 2
1 1 1 0 2 1 2 0
19/59
Fikre Bogale Chapter Three Elements of Graph Theory
Solution
1 Since the graphs have 4 vertices. Then we will have 4 × 4
matrices
0 1 1 1 1 2 1 0
1 0 1 0 2 1 0 2
1 1 0 0 (b) 1 0 0 2
(a)
1 0 0 0 0 2 2 1
2 Since the matrices are 4 × 4. Then the graphs have 4
vertices
(a) (b)
3 Note that an adjacency matrix is always a symmetric
matrix. 20/59
Fikre Bogale Chapter Three Elements of Graph Theory
Solution
1 Since the graphs have 4 vertices. Then we will have 4 × 4
matrices
0 1 1 1 1 2 1 0
1 0 1 0 2 1 0 2
1 1 0 0 (b) 1 0 0 2
(a)
1 0 0 0 0 2 2 1
2 Since the matrices are 4 × 4. Then the graphs have 4
vertices
(a) (b)
3 Note that an adjacency matrix is always a symmetric
matrix. 20/59
Fikre Bogale Chapter Three Elements of Graph Theory
Matrix Representation of Graphs
Another common way to represent graphs is to use incidence
matrix
Incidence Matrix
Let G = (V , E ) be a graph with V = {v1 , v2 , · · · vn } and
E = {e1 , e2 , · · · , em }. Then the incidence matrix of the graph
G is an n × m matrix B = [bij ] with:
(
1, if edge ej is incidence with vi
bij =
0, otherwise
Note
The incident matrix of a graph is not necessary a square
and symmetric matrix.
An incident matrix B has a row each vertex and a column
of each edge. 21/59
Fikre Bogale Chapter Three Elements of Graph Theory
Matrix Representation of Graphs
Another common way to represent graphs is to use incidence
matrix
Incidence Matrix
Let G = (V , E ) be a graph with V = {v1 , v2 , · · · vn } and
E = {e1 , e2 , · · · , em }. Then the incidence matrix of the graph
G is an n × m matrix B = [bij ] with:
(
1, if edge ej is incidence with vi
bij =
0, otherwise
Note
The incident matrix of a graph is not necessary a square
and symmetric matrix.
An incident matrix B has a row each vertex and a column
of each edge. 21/59
Fikre Bogale Chapter Three Elements of Graph Theory
Matrix Representation of Graphs
Example
1 Find the incidence matrix B for the graph shown below
(a) (b)
2 Draw the graph
represented
by the
given incidence matrix
1 1 0 1 1 0 0
(a) 1 0 1 (b) 0 1 1 0
0 1 1 1 0 1 0
22/59
Fikre Bogale Chapter Three Elements of Graph Theory
Matrix Representation of Graphs
Solution
1 (a) Since the graph has 5 edges and 4 vertices, then the
incidence
matrixis 4 × 5.
1 0 0 0 0
1 1 0 0 0
0 1 1 1 0
0 0 0 1 1
(b) Since the graph has 5 edges and 4 vertices, then the
incidence
matrixis 4 × 5.
1 0 1 1 0
1 1 0 0 1
0 1 0 1 0
0 0 1 0 1
23/59
Fikre Bogale Chapter Three Elements of Graph Theory
Subgraph of a Graph
Definition
A graph H is called a subgraph of a graph G , written H ⊆ G ,
if V (H) ⊆ V (G ) and E (H) ⊆ E (G ). If H ⊆ G but H 6= G ,
we call H a proper subgraph of G . If H is a subgraph of G ,
then G is called the super graph of H.
A spanning subgraph of G is a subgraph that contains all
vertices of G .
Definition
Let G = (V , E ) and let V 0 ⊆ V . The subgraph of G induced
by V 0 , denoted G [V 0 ], is the graph H = (V 0 , E 0 ) where, for
every x, y ∈ V 0 , xy ∈ E 0 if and only if xy ∈ E . We say
H = G [V 0 ] is an induced subgraph of G . The subgraph of G
obtained by deleting V 0 is G [V \ V 0 ], which is usually witten
as G − V 0 . If V 0 = {v }, it is common to write G − v
24/59
Fikre Bogale Chapter Three Elements of Graph Theory
Subgraph of a Graph
Definition
A graph H is called a subgraph of a graph G , written H ⊆ G ,
if V (H) ⊆ V (G ) and E (H) ⊆ E (G ). If H ⊆ G but H 6= G ,
we call H a proper subgraph of G . If H is a subgraph of G ,
then G is called the super graph of H.
A spanning subgraph of G is a subgraph that contains all
vertices of G .
Definition
Let G = (V , E ) and let V 0 ⊆ V . The subgraph of G induced
by V 0 , denoted G [V 0 ], is the graph H = (V 0 , E 0 ) where, for
every x, y ∈ V 0 , xy ∈ E 0 if and only if xy ∈ E . We say
H = G [V 0 ] is an induced subgraph of G . The subgraph of G
obtained by deleting V 0 is G [V \ V 0 ], which is usually witten
as G − V 0 . If V 0 = {v }, it is common to write G − v
24/59
Fikre Bogale Chapter Three Elements of Graph Theory
Example: Draw the subgraphs of a given graph
Solution: The following are sub-graphs of the given graph.
25/59
Fikre Bogale Chapter Three Elements of Graph Theory
Isomorphic Graphs
Definition
A simple graphs G1 = (V1 , E1 ) and G2 = (V2 , E2 ) are
isomorphic, written G1 ∼ = G2 , if there is one-to-one and on to
function f from V1 to V2 with the property that a and b are
adjacent in G1 iff f (a) and f (b) are adjacent in G2 , for all a
and b in V1 .
Example: Show that the graphs G = (V1 , E1 ) and
H = (V2 , E2 ) are isomorphic.
Solution: The function f with f (u1 ) = v1 , f (u2 ) = v4 ,
26/59
f (u3 ) = v3 and f (u4 ) =Fikrev2Bogale
is a one-to-one correspondence.
Chapter Three Elements of Graph Theory
Graph Theory
There are different points to check whether the two graphs are
isomorphic or not, using invariant conditions such as number
of vertices, number of edges and degree of vertices.
Remark
Two simple isomorphic graphs must have
1 equal number of vertices
2 equal number of edges
3 corresponding vertices must have equal degree.
Finally we can check by using adjacency matrix, if the
adjacency matrix of the two graphs are the same, then we can
say the two graphs are isomorphic.
27/59
Fikre Bogale Chapter Three Elements of Graph Theory
Graph Theory
There are different points to check whether the two graphs are
isomorphic or not, using invariant conditions such as number
of vertices, number of edges and degree of vertices.
Remark
Two simple isomorphic graphs must have
1 equal number of vertices
2 equal number of edges
3 corresponding vertices must have equal degree.
Finally we can check by using adjacency matrix, if the
adjacency matrix of the two graphs are the same, then we can
say the two graphs are isomorphic.
27/59
Fikre Bogale Chapter Three Elements of Graph Theory
Examples of non-Isomorphic Graphs
Example: Show that the graphs G and H are not isomorphic.
Solution: Both G and H have five vertices and six edges.
However, H has a vertex of degree one, namely, e, whereas G
has no vertices of degree one. It follows that G and H are not
isomorphic.
28/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Definition
Let v0 and vn be two vertices in a graph G . A path of length n
from v0 to vn is a sequence of vertices vi and edges ei of the
form
v0 e1 v1 e2 · · · vn−1 en vn
where each edge ei is incident with the vertices vi−1 and vi
Note
If the graph is simple, the path is unique and is denoted
by just listing the vertices along the path v0 v1 · · · vn−1 vn .
A simple path from v0 to vn contains no repeated vertices.
Length of path depending on the number of edges.
29/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Definition
Let v0 and vn be two vertices in a graph G . A path of length n
from v0 to vn is a sequence of vertices vi and edges ei of the
form
v0 e1 v1 e2 · · · vn−1 en vn
where each edge ei is incident with the vertices vi−1 and vi
Note
If the graph is simple, the path is unique and is denoted
by just listing the vertices along the path v0 v1 · · · vn−1 vn .
A simple path from v0 to vn contains no repeated vertices.
Length of path depending on the number of edges.
29/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Given the path P = v0 e1 v1 e2 · · · vn−1 en vn . Then
v0 is called the initial and vn is the terminal vertex of P.
The path is said to be closed if v0 = vn .
The path is said to be open v0 6= vn .
P is called simple path if all the vertices are distinct.
P is called a cycle if it is a closed simple path( i.e. all the
vertices are distinct except v0 and vn ). A cycle of length n
is is called an n-cycle and is denoted by Cn .
P is called a trial if all edges are distinct.
A loop is a cycle of length 1.
A simple path of length ≥ 1 with no repeated edges and
whose end points are equal is called a circuit.
30/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Given the path P = v0 e1 v1 e2 · · · vn−1 en vn . Then
v0 is called the initial and vn is the terminal vertex of P.
The path is said to be closed if v0 = vn .
The path is said to be open v0 6= vn .
P is called simple path if all the vertices are distinct.
P is called a cycle if it is a closed simple path( i.e. all the
vertices are distinct except v0 and vn ). A cycle of length n
is is called an n-cycle and is denoted by Cn .
P is called a trial if all edges are distinct.
A loop is a cycle of length 1.
A simple path of length ≥ 1 with no repeated edges and
whose end points are equal is called a circuit.
30/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Given the path P = v0 e1 v1 e2 · · · vn−1 en vn . Then
v0 is called the initial and vn is the terminal vertex of P.
The path is said to be closed if v0 = vn .
The path is said to be open v0 6= vn .
P is called simple path if all the vertices are distinct.
P is called a cycle if it is a closed simple path( i.e. all the
vertices are distinct except v0 and vn ). A cycle of length n
is is called an n-cycle and is denoted by Cn .
P is called a trial if all edges are distinct.
A loop is a cycle of length 1.
A simple path of length ≥ 1 with no repeated edges and
whose end points are equal is called a circuit.
30/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Given the path P = v0 e1 v1 e2 · · · vn−1 en vn . Then
v0 is called the initial and vn is the terminal vertex of P.
The path is said to be closed if v0 = vn .
The path is said to be open v0 6= vn .
P is called simple path if all the vertices are distinct.
P is called a cycle if it is a closed simple path( i.e. all the
vertices are distinct except v0 and vn ). A cycle of length n
is is called an n-cycle and is denoted by Cn .
P is called a trial if all edges are distinct.
A loop is a cycle of length 1.
A simple path of length ≥ 1 with no repeated edges and
whose end points are equal is called a circuit.
30/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Given the path P = v0 e1 v1 e2 · · · vn−1 en vn . Then
v0 is called the initial and vn is the terminal vertex of P.
The path is said to be closed if v0 = vn .
The path is said to be open v0 6= vn .
P is called simple path if all the vertices are distinct.
P is called a cycle if it is a closed simple path( i.e. all the
vertices are distinct except v0 and vn ). A cycle of length n
is is called an n-cycle and is denoted by Cn .
P is called a trial if all edges are distinct.
A loop is a cycle of length 1.
A simple path of length ≥ 1 with no repeated edges and
whose end points are equal is called a circuit.
30/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Given the path P = v0 e1 v1 e2 · · · vn−1 en vn . Then
v0 is called the initial and vn is the terminal vertex of P.
The path is said to be closed if v0 = vn .
The path is said to be open v0 6= vn .
P is called simple path if all the vertices are distinct.
P is called a cycle if it is a closed simple path( i.e. all the
vertices are distinct except v0 and vn ). A cycle of length n
is is called an n-cycle and is denoted by Cn .
P is called a trial if all edges are distinct.
A loop is a cycle of length 1.
A simple path of length ≥ 1 with no repeated edges and
whose end points are equal is called a circuit.
30/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Given the path P = v0 e1 v1 e2 · · · vn−1 en vn . Then
v0 is called the initial and vn is the terminal vertex of P.
The path is said to be closed if v0 = vn .
The path is said to be open v0 6= vn .
P is called simple path if all the vertices are distinct.
P is called a cycle if it is a closed simple path( i.e. all the
vertices are distinct except v0 and vn ). A cycle of length n
is is called an n-cycle and is denoted by Cn .
P is called a trial if all edges are distinct.
A loop is a cycle of length 1.
A simple path of length ≥ 1 with no repeated edges and
whose end points are equal is called a circuit.
30/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Given the path P = v0 e1 v1 e2 · · · vn−1 en vn . Then
v0 is called the initial and vn is the terminal vertex of P.
The path is said to be closed if v0 = vn .
The path is said to be open v0 6= vn .
P is called simple path if all the vertices are distinct.
P is called a cycle if it is a closed simple path( i.e. all the
vertices are distinct except v0 and vn ). A cycle of length n
is is called an n-cycle and is denoted by Cn .
P is called a trial if all edges are distinct.
A loop is a cycle of length 1.
A simple path of length ≥ 1 with no repeated edges and
whose end points are equal is called a circuit.
30/59
Fikre Bogale Chapter Three Elements of Graph Theory
Path and connectivity of a graph
Example: Consider the graph
Take the following sequence of vertices.
α = (v4 , v1 , v2 , v5 , v1 , v2 , v3 , v6 )
β = (v4 , v1 , v5 , v2 , v6 )
γ = (v4 , v1 , v5 , v2 , v3 , v5 , v6 )
δ = (v4 , v1 , v5 , v3 , v6 )
P = (v4 , v1 , v2 , v3 , v5 , v4 )
31/59
Fikre Bogale Chapter Three Elements of Graph Theory
Then we can discuss about the following results
α is an open path from v4 to v6 , but not a cycle and not
a trial as well.
β is not a path since there is no edge connecting v2 and
v6 in the graph.
γ is a trial(no edge is used twice) but not a cycle.
δ is a simple path as well as a trial between v4 and v6 , but
not the shortest path between v4 and v6 .
The shortest path between v4 and v6 is v4 v5 v6 which has
length 2.
The sequence p is a circuit of length 5.
Two vertices u and v in G are said to be connected if
there is a (u, v )-path in G .
32/59
Fikre Bogale Chapter Three Elements of Graph Theory
Connectivity of a graph
Definition
A graph G is called connected if there is a path between any
two vertices of the graph. Otherwise it is disconnected.
Example
Consider the following graphs
The first is connected, but the second one is disconnected.
Because in the second graph, no path between v1 and v4 .
33/59
Fikre Bogale Chapter Three Elements of Graph Theory
Connectivity of a graph
Definition
A graph G is called connected if there is a path between any
two vertices of the graph. Otherwise it is disconnected.
Example
Consider the following graphs
The first is connected, but the second one is disconnected.
Because in the second graph, no path between v1 and v4 .
33/59
Fikre Bogale Chapter Three Elements of Graph Theory
Special Types of Graphs
Definition
A simple graph G = (V , E ) is called bipartite if V is
partitioned into two disjoint set of vertices V1 and V2 such
that each edge in a graph G connects a vertex in V1 and a
vertex in V2 . By a complete bipartite graph we mean each
vertex of V1 is connected to each vertex of V2 , this graph is
denoted by Km,n where m is the number of vertices in V1 and
n is the number of vertices in V2 . Note that |E (Km,n )| = mn.
Note
Two sets V1 and V2 are partition of a set V if
1 V1 ∩ V2 = ∅
2 V = V1 ∪ V2
34/59
Fikre Bogale Chapter Three Elements of Graph Theory
Special Types of Graphs
Definition
A simple graph G = (V , E ) is called bipartite if V is
partitioned into two disjoint set of vertices V1 and V2 such
that each edge in a graph G connects a vertex in V1 and a
vertex in V2 . By a complete bipartite graph we mean each
vertex of V1 is connected to each vertex of V2 , this graph is
denoted by Km,n where m is the number of vertices in V1 and
n is the number of vertices in V2 . Note that |E (Km,n )| = mn.
Note
Two sets V1 and V2 are partition of a set V if
1 V1 ∩ V2 = ∅
2 V = V1 ∪ V2
34/59
Fikre Bogale Chapter Three Elements of Graph Theory
Examples of bipartite graphs
Consider the graphs and check whether they are bipartite or
not
(a)
(b)
35/59
Fikre Bogale Chapter Three Elements of Graph Theory
Examples of bipartite graphs
(c)
(d)
36/59
Fikre Bogale Chapter Three Elements of Graph Theory
Solution
From (a), the graph has V = {v1 , v2 , v3 , v4 , v5 , v6 } as the
set of vertices. Then we can partitioned V into
V1 = {v1 , v2 , v3 } and V2 = {v4 , v5 , v6 } such that each
edge of the graph connects in V1 and V2 . Hence, the
graph is bipartite graph.
Graphs from (b) and (c) are Not bipartite
From (d), the graph has V = {v1 , v2 , v3 , v4 } as the set of
vertices. Then we can partitioned V into V1 = {v1 , v4 }
and V2 = {v2 , v3 } such that each edge of the graph
connects in V1 and V2 . Hence, the graph is bipartite
graph.
Theorem
A graph with at least two vertices is bipartite if and only if it
contains no odd cycles.
37/59
Fikre Bogale Chapter Three Elements of Graph Theory
Solution
From (a), the graph has V = {v1 , v2 , v3 , v4 , v5 , v6 } as the
set of vertices. Then we can partitioned V into
V1 = {v1 , v2 , v3 } and V2 = {v4 , v5 , v6 } such that each
edge of the graph connects in V1 and V2 . Hence, the
graph is bipartite graph.
Graphs from (b) and (c) are Not bipartite
From (d), the graph has V = {v1 , v2 , v3 , v4 } as the set of
vertices. Then we can partitioned V into V1 = {v1 , v4 }
and V2 = {v2 , v3 } such that each edge of the graph
connects in V1 and V2 . Hence, the graph is bipartite
graph.
Theorem
A graph with at least two vertices is bipartite if and only if it
contains no odd cycles.
37/59
Fikre Bogale Chapter Three Elements of Graph Theory
Special Types of Graphs
Complete Graphs: A complete graph on n vertices,
denoted by Kn , is the graph such that every vertex in G is
connected to every other vertex in G .
Empty (Null) Graphs: The empty graph on n vertices,
denoted by Nn , is the graph of order n and no edges.
Regular Graphs: A graph G is regular if every vertex
has the same degree. G is said to be regular of degree r
(or r -regular) if deg (v ) = r for all vertices v in G .
Complete graphs of order n are regular of degree n − 1,
and empty graphs are regular of degree 0.
Complement of a graph: The complement of a graph
G is denoted by G is a graph with V (G ) = V (G ) but
uv ∈ E (G ) if and only if uv ∈ / E (G ).
A simple graph G is said to be self complementary if
G∼ = G. 38/59
Fikre Bogale Chapter Three Elements of Graph Theory
Eulerian and Hamiltonian Graphs
Introduction
Can we travel along the edges of a graph starting at a
vertex and returning to it by traversing each edge of the
graph exactly once?
Similarly, can we travel along the edges of a graph
starting at a vertex and returning to it while visiting each
vertex of the graph exactly once?
The first question asks whether a graph has an Euler
circuit, while the second question asks whether a graph
has a Hamilton circuit.
Definition
An Eulerian circuit in a graph G is a simple circuit
containing every edge of G . An Eulerian path in G is a
simple path containing every edge of G
39/59
Fikre Bogale Chapter Three Elements of Graph Theory
Eulerian and Hamiltonian Graphs
Introduction
Can we travel along the edges of a graph starting at a
vertex and returning to it by traversing each edge of the
graph exactly once?
Similarly, can we travel along the edges of a graph
starting at a vertex and returning to it while visiting each
vertex of the graph exactly once?
The first question asks whether a graph has an Euler
circuit, while the second question asks whether a graph
has a Hamilton circuit.
Definition
An Eulerian circuit in a graph G is a simple circuit
containing every edge of G . An Eulerian path in G is a
simple path containing every edge of G
39/59
Fikre Bogale Chapter Three Elements of Graph Theory
Eulerian and Hamiltonian Graphs
Introduction
Can we travel along the edges of a graph starting at a
vertex and returning to it by traversing each edge of the
graph exactly once?
Similarly, can we travel along the edges of a graph
starting at a vertex and returning to it while visiting each
vertex of the graph exactly once?
The first question asks whether a graph has an Euler
circuit, while the second question asks whether a graph
has a Hamilton circuit.
Definition
An Eulerian circuit in a graph G is a simple circuit
containing every edge of G . An Eulerian path in G is a
simple path containing every edge of G
39/59
Fikre Bogale Chapter Three Elements of Graph Theory
Eulerian and Hamiltonian Graphs
Introduction
Can we travel along the edges of a graph starting at a
vertex and returning to it by traversing each edge of the
graph exactly once?
Similarly, can we travel along the edges of a graph
starting at a vertex and returning to it while visiting each
vertex of the graph exactly once?
The first question asks whether a graph has an Euler
circuit, while the second question asks whether a graph
has a Hamilton circuit.
Definition
An Eulerian circuit in a graph G is a simple circuit
containing every edge of G . An Eulerian path in G is a
simple path containing every edge of G
39/59
Fikre Bogale Chapter Three Elements of Graph Theory
Eulerian and Hamiltonian Graphs
Example: Which of the following graphs have an Euler
circuit? Of those that do not, which have an Euler path?
Solution: The graph G1 has an Eulerian circuit, for example,
aecdeba. Nether of the graphs G2 or G3 has an Eulerian circuit
(Verify). However, G3 has an Euler path namely, acdebdab.
G2 does not have an Eulerian path (Verify).
40/59
Fikre Bogale Chapter Three Elements of Graph Theory
Eulerian and Hamiltonian Graphs
Example: Which of the following graphs have an Euler
circuit? Of those that do not, which have an Euler path?
Solution: The graph G1 has an Eulerian circuit, for example,
aecdeba. Nether of the graphs G2 or G3 has an Eulerian circuit
(Verify). However, G3 has an Euler path namely, acdebdab.
G2 does not have an Eulerian path (Verify).
40/59
Fikre Bogale Chapter Three Elements of Graph Theory
Eulerian and Hamiltonian Graphs
Theorem
A connected graph G with at least two vertices has an Euler
circuit if and only if each of its vertices has even degree.
A graph that contains an Eulerian circuit is called an Eulerian
graph.
Definition
A simple path in a graph G that passes through every vertex
exactly once is called a Hamilton path, and a simple circuit
in a graph G that passes through every vertex exactly once is
called a Hamilton circuit. A graph G is called Hamiltonian
graph if it admits a Hamiltonian cycle.
41/59
Fikre Bogale Chapter Three Elements of Graph Theory
Eulerian and Hamiltonian Graphs
Theorem
A connected graph G with at least two vertices has an Euler
circuit if and only if each of its vertices has even degree.
A graph that contains an Eulerian circuit is called an Eulerian
graph.
Definition
A simple path in a graph G that passes through every vertex
exactly once is called a Hamilton path, and a simple circuit
in a graph G that passes through every vertex exactly once is
called a Hamilton circuit. A graph G is called Hamiltonian
graph if it admits a Hamiltonian cycle.
41/59
Fikre Bogale Chapter Three Elements of Graph Theory
Remark: a graph with a vertex of degree one cannot
have a Hamilton circuit, because in a Hamilton circuit,
each vertex is incident with two edges in the circuit.
Example: Which of the following simple graphs have a
Hamilton circuit or, if not, a Hamilton path?
Solution:G1 has a Hamilton circuit: a, b, c, d, e, a. There
is no Hamilton circuit in G2 because G2 has a vertex of
degree one, namely, a, but G2 does have a Hamilton path,
namely, a, b, c, d. G3 has neither a Hamilton circuit nor a
Hamilton path (Verify).
42/59
Fikre Bogale Chapter Three Elements of Graph Theory
Trees and Forests
Definition
1 A graph T is called a tree if T is connected and T has no
cycle.
2 A forest G is a graph with no cycles; hence the connected
components of a forest G are trees.
3 A graph without a cycle is said to be cycle-free (acyclic)
graph.
4 A tree consisting of a single vertex with no edges is called
the degenerate tree.
5 A loop is a cycle of length one, then a tree is a loop free
graph.
43/59
Fikre Bogale Chapter Three Elements of Graph Theory
Trees and Forests
Definition
1 A graph T is called a tree if T is connected and T has no
cycle.
2 A forest G is a graph with no cycles; hence the connected
components of a forest G are trees.
3 A graph without a cycle is said to be cycle-free (acyclic)
graph.
4 A tree consisting of a single vertex with no edges is called
the degenerate tree.
5 A loop is a cycle of length one, then a tree is a loop free
graph.
43/59
Fikre Bogale Chapter Three Elements of Graph Theory
Trees and Forests
Definition
1 A graph T is called a tree if T is connected and T has no
cycle.
2 A forest G is a graph with no cycles; hence the connected
components of a forest G are trees.
3 A graph without a cycle is said to be cycle-free (acyclic)
graph.
4 A tree consisting of a single vertex with no edges is called
the degenerate tree.
5 A loop is a cycle of length one, then a tree is a loop free
graph.
43/59
Fikre Bogale Chapter Three Elements of Graph Theory
Trees and Forests
Definition
1 A graph T is called a tree if T is connected and T has no
cycle.
2 A forest G is a graph with no cycles; hence the connected
components of a forest G are trees.
3 A graph without a cycle is said to be cycle-free (acyclic)
graph.
4 A tree consisting of a single vertex with no edges is called
the degenerate tree.
5 A loop is a cycle of length one, then a tree is a loop free
graph.
43/59
Fikre Bogale Chapter Three Elements of Graph Theory
Trees and Forests
Definition
1 A graph T is called a tree if T is connected and T has no
cycle.
2 A forest G is a graph with no cycles; hence the connected
components of a forest G are trees.
3 A graph without a cycle is said to be cycle-free (acyclic)
graph.
4 A tree consisting of a single vertex with no edges is called
the degenerate tree.
5 A loop is a cycle of length one, then a tree is a loop free
graph.
43/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forests
Example
Eg. Differentiate the following graphs as trees and forests.
44/59
Fikre Bogale Chapter Three Elements of Graph Theory
Solution
G1 is a degenerate tree, since the graph has only single
vertex.
The graphs G1 , G2 and G3 are connected with no cycles,
then they are trees.
G4 is a forest not a tree, since it is not connected.
Note
1 A connected graph with n vertex is called a tree if it has
exactly n − 1 edges.
2 In each tree T , there are some vertices of degree 1.
These vertices (of degree 1) are called leaves.
3 Every tree T with at least one edge has at least two
leaves.
4 The edges of a tree T are called branches.
45/59
Fikre Bogale Chapter Three Elements of Graph Theory
Solution
G1 is a degenerate tree, since the graph has only single
vertex.
The graphs G1 , G2 and G3 are connected with no cycles,
then they are trees.
G4 is a forest not a tree, since it is not connected.
Note
1 A connected graph with n vertex is called a tree if it has
exactly n − 1 edges.
2 In each tree T , there are some vertices of degree 1.
These vertices (of degree 1) are called leaves.
3 Every tree T with at least one edge has at least two
leaves.
4 The edges of a tree T are called branches.
45/59
Fikre Bogale Chapter Three Elements of Graph Theory
Solution
G1 is a degenerate tree, since the graph has only single
vertex.
The graphs G1 , G2 and G3 are connected with no cycles,
then they are trees.
G4 is a forest not a tree, since it is not connected.
Note
1 A connected graph with n vertex is called a tree if it has
exactly n − 1 edges.
2 In each tree T , there are some vertices of degree 1.
These vertices (of degree 1) are called leaves.
3 Every tree T with at least one edge has at least two
leaves.
4 The edges of a tree T are called branches.
45/59
Fikre Bogale Chapter Three Elements of Graph Theory
Solution
G1 is a degenerate tree, since the graph has only single
vertex.
The graphs G1 , G2 and G3 are connected with no cycles,
then they are trees.
G4 is a forest not a tree, since it is not connected.
Note
1 A connected graph with n vertex is called a tree if it has
exactly n − 1 edges.
2 In each tree T , there are some vertices of degree 1.
These vertices (of degree 1) are called leaves.
3 Every tree T with at least one edge has at least two
leaves.
4 The edges of a tree T are called branches.
45/59
Fikre Bogale Chapter Three Elements of Graph Theory
Solution
G1 is a degenerate tree, since the graph has only single
vertex.
The graphs G1 , G2 and G3 are connected with no cycles,
then they are trees.
G4 is a forest not a tree, since it is not connected.
Note
1 A connected graph with n vertex is called a tree if it has
exactly n − 1 edges.
2 In each tree T , there are some vertices of degree 1.
These vertices (of degree 1) are called leaves.
3 Every tree T with at least one edge has at least two
leaves.
4 The edges of a tree T are called branches.
45/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forest
Theorem
Let G be a graph with n > 1 vertices. Then the following are
equivalent.
1 G is a tree,
2 G is cycle-free and has n − 1 edges,
3 G is connected and has n − 1 edges.
Example
A tree has 4 vertices of degree 3 and 3 vertices of degree 2.
The remaining vertices have degree 1. Find the total number
of vertices in the tree.
46/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forest
Theorem
Let G be a graph with n > 1 vertices. Then the following are
equivalent.
1 G is a tree,
2 G is cycle-free and has n − 1 edges,
3 G is connected and has n − 1 edges.
Example
A tree has 4 vertices of degree 3 and 3 vertices of degree 2.
The remaining vertices have degree 1. Find the total number
of vertices in the tree.
46/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forest
Solution
Sol. Let n be the number of vertices of the tree.
Degree of vertex 3 2 1 Total
No. of vertices 4 3 n-7 n
Sum of degrees 12 6 n-7 18+(n-7)
Then from Hand Shaking Theorem, we have
18 + (n − 7) = 2|E |
And in a tree for n vertices we have n − 1 edges. Then
18 + (n − 7) = 2(n − 1)
∴ There are 13 vertices and 6 of them are of degree 1.
47/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forest
Definition
A spanning tree of a connected graph G is acyclic connected
subgraph of G which contains all the vertices of G .
Example:Find the spanning tree of the graph G .
Solution: The following are some spanning trees of the graph
G.
48/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forest
Definition
A spanning tree of a connected graph G is acyclic connected
subgraph of G which contains all the vertices of G .
Example:Find the spanning tree of the graph G .
Solution: The following are some spanning trees of the graph
G.
48/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forest
Note
For any connected graph G , we can find a spanning tree of G
by any of the following methods.
1 Cutting-down method: we start by choosing any cycle
in G and remove one of its edges-(i.e destroying a cycle
containing this edge). We repeat this procedure until no
cycle is left in the resulting graph.
2 Building-up method: we select edges of G one at a
time in such a way that the selection of edges does not
create a cycle. Repeat this procedure until all the vertices
of G are included in the resulting graph.
49/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forest
Note
For any connected graph G , we can find a spanning tree of G
by any of the following methods.
1 Cutting-down method: we start by choosing any cycle
in G and remove one of its edges-(i.e destroying a cycle
containing this edge). We repeat this procedure until no
cycle is left in the resulting graph.
2 Building-up method: we select edges of G one at a
time in such a way that the selection of edges does not
create a cycle. Repeat this procedure until all the vertices
of G are included in the resulting graph.
49/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forest
Note
For any connected graph G , we can find a spanning tree of G
by any of the following methods.
1 Cutting-down method: we start by choosing any cycle
in G and remove one of its edges-(i.e destroying a cycle
containing this edge). We repeat this procedure until no
cycle is left in the resulting graph.
2 Building-up method: we select edges of G one at a
time in such a way that the selection of edges does not
create a cycle. Repeat this procedure until all the vertices
of G are included in the resulting graph.
49/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forest
Example: From the connected graph G develop spanning tree
using the above two methods.
Solution: From the above graph G
Using Cutting-down method, remove the edges
VY (destroying the cycle VWYV )
ZY (destroying the cycle VWYZV )
YX (destroying the cycle WXYW )
Now, there is no cycle left and this procedure gives the
first spanning tree of G .
50/59
Fikre Bogale Chapter Three Elements of Graph Theory
Tree and Forest
Using Building-up method, choose the edges VZ , ZY , YX
and XW one at a time. Then this choice of edges:
Includes all the vertices of G
Does not create a cycle
Hence, the second spanning tree of G is obtained by this
method.
Therefore the resulting graphs are:
51/59
Fikre Bogale Chapter Three Elements of Graph Theory
Planar Graphs
Definition
A planar graph G is a graph that can be drawn on a plane
without any edges crossing, and such a drawing is called a
planar representation of the graph in the plane.
A graph is non-planar if no plane drawing of G exists.
Note that there exist planar as well as nonplanar graph. In
Figure 1, a planar graph and two of its plane representations
are shown. Note that all trees are planar as are also cycles.
Figure: Planar graph K4 with two plane embeddings of K4 .
52/59
Fikre Bogale Chapter Three Elements of Graph Theory
Planar Graphs
Definition
A planar graph G is a graph that can be drawn on a plane
without any edges crossing, and such a drawing is called a
planar representation of the graph in the plane.
A graph is non-planar if no plane drawing of G exists.
Note that there exist planar as well as nonplanar graph. In
Figure 1, a planar graph and two of its plane representations
are shown. Note that all trees are planar as are also cycles.
Figure: Planar graph K4 with two plane embeddings of K4 .
52/59
Fikre Bogale Chapter Three Elements of Graph Theory
Examples of Planar Graphs
K1,n and K2,n are planar graphs for all n.
A complete graph K5 and a complete bipartite graph K3,3
are non-planar.(Exercise draw)
Definition
A planar representation of a graph G divides the plane into a
set of regions (faces), where one of them has infinite area
and is called the infinite region (face).
Example: G has 7 faces, where f0 is the infinite face.
53/59
Fikre Bogale Chapter Three Elements of Graph Theory
Euler’s Planar Formula
Definition
The degree of a region(face) d(f ) is to be the number of
edges bounding the face f (cut edges are counted twice)
Each edge appears twice as an edge Pof a boundary and so
if F is the set of faces of G , then f ∈F d(f ) = 2|E (G )|
Example: G has 4 faces f0 , f1 , f2 and f3 with
d(f0 ) = 10, d(f1 ) = 8, d(f ) = 3, d(f ) = 1.
54/59
Fikre Bogale Chapter Three Elements of Graph Theory
Euler’s Planar Formula
Theorem (Euler’s Formula)
Suppose a connected planar graph G has |V | vertices, |E |
edges and |F | faces. Then |V | − |E | + |F | = 2.
Example: Verify Euler’s Formula
Solution: |V | = 4, |F | = 4, |E | = 6
55/59
Fikre Bogale Chapter Three Elements of Graph Theory
Properties of Planar Graphs
Example: Verify Euler’s Formula
|V | = 10, |F | = 7, |E | = 15 ⇒
|V | − |E | + |F | = 10 − 15 + 7 = 2
If a connected planar graph G has |E | edges and |V |
vertices, then 3|V | − |E | ≥ 6.
A complete graph Kn is a planar if and only if n < 5.
Every planar graph has a vertex of degree ≤ 5.
A complete bipartite graph Km,n is planar if and only if
m < 3 or n > 3.
56/59
Fikre Bogale Chapter Three Elements of Graph Theory
Graph Coloring (Vertex coloring)
Definition
A vertex coloring of a simple graph is the assignment of a
color to each vertex of the graph. A vertex coloring is called
proper coloring if it assigns different colors to adjacent
vertices.
Note that the term k-coloring refers to proper colorings
with k colors. G is said to be k-colorable if there is a
proper k-coloring of its vertices. Example:
57/59
Fikre Bogale Chapter Three Elements of Graph Theory
Graph Coloring (Vertex coloring)
Definition
The minimum number of colors needed to properly color a
given graph G is called the chromatic number of G , and it
is denoted by χ(G ).
1 Let G be a simple graph. The following are eqiuvalent:
a) χ(G ) = 2
b) G is bipartite
c) Every cycle in G has even length
2 Let G be a simple graph whose maximum degree is
∆(G ), then χ(G ) ≤ ∆(G ) + 1.
Exercise What is the chromatic number of the following graphs
K3 , K4 , K5 , Kn , Cn ?
58/59
Fikre Bogale Chapter Three Elements of Graph Theory
End of Chapter 3
End chapter
End of Chapter 3
59/59
Fikre Bogale Chapter Three Elements of Graph Theory