This preview shows pages 1–9. Sign up to view the full content.
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 DocumentThis 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: UMass Lowell Computer Science 91.404 Analysis of Algorithms Prof. Karen Daniels Fall, 2011 Chapter 22: Graph Algorithms Chapter 23: Minimum Spanning Trees Chapter 24: Shortest Paths [Source: Cormen et al . textbook except where noted] Overview: Graph Algorithms Chapter 22: Elementary Graph Algorithms Introductory Concepts Graph Traversals: DepthFirst Search BreadthFirst Search Topological Sort Chapter 23: Minimum Spanning Trees Kruskal Prim Chapter 24: Shortest Paths Dijkstra Chapter 22 Graph Algorithms Introductory Concepts DepthFirst Search BreadthFirst Search Topological Sort [Source: Cormen et al. textbook except where noted] Introductory Graph Concepts G= (V,E) Vertex Degree SelfLoops Edges may have weights (see Chapters 2324) B E C F D A B E C F D A Directed Graph (digraph) Degree: in/out SelfLoops allowed Undirected Graph No SelfLoops Adjacency is symmetric This treatment follows 91.503 textbook Cormen et al. Some definitions differ slightly from other graph literature. Introductory Graph Concepts: Motivation Networks are often modeled using graphs. Introductory Graph Concepts: Representations B E C F D A B E C F D A Undirected Graph Directed Graph (digraph) 1 1 1 1 1 1 1 1 1 A B C D E F A B C D E F 1 1 1 1 1 1 1 1 1 1 1 1 1 1 A B C D E F A B C D E F A BC B ACEF C AB D E E BDF F BE A BC B CEF C D D E BD F E Adjacency Matrix Adjacency List Adjacency Matrix Adjacency List This treatment follows textbook Cormen et al. Some definitions differ slightly from other graph literature. Introductory Graph Concepts: Paths, Cycles Path: length: number of edges simple: all vertices distinct Cycle: Directed Graph: <v ,v 1 ,...,v k > forms cycle if v =v k and k>=1 simple cycle: v 1 ,v 2 ..,v k also distinct selfloop is cycle of length 1 Undirected Graph: <v ,v 1 ,...,v k > forms (simple) cycle if v =v k and k>=3 simple cycle: v 1 ,v 2 ..,v k also distinct B E C F D A path <A,B,F> B E C F D A simple cycle <E,B,F,E> This treatment follows 91.503 textbook Cormen et al. Some definitions differ slightly from other graph literature. B E C F D A simple cycle <A,B,C,A>= <B,C,A,B> Introductory Graph Concepts: Connectivity Undirected Graph: connected every pair of vertices is connected by a path one connected component connected components: equivalence classes under is reachable from relation Directed Graph: strongly connected every pair of vertices is reachable from each other one strongly connected component strongly connected components: equivalence classes under mutually reachable relation maximal sized vertex subset inducing strongly connected subgraph B E C F D A B E C F D A connected 2 connected components not strongly connected strongly connected component B E C F D A B E C F D A This treatment follows 91.503 textbook Cormen et al. Some definitions differ slightly from other graph literature. DepthFirst Search (DFS)...
View
Full
Document
This note was uploaded on 02/13/2012 for the course CS 91.404 taught by Professor Dr.karendaniels during the Fall '09 term at UMass Lowell.
 Fall '09
 DR.KARENDANIELS
 Algorithms

Click to edit the document details