Skip to main content
Logo image

Activities to Accompany Applied Combinatorics

Worksheet 5.1 Hamiltonian or Not?

described in detail following the image
A graph with 10 vertices. The neighbors of each vertex are given in the table below.
Vertex Neighbors
\(1\) \(4\text{,}\) \(5\)
\(2\) \(3\text{,}\) \(6\text{,}\) \(9\)
\(3\) \(2\text{,}\) \(7\text{,}\) \(10\)
\(4\) \(1\text{,}\) \(7\text{,}\) \(8\text{,}\) \(10\)
\(5\) \(1\text{,}\) \(6\text{,}\) \(7\)
\(6\) \(2\text{,}\) \(5\text{,}\) \(8\)
\(7\) \(3\text{,}\) \(4\text{,}\) \(5\)
\(8\) \(4\text{,}\) \(6\text{,}\) \(9\)
\(9\) \(2\text{,}\) \(8\text{,}\) \(10\)
\(10\) \(3\text{,}\) \(4\text{,}\) \(9\)
(a) \(\bfG_1\)
described in detail following the image
A graph with 10 vertices. The neighbors of each vertex are given in the table below.
Vertex Neighbors
\(1\) \(2\text{,}\) \(10\)
\(2\) \(1\text{,}\) \(4\text{,}\) \(5\text{,}\) \(7\text{,}\) \(9\)
\(3\) \(7\text{,}\) \(8\text{,}\) \(9\)
\(4\) \(2\text{,}\) \(10\)
\(5\) \(2\text{,}\) \(6\)
\(6\) \(5\text{,}\) \(8\text{,}\) \(9\)
\(7\) \(2\text{,}\) \(3\)
\(8\) \(3\text{,}\) \(6\)
\(9\) \(2\text{,}\) \(3\text{,}\) \(6\)
\(10\) \(1\text{,}\) \(4\)
(b) \(\bfG_2\)
described in detail following the image
A graph with 10 vertices. The neighbors of each vertex are given in the table below.
Vertex Neighbors
\(1\) \(5\text{,}\) \(7\)
\(2\) \(3\text{,}\) \(5\text{,}\) \(6\text{,}\) \(7\)
\(3\) \(2\text{,}\) \(8\text{,}\) \(10\)
\(4\) \(7\text{,}\) \(9\text{,}\) \(10\)
\(5\) \(1\text{,}\) \(2\text{,}\) \(6\)
\(6\) \(2\text{,}\) \(5\)
\(7\) \(1\text{,}\) \(2\text{,}\) \(4\)
\(8\) \(3\text{,}\) \(9\)
\(9\) \(4\text{,}\) \(8\text{,}\) \(10\)
\(10\) \(3\text{,}\) \(4\text{,}\) \(9\)
(c) \(\bfG_3\)
described in detail following the image
A graph with 10 vertices labeled 0 to 9. For the vertices with labels 0 through 4, the vertex with label \(i\) has neighbors \(i-1\text{,}\) \(i+1\text{,}\) and \(i+5\text{.}\) The first two adjacencies are interpreted cyclically so that, for instance, \(4\) has neighbors \(3\) and \(0\text{.}\) For the vertices with labels 5 through 9, the vertex with label \(i\) has neighbors \(i-5\text{,}\) \(i+2\text{,}\) and \(i+3\text{.}\) The second and third adjacencies are interpreted cyclically so that, for instance, \(9\) has neighbors \(6\) and \(7\text{.}\)
(d) \(\bfG_4\)
described in detail following the image
A graph with 10 vertices labeled 0 to 9. For the vertices with labels 0 through 4, the vertex with label \(i\) has neighbors \(i-1\text{,}\) \(i+1\text{,}\) and \(i+5\text{.}\) The first two adjacencies are interpreted cyclically so that, for instance, \(4\) has neighbors \(3\) and \(0\text{.}\) For the vertices with labels 5 through 9, the vertex with label \(i\) has neighbors \(i-5\text{,}\) \(i+2\text{,}\) and \(i+3\text{.}\) The second and third adjacencies are interpreted cyclically so that, for instance, \(9\) has neighbors \(6\) and \(7\text{.}\) There is also an edge between the vertices with labels \(7\) and \(8\text{.}\)
(e) \(\bfG_5\)
Figure 5.1. Find a hamiltonian cycle in each graph or explain why there is not one
  1. The graph \(\bfG_{1}\) is hamiltonian. One example of a hamiltonian cycle is \(1,5,7,3,2,6,8,9,10,4\text{.}\) (There are others.)
  2. The graph \(\bfG_{2}\) is not hamiltonian. One reason for this is that removing the vertex \(2\) leaves a disconnected graph. Put another way, \(1,10,4,2\) forms a cycle, and the only way to get from the other vertices onto that cycle is via vertex \(2\text{.}\) Once you’re onto it, there’s no way off again. Thus, there’s no way to construct a cycle containing all \(10\) vertices.
  3. The graph \(\bfG_{3}\) is hamiltonian. One example of a hamiltonian cycle is \(1,5,6,2,3,8,9,10,4,7\text{.}\)
  4. The graph \(\bfG_{4}\) is not hamiltonian. This is a nontrivial fact. For those interested in a complete proof, see the end of this document. (You will not be tested on the proof, so it’s purely optional reading.)
  5. The graph \(\bfG_{5}\) (formed by adding one edge to the Petersen graph \(\bfG_{1}\)) is hamiltonian. One example of a hamiltonian cycle is \(10,7,1,5,8,4,6,3,2,9\text{.}\)

Proof the Petersen Graph is not hamiltonian.

Consider what a hamiltonian cycle in \(\bfG_{4}\) would look like. The graph has \(15\) edges, and a hamiltonian cycle would use \(10\) of them. Thus, you’d have the cycle and five leftover edges that would connect vertices across the cycle (β€œchords”). How would these edges fit along the cycle? If an edge connected a vertex to a vertex two steps down the cycle (for example, if the cycle contains the sequence \(a,b,c\) of vertices and there’s an edge from \(a\) to \(c\)), then there would be a triangle (a cyle on three vertices) in the graph. There is no such cycle in \(\bfG_{4}\text{.}\) If a chord connects a vertex to another vertex at distance three along the hamiltonian cycle, then there is a cycle on four vertices. However, there is no such cycle in \(\bfG_{4}\text{.}\)
Now suppose that a chord connects a vertex \(v_{0}\) to another vertex \(v_{1}\) at distance four along the hamiltonian cycle. Let \(v_{0}'\) be the vertex opposite \(v_{0}\) along the hamiltonian cycle. There is also a chord incident with \(v_{0}'\text{,}\) connecting it across the hamiltonian cycle to a vertex \(v_{1}'\text{.}\) We’ve already explained that the distance from \(v_{0}'\) to \(v_{1}'\) along the hamiltonian cycle cannot be less than four, and it cannot be five since that would give \(v_{0}'\) degree four. Thus the distance along the hamiltonian cycle from \(v_{0}'\) to \(v_{1}'\) must be four. Now \(v_{0},v_{1},v_{1}',v_{0}'\) is a cycle of length four (draw a picture to convince yourself), which we don’t have in \(\bfG_{4}\text{.}\) Finally, the only option that remains is that the chords all connect vertices that are exactly opposite each other on the hamiltonian cycle. However, then if \(v_{0}\) and \(v_{1}\) are adjacent along the hamiltonian cycle and \(v_{0}'\) and \(v_{1}'\) are the vertices opposite them, \(v_{0},v_{1},v_{1}',v_{0}'\) is a cycle of length four.