
FINAL REPORT 3
1.2.4. Route and Multi-Waypoint Formulation. A route is a walk π = (v
0
, e
1
, v
1
, . . . , e
k
, v
k
) in G. Its
total weighted cost is
(6) W (π) =
k
i=1
w(e
i
, σ, P ),
and its total displayed travel time is computed using the adjusted costs ˆc (without the preference dis-
count), so that the displayed time reflects true traversal duration rather than the artificial cost used to
bias routing.
When the user specifies m ≥ 1 intermediate waypoints in addition to origin and destination, the
full journey is decomposed into m + 1 independent sub-problems. Given an ordered waypoint sequence
(w
0
, w
1
, . . . , w
m+1
), the optimal route for each segment [w
i
, w
i+1
] is found independently, and the full
route is their concatenation.
1.2.5. Multi-Candidate Route Generation. Rather than returning a single optimal route, the system
generates a small set of candidate routes by solving the shortest-path problem under several distinct
preference profiles derived from the user’s input (for example, one enforcing stair avoidance and another
promoting lift usage). Duplicate routes, identified by equality of their ordered edge sequences, are
discarded. The surviving candidates are then ranked and labelled according to secondary criteria such
as total travel time and number of stops.
2. Surveying of Existing Solutions
As planned, six existing solutions for navigation, grouped into three categories, were surveyed and
evaluated on different aspects. The solutions are first compared in an overall manner in Table 1, and
then compared in a more detailed manner with focus on specific features in Table 2.
The three categories of solutions surveyed are: (1) general-purpose navigation applications, repre-
sented by Google Maps and Citymapper; (2) transit-specific applications, represented by MTR Mobile
and HKBUS.app; and (3) static campus reference tools, represented by the HKU campus map and on-
campus signage. The general-purpose navigation applications provide dynamic estimated times of arrival,
multi-modal transfer handling, and city-scale route planning, but both perform poorly in multi-floor en-
vironments such as the HKU campus and operate exclusively online. The transit-specific applications
are limited in scope to their respective transport modes: MTR Mobile supports only station-to-station
queries within the MTR and light rail network, while HKBUS.app restricts users to at most one bus
transfer and cannot locate the user or direct them to the nearest bus stop. Both transit apps also require
a live network connection. The static campus reference tools — the HKU campus map and on-campus
signage — provide a visual overview of building locations and nearby paths, but are non-interactive,
offer no route direction or estimated arrival time, and are inherently unable to adapt to a user’s starting
point or destination.
The surveying exercise informed several concrete design decisions for this project. The station-based
topology of transit apps, in which discrete named stops are connected by typed transport links, was
adopted as the foundational data model, resulting in the node-and-edge multigraph representation de-
scribed in subsection 1.2. The accessibility mode offered by Google Maps — which avoids stairs and
promotes lift usage — motivated the Accessible Route preference toggle and the hard-exclusion mecha-
nism in the cost function. The route suggestion display of Citymapper, which presents fare and expected
time for each option in a compact list, informed the design of the route card display, where each candidate
route is accompanied by a time estimate, stop count, and a salient label indicating its primary charac-
teristic. Finally, the dependence of all surveyed online solutions on live network connectivity, contrasted
with the offline availability of the HKU campus map PDF, motivated the decision to bundle a static copy
of the campus dataset within the application, ensuring full functionality in offline or restricted-network
environments.
3. Core Implementation
3.1. System Architecture Overview. The project is constructed with a layered and modular ar-
chitecture, as illustrated in Figure 1. The project enforces principles of object-oriented programming
throughout its design, with some utility functions implemented in a functional style to avoid boilerplate
code and improve readability. The design allows a clear separation of data representation, data parsing,
route-finding business logic, and state management of the user interface, which facilitates maintainability
of the codebase.