0% found this document useful (0 votes)
9 views

Eulerian Assignmen

Uploaded by

Kalpana M IITM
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views

Eulerian Assignmen

Uploaded by

Kalpana M IITM
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Math 3260, W20.

Assignment #3 solutions
(1) Prove or disprove: Every Eulerian graph in which the degree of
every vertex is at least 3 is Hamiltonian.
Solution. This is false: take K4,6 . This graph is Eulerian since
every vertex has an even degree. The degree of each vertex is
eiher 4 or 6. It is not Hamiltonian, since every cycle has to
visit each of the two components of a bipartite graph the same
number of times.
(2) Is there a graph with a bridge in which every vertex has an even
degree? Prove your claim.
Solution. There is no such graph. Assume otherwise, let G
be a graph with a bridge e in which every vertex has an even
degree. Then G − e is not connected, and it has two components
(corresponding to the two vertices, v and w, incident with e).
Let H be the component containing v. In it the degree of v is
odd (being one less than the degree of v in G), and the degree
of any other vertex is even. This contradicts the Handshaking
Lemma.
(3) Find the shortest path from a to each of the other vertices in
the weighted graph of the figure below. Draw a spanning tree
rooted at a with smallest weight.

6 2
•a ❅ •b ❅ •c
❅❅ ❅❅
❅❅ 1 ❅❅ 4
2 ❅❅ 3 ❅❅ 1
❅❅ ❅❅
❅ ❅
5 7
•d •e •f
⑦⑦ ⑦⑦
⑦⑦⑦ ⑦⑦⑦
3 ⑦⑦ 8 ⑦⑦ 1
⑦ 4 ⑦ 2
⑦⑦ 3 ⑦⑦
2
•g •h •i
Solution. This one was straightforward - apply the ‘shortest
path algorithm’ first. One obtains the shortest path a-e-b-c-f-i.
Since we followed the algorithm, the obtain path is the shortest
possible.
(Note that it was required to provide all details. The details
are straightforward, and I did not have time to write them down.
If you are unsure about filling in the details and would like to
see a detailed solution, please let me know.)
To find the spanning tree of the minimal weight, apply the
‘greedy algorithm’ from §3.3. There are several correct solutions.
1
2

It was not required to find all of them. All of them are subtrees
of the following subgraph (it was not required to find this graph
either).
2
•a ❅ •b •c
❅❅
❅❅ 1
2 ❅❅ 3 1
❅❅

•d •e •f

⑦⑦⑦
3 ⑦⑦ 1
⑦⑦⑦ 2

3 2
•g •h •i
Here are some of the spanning trees of minimal weight
2
•a ❅ •b •c
❅❅
❅❅ 1
2 ❅❅ 3 1
❅❅

•d •e •f
⑦⑦
⑦⑦⑦
3 ⑦ 1
⑦⑦ 2
⑦⑦
•g •h •i
or
2
•a ❅ •b •c
❅❅
❅❅ 1
2 ❅❅ 3 1
❅❅

•d •e •f

3 1

2
•g •h •i
or
2
•a ❅ •b •c
❅❅
❅❅ 1
2 ❅❅ 3 1
❅❅

•d •e •f
⑦⑦
⑦⑦⑦
⑦ 1
⑦⑦⑦ 2

3
•g •h •i
and so on.
3

Since we followed the greedy algorithm, either of the resulting


trees is a spanning tree of the minimal possible weight.
(Note that it was required to provide all details. The details
are straightforward, and I did not have time to write them down.
If you are unsure about filling in the details and would like to
see a detailed solution, please let me know.)
(4) Can a simple graph have exactly two spanning trees? Justify
your answer.

Solution. No. Proof: Assume G has two distinct spanning


trees, T1 and T2 . We need to prove that G has at least one more
spanning tree. Let e1 be an edge in T1 − T2 (there is one since
T1 and T2 have the same number n − 1 of edges; n = #V (G)).
Then T2 + e1 has the unique cycle C (Theorem 9.1 (vi) again).
Since T1 has no cycles, pick e2 ∈ C − T1 . Since G is simple, C
has at least three edges. Let e3 be an edge in C distinct from
both e1 and e2 . Then T3 = (T2 + e1 ) − e3 is a spanning tree of G,
and we only need to check that it is distinct from both T1 and
T2 . Since e1 ∈ T3 − T2 , T3 ∕= T2 . Since e2 ∈ T3 − T1 , T3 ∕= T1 .
(5) Find a spanning tree of the following graph of smallest possible
weight. Show all work and prove that the tree that you found
has the smallest possible weight.
5
A❅ B❅
❅❅ ❅❅
❅❅ 4 ❅❅ 2
1 ❅❅ 4 ❅❅
❅❅ ❅❅
❅ ❅
2 5
C❅ D❅ E❅
❅❅ ❅❅ ❅❅
❅❅ 3 ❅❅ 5 ❅❅ 6
❅❅ 4 ❅❅ 2 ❅❅
❅❅ ❅❅ ❅❅
❅ ❅ ❅
1 2
F G H

Solution. We apply greedy algorithm to find this tree. Pick


both edges of weight 1, AC and FG, perhaps not in this order.
Then pick edges of weight 2, CD, BE, GE, GH, (again, perhaps
not in this order).1

1At this point you may notice a legit minor improvement to the greedy algorithm. Suppose
that at any stage there are several edges that (i) haven’t been chosen yet (ii) they all have the
same weight (iii) this weight is minimal possible among the edges not chosen so far, and (iv) these
edges, together with the edges chosen so far, do not form a cycle. Then one can choose all of these
edges and add them to the spanning tree.
4

So far, we have chosen the following edges


A B❅
❅❅
❅❅ 2
1 ❅❅
❅❅

2
C D E
2

1 2
F G H
At this point, we move on to edges of the next smallest weight,
which is 3. The only edge of weight 3 is CF. After choosing it,
we obtain the spanning tree of minimal weight:
A B❅
❅❅
❅❅ 2
1 ❅❅
❅❅

2
C❅ D E .
❅❅
❅❅ 3
❅❅ 2
❅❅

1 2
F G H
Since we followed the greedy algorithm, either of the resulting
trees is a spanning tree of the minimal possible weight.

You might also like