A Deterministic Parallel APSP Algorithm and its Applications

In this paper we show a deterministic parallel all-pairs shortest paths algorithm for realweighted directed graphs. The algorithm has Õ(nm + (n/d)) work and Õ(d) depth for any depth parameter d ∈ [1, n]. To the best of our knowledge, such a trade-off has only been previously described for the real-weighted single-source shortest paths problem using randomization [Bringmann et al., ICALP’17]. Moreover, our result improves upon the parallelism of the state-of-the-art randomized parallel algorithm for computing transitive closure, which has Õ(nm+ n/d) work and Õ(d) depth [Ullman and Yannakakis, SIAM J. Comput. ’91]. Our APSP algorithm turns out to be a powerful tool for designing efficient planar graph algorithms in both parallel and sequential regimes. By suitably adjusting the depth parameter d and applying known techniques, we obtain: (1) nearly work-efficient Õ(n)-depth parallel algorithms for the real-weighted single-source shortest paths problem and finding a bipartite perfect matching in a planar graph, (2) an Õ(n)-time sequential strongly polynomial algorithm for computing a minimum mean cycle or a minimum cost-to-time-ratio cycle of a planar graph, (3) a slightly faster algorithm for computing so-called external dense distance graphs of all pieces of a recursive decomposition of a planar graph. One notable ingredient of our parallel APSP algorithm is a simple deterministic Õ(nm)-work Õ(d)-depth procedure for computing Õ(n/d)-size hitting sets of shortest d-hop paths between all pairs of vertices of a real-weighted digraph. Such hitting sets have also been called d-hub sets. Hub sets have previously proved especially useful in designing parallel or dynamic shortest paths algorithms and are typically obtained via random sampling. Our procedure implies, for example, an Õ(nm)-time deterministic algorithm for finding a shortest negative cycle of a real-weighted digraph. Such a near-optimal bound for this problem has been so far only achieved using a randomized algorithm [Orlin et al., Discret. Appl. Math. ’18]. ∗ a.karczmarz@mimuw.edu.pl. Supported by ERC Consolidator Grant 772346 TUgbOAT, the Polish National Science Centre 2018/29/N/ST6/00757 grant, and by the Foundation for Polish Science (FNP) via the START programme. † sank@mimuw.edu.pl. Supported by ERC Consolidator Grant 772346 TUgbOAT.

[1]  Aaron Sidford,et al.  Parallel Reachability in Almost Linear Work and Square Root Depth , 2019, 2019 IEEE 60th Annual Symposium on Foundations of Computer Science (FOCS).

[2]  Jeremy T. Fineman,et al.  Efficient construction of directed hopsets and parallel approximate shortest paths , 2019, STOC.

[3]  Edith Cohen,et al.  Polylog-time and near-linear work approximation scheme for undirected shortest paths , 1994, STOC '94.

[4]  Thomas H. Spencer,et al.  Time-work tradeoffs for parallel algorithms , 1997, JACM.

[5]  Adam Karczmarz,et al.  Reliable Hubs for Partially-Dynamic All-Pairs Shortest Paths in Directed Graphs , 2019, ESA.

[6]  Jason Li Faster parallel algorithm for approximate shortest path , 2020, STOC.

[7]  Donald B. Johnson,et al.  Efficient Algorithms for Shortest Paths in Sparse Networks , 1977, J. ACM.

[8]  David A. Bader,et al.  Parallel Algorithms for Evaluating Centrality Indices in Real-world Networks , 2006, 2006 International Conference on Parallel Processing (ICPP'06).

[9]  Daniel J. Kleitman,et al.  An Almost Linear Time Algorithm for Generalized Matrix Searching , 1990, SIAM J. Discret. Math..

[10]  Piotr Sankowski,et al.  Single Source -- All Sinks Max Flows in Planar Digraphs , 2012, 2012 IEEE 53rd Annual Symposium on Foundations of Computer Science.

[11]  Jeremy T. Fineman Nearly work-efficient parallel algorithm for digraph reachability , 2017, STOC.

[12]  James B. Orlin,et al.  Finding minimum cost to time ratio cycles with small integral transit times , 1993, Networks.

[13]  Image Segmentation with Minimum Mean Cut , 2001, ICCV.

[14]  Sivan Toledo,et al.  Applications of parametric searching in geometric optimization , 1992, SODA '92.

[15]  Panagiotis Charalampopoulos,et al.  Almost optimal distance oracles for planar graphs , 2018, STOC.

[16]  Christian Wulff-Nilsen,et al.  Shortest Paths in Planar Graphs with Real Lengths in O(nlog2n/loglogn) Time , 2009, ESA.

[17]  K. Subramani,et al.  Randomized algorithms for finding the shortest negative cost cycle in networks , 2018, Discret. Appl. Math..

[18]  Olga Veksler,et al.  Stereo Correspondence with Compact Windows via Minimum Ratio Cycle , 2002, IEEE Trans. Pattern Anal. Mach. Intell..

[19]  Bonnie Berger,et al.  Efficient NC Algorithms for Set Cover with Applications to Learning and Geometry , 1994, J. Comput. Syst. Sci..

[20]  Philip N. Klein,et al.  A linear-processor polylog-time algorithm for shortest paths in planar graphs , 1993, Proceedings of 1993 IEEE 34th Annual Foundations of Computer Science.

[21]  Seth Pettie,et al.  A new approach to all-pairs shortest paths on real-weighted graphs , 2004, Theor. Comput. Sci..

[22]  Satish Rao,et al.  Planar graphs, negative weight edges, shortest paths, and near linear time , 2006, J. Comput. Syst. Sci..

[23]  Robert E. Tarjan,et al.  Applications of a planar separator theorem , 1977, 18th Annual Symposium on Foundations of Computer Science (sfcs 1977).

[24]  Meena Mahajan,et al.  A new NC-algorithm for finding a perfect matching in bipartite planar and small genus graphs (extended abstract) , 2000, STOC '00.

[25]  Jesper Larsson Träff,et al.  A Parallel Priority Queue with Constant Time Operations , 1998, J. Parallel Distributed Comput..

[26]  Richard P. Brent,et al.  The Parallel Evaluation of General Arithmetic Expressions , 1974, JACM.

[27]  Haim Kaplan,et al.  Submatrix Maximum Queries in Monge Matrices and Partial Monge Matrices, and Their Applications , 2017, ACM Trans. Algorithms.

[28]  Richard M. Karp,et al.  A characterization of the minimum cycle mean in a digraph , 1978, Discret. Math..

[29]  Philip N. Klein,et al.  A Randomized Parallel Algorithm for Single-Source Shortest Paths , 1997, J. Algorithms.

[30]  Gary L. Miller,et al.  Finding small simple cycle separators for 2-connected planar graphs. , 1984, STOC '84.

[31]  Mihalis Yannakakis,et al.  High-probability parallel transitive closure algorithms , 1990, SPAA '90.

[32]  Glencora Borradaile,et al.  Min st-cut Oracle for Planar Graphs with Near-Linear Preprocessing Time , 2010, 2010 IEEE 51st Annual Symposium on Foundations of Computer Science.

[33]  Éva Tardos,et al.  A strongly polynomial minimum cost circulation algorithm , 1985, Comb..

[34]  Gary L. Miller,et al.  Flow in Planar Graphs with Multiple Sources and Sinks , 1995, SIAM J. Comput..

[35]  Valerie King,et al.  Fully dynamic algorithms for maintaining all-pairs shortest paths and transitive closure in digraphs , 1999, 40th Annual Symposium on Foundations of Computer Science (Cat. No.99CB37039).

[36]  Alok Aggarwal,et al.  Parallel Searching in Generalized Monge Arrays , 1997, Algorithmica.

[37]  Yijie Han,et al.  Efficient parallel algorithms for computing all pair shortest paths in directed graphs , 1992, SPAA '92.

[38]  Edith Cohen Efficient parallel shortest-paths in digraphs with a separator decomposition , 1993, SPAA '93.

[39]  S. Sitharama Iyengar,et al.  Introduction to parallel algorithms , 1998, Wiley series on parallel and distributed computing.

[40]  Piotr Sankowski,et al.  Decremental single-source reachability in planar digraphs , 2017, STOC.

[41]  Panagiotis Charalampopoulos,et al.  Exact Distance Oracles for Planar Graphs with Failing Vertices , 2018, SODA.

[42]  Karl Bringmann,et al.  Improved Algorithms for Computing the Cycle of Minimum Cost-to-Time Ratio in Directed Graphs , 2017, ICALP.

[43]  Thomas H. Spencer,et al.  Time-Work Tradeoffs of the Single-Source Shortest Paths Problem , 1999, J. Algorithms.

[44]  Danupon Nanongkai,et al.  A Faster Distributed Single-Source Shortest Paths Algorithm , 2017, 2018 IEEE 59th Annual Symposium on Foundations of Computer Science (FOCS).

[45]  K. Subramani,et al.  Optimal Length Resolution Refutations of Difference Constraint Systems , 2009, Journal of Automated Reasoning.

[46]  Adam Karczmarz Decrementai Transitive Closure and Shortest Paths for Planar Digraphs and Beyond , 2018, SODA.

[47]  Ian H. Jermyn,et al.  Globally Optimal Regions and Boundaries as Minimum Ratio Weight Cycles , 2001, IEEE Trans. Pattern Anal. Mach. Intell..

[48]  Uri Zwick,et al.  All pairs shortest paths using bridging sets and rectangular matrix multiplication , 2000, JACM.

[49]  Mihalis Yannakakis,et al.  High-Probability Parallel Transitive-Closure Algorithms , 1991, SIAM J. Comput..

[50]  Pawel Gawrychowski,et al.  Improved Bounds for Shortest Paths in Dense Distance Graphs , 2018, ICALP.

[51]  Ramesh Hariharan,et al.  Improved decremental algorithms for maintaining transitive closure and all-pairs shortest paths , 2002, STOC '02.

[52]  Robert E. Tarjan,et al.  Faster parametric shortest path and minimum-balance algorithms , 1991, Networks.

[53]  Guy E. Blelloch,et al.  Parallel Shortest Paths Using Radius Stepping , 2016, SPAA.

[54]  Christian Sommer,et al.  Exact distance oracles for planar graphs , 2010, SODA.

[55]  Edith Cohen Using Selective Path-Doubling for Parallel Shortest-Path Computations , 1997, J. Algorithms.

[56]  Philip N. Klein,et al.  Shortest paths in directed planar graphs with negative lengths: A linear-space O(n log2 n)-time algorithm , 2010, TALG.

[57]  Jeffrey Mark Siskind,et al.  Image Segmentation with Ratio Cut , 2003, IEEE Trans. Pattern Anal. Mach. Intell..

[58]  Shiri Chechik,et al.  Simplifying and Unifying Replacement Paths Algorithms in Weighted Directed Graphs , 2020, ICALP.

[59]  Philip N. Klein,et al.  Structured recursive separator decompositions for planar graphs in linear time , 2012, STOC '13.

[60]  Xiaofeng Gu,et al.  Improved algorithms for optimal length resolution refutation in difference constraint systems , 2011, Formal Aspects of Computing.

[61]  Aaron Bernstein Maintaining Shortest Paths Under Deletions in Weighted Directed Graphs , 2016, SIAM J. Comput..

[62]  Alexandr Andoni,et al.  Parallel approximate undirected shortest paths via low hop emulators , 2019, STOC.

[63]  Philip N. Klein,et al.  Multiple-source shortest paths in planar graphs , 2005, SODA '05.

[64]  Nimrod Megiddo,et al.  Applying parallel computation algorithms in the design of serial algorithms , 1981, 22nd Annual Symposium on Foundations of Computer Science (sfcs 1981).