# Dijkstra, Floyd and Warshall meet Kleene

- 370 Downloads
- 15 Citations

## Abstract

Around 1960, Dijkstra, Floyd and Warshall published papers on algorithms for solving single-source and all-sources shortest path problems, respectively. These algorithms, nowadays named after their inventors, are well known and well established. This paper sheds an algebraic light on these algorithms. We combine the shortest path problems with Kleene algebra, also known as Conway’s regular algebra. This view yields a purely algebraic version of Dijkstra’s shortest path algorithm and the one by Floyd/Warshall. Moreover, the algebraic abstraction yields applications of these algorithms to structures different from graphs and pinpoints the mathematical requirements on the underlying cost algebra that ensure their correctness.

## Keywords

Algebra Algorithms Shortest-path Kleene algebra Semiring## Preview

Unable to display preview. Download preview PDF.

## References

- AHU74.Aho AV, Hopcroft JE, Ullman JD (1974) The design and analysis of computer algorithms. Addison-Wesley, USAzbMATHGoogle Scholar
- BC75.Backhouse R, Carré B (1975) Regular algebra applied to path-finding problems. IMA J Appl Math 15(2): 161–186zbMATHCrossRefGoogle Scholar
- BEG94.Backhouse R, van den Eijnde J, van Gasteren A (1994) Calculating path algorithms. Sci Comput Progr 22(1–2): 3–19zbMATHCrossRefGoogle Scholar
- Bel58.Bellman R (1958) On a routing problem. Quart Appl Math 16: 87–90MathSciNetzbMATHGoogle Scholar
- Ber62.Berge C (1962) The theory of graphs and its applications. MethuenGoogle Scholar
- Car71.Carré B (1971) An algebra for network routing problems. IMA J Appl Math 7: 273–294zbMATHCrossRefGoogle Scholar
- Car79.Carré B (1979) Graphs and networks.Oxford applied mathematics and computing science series. Clarendon Press, Oxford UniversityGoogle Scholar
- CFM08.Coltun R, Ferguson D, Moy J (2008) OSPF for IPv6. RFC 2328 (Standard, Errata Exist)Google Scholar
- Con71.Conway J (1971) Regular algebra and finite machines. Chapman and Hall, LondonGoogle Scholar
- Dan60.Dantzig G (1960) On the shortest route through a network. Manag Sci 6: 187–190MathSciNetzbMATHCrossRefGoogle Scholar
- Dij59.Dijkstra E (1959) A note on two problems in connexion with graphs. Numer Mathe 1: 269–271MathSciNetzbMATHCrossRefGoogle Scholar
- DP02.Davey B, Priestley H (2002) Introduction to lattices and order. Cambridge University Press, LondonzbMATHCrossRefGoogle Scholar
- Flo62.Floyd R (1962) Algorithm 97: Shortest path. Commun ACM 5: 345CrossRefGoogle Scholar
- GM79.Gondran M, Minoux M (1979) Graphes et algorithmes. EyrollesGoogle Scholar
- GM88.Gondran M, Minoux M (1988) Graphs and Algorithms. WileyGoogle Scholar
- GM08.Gondran M, Minoux M (2008) Graphs, Dioids and Semirings—new models and algorithms. Springer, BerlinzbMATHGoogle Scholar
- HM11.Höfner P, McIver A (2011) Towards an algebra of routing tables. In: de Swart H (ed) Relations and Kleene algebra in computer science, lecture notes in computer science, vol 6663. Springer, Berlin, pp 212–229Google Scholar
- Hol98.Hollenberg M (1998) Equational axioms of test algebra. In: Nielsen M, Thomas W (eds) CSL ’97: selected papers from the 11th international workshop on computer science logic, lecture notes in computer science, vol 1414Google Scholar
- HS07.Höfner P, Struth G (2007) Automated reasoning in Kleene algebra. In: Pfennig F (ed) Automated deduction, lecture notes in artificial intelligence, vol 4603. Springer, Berlin, pp 279–294Google Scholar
- Kle51.Kleene S (1951) Representation of events in nerve nets and finite automata. Technical Report RM-704, RAND Corporation RAND Research MemorandumGoogle Scholar
- Kle52.Kleene SC (1952) Introduction to metamathematics. Van NostrandGoogle Scholar
- Koz94.Kozen D (1994) A completeness theorem for Kleene algebras and the algebra of regular events. Inf Comput 110(2): 366–390MathSciNetzbMATHCrossRefGoogle Scholar
- Koz97.Kozen D (1997) Kleene algebra with tests. ACM Trans Progr Lang Syst 19(3): 427–443CrossRefGoogle Scholar
- LT91a.Lengauer T, Theune D (1991) Efficient algorithms for path problems with general cost citeria. In: Leach Albert J, Burkhard Monien B, Rodríguez-Artalejo M (eds) Automata, languages and programming, 18th International colloquium, ICALP91, Madrid, Spain, July 8–12, 1991, proceedings. Lecture notes in computer science vol 510. Springer, Berlin, pp 314–326Google Scholar
- LT91b.Lengauer T, Theune D (1991) Unstructured path problems and the making of semirings (preliminary version). In: Dehne F, Sack J-R, Santoro N (eds) Algorithms and data structures, 2nd workshop WADS ’91, Ottawa, Canada, August 14–16, 1991, proceedings. Lecture notes in computer science, vol 519. Springer, Berlin, pp 189–200Google Scholar
- Moy98.Moy J (1998) OSPF version 2. RFC 2328 (Standard, Errata Exist)Google Scholar
- Ora90 .Oran D (1990) IS-IS protocol specification (IETF). RFC 1142 (Informational)Google Scholar
- PBD03.Perkins C, Belding-Royer E, Das S (2003) Ad hoc on-demand distance vector (AODV) routing. RFC 3561 (Experimental)Google Scholar
- Roy59.Roy B (1959) Transitivité et connexité. Comptes Rendus de l’Académie des Sci Paris 249: 216–218zbMATHGoogle Scholar
- Tar81.Tarjan R. (1981) A unified approach to path problems. J ACM 28: 577–593MathSciNetzbMATHCrossRefGoogle Scholar
- War62.Warshall S (1962) A theorem on boolean matrices. J ACM 9(1): 11–12MathSciNetzbMATHCrossRefGoogle Scholar