Journey Planner Implementation This document involves the creation of a computer software application that allows the user to identify the shortest route between two specific London Underground stations. The application itself will be written in the Ruby scripting language, and the Underground schema will be stored in a MySQL database. To be effective, the application would provide an implementation of Dijkstra's shortest path algorithm. An initial prototype of the application would be a console-based application, i.e. a non-gui style application. This could be further developed into a graphical user interface (gui) application or possibly even a web-based application. The application should also provide administrative options to back up and restore the database and use MySQL scripts to create and populate the database schema. Logic Behind Software Choices Ruby was chosen as the primary scripting language because the problem space scales well to real-life objects and Ruby is strongly object-oriented. A solution to the shortest path algorithm will spend its time scanning the "nodes" in our case of subway line stations and the "edges" a connection between two adjacent stations. Ruby should make the job of applying Dijkstra's algorithm to generate code easier. MySQL was selected as the target database because MySQL is open source, readily available, and works well in tandem with Ruby. Project Environment and Design The project would be built on the Ubuntu Linux distribution and should make use of modern design practices such as modeling entity relationship diagrams for the database schema. The application itself should be object oriented and be designed with the help of The Unified Modeling The...... middle of the paper...... of adjacent nodes (stations) is connected in both directions. Is the application still working properly? Now include more stations/lines and run the test again. Next, decide on a database design that can load the nodes and edges. Modify the Ruby code to dynamically populate Nodes and Edge objects from the database. Again, test carefully. At this stage, the main "engine" of the application is ready. Modify the code so that it becomes parameterized and accepts the origin and destination station names generating appropriate trips. Develop MySQL scripts to input all London Underground lines and stations. How scalable is the application? Finally, wrap the application as a menu-driven program that prompts users for pairs of stations to which to calculate the shortest route and provides administration options to back up and restore the database.
tags