Euler and Hamilton Paths

Slides:



Advertisements
Similar presentations
CSE 211 Discrete Mathematics
Advertisements

KNURE, Software department, Ph , N.V. Bilous Faculty of computer sciences Software department, KNURE An Euler.
Introduction to Graph Theory Instructor: Dr. Chaudhary Department of Computer Science Millersville University Reading Assignment Chapter 1.
Midwestern State University Department of Computer Science Dr. Ranette Halverson CMPS 2433 – CHAPTER 4 GRAPHS 1.
Graph-02.
Chapter 7 Graph Theory 7.1 Modeling with graphs and finding Euler circuits. Learning Objectives: Know how to use graphs as models and how to determine.
1 Lecture 5 (part 2) Graphs II Euler and Hamiltonian Path / Circuit Reading: Epp Chp 11.2, 11.3.
Lecture 21 Paths and Circuits CSCI – 1900 Mathematics for Computer Science Fall 2014 Bill Pine.
BY: MIKE BASHAM, Math in Scheduling. The Bridges of Konigsberg.
Euler Circuits and Paths
IEOR266 © Classification of MCNF problems.
4/17/2017 Section 8.5 Euler & Hamilton Paths ch8.5.
How is this going to make us 100K Applications of Graph Theory.
MATH 310, FALL 2003 (Combinatorial Problem Solving) Lecture 5,Wednesday, September 10.
Euler and Hamilton Paths
Chapter 11 Graphs and Trees This handout: Terminology of Graphs Eulerian Cycles.
22C:19 Discrete Math Graphs Spring 2014 Sukumar Ghosh.
Graphs and Euler cycles Let Maths take you Further…
Euler Paths and Circuits. The original problem A resident of Konigsberg wrote to Leonard Euler saying that a popular pastime for couples was to try.
The Bridge Obsession Problem By Vamshi Krishna Vedam.
Copyright © Cengage Learning. All rights reserved.
GRAPH Learning Outcomes Students should be able to:
Take a Tour with Euler Elementary Graph Theory – Euler Circuits and Hamiltonian Circuits Amro Mosaad – Middlesex County Academy.
Chapter 15 Graph Theory © 2008 Pearson Addison-Wesley.
EECS 203: It’s the end of the class and I feel fine. Graphs.
Graph Theory Topics to be covered:
© Nuffield Foundation 2011 Nuffield Free-Standing Mathematics Activity Chinese postman problems What route can I take to avoid going along the same street.
Graphs Rosen, Chapter 8. Isomorphism (Rosen 560 to 563) Are two graphs G1 and G2 of equal form? That is, could I rename the vertices of G1 such that the.
Structures 7 Decision Maths: Graph Theory, Networks and Algorithms.
Euler and Hamilton Paths. Euler Paths and Circuits The Seven bridges of Königsberg a b c d A B C D.
CS 200 Algorithms and Data Structures
5.4 Graph Models (part I – simple graphs). Graph is the tool for describing real-life situation. The process of using mathematical concept to solve real-life.
Fall 2015 COMP 2300 Discrete Structures for Computation Donghyun (David) Kim Department of Mathematics and Physics North Carolina Central University 1.
Lecture 14: Graph Theory I Discrete Mathematical Structures: Theory and Applications.
Chapter 10.8 Graph Coloring
1.5 Graph Theory. Graph Theory The Branch of mathematics in which graphs and networks are used to solve problems.
AND.
Associated Matrices of Vertex Edge Graphs Euler Paths and Circuits Block Days April 30, May 1 and May
Euler Paths and Circuits. The original problem A resident of Konigsberg wrote to Leonard Euler saying that a popular pastime for couples was to try.
MAT 2720 Discrete Mathematics Section 8.2 Paths and Cycles
Lecture 52 Section 11.2 Wed, Apr 26, 2006
Lecture 11: 9.4 Connectivity Paths in Undirected & Directed Graphs Graph Isomorphisms Counting Paths between Vertices 9.5 Euler and Hamilton Paths Euler.
Copyright 2013, 2010, 2007, Pearson, Education, Inc. Section 14.2 Euler Paths, and Euler Circuits.
Chapter 6: Graphs 6.1 Euler Circuits
Review Euler Graph Theory: DEFINITION: A NETWORK IS A FIGURE MADE UP OF POINTS (VERTICES) CONNECTED BY NON-INTERSECTING CURVES (ARCS). DEFINITION: A VERTEX.
Introduction to Graphs Slides by Gene Boggess
Introduction to Graph Theory
1) Find and label the degree of each vertex in the graph.
Graph Theory Euler Paths and Euler Circuits. Euler Paths & Circuits Euler Paths and Euler Circuits (Euler is pronounced the same as Oiler) An Euler path.
Euler and Hamiltonian Graphs
Chapter 10.8 Graph Coloring These class notes are based on material from our textbook, Discrete Mathematics and Its Applications, 7 th ed., by Kenneth.
Chapter 14 Section 3 - Slide 1 Copyright © 2009 Pearson Education, Inc. AND.
Graphs Rosen, Chapter 8. NOT ONE OF THESE! One of these!
Grade 11 AP Mathematics Graph Theory Definition: A graph, G, is a set of vertices v(G) = {v 1, v 2, v 3, …, v n } and edges e(G) = {v i v j where 1 ≤ i,
EECS 203 Lecture 19 Graphs.
Euler and Hamiltonian Graphs
Euler and Hamiltonian Graphs
Euler Paths and Circuits
Graphs Rosen, Chapter 8.
Discrete Structures – CNS2300
EECS 203 Lecture 20 More Graphs.
Discrete Maths 9. Graphs Objective
Euler Circuits and Paths
Introduction to Graph Theory Euler and Hamilton Paths and Circuits
Konigsberg- in days past.
Euler Circuits and Paths
Euler and Hamilton Paths
Euler and Hamiltonian Graphs
Graph Theory Relations, graphs
A Survey of Mathematics with Applications
Presentation transcript:

Euler and Hamilton Paths Chapter 10.5 Euler and Hamilton Paths Slides by Gene Boggess Computer Science Department Mississippi State University Based on Discrete Mathematics and Its Applications, 7th ed., by Kenneth H. Rosen, published by McGraw Hill, Boston, MA, 2011. Modified and extended by Longin Jan Latecki latecki@temple.edu

Euler Paths and Circuits The Seven bridges of Königsberg, Prussia (now called Kaliningrad and part of the Russian republic) a b c d A B C D The townspeople wondered whether it was possible to start at some location in the town, travel across all the bridges once without crossing any bridge twice, and return to the starting point . The Swiss mathematician Leonhard Euler solved this problem. His solution, published in 1736, may be the first use of graph theory.

Euler Paths and Circuits An Euler path is a path using every edge of the graph G exactly once. An Euler circuit is an Euler path that returns to its start. A B C D Does this graph have an Euler circuit? No.

Necessary and Sufficient Conditions How about multigraphs? A connected multigraph has a Euler circuit iff each of its vertices has an even degree. A connected multigraph has a Euler path but not an Euler circuit iff it has exactly two vertices of odd degree. We will first see some examples, then the proof in the book starting on p. 694.

Example Which of the following graphs has an Euler circuit? yes no no d a c b e d a c b e c a d b yes no no (a, e, c, d, e, b, a)

Example Which of the following graphs has an Euler path? yes no yes d a c b e d a c b e c a d b yes no yes (a, e, c, d, e, b, a ) (a, c, d, e, b, d, a, b)

Euler Circuit in Directed Graphs NO (a, g, c, b, g, e, d, f, a) NO

Euler Path in Directed Graphs NO (a, g, c, b, g, e, d, f, a) (c, a, b, c, d, b)

THEOREM 1. A connected multigraph with at least two vertices has an Euler circuit if and only if each of its vertices has even degree. The proof starts on p. 694 in the book. It is constructive and leads to the following

APPLICATIONS OF EULER PATHS AND CIRCUITS Euler paths and circuits can be used to solve many practical problems. For example, many applications ask for a path or circuit that traverses each street in a neighborhood, each road in a transportation network, each connection in a utility grid, or each link in a communications network exactly once. Finding an Euler path or circuit in the appropriate graph model can solve such problems. For example, if a postman can find an Euler path in the graph that represents the streets the postman needs to cover, this path produces a route that traverses each street of the route exactly once. If no Euler path exists, some streets will have to be traversed more than once. The problem of finding a circuit in a graph with the fewest edges that traverses every edge at least once is known as the Chinese postman problem in honor of Guan Meigu, who posed it in 1962.

Hamilton Paths and Circuits A Hamilton path in a graph G is a path which visits every vertex in G exactly once. A Hamilton circuit is a Hamilton path that returns to its start.

Hamilton Circuits Dodecahedron puzzle and it equivalent graph Is there a circuit in this graph that passes through each vertex exactly once?

Dodecahedron is a polyhedron with twelve flat faces

Hamilton Circuits Yes; this is a circuit that passes through each vertex exactly once.

Finding Hamilton Circuits Which of these three figures has a Hamilton circuit? Or, if no Hamilton circuit, a Hamilton path?

Finding Hamilton Circuits G1 has a Hamilton circuit: a, b, c, d, e, a G2 does not have a Hamilton circuit, but does have a Hamilton path: a, b, c, d G3 has neither.

Finding Hamilton Circuits Unlike the Euler circuit problem, finding Hamilton circuits is hard. There is no simple set of necessary and sufficient conditions, and no simple algorithm.

Properties to look for ... No vertex of degree 1 If a node has degree 2, then both edges incident to it must be in any Hamilton circuit. No smaller circuits contained in any Hamilton circuit (the start/endpoint of any smaller circuit would have to be visited twice).

Show that neither graph displayed below has a Hamilton circuit. There is no Hamilton circuit in G because G has a vertex of degree one: e. Now consider H. Because the degrees of the vertices a, b, d, and e are all two, every edge incident with these vertices must be part of any Hamilton circuit. No Hamilton circuit can exist in H, for any Hamilton circuit would have to contain four edges incident with c, which is impossible.

A Sufficient Condition Let G be a connected simple graph with n vertices with n  3. If the degree of each vertex is  n/2, then G has a Hamilton circuit.

Travelling Salesman Problem A Hamilton circuit or path may be used to solve practical problems that require visiting “vertices”, such as: road intersections pipeline crossings communication network nodes A classic example is the Travelling Salesman Problem – finding a Hamilton circuit in a complete graph such that the total weight of its edges is minimal.

Time Complexity The best algorithms known for finding a Hamilton circuit in a graph or determining that no such circuit exists have exponential worst-case time complexity (in the number of vertices of the graph). Finding an algorithm that solves this problem with polynomial worst-case time complexity would be a major accomplishment because it has been shown that this problem is NP-complete. Consequently, the existence of such an algorithm would imply that many other seemingly intractable problems could be solved using algorithms with polynomial worst-case time complexity.

Summary Property Euler Hamilton Repeated visits to a given node allowed? Yes No Repeated traversals of a given edge allowed? Omitted nodes allowed? Omitted edges allowed?