Directed Graphs - Princeton University
Directed Graphs
digraph search transitive closure topological sort strong components
References: Algorithms in Java, Chapter 19
1
Directed graphs (digraphs)
Set of objects with oriented pairwise connections.
one-way streets in a map
dependencies in software modules
prey-predator relationships
hyperlinks connecting web pages
0
25
1
0
34
2
3
4
7
5
6
10
2
7
40
8
41 44
29 49
15 45
19 8
9 33 10
11 12 13 14 15
16
28
17
1
14
18
19
22
48
20
39
21
18
6
21
22
23
24
42
13
23
25 26 27
31
47
28
11
12
29
32
30
30
31
27
5
37
9
26
32
33
34
16
35 36
43
37
38
4
24
39 40
38
41
3
17
36
20
42
35
46
43 44 45
46
47
48
49
6
22
Page ranks with histogram for a larger example
2
Digraph applications
digraph
financial transportation
scheduling WordNet
Web game telephone food web infectious disease citation object graph inheritance hierarchy control flow
vertex
stock, currency street intersection, airport
task synset web page board position person species person journal article object class code block
edge
transaction highway, airway route precedence constraint
hypernym hyperlink legal move placed call predator-prey relation infection citation pointer inherits from
jump
3
Some digraph problems
Transitive closure. Is there a directed path from v to w?
Strong connectivity. Are all vertices mutually reachable?
Topological sort. Can you draw the digraph so that all edges point from left to right?
PERT/CPM. Given a set of tasks with precedence constraints, how we can we best complete them all?
Shortest path. Find best route from s to t in a weighted digraph
PageRank. What is the importance of a web page? 4
Digraph representations
Vertices
? this lecture: use integers between 0 and V-1. ? real world: convert between names and integers with symbol table.
Edges: four easy options
? list of vertex pairs ? vertex-indexed adjacency arrays (adjacency matrix) ? vertex-indexed adjacency lists ? vertex-indexed adjacency SETs
0
7
8
Same as undirected graph BUT
orientation of edges is significant.
1
2
6
9
3
4
11
5
10 12
5
................
................
In order to avoid copyright disputes, this page is only a partial summary.
To fulfill the demand for quickly locating and searching documents.
It is intelligent file search solution for home and business.
Related download
- complete guide for rf 433mhz transmitter receiver module
- jan schwinghammer december 5 2005 n ramsey
- integers in lua 5
- lua string format binary
- an intermediate representation for structured input lua
- last edit 07 02 2010 lua 5 1 c api
- directed graphs princeton university
- luatex a user s perspective tug
- seminar configurable systems
- programming in lua extending lua ufrj
Related searches
- princeton community hospital princeton wv
- princeton university admissions staff
- princeton university hospital princeton nj
- vanguard self directed brokerage account
- university medical center princeton nj
- princeton hospital princeton nj
- university of scranton princeton review
- princeton medical center princeton nj
- princeton review university rankings
- princeton university acceptance rate
- princeton university acceptance
- princeton university early decision