English

Constructing a Distance Sensitivity Oracle in $O(n^{2.5794}M)$ Time

Data Structures and Algorithms 2021-08-04 v2

Abstract

We continue the study of distance sensitivity oracles (DSOs). Given a directed graph GG with nn vertices and edge weights in {1,2,,M}\{1, 2, \dots, M\}, we want to build a data structure such that given any source vertex uu, any target vertex vv, and any failure ff (which is either a vertex or an edge), it outputs the length of the shortest path from uu to vv not going through ff. Our main result is a DSO with preprocessing time O(n2.5794M)O(n^{2.5794}M) and constant query time. Previously, the best preprocessing time of DSOs for directed graphs is O(n2.7233M)O(n^{2.7233}M), and even in the easier case of undirected graphs, the best preprocessing time is O(n2.6865M)O(n^{2.6865}M) [Ren, ESA 2020]. One drawback of our DSOs, though, is that it only supports distance queries but not path queries. Our main technical ingredient is an algorithm that computes the inverse of a degree-dd polynomial matrix (i.e. a matrix whose entries are degree-dd univariate polynomials) modulo xrx^r. The algorithm is adapted from [Zhou, Labahn, and Storjohann, Journal of Complexity, 2015], and we replace some of its intermediate steps with faster rectangular matrix multiplication algorithms. We also show how to compute unique shortest paths in a directed graph with edge weights in {1,2,,M}\{1, 2, \dots, M\}, in O(n2.5286M)O(n^{2.5286}M) time. This algorithm is crucial in the preprocessing algorithm of our DSO. Our solution improves the O(n2.6865M)O(n^{2.6865}M) time bound in [Ren, ESA 2020], and matches the current best time bound for computing all-pairs shortest paths.

Keywords

Cite

@article{arxiv.2102.08569,
  title  = {Constructing a Distance Sensitivity Oracle in $O(n^{2.5794}M)$ Time},
  author = {Yong Gu and Hanlin Ren},
  journal= {arXiv preprint arXiv:2102.08569},
  year   = {2021}
}

Comments

accepted to ICALP 2021

R2 v1 2026-06-23T23:14:09.331Z