Question: Problem 2 . MSTs In Lecture 2 1 , we saw two different greedy algorithms for building MST - growing a cloud ( Prim '
Problem MSTs
In Lecture we saw two different greedy algorithms for building MST "growing a cloud" Prims algorithm and "combining clusters" Kruskals algorithm Consider the following graph G for which we want to build an MST
a Show the order in which Prim's algorithm will add edges to the MST starting at node A For each edge uv added, show the value for v in the priority queue at the time it was added. What is the total weight of the MST
b Repeat a but starting at node H Hint: the total weight of the MST should be the same.
c Show the order in which Krusgal's algorithm will add edges to the MST Any time you skip an edge ie it is the next smallest, but not added note this and explain why.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
