Download presentation
1
Fleury's Algorithm Euler Circuit Algorithm
Euler's Theorems are examples of existence theorems existence theorems tell whether or not something exists (e.g. Euler circuit) …. but doesn't tell us how to create it! We want a constructive method for finding Euler paths and circuits Methods (well-defined procedures, recipes) for construction are called algorithms There is an algorithm for constructing an Euler circuit: Fleury's Algorithm
2
1. Pick any vertex to start 2
1. Pick any vertex to start 2. From that vertex pick an edge to traverse (see below for important rule) 3. Darken that edge, as a reminder that you can't traverse it again 4. Travel that edge, coming to the next vertex 5. Repeat 2-4 until all edges have been traversed, and you are back at the starting vertex At each stage of the algorithm: The original graph minus the darkened (already used) edges = reduced graph Important rule: never cross a bridge of the reduced graph unless there is no other choice why must we observe that rule?
3
Fleury's Algorithm the same algorithm works for Euler paths
before starting, use Euler’s theorems to check that the graph has an Euler path and/or circuit to find! when you do this on paper, you can erase each edge as you traverse it this will make the reduced graph visible, and its bridges apparent
4
Fleury’S Algorithm Practice
Use Fleury’s Algorithm to find an Euler Path or Circuit if one exists….. A B G E C F D H J
5
Practice on your own Use Fleury’s Algorithm to find an Euler Circuit if one exists….
6
Hamiltonian Circuits and Paths
7
Exploration Let’s pretend that you are a city inspector and it is time for you to inspect the fire hydrants that are located at each of the street intersections. To optimize your route, you must find a path that begins at the garage, G, visits each intersection exactly once, and returns to the garage.
8
Exploration f h d c G e a b i j
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.