Determining Fixed-Length Paths in Directed and Undirected Edge-Weighted Graphs

Authors Daniel Hambly , Rhyd Lewis , Padraig Corcoran



PDF
Thumbnail PDF

File

LIPIcs.SEA.2024.15.pdf
  • Filesize: 0.73 MB
  • 11 pages

Document Identifiers

Author Details

Daniel Hambly
  • School of Mathematics, Cardiff University, Wales, UK
Rhyd Lewis
  • School of Mathematics, Cardiff University, Wales, UK
Padraig Corcoran
  • School of Computer Science and Informatics, Cardiff University, Wales, UK

Cite AsGet BibTex

Daniel Hambly, Rhyd Lewis, and Padraig Corcoran. Determining Fixed-Length Paths in Directed and Undirected Edge-Weighted Graphs. In 22nd International Symposium on Experimental Algorithms (SEA 2024). Leibniz International Proceedings in Informatics (LIPIcs), Volume 301, pp. 15:1-15:11, Schloss Dagstuhl – Leibniz-Zentrum für Informatik (2024)
https://doi.org/10.4230/LIPIcs.SEA.2024.15

Abstract

In this paper, we examine the NP-hard problem of identifying fixed-length s-t paths in edge-weighted graphs - that is, a path of a desired length k from a source vertex s to a target vertex t. Many existing strategies look at paths whose lengths are determined by the number of edges in the path. We, however, look at the length of the path as the sum of the edge weights. Here, three exact algorithms for this problem are proposed: the first based on an integer programming (IP) formulation, the second a backtracking algorithm, and the third based on an extension of Yen’s algorithm. Analysis of these algorithms on random graphs shows that the backtracking algorithm performs best on smaller values of k, whilst the IP is preferable for larger values of k.

Subject Classification

ACM Subject Classification
  • Theory of computation → Backtracking
  • Theory of computation → Integer programming
  • Information systems → Fixed length attributes
Keywords
  • Graphs
  • paths
  • backtracking
  • integer programming
  • Yen’s algorithm

Metrics

  • Access Statistics
  • Total Accesses (updated on a weekly basis)
    0
    PDF Downloads

References

  1. Noga Alon, Raphael Yuster, and Uri Zwick. Color-coding. J. ACM, 42(4):844-856, 1995. URL: https://doi.org/10.1145/210332.210337.
  2. Stefano Basagni, Danilo Bruschi, and F. Ravasio. On the difficulty of finding walks of length k. RAIRO Theor. Informatics Appl., 31(5):429-435, 1997. URL: https://doi.org/10.1051/ita/1997310504291.
  3. Eric T. Bax. Algorithms to count paths and cycles. Inf. Process. Lett., 52(5):249-252, 1994. URL: https://doi.org/10.1016/0020-0190(94)00151-0.
  4. Eric T. Bax and Joel Franklin. A finite-difference sieve to count paths and cycles by length. Inf. Process. Lett., 60(4):171-176, 1996. URL: https://doi.org/10.1016/S0020-0190(96)00159-7.
  5. Etienne Birmelé, Rui A. Ferreira, Roberto Grossi, Andrea Marino, Nadia Pisanti, Romeo Rizzi, and Gustavo Sacomoto. Optimal listing of cycles and st-paths in undirected graphs. In Sanjeev Khanna, editor, Proceedings of the Twenty-Fourth Annual ACM-SIAM Symposium on Discrete Algorithms, SODA 2013, New Orleans, Louisiana, USA, January 6-8, 2013, pages 1884-1896. SIAM, SIAM, 2013. URL: https://doi.org/10.1137/1.9781611973105.134.
  6. Andreas Björklund, Thore Husfeldt, Petteri Kaski, and Mikko Koivisto. The fast intersection transform with applications to counting paths. CoRR, abs/0809.2489, 2008. URL: https://doi.org/10.48550/arXiv.0809.2489.
  7. Andreas Björklund, Thore Husfeldt, Petteri Kaski, and Mikko Koivisto. Narrow sieves for parameterized paths and packings. J. Comput. Syst. Sci., 87:119-139, 2017. URL: https://doi.org/10.1016/j.jcss.2017.03.003.
  8. Hans L. Bodlaender. On linear time minor tests with depth-first search. J. Algorithms, 14(1):1-23, 1993. URL: https://doi.org/10.1006/jagm.1993.1001.
  9. J.A. Bondy and G. Fan. Optimal paths and cycles in weighted graphs. In Graph Theory in Memory of G.A. Dirac, volume 41 of Annals of Discrete Mathematics, pages 53-69. Elsevier, 1988. URL: https://doi.org/10.1016/S0167-5060(08)70449-7.
  10. David Chalupa, Phininder Balaghan, Ken A. Hawick, and Neil A. Gordon. Computational methods for finding long simple cycles in complex networks. Knowl. Based Syst., 125:96-107, 2017. URL: https://doi.org/10.1016/j.knosys.2017.03.022.
  11. Jianer Chen, Joachim Kneis, Songjian Lu, Daniel Mölle, Stefan Richter, Peter Rossmanith, Sing-Hoi Sze, and Fenghui Zhang. Randomized divide-and-conquer: Improved path, matching, and packing algorithms. SIAM Journal on Computing, 38(6):2526-2547, 2009. Google Scholar
  12. Jianer Chen, Songjian Lu, Sing-Hoi Sze, and Fenghui Zhang. Improved algorithms for path, matching, and packing problems. In Nikhil Bansal, Kirk Pruhs, and Clifford Stein, editors, Proceedings of the Eighteenth Annual ACM-SIAM Symposium on Discrete Algorithms, SODA 2007, New Orleans, Louisiana, USA, January 7-9, 2007, volume 7, pages 298-307. Citeseer, SIAM, 2007. URL: http://dl.acm.org/citation.cfm?id=1283383.1283415.
  13. Gabriel Andrew Dirac. Some theorems on abstract graphs. Proceedings of the London Mathematical Society, 3(1):69-81, 1952. Google Scholar
  14. David Eppstein. Finding the k shortest paths. SIAM J. Comput., 28(2):652-673, 1998. URL: https://doi.org/10.1137/S0097539795290477.
  15. Jörg Flum and Martin Grohe. The parameterized complexity of counting problems. SIAM J. Comput., 33(4):892-922, 2004. URL: https://doi.org/10.1137/S0097539703427203.
  16. Fedor V. Fomin, Petr A. Golovach, Tuukka Korhonen, Kirill Simonov, and Giannos Stamoulis. Fixed-parameter tractability of maximum colored path and beyond. In Nikhil Bansal and Viswanath Nagarajan, editors, Proceedings of the 2023 ACM-SIAM Symposium on Discrete Algorithms, SODA 2023, Florence, Italy, January 22-25, 2023, pages 3700-3712. SIAM, SIAM, 2023. URL: https://doi.org/10.1137/1.9781611977554.ch142.
  17. Fedor V. Fomin, Petr A. Golovach, Danil Sagunov, and Kirill Simonov. Algorithmic extensions of dirac’s theorem. In Joseph (Seffi) Naor and Niv Buchbinder, editors, Proceedings of the 2022 ACM-SIAM Symposium on Discrete Algorithms, SODA 2022, Virtual Conference / Alexandria, VA, USA, January 9 - 12, 2022, pages 406-416. SIAM, SIAM, 2022. URL: https://doi.org/10.1137/1.9781611977073.20.
  18. Fedor V. Fomin, Daniel Lokshtanov, Fahad Panolan, and Saket Saurabh. Efficient computation of representative families with applications in parameterized and exact algorithms. J. ACM, 63(4):29:1-29:60, 2016. URL: https://doi.org/10.1145/2886094.
  19. A. Frieze, C. McDiarmid, and B. Reed. On a conjecture of Bondy and Fan. Ars Combin., 33:329-336, 1992. Google Scholar
  20. T Gallai et al. On maximal paths and circuits of graphs. Acta Math. Acad. Sci. Hungar, 10:337-356, 1959. Google Scholar
  21. Pierre-Louis Giscard, Nils M. Kriege, and Richard C. Wilson. A general purpose algorithm for counting simple cycles and simple paths of any length. Algorithmica, 81(7):2716-2737, 2019. URL: https://doi.org/10.1007/s00453-019-00552-1.
  22. Daniel Hambly, Rhyd Lewis, and Padraig Corcoran. Code and Data for the Paper "Determining Fixed-Length Paths in Directed and Undirected Edge-Weighted Graphs". Software, version 1.0. (visited on 2024-06-28). URL: https://zenodo.org/doi/10.5281/zenodo.11059135.
  23. Magnus Lie Hetland. Python Algorithms: mastering basic algorithms in the Python Language. Apress, 2014. Google Scholar
  24. Brian P Kelley, Roded Sharan, Richard M Karp, Taylor Sittler, David E Root, Brent R Stockwell, and Trey Ideker. Conserved pathways within bacteria and yeast as revealed by global protein network alignment. Proceedings of the National Academy of Sciences, 100(20):11394-11399, 2003. Google Scholar
  25. Joachim Kneis, Daniel Mölle, Stefan Richter, and Peter Rossmanith. Divide-and-color. In Fedor V. Fomin, editor, Graph-Theoretic Concepts in Computer Science, 32nd International Workshop, WG 2006, Bergen, Norway, June 22-24, 2006, Revised Papers, volume 4271 of Lecture Notes in Computer Science, pages 58-67. Springer, Springer, 2006. URL: https://doi.org/10.1007/11917496_6.
  26. W. Kocay and D.L. Kreher. Graphs, Algorithms, and Optimization, Second Edition. Discrete Mathematics and Its Applications. CRC Press, 2016. Google Scholar
  27. Ioannis Koutis. Faster algebraic algorithms for path and packing problems. In Luca Aceto, Ivan Damgård, Leslie Ann Goldberg, Magnús M. Halldórsson, Anna Ingólfsdóttir, and Igor Walukiewicz, editors, Automata, Languages and Programming, 35th International Colloquium, ICALP 2008, Reykjavik, Iceland, July 7-11, 2008, Proceedings, Part I: Tack A: Algorithms, Automata, Complexity, and Games, volume 5125 of Lecture Notes in Computer Science, pages 575-586. Springer, Springer, 2008. URL: https://doi.org/10.1007/978-3-540-70575-8_47.
  28. Rhyd Lewis and Padraig Corcoran. Finding fixed-length circuits and cycles in undirected edge-weighted graphs: an application with street networks. J. Heuristics, 28(3):259-285, 2022. URL: https://doi.org/10.1007/s10732-022-09493-5.
  29. Rhyd Lewis, Padraig Corcoran, and Andrei V. Gagarin. Methods for determining cycles of a specific length in undirected graphs with edge weights. J. Comb. Optim., 46(5):29, 2023. URL: https://doi.org/10.1007/s10878-023-01091-w.
  30. Burkhard Monien. How to find long paths efficiently. In North-Holland Mathematics Studies, volume 109, pages 239-254. Elsevier, 1985. Google Scholar
  31. Sandro Montanari and Paolo Penna. On sampling simple paths in planar graphs according to their lengths. In Giuseppe F. Italiano, Giovanni Pighizzini, and Donald Sannella, editors, Mathematical Foundations of Computer Science 2015 - 40th International Symposium, MFCS 2015, Milan, Italy, August 24-28, 2015, Proceedings, Part II, volume 9235 of Lecture Notes in Computer Science, pages 493-504. Springer, Springer, 2015. URL: https://doi.org/10.1007/978-3-662-48054-0_41.
  32. Christos H. Papadimitriou and Mihalis Yannakakis. On limited nondeterminism and the complexity of the V-C dimension. J. Comput. Syst. Sci., 53(2):161-170, 1996. URL: https://doi.org/10.1006/jcss.1996.0058.
  33. Ben Roberts and Dirk P. Kroese. Estimating the number of s-t paths in a graph. J. Graph Algorithms Appl., 11(1):195-214, 2007. URL: https://doi.org/10.7155/jgaa.00142.
  34. Jacob Scott, Trey Ideker, Richard M. Karp, and Roded Sharan. Efficient algorithms for detecting signaling pathways in protein interaction networks. J. Comput. Biol., 13(2):133-144, 2006. URL: https://doi.org/10.1089/cmb.2006.13.133.
  35. R. Sedgewick. Algorithms in Java, Part 5: Graph Algorithms, 3rd Edition. Addison-Wesley Professional, 2003. Google Scholar
  36. Robert Sedgewick and Kevin Wayne. Algorithms, 4th Edition. Addison-Wesley, 2011. Google Scholar
  37. Dekel Tsur. Faster deterministic parameterized algorithm for k-path. Theor. Comput. Sci., 790:96-104, 2019. URL: https://doi.org/10.1016/j.tcs.2019.04.024.
  38. Leslie G. Valiant. The complexity of enumeration and reliability problems. SIAM J. Comput., 8(3):410-421, 1979. URL: https://doi.org/10.1137/0208032.
  39. Piet Van Mieghem. Graph spectra for complex networks. Cambridge university press, 2023. Google Scholar
  40. David Willems, Oliver Zehner, and Stefan Ruzika. On a technique for finding running tracks of specific length in a road network. In Natalia Kliewer, Jan Fabian Ehmke, and Ralf Borndörfer, editors, Operations Research Proceedings 2017, Selected Papers of the Annual International Conference of the German Operations Research Society (GOR), Freie Universiät Berlin, Germany, September 6-8, 2017, Operations Research Proceedings, pages 333-338. Springer, Springer, 2017. URL: https://doi.org/10.1007/978-3-319-89920-6_45.
  41. Ryan Williams. Finding paths of length k in o^*(2^k) time. Inf. Process. Lett., 109(6):315-318, 2009. URL: https://doi.org/10.1016/j.ipl.2008.11.004.
  42. Jin Y Yen. Finding the k shortest loopless paths in a network. management Science, 17(11):712-716, 1971. Google Scholar
  43. Meirav Zehavi. Mixing color coding-related techniques. In Nikhil Bansal and Irene Finocchi, editors, Algorithms - ESA 2015 - 23rd Annual European Symposium, Patras, Greece, September 14-16, 2015, Proceedings, volume 9294 of Lecture Notes in Computer Science, pages 1037-1049. Springer, Springer, 2015. URL: https://doi.org/10.1007/978-3-662-48350-3_86.