Lecture 10 The Label Correcting Algorithm.

Slides:



Advertisements
Similar presentations
and 6.855J Modified Label Correcting Algorithm.
Advertisements

15.082J & 6.855J & ESD.78J Shortest Paths 2: Bucket implementations of Dijkstra’s Algorithm R-Heaps.
and 6.855J February 25, 2003 Radix Heap Animation.
Chapter 5 Shortest Paths: Label-Correcting Algorithms
Chapter 6 Maximum Flow Problems Flows and Cuts Augmenting Path Algorithm.
15.082J, 6.855J, and ESD.78J Sept 16, 2010 Lecture 3. Graph Search Breadth First Search Depth First Search Intro to program verification Topological Sort.
Management Science 461 Lecture 2b – Shortest Paths September 16, 2008.
1 Maximum Flow Networks Suppose G = (V, E) is a directed network. Each edge (i,j) in E has an associated ‘capacity’ u ij. Goal: Determine the maximum amount.
Chapter 7 Maximum Flows: Polynomial Algorithms
MIT and James Orlin © Introduction to Networks Eulerian Tours Hamiltonian Tours The Shortest Path Problem Dijkstra’s Algorithm for Solving the Shortest.
Computational Methods for Management and Economics Carla Gomes
& 6.855J & ESD.78J Algorithm visualizations Modified Label Correcting Algorithm.
Chapter 4 Shortest Path Label-Setting Algorithms Introduction & Assumptions Applications Dijkstra’s Algorithm.
Dijkstra’s algorithm N: set of nodes for which shortest path already found Initialization: (Start with source node s) n N = {s}, D s = 0, “s is distance.
15.082J & 6.855J & ESD.78J September 23, 2010 Dijkstra’s Algorithm for the Shortest Path Problem.
Diverse Routing Algorithms
1 1 © 2003 Thomson  /South-Western Slide Slides Prepared by JOHN S. LOUCKS St. Edward’s University.
and 6.855J The Goldberg-Tarjan Preflow Push Algorithm for the Maximum Flow Problem.
Network Simplex Animations Network Simplex Animations.
15.082J and 6.855J and ESD.78J The Successive Shortest Path Algorithm and the Capacity Scaling Algorithm for the Minimum Cost Flow Problem.
and 6.855J March 6, 2003 Maximum Flows 2. 2 Network Reliability u Communication Network u What is the maximum number of arc disjoint paths from.
15.082J & 6.855J & ESD.78J September 30, 2010 The Label Correcting Algorithm.
Suppose G = (V, E) is a directed network. Each edge (i,j) in E has an associated ‘length’ c ij (cost, time, distance, …). Determine a path of shortest.
Decision Maths 1 Shortest path algorithm Dijkstra’s Algorithm A V Ali :
EMIS 8374 Shortest Path Trees Updated 11 February 2008 Slide 1.
EMIS 8374 The Ford-Fulkerson Algorithm (aka the labeling algorithm) Updated 4 March 2008.
15.082J and 6.855J and ESD.78J Network Simplex Animations.
1 Maximum Flows CONTENTS Introduction to Maximum Flows (Section 6.1) Introduction to Minimum Cuts (Section 6.1) Applications of Maximum Flows (Section.
Shortest Path from G to C Using Dijkstra’s Algorithm
Network Simplex Animations
EMIS 8374 Dijkstra’s Algorithm Updated 18 February 2008
Disjoint Path Routing Algorithms
Dijkstra’s Algorithm with two levels of buckets
Lecture 21 CSE 331 Oct 21, 2016.
EMIS 8374 Node Splitting updated 27 January 2004
The Shortest Augmenting Path Algorithm for the Maximum Flow Problem
Lecture 21 CSE 331 Oct 20, 2017.
15.082J & 6.855J & ESD.78J Visualizations
Dijkstra’s Algorithm for the Shortest Path Problem
15.082J & 6.855J & ESD.78J Visualizations
Shortest Path.
Dijkstra’s Algorithm for the Shortest Path Problem
Lecture 19-Problem Solving 4 Incremental Method
Label Name Label Name Label Name Label Name Label Name Label Name
EMIS 8374 Shortest Path Problems: Introduction Updated 9 February 2008
Shortest-Path Property 4.1
Primal-Dual Algorithm
Shortest Path Problems
and 6.855J March 6, 2003 Maximum Flows 2
Shortest Path.
Title Slide After creating the template:
15.082J & 6.855J & ESD.78J Radix Heap Animation
Lecture 23 CSE 331 Oct 28, 2009.
Min Global Cut Animation
The Shortest Augmenting Path Algorithm for the Maximum Flow Problem
The Shortest Augmenting Path Algorithm for the Maximum Flow Problem
The Ford-Fulkerson Algorithm
Network Optimization Topological Ordering
and 6.855J Dijkstra’s Algorithm
Visualizations Dijkstra’s Algorithm
Network Simplex Animations
and 6.855J Topological Ordering
Lecture 23 CSE 331 Oct 24, 2011.
15.082J & 6.855J & ESD.78J Visualizations
Implementation of Dijkstra’s Algorithm
and 6.855J Depth First Search
Constraint Graph Binary CSPs
Algorithms Lecture # 26 Dr. Sohail Aslam.
15.082J & 6.855J & ESD.78J Visualizations
(Type Answer Here) (Type Answer Here) (Type Answer Here)
Presentation transcript:

Lecture 10 The Label Correcting Algorithm

Label Correcting Algorithm

An Example 3 Initialize   d(1) := 0; d(j) :=  for j    0  In next slides: the number inside the node will be d(j). Violating arcs will be in thick lines.

An Example 3 Generic Step An arc (i,j) is violating if d(j) > d(i) + c ij. 0      Pick a violating arc (i,j) and replace d(j) by d(i) + c ij. 3

An Example 3 Generic Step An arc (i,j) is violating if d(j) > d(i) + c ij. 0      Pick a violating arc (i,j) and replace d(j) by d(i) + c ij. 3 6

An Example 3 Generic Step An arc (i,j) is violating if d(j) > d(i) + c ij. 0      Pick a violating arc (i,j) and replace d(j) by d(i) + c ij

An Example 3 Generic Step An arc (i,j) is violating if d(j) > d(i) + c ij. 0      Pick a violating arc (i,j) and replace d(j) by d(i) + c ij

An Example 3 Generic Step An arc (i,j) is violating if d(j) > d(i) + c ij. 0      Pick a violating arc (i,j) and replace d(j) by d(i) + c ij

An Example 3 Generic Step An arc (i,j) is violating if d(j) > d(i) + c ij. 0      Pick a violating arc (i,j) and replace d(j) by d(i) + c ij

An Example 3 Generic Step An arc (i,j) is violating if d(j) > d(i) + c ij. 0      Pick a violating arc (i,j) and replace d(j) by d(i) + c ij

An Example 3 Generic Step An arc (i,j) is violating if d(j) > d(i) + c ij. 0      Pick a violating arc (i,j) and replace d(j) by d(i) + c ij

An Example 3 Generic Step An arc (i,j) is violating if d(j) > d(i) + c ij. 0      Pick a violating arc (i,j) and replace d(j) by d(i) + c ij No arc is violating The distance labels are optimal We now show the predecessor arcs.

Modified Label Correcting Algorithm

The Modified Label Correcting Algorithm 3 Initialize   d(1) := 0; d(j) :=  for j    0  In next slides: the number inside the node will be d(j). LIST := {1}

An Example 3 Generic Step Take a node i from LIST 0      Update(i): for each arc (i,j) with d(j) > d(i) + c ij replace d(j) by d(i) + c ij. 3 LIST := {1}LIST := { } 6 LIST := { 2 }LIST := { 2, 3 } 3 LIST := { 2, 3, 4 } 0

An Example 3 Take a node i from LIST 0      Update(i): for each arc (i,j) with d(j) > d(i) + c ij replace d(j) by d(i) + c ij. 3 LIST := {1}LIST := { } 6 LIST := { 2 }LIST := { 2, 3 } 3 LIST := { 2, 3, 4 } 3 LIST := { 3, 4 } 4 5 LIST := { 3, 4, 5 }

An Example 3 Take a node i from LIST 0      Update(i): for each arc (i,j) with d(j) > d(i) + c ij replace d(j) by d(i) + c ij LIST := { 3, 4, 5 } 3 LIST := { 4, 5 }

An Example 3 Take a node i from LIST 0      Update(i): for each arc (i,j) with d(j) > d(i) + c ij replace d(j) by d(i) + c ij LIST := { 3, 4, 5 } LIST := { 4, 5 } 4 LIST := { 5 } 6 LIST := { 5, 6 }

An Example 3 Take a node i from LIST 0      Update(i): for each arc (i,j) with d(j) > d(i) + c ij replace d(j) by d(i) + c ij LIST := { 3, 4, 5 } LIST := { 4, 5 }LIST := { 5 } 6 LIST := { 5, 6 } 5 LIST := { 6 }

An Example 3 Take a node i from LIST 0      Update(i): for each arc (i,j) with d(j) > d(i) + c ij replace d(j) by d(i) + c ij LIST := { 3, 4, 5 } LIST := { 4, 5 }LIST := { 5 } 6 LIST := { 5, 6 }LIST := { 6 } 6 LIST := { } 2 LIST := { 3 } 9 LIST := { 3, 7 }

An Example 3 Take a node i from LIST 0      Update(i): for each arc (i,j) with d(j) > d(i) + c ij replace d(j) by d(i) + c ij LIST := { 3, 4, 5 } LIST := { 4, 5 }LIST := { 5 } 6 LIST := { 5, 6 }LIST := { 6 }LIST := { } 2 LIST := { 3 } 9 LIST := { 3, 7 } 2 LIST := { 7 }

An Example 3 Take a node i from LIST 0      Update(i): for each arc (i,j) with d(j) > d(i) + c ij replace d(j) by d(i) + c ij LIST := { 3, 4, 5 } LIST := { 4, 5 }LIST := { 5 } 6 LIST := { 5, 6 }LIST := { 6 }LIST := { } 2 LIST := { 3 } 9 LIST := { 3, 7 }LIST := { 7 } 9 LIST := { }

An Example 3 LIST is empty. The distance labels are optimal 0      LIST := { 3, 4, 5 } LIST := { 4, 5 }LIST := { 5 } 6 LIST := { 5, 6 }LIST := { 6 }LIST := { } 2 LIST := { 3 } 9 LIST := { 3, 7 }LIST := { 7 }LIST := { } Here are the predecessors