In this assignment, you will build an animation of the single pair shortest path algorithm on a directed graph. You can assume that edge weights will always be positive. As before, use the samba tool. You should try to make the animation as informative and interesting as possible. You will be graded on the correctness of the animation (does it accurately reflect the operation of the algorithm), its informative content (does it really help explain what the algorithm is doing), and its general originality and visual aesthetics.
The input files for your programs will consist of 4 sequential sections. The first section is simply one integer number which denotes how many vertices are in the graph. The next section, one line per vertex, provides the x, y position of each vertex (0.0 - 1.0 coordinate system in both dimensions). The third section provides the adjacency matrix for the graph, with each non-zero entry indicating the weight of that edge. The final section will consist of two integer numbers, the start and end vertex numbers of the path, respectively. (Assume that we start counting at 1.)
Again, all you need to do to submit your assignment is to use the 3158in program to electronically submit the ascii trace file of the animator commands for that special input set.
5 0.2 0.4 0.45 0.3 0.3 0.85 0.6 0.55 0.9 0.65 0 3 0 7 0 4 0 3 5 0 0 1 0 6 0 2 5 0 0 7 0 3 4 0 0 1 5