Graphs II: Basic Algorithms :

Print this page
 
 
 
  •  The event queue in Dijkstra's algorithm can be implemented using array or heap.
 
             
 

All pairs shortest path

  •  Problem: In a given weighted directed graph find the shortest path between every pair of vertices.
  •  This problem can be solved by repeatedly invoking the single source shortest path algorithm for each vertex as a source.
  •  Another way of solving the problem is using dynamic programming technique. See any algorithms book.
               
Prev