Presentation is loading. Please wait.

Presentation is loading. Please wait.

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.

Similar presentations


Presentation on theme: "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."— Presentation transcript:

1 Graph Theory Euler Paths and Euler Circuits

2 Euler Paths & Circuits Euler Paths and Euler Circuits (Euler is pronounced the same as Oiler) An Euler path is a path that passes through each edge of a graph exactly one time. D, B, A, C, B, E, C, D, E

3 Euler Paths & Circuits An Euler circuit is a circuit that passes through each edge of a graph exactly one time. D, E, B, C, A, B, D, C, E, F, D

4 Euler Paths & Circuits Although we could find Euler Paths and Euler Circuits simply by trail and error, this becomes tedious and with larger graphs it can become very difficult. To determine if an Euler Path or an Euler Circuit exists, we use Euler’s Theorem.

5 Euler Paths & Circuits Euler’s Theorem For a connected graph, the following statements are true 1.A graph with no odd vertices (all even vertices) has at least one Euler path, which is also an Euler circuit. An Euler circuit can be started at any vertex and it will end at the same vertex. 2.A graph with exactly two odd vertices has at least one Euler path but no Euler circuits. Each Euler path must begin at one of the two odd vertices, and it will end at the other odd vertex. 3.A graph with more than two odd vertices has neither and Euler path nor an Euler circuit.

6 3.More than two Odd vertices: No Euler Path and No Euler Circuit 2.Exactly two Odd vertices: Euler Path, but No Euler Circuit Euler Paths & Circuits Euler's Theorem (summary) 1.No Odd vertices: Euler Path and Euler Circuit

7 Euler Paths & Circuits A C B D F E Use Euler's Theorem to determine if an Euler Path or Euler Circuit exists: Determine the degree of each vertex. 2 2 2 4 4 4 Count the number of odd vertices. This graph has NO Odd vertices. (all even vertices) 1.No Odd vertices: Euler Path and Euler Circuit An Euler circuit exists, which is also an Euler path.

8 Euler Paths & Circuits A C B D FE Use Euler's Theorem to determine if an Euler Path or Euler Circuit exists: Determine the degree of each vertex. Count the number of odd vertices. This graph has Exactly two Odd vertices. 2.Exactly two Odd vertices: Euler Path, but No Euler Circuit 2 3 2 2 3 2 An Euler Path only. Notice the path shown above started at C and ended at D

9 Euler Paths & Circuits A C BD E Use Euler's Theorem to determine if an Euler Path or Euler Circuit exists: ? ? Determine the degree of each vertex. Count the number of odd vertices. This graph has More than two Odd vertices. 4 3 3 3 3 3.More than two Odd vertices: No Euler Path and No Euler Circuit Neither exist.

10 Euler Paths & Circuits Solving the Konigsberg Bridge Problem: Could a walk be taken through Konigsberg during which each bridge is crossed exactly one time? Draw a vertex-edge graph to represent the problem. Remember: Locations are vertices and connections between those locations are edges. A D CB

11 Euler Paths & Circuits A D CB If we are trying to take a walk an cross each bridge exactly one time, an Euler path or an Euler circuit will have to be present in the graph. There are more than two odd vertices in the graph. Degree 5 Degree 3 This means that there is no Euler path and no Euler Circuit. Therefore, you cannot cross each bridge exactly once. Degree 3 Degree 3

12 Euler Paths & Circuits (Modified) Konigsberg Bridge Problem: A D CB If Konigsberg added some bridges to their city, could a walk be taken through which each bridge is crossed exactly one time?

13 Euler Paths & Circuits Modified Konigsberg Bridge Problem: If Konigsberg added some bridges to their city, could a walk be taken through which each bridge is crossed exactly one time? A D CB There are exactly two odd vertices in the graph. This means that there is an Euler path, but no Euler circuit. Therefore, you can cross each bridge exactly once. Degree 5 Degree 5 Degree 4 Degree 4

14 Euler Paths & Circuits Fleury's Algorithm: (How to find the Euler Path or circuit) 1. Does an Euler path or Euler circuit exist? 2. Start anywhere for a circuit. Start at an odd vertex for a path. The path will end at the other odd vertex. The circuit will end where you started. 3. Start tracing edges (number them as you go) 4. Avoid dead ends. Try not to get trapped.

15 Euler Paths & Circuits Recall the museum problem: Is it possible for someone to move through the museum by going through each doorway (or using each edge) of the museum exactly once? Condor Gallery French Gallery Hamersma Gallery Jessee Gallery Muhundan Gallery Paduchowski Gallery CFH JMP Outside Degree 3 Degree 3 There are exactly two odd vertices in the graph. This means that there is an Euler path, but no Euler circuit. So, yes, it is possible. (Although, the starting and ending points will be different.)

16 Euler Paths & Circuits Because there is only an Euler path, we must start at one of the odd vertices. If we start at F, we will end at P. CFH JMP Outside To find the Euler path, start tracing edges. This is one possible solution. Can you write the path? 1 2 3 4 5 6 7 8 9 Because it is difficult to remember the path we traced, we should number each edge as we trace it. Now it is easy to follow the path we found. One possible solution path is: FCJMPOMFHP

17 Euler Paths & Circuits Intersections are locations, and streets are connections between those locations

18 Euler Paths & Circuits The Country Oaks Neighborhood Association is planning to organize a crime stopper group in which residents take turns walking through the neighborhood with cell phones to report any suspicious activity to police. a) Can the residents start at one intersection (vertex) and walk each street block (edge) exactly once and return to the intersection where they started? b)If yes, determine a circuit that could be followed. Try this.

19 Euler Paths & Circuits Draw this graph in your notes and try the problem. You are looking for an Euler circuit, so you can start tracing at any point.

20


Download ppt "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."

Similar presentations


Ads by Google