NAMES:

LOGINS:

PRECEPT:

COS 226 Exercises on MST


1. Consider the following weighted undirected graph.

weighted graph

Give the order in which the edges in the MST are discovered by Kruskal's algorithm. Since all edge weights are distinct, identify the edge by its weight.

















2. Answer question 1 for Prim's algorithm, starting the search at A.









3. Explain briefly, but rigorously, why running Kruskal's algorithm with the squares of the weights yields an MST on the original network (with the original weights). Assume all weights are nonnegative.