16-735 Assingment 5 - Visibility Graphs

Jeremy Stolarz

In these two movies the robot successfully plans a route to the goal in slightly different environments using visibility graphs.











In this movie the robot fails to arrive at the goal because it is on a different visibility graph than the goal is (they are disconnected). It's not all that exciting because the visibility graph and best path are drawn within the first few milliseconds of running the algorithm.





A note on the movies:
The small purple dots mark the vertices of the configuration space obstacles. Also the red line is the shortest path, which the robot follows to the goal. Blue lines show the visibility graph, while any gray lines mark the configuration space obstacle boundaries. The text in the upper right states whether the planner successfully found a path to the goal (not whether the robot actually follows that path).

Algorithm

The overall algorithm for this assignment was:
Constructing C-Space obstacles

My C-Space construction algorithm is rather simple: I essentially expand the boundaries of each obstacle by the length of the diagonal of the robot. Since my robot turns in place, and I did not wish to have to construct the real C-Space in SE2, I approximated it in 2-d by expanding the obstacle by its diagonal rather than by the robot's width and height at each time step. The boundary produced is thus equivalent to tracing the robot around the obstacle with the center of the robot as the reference point.

After the intial boundary expansion for each obstacle (rectangle), I then see if any of the boundaries intersect with boundaries from other obstacles. If they do, I save that intersection point as a vertex on each obstacle so they can be properly included in the visibility graph.

Building the visibility graphs

To build the visibility graph, for each vertex v of a C-space obstacle, I drew a line to each of the other vertices. If these lines did not intersect with any configuration space obstacles, then the vertex the line was drawn to was added to the "neighbor" list of v. The start and end locations were also considered "vertices" for this purpose.

Searching the graph for the shortest path to the goal

Once the graph was constructed as above, I used A* search (as in Assignment 4) to find the shortest path to the goal. I used the same heuristic of Euclidean distance to the goal for each vertex, and the cost function was the Euclidean distance between vertices.