lecture 27 cse 331 nov 3, 2010. combining groups groups can unofficially combine in the lectures
Post on 21-Dec-2015
216 views
TRANSCRIPT
![Page 1: Lecture 27 CSE 331 Nov 3, 2010. Combining groups Groups can unofficially combine in the lectures](https://reader036.vdocuments.site/reader036/viewer/2022062516/56649d635503460f94a46a0b/html5/thumbnails/1.jpg)
Lecture 27
CSE 331Nov 3, 2010
![Page 2: Lecture 27 CSE 331 Nov 3, 2010. Combining groups Groups can unofficially combine in the lectures](https://reader036.vdocuments.site/reader036/viewer/2022062516/56649d635503460f94a46a0b/html5/thumbnails/2.jpg)
Combining groups
Groups can unofficially combine in the lectures
![Page 3: Lecture 27 CSE 331 Nov 3, 2010. Combining groups Groups can unofficially combine in the lectures](https://reader036.vdocuments.site/reader036/viewer/2022062516/56649d635503460f94a46a0b/html5/thumbnails/3.jpg)
Dijkstra’s shortest path algorithm
Input: Directed G=(V,E), le ≥ 0, s in V
S = {s}, d(s) =0
While there is a v not in S with (u,v) in E, u in S
Pick w that minimizes d’(w) Add w to Sd(w) = d’(w)
At most n iterationsAt most n iterations
O(m) timeO(m) time
O(mn) time bound is trivial
O(m log n) time implementation is possible
d’(v) = min e=(u,v) in E, u in S d(u)+le
![Page 4: Lecture 27 CSE 331 Nov 3, 2010. Combining groups Groups can unofficially combine in the lectures](https://reader036.vdocuments.site/reader036/viewer/2022062516/56649d635503460f94a46a0b/html5/thumbnails/4.jpg)
Reading AssignmentSec 4.4 of [KT]
![Page 5: Lecture 27 CSE 331 Nov 3, 2010. Combining groups Groups can unofficially combine in the lectures](https://reader036.vdocuments.site/reader036/viewer/2022062516/56649d635503460f94a46a0b/html5/thumbnails/5.jpg)
Building a fiber network
Lay down fibers to connect n locations
All n locations should be connected
Laying down a fiber costs money
What is the cheapest way to lay down the fibers?
![Page 6: Lecture 27 CSE 331 Nov 3, 2010. Combining groups Groups can unofficially combine in the lectures](https://reader036.vdocuments.site/reader036/viewer/2022062516/56649d635503460f94a46a0b/html5/thumbnails/6.jpg)
Today’s agenda
Minimum Spanning Tree (MST) Problem
Greedy algorithm(s) for MST problem