Computer Science > Data Structures and Algorithms
[Submitted on 11 Apr 2022]
Title:Constrained Shortest Path and Hierarchical Structures
View PDFAbstract:The Constraint Shortest Path (CSP) problem is as follows. An $n$-vertex graph is given, each edge/arc assigned two weights. Let us call them "cost" and "length" for definiteness. Finding a min-cost upper-bounded length path between a given pair of vertices is required. The problem is NP-hard even when the lengths of all edges are the same. Therefore, various approximation algorithms have been proposed in the literature for it. The constraint on path length can be accounted for by considering one edge weight equals to a linear combination of cost and length. By varying the multiplier value in a linear combination, a feasible solution delivers a minimum to the function with new weights. At the same time, Dijkstra's algorithm or its modifications are used to construct the shortest path with the current weights of the edges. However, with insufficiently large graphs, this approach may turn out to be time-consuming. In this article, we propose to look for a solution, not in the original graph but specially constructed hierarchical structures (HS). We show that the shortest path in the HS is constructed with $O(m)$-time complexity, where $m$ is the number of edges/arcs of the graph, and the approximate solution in the case of integer costs and lengths of the edges is found with $O(m\log n)$-time complexity. The a priori estimate of the algorithm's accuracy turned out to depend on the parameters of the problem and can be significant. Therefore, to evaluate the algorithm's effectiveness, we conducted a numerical experiment on the graphs of roads of megalopolis and randomly constructed unit-disk graphs (UDGs). The numerical experiment results show that in the HS, a solution close to optimal one is built 10--100 times faster than in the methods which use Dijkstra's algorithm to build a min-weight path in the original graph.
References & Citations
Bibliographic and Citation Tools
Bibliographic Explorer (What is the Explorer?)
Connected Papers (What is Connected Papers?)
Litmaps (What is Litmaps?)
scite Smart Citations (What are Smart Citations?)
Code, Data and Media Associated with this Article
alphaXiv (What is alphaXiv?)
CatalyzeX Code Finder for Papers (What is CatalyzeX?)
DagsHub (What is DagsHub?)
Gotit.pub (What is GotitPub?)
Hugging Face (What is Huggingface?)
Papers with Code (What is Papers with Code?)
ScienceCast (What is ScienceCast?)
Demos
Recommenders and Search Tools
Influence Flower (What are Influence Flowers?)
CORE Recommender (What is CORE?)
arXivLabs: experimental projects with community collaborators
arXivLabs is a framework that allows collaborators to develop and share new arXiv features directly on our website.
Both individuals and organizations that work with arXivLabs have embraced and accepted our values of openness, community, excellence, and user data privacy. arXiv is committed to these values and only works with partners that adhere to them.
Have an idea for a project that will add value for arXiv's community? Learn more about arXivLabs.