Königsberg Bridge Problem

advertisement
Königsberg Bridge Problem
The problem is simply to find a path around a collection of bridges that crosses each bridge
exactly once. The map below shows the layout of bridges in the town of Königsberg, with seven
bridges and two islands.
Map of Königsberg
The seven bridges problem is well-known in both Maths and Computer Science, and so is
particularly appropriate for the garden since the bridges problem links the two departments that
sponsored the garden! It is usually associated with the 18th century mathematician Leonhard
Euler -- a path that solves the problem is called an Eulerian path. Eulerian paths have interesting
properties, both mathematically and computationally. The layout of bridges is from the town of
Königsberg in northern Germany (now part of Russia). The islands are in the middle of a river.
In our garden the river is represented by the garden. Since it is a river, you aren't allowed to go
around the far ends of the diamond!
Euler is supposed to have proved that there is no solution when he was working in St. Petersberg.
There could only be a solution if every island had an even number of bridges touching it, since
one must leave an island the same number of times one arrives at it. Alternatively, exactly two
islands can have an odd number of bridges, and these must be the start and finish point of the
tour.
Graphs
Euler's approach was to regard the spots of land (there are 4 of them) as points to be visited, and
the bridges as paths between those points. The mathematical essentials of the map of
Königsberg can then be reduced to the following diagram, which is an example of what is called
a graph:
A graph is a figure consisting of points (called vertices--the plural of vertex) and connecting lines
or curves (called edges). The problem of the bridges of Königsberg can then be reformulated as
whether this graph can be traced without tracing any edge more than once.
For each of the vertices of a graph, the order of the vertex is the number of edges at that
vertex. The figure below shows the graph of the Königsberg bridge problem, with the orders of
the vertices labeled.
Euler's Solution
Euler's solution to the problem of the Königsberg bridges involved the observation that when a
vertex is "visited" in the middle of the process of tracing a graph, there must be an edge coming
into the vertex, and another edge leaving it; and so the order of the vertex must be an even
number. This must be true for all but at most two of the vertices--the one you start at, and the
one you end at, and so a connected graph is traversible if and only if it has at most two vertices
of odd order. (Note that the starting and ending vertices may be the same, in which case the
order of every vertex must be even.) Now a quick look at the graph above shows that there are
more than two vertices of odd order, and so the graph cannot be traced; that is the desired
walking tour of Königsberg is impossible.
Additional Fun with Graphs
1. Suppose the citizens of Königsberg decided to build an eighth bridge, as in the diagram
shown below. Would a walking tour of Königsberg now be possible?
2. Show how you could add a ninth bridge to the diagram above, to make the walking tour once
again impossible.
A Different Problem with the Same Solution
Euler's solution can also be applied to problems that at first look different from the problem of
the Königsberg bridges. Consider the problem of whether it is possible to draw a continuous
curve that passes through each of the ten edges (line segments) of the following figure exactly
once. (A curve that passes through a vertex is not allowed.)
The next figure shows a start on a possible solution.
Is there a systematic way to approach this problem? To analyze this problem, we will create a
graph with four vertices, one for each of the four regions (including the outside region,
D). There will be ten edges in our graph, one for each of the boundary edges between two of the
regions. For instance, our graph will have three edges between the vertices for regions A and D,
because there are three boundary edges between regions A and D in the figure above. The
resulting graph can be drawn as follows:
The question of whether there is a continuous curve passing through all ten edges is equivalent to
the question of whether this graph can be traced. Since there are only two vertices of odd order,
Euler's theorem not only answers the question in the affirmative, but also tells you that you must
start either in region A or in region D.
Can you determine whether it is possible to draw a continuous curve that passes through each of
the edges of the following figure exactly once? Now that you know the secret, you can easily
make up your own similar challenges.
Download