Graph Theory
Graph Theory
Despite the fact that the two graphs have different arrangements of vertices and
edges, they are equivalent. To illustrate, we examine the edges of each graph. The
first graph contains six edges; we can list them by indicating which two vertices they
connect. The edges are AC, AE, BD, BE, CE, and DE. If we do the same for the
second graph, we get the same six edges. Because the two graphs represent the
same connections among the vertices, they are equivalent.
Simple Graphs and Multiple Graphs
An edge joining distinct vertices is called a link and
a b
two edges.
d c
On this graph the vertices a,
b, c and d have a degree of 2,
while vertex e has a degree of A loop at a vertex contributes
twice to the degree of the
four. vertex.
Handshaking Lemma
(First Theorem of Graph Theory)
In any graph, the sum of all the vertex
degrees is equal to twice the number of edges.
Recitation:
Find the degree of each vertex.
Find the number of edges.
Prove that the Handshaking Lemma is true to this graph.
Euler Graph
Any connected graph is called an Euler Graph if and only if all its vertices
are of even degree.
An Euler Graph is a connected graph that contains an Euler Circuit.
This graph is a connected graph and all its vertices are of even
degree.
Therefore, it is an Euler graph.
Euler Path
Euler path is also known as Euler Trail or Euler Walk.
•If there exists a Trail in the connected graph that contains all
the edges of the graph, then that trail is called as an Euler trail.
•If there exists a walk in the connected graph that visits every
edge of the graph exactly once with or without repeating the
vertices, then such a walk is called as an Euler walk.
Notice that not all edges need to be used. Unlike Euler Paths and Circuits, there is
no trick to tell if a graph has a Hamilton Path or Circuit.
Hamiltonian Path
A delivery driver wants to make the best
use of her time and vehicle's gas
mileage by planning a route that will
require the least amount of mileage and
time. In Figure 1, the houses she plans
to make deliveries to are numbered
from two to six, with the delivery
warehouse marked as one. To reduce
the amount of time she spends driving When following this path in Figure 1, it
and delivering, the driver plans her becomes clear that each of these stops is
traveled to only once by the driver. Because
route with the stops in the following only one visit is made to each of these stops,
order: 1, 2, 6, 3, 4, 5. the path chosen by the driver represents
a Hamiltonian path.
Hamiltonian Circuit
In Figure 2, the same neighborhood is
depicted in the form of a pentagon with
houses labeled from two to six, with node 1
representing the warehouse. This time, the
delivery driver wants to plan the most
efficient route in order to make her deliveries
and return to the warehouse afterward.
Because the driver will be starting and ending
her route at the first node (or first vertex), her
path represents a Hamiltonian circuit. In this
case, her route will travel along the following
path: 1, 2, 6, 3, 4, 5, 1.
Example 1- Does the
following graph have
a Hamiltonian Circuit?
Solution- Yes, the
above graph has a
Hamiltonian circuit.
The solution is –
Example 2- Does
the following graph
have a Hamiltonian
Circuit?
Solution- No, the given
graph does not have a
Hamiltonian circuit as
there are two vertices
with degree one in the
graph.
Study the graph and
answer the following.
1. Is the graph an
Eulerian graph? Why?
2. Is the graph
Hamiltonian? Why?
3. Identify:
a. Eulerian path
b. Eulerian circuit
c. Hamiltonian path
d. Hamiltonian circuit
"Education's purpose is to replace an empty mind
with an open one."
-Malcolm Forbes