Lecture9

Lecture9 - Graphs and Network Flows ISE 411 Lecture 9 Dr...

• 15

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

Graphs and Network Flows ISE 411 Lecture 9 Dr. Ted Ralphs

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

ISE 411 Lecture 9 1 References for Today’s Lecture Required reading Section 21.2 References AMO Sections 4.5–4.7 CLRS Section 24.3
ISE 411 Lecture 9 2 Solving SPP with Non-Negative Arc Lengths When there are cycles, the situation is a bit more complex. Dijkstra’s Algorithm generalizes the algorithm from Lecture 7 for the acyclic case. The difference is the order in which the nodes are examined. As before, nodes are divided into two groups temporarily labeled permanently labeled In order to produce the shortest paths tree, we keep track of the predecessor node each time a label is updated. Basic Idea : Fan out from source and permanently label nodes in order of distance from the source.

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

ISE 411 Lecture 9 3 Dijkstra’s Algorithm Input: An network G = ( N, A ) and a vector of arc lengths c Z A + Output: d ( i ) is the length of a shortest path from node s to node i and pred(i) is the immediate predecessor of i in an associated shortest paths tree. S := ¯ S := N d ( i ) ← ∞∀ i N d ( s ) 0 and pred ( s ) 0 while | S | < n do let i ¯ S be the node for which d ( i ) = min { d ( j ) : j ¯ S } S S ∪ { i } ¯ S ¯ S \ { i } for ( i, j ) A ( i ) do if d ( j ) > d ( i ) + c ij then d ( j ) d ( i ) + c ij and pred ( j ) i end if
This is the end of the preview. Sign up to access the rest of the document.
• Spring '14
• TedRalphs
• Graph Theory, Binary heap, Priority queue

{[ snackBarMessage ]}

What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern