Graph Shortest Paths: Consider the following directed, weighted graph:
Even though the graph has negative weight edges, step through Dijkstra's algorithm to calculate supposedly shortest paths from A to every other vertex. Show your steps in the table below. At the end of each step, show the distances as they are after relaxation (in the beginning, only d[A] is 0, the rest are 0 shown for your convenience). Also, list for each vertex its Edge To (which is the edge that marks the final step in the shortest path as shown in class). Under "Vertex," show the vertex being added to the tree (taken out of the priority queue) at that stage:
Step Start Vertex d[A] Final Dist: EdgeTo:
1 A 0
2 B ∞
3 C ∞
4 D ∞
5 E ∞
6 F ∞
7 G ∞
8 H ∞
9 I ∞
10 J ∞
Due to the negative edges, Dijkstra's algorithm found the wrong path to some of the vertices. For just the vertices where the wrong path was computed, write both the path that was computed by Dijkstra and the correct path and their weights. There are three such paths.
Path 1: Computed weight: 10, Correct weight: 9
Path 2: Computed weight: 8, Correct weight: 7
Path 3: Computed weight: 12, Correct weight: 11
What single edge could be removed from the graph such that Dijkstra's algorithm would show the correct path for all vertices? Explain.