{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

# lec0502-MST - Announcements MP 7 available Due 5/4 11:59p...

This preview shows pages 1–7. Sign up to view the full content.

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Announcements: MP 7 available. Due 5/4, 11:59p. Today: Algorithms – MST Graphs: Traversal – quiz Algorithm ________(G,v): ________ p; setLabel(v, VISITED) __________ While !(p.isEmpty) p.___________(v) For all w in G._______________(v) if getLabel(w) = UNEXPLORED setLabel((v,w),DISCOVERY) setLabel(w, VISITED) p.______________(w) else if getLabel((v,w)) = UNEXPLORED setLabel((v,w),______________) C B A E D F Running time: ___________ If we do not assume an _____________ implementation, the running time increases to _________ . Why? Minimum Spanning Tree Algorithms: •Input: connected, undirected graph G with unconstrained edge weights •Output: a graph G’ with the following characteristics - •G’ is a spanning subgraph of G •G’ is connected and acyclic (a tree) •G’ has minimal total weight among all such spanning trees - _________________________ C B A E D F 4 6 7 1 2 5 2 3 9 Kruskal’s Algorithm a b c f g h e d 5 15 5 16 10 11 12 9 2 8 12 13 17 2 16 4 (a,d) (e,h) (f,g) (a,b) (b,d) (g,e) (g,h) (e,c) (c,h) (e,f) (f,c) (d,e) (b,c) (c,d) (a,f) (d,f) Kruskal’s Algorithm (1956) a b c...
View Full Document

{[ snackBarMessage ]}

### Page1 / 13

lec0502-MST - Announcements MP 7 available Due 5/4 11:59p...

This preview shows document pages 1 - 7. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online