Download presentation
Presentation is loading. Please wait.
1
Analysis of Algorithms
Minimum Spanning Trees Uri Zwick February 2014
2
Find a minimum spanning tree
11 16 22 17 5 8 1 13 3 18 30 12 25 9 2 15
3
Kruskal’s algorithm 11 16 22 17 5 8 1 13 3 18 30 12 25 9 2 15
4
Prim’s algorithm 11 16 22 17 5 8 1 13 3 18 30 12 25 9 2 15
5
Boruvka’s algorithm 11 16 22 17 5 8 1 13 3 18 30 12 25 9 2 15
6
MST verification 11 16 22 17 5 8 1 13 3 18 30 12 25 9 2 15
7
Comparison-based MST algorithms
Running time Algorithm O(m log n) Kruskal (1956) O(m + n log n) Prim (1957) Boruvka (1926) O(m log (m,n)) Gabow-Galil- Spencer-Tarjan (1986) O(m (m,n)) Chazelle (2000) O(m + n) Karger-Klein-Tarjan (1995) Deterministic Rand.
8
Assume for simplicity that all edge weights are distinct
The MST is then unique
9
The lightest edge in a cut is contained in the MST
Cut rule S VS The lightest edge in a cut is contained in the MST
10
The heaviest edge on a cycle is not contained in the MST
Cycle rule C The heaviest edge on a cycle is not contained in the MST
11
The intersection between a cut and a cycle is of even size
Cuts and cycles The intersection between a cut and a cycle is of even size
12
Fundamental cycles Tree + non-tree edge unique cycle
The removal of any tree edge on the cycle generates a new tree
13
The lightest edge in a cut is contained in the MST
Cut rule - proof S VS w' w w < w' The lightest edge in a cut is contained in the MST
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.