This preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: 35 + 30 = 65 > D Not enough space, skip 30 35 + 25 = 60 > D Not enough space, skip 25 35 + 20 = 55 > D Not enough space, skip 20 35 + 10 = 45 < D Accepted! The algorithm will consume 45 out of 50 units of memory. However, it is not the best solution to the problem. A better solution can be as follows: 30 + 20 = 50 (50 = = D) 3a No. A short path in an original tree from one point to another will be also the shortest in the MST. 3b Explanation:If each edge has one and only one weight, then there will only be one MST.If the edge of point A is larger than any edges connected to A, then it cannot be in the MST.If the edge of point A is smaller than all other edges, then it will definitely be in the MST. In the following graph, the shortest path from A to F is: A, B , C, D, E, F If we take the MST of the graph, the path is also the same:...
View
Full Document
 Fall '07
 Dr.Chandra
 Algorithms, Graph Theory, Greedy algorithm, Kruskal's algorithm, Assume program sizes

Click to edit the document details