4 - Networks Model and Shortest Path
4 - Networks Model and Shortest Path
225J
1.225J (ESD 225) Transportation Flow Systems
Lecture 4
Lecture 4 Outline
1
Conceptual Networks: Definitions
A network is:
• a set of nodes N and a set of links A
• nodes are also called vertices or points
• links are also called arcs or edges
Examples:
Net 1 Net 2
1 2
1 2
3
3 4
4 5
2
Intersection Representations
Simple node representation:
• no direction differenciation
• no conflicting movement
Subnetwork representation:
• explicit direction representation
• conflicting turns in an intersection
are captured by internal links and
their impedances
Conceptual representation is not unique and
depends on:
• type of analysis
• data availability to build, validate, and apply model
• accuracy vs. computation time trade-off
1.225, 11/07/02 Lecture 4, Page 5
3
Dijkstra’
Dijkstra’s Shortest Paths Algorithm: Example
7
Mixed network b f 6
3 5 5 5 h
2
1
a c e j
8 8
1
6
5 2 6
i
d g 4
4
7
Directed network b f 6
3 5 5 h
5 2
1
a c e j
8
8
1
6 6
5 2
i
d g 4
4
Notation:
• s: source node
• d(j): length of shortest path from s to j discovered so far
• p(j): immediate predecessor to node j on shortest path from s to j
discovered so far
• k: last node selected by algorithm
Step 1: Initialization
• d(s) = 0, p(s) = *
• d(j) = ∝, p(j) = -, for all other nodes j ≠ s
• k=s
4
Dijkstra’
Dijkstra’s Shortest Paths Algorithm: Example
7 (∝,-)
(3,a)+
1st iteration b f 6
(∝,-)
3 5 5 h
5 2
(∝,-)
(0,*)+ 1
a c e j (∝,-)
(8,-) 8
8
1
6 6
5 2
i
d g 4 (∝,-)
(5,-) 4 (∝,-)
7 (10,-)
2nd iteration (3,a)+ b f 6
(∝,-)
3 5 5 h
5 2
(∝,-)
(0,*)+ 1
a c e j (∝,-)
(8,-) 8
8
1
6 6
5 2
i
d g 4 (∝,-)
(5,a)+ 4 (∝,-)
5
Shortest Paths Algorithm: Example
7 (10,-)
3rd iteration (3,a)+ b f 6
(∝,-)
3 5 5 h
5 2
(∝,-)
(0,*)+ 1
a c e j (∝,-)
(7,d)+ 8
8
1
6 6
5 2
i
d g 4 (∝,-)
(5,a)+ 4 (9,-)
7 (10,-)
4th iteration (3,a)+ b f 6
(∝,-)
3 5 5 h
5 2
(15,-)
(0,*)+ 1
a c e j (∝,-)
(7,d)+ 8
8
1
6 6
5 2
i
d g 4 (∝,-)
(5,a)+ 4 (9,d)+
7 (10,b)+
6th iteration (3,a)+ b f 6
(16,-)
3 5 5 h
5 2
(15,-)
(0,*)+ 1
a c e j (∝,-)
(7,d)+ 8
8
1
6 6
5 2
i
d g 4 (13,g)+
(5,a)+ 4 (9,d)+
6
Shortest Paths Algorithm: Example
7 (10,b)+
7th iteration (3,a)+ b f 6
(16,-)
3 5 5 h
5 2
(14,i)+
(0,*)+ 1
a c e j (19,-)
(7,d)+ 8
8
1
6 6
5 2
i
d g 4 (13,g)+
(5,a)+ 4 (9,d)+
7 (10,b)+
8th iteration (3,a)+ b f 6
(15,e)+
3 5 5 h
5 2
(14,i)+
(0,*)+ 1
a c e j (∝,-)
(7,d)+ 8
8
1
6 6
5 2
i
d g 4 (13,g)+
(5,a)+ 4 (9,d)+
7 (10,b)+
(3,a)+ b f
Shortest-path tree
(15,e)+
3 h
2
(14,i)+
(0,*)+ 1
a c e j (17,h)+
(7,d)+
1
5 2
i
d g 4 (13,g)+
(5,a)+ 4 (9,d)+
1.225, 11/07/02 Lecture 4, Page 14
7
Observations about Dijkstra’
Dijkstra’s Algorithm
8
A Traffic Assignment Problem
2
2
1
4 1
8 4
1 4 5
2
3 1 2 3 4 5
6
1 - 30 35 40 15
3 2 10 - 15 12 10
3 50 40 - 35 20
4 25 30 35 - 40
5 45 30 35 40 -
1.225, 11/07/02 Lecture 4, Page 17
“All-
All-or-
or-nothing”
nothing” Traffic Assignment
130
47
85
2
115
130
235
52 127
120 130
150
1 4 5
130 85
50 180
170
35
9
Traffic Assignment Models
Conceptual definition:
Zoning
Physical zones Zone-to-zone Flows
10 11 12
Zone 1 Zone 2 Zone 3 Zone 4
Zone 1 Zone 2 Zone 1 0 90 120 80
13 14 15 Zone 2 100 0 60 130
Zone 3 Zone 4 Zone 3 120 180 0 50
16 17 18
Zone 4 40 70 150 0
10
Analysis Periods
flows
time of day
Morning-peak Midday period Evening-peak
period period
Over an analysis period, flows are assumed constant in order for steady-
state analysis to apply
The duration of a period is longer than a trip
Typical analysis periods: morning-peak, midday, evening-peak
1.225, 11/07/02 Lecture 4, Page 21
Lecture 4 Summary
11