graph theory (networks)

34
Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 1 4 Graph Theory (Networks) The Mathematics of Relationships 4

Upload: anahid

Post on 22-Jan-2016

37 views

Category:

Documents


0 download

DESCRIPTION

4. Graph Theory (Networks). The Mathematics of Relationships. Graphs, Puzzles, and Map Coloring. 4.1. Understand graph terminology Apply Euler ’ s theorem to graph tracing Understand when to use graphs as models. ( continued on next slide ). Graphs, Puzzles, and Map Coloring. 4.1. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc.Copyright © 2014, 2010, 2007 Pearson Education, Inc.

Section 4.1, Slide 1

4 Graph Theory (Networks)

The Mathematics of Relationships

4

Page 2: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc.Copyright © 2014, 2010, 2007 Pearson Education, Inc.

Section 4.1, Slide 2

Graphs, Puzzles, and Map Coloring

4.1

• Understand graph terminology

• Apply Euler’s theorem to graph tracing

• Understand when to use graphs as models

(continued on next slide)

Page 3: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc.Copyright © 2014, 2010, 2007 Pearson Education, Inc.

Section 4.1, Slide 3

Graphs, Puzzles, and Map Coloring

4.1

• Use Fleury’s theorem to find Euler circuits

• Utilize graph coloring to simplify a problem

Page 4: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 4

Graph Terminology

Page 5: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 5

Examples of Graphs

http://oak.cats.ohiou.edu/~ridgely/Volvo_docs/

http://maps.google.com/?ie=UTF8&ll=57.703528,11.966429&spn=0.017449,0.036993&z=15

Page 6: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 6

Graph Terminology

Page 7: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 7

Graph Tracing

• The Koenigsberg bridge problem

Starting at some point, can you visit all parts of the city, crossing each bridge once and only once, and return to the starting point?

Page 8: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 8

Graph Tracing

• We can model the problem with a graph model.

Page 9: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 9

Graph Tracing

• The Koenigsberg problem, phased in graph theory language, is “Can the graph be traced?”

To trace a graph means to begin at some vertex and draw the entire graph without lifting the pencil and without going over any edge more than once.

Page 10: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 10

Graph Tracing

*Connected graphs are also called networks.

Page 11: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 11

Graph Tracing

• Example:

(solution on next slide)

Page 12: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 12

Graph Tracing

• Example:

Odd: B and C

Even: A, D, E, and F

(Zero edges is considered “even”)

Page 13: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 13

Euler’s Theorem

Page 14: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 14

Euler’s Theorem

Page 15: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 15

Euler’s Theorem

• Example: Which of the graphs can be traced?

(solution on next slide)

Page 16: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 16

Euler’s Theorem

• Solution:

Not trace-able

Trace-able

Trace-ableTrace-able

Page 17: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 17

Euler’s Theorem

Page 18: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 18

Euler’s Theorem

• Example:

• Solution:Path ACEB has length 3.

Path ACEBDA is an Euler path of length 5. It is also an Euler circuit.

Page 19: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 19

Fleury’s Algorithm

• We use Fleury’s algorithm to find Euler circuits.

(example on next slide)

Page 20: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 20

Fleury’s Algorithm

• Example:

(solution on next 3 slides)

Page 21: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 21

Fleury’s Algorithm

• Solution: (answers may vary)

(continued on next slide)

erase

Page 22: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 22

Fleury’s Algorithm

• Solution: (answers may vary)

(continued on next slide)

erase

Page 23: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 23

Fleury’s Algorithm

• Solution: (answers may vary)

erase

Page 24: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 24

Eulerizing a Graph

• We can add edges to convert a non-Eulerian graph to an Eulerian graph.

• This technique is called Eulerizing a graph.

(example on next slide)

Page 25: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 25

Eulerizing a Graph

• Example:

(solution on next slide)

Page 26: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 26

Eulerizing a Graph

• Solution: (answers may vary)

Eulerize

Page 27: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 27

Map Coloring

Page 28: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 28

Map Coloring

• Example:

(continued on next slide)

Page 29: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 29

Map Coloring

• Solution:

(continued on next slide)

We can rephrase the map-coloring question now as follows: Using four or fewer colors, can we color the vertices so that no two vertices of the same edge receive the same color?

Page 30: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 30

Map Coloring

• Solution:

There is no particular method for solving the problem.

A trial-and-error is shown.

Other solutions are possible.

Page 31: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 31

Map Coloring

Page 32: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 32

Map Coloring

• Example:Each member of a city council usually serves on several committees in city government. Assume council members serve on the following committees: police, parks, sanitation, finance, development, streets, fire department, and public relations. Use the table below to determine a conflict-free schedule for the meetings. We do not duplicate information - that is, because police conflicts with fire department, we do not also list that fire department conflicts with police.

(solution on next slide)

Page 33: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 33

Map Coloring

• Solution:

Model the information with a graph. Join conflicting committees with an edge.

(continued on next slide)

Page 34: Graph Theory (Networks)

Copyright © 2014, 2010, 2007 Pearson Education, Inc. Section 4.1, Slide 34

Map Coloring

• Solution:

Using trial and error and four colors or less, color committees that can meet at the same time with a common color. That is, similar-colored vertices should not share a common edge (same problem as the four-color problem).