Documentation

CslibFrontier.Algorithms.WordRAM.Dijkstra.FibonacciStatement

Dijkstra's algorithm on the word RAM with a Fibonacci heap: statements #

This file states what a single-source shortest-path program on the word RAM must satisfy to achieve the Fredman–Tarjan running-time bound of Dijkstra's algorithm with a Fibonacci heap Dijkstra Fredman and Tarjan Cormen et al., Chapter 19 and Section 24.3.

Because memory past the input starts at 0, the priority-queue and distance arrays require only O(1) fresh initialization, and the algorithm extracts at most min n (m + 1) reachable vertices from the source. We therefore state both:

Both bounds use the exact same word-size hypothesis Fits w (8 * (G.n + G.m + 2) * (G.maxWeight + 2)) as Cslib.Algorithms.WordRAM.Dijkstra.LogLinearSpec.

Main definitions #

Main results #

References #

@[reducible, inline]

Shortest paths in O(m + min(n, m + 1) (⌊log₂ n⌋ + 1)) time. Instantiation of ShortestPathSpec with the sharper reachable-vertex Fredman–Tarjan step bound.

@[reducible, inline]

Shortest paths in O(m + n (⌊log₂ n⌋ + 1)) time. Instantiation of ShortestPathSpec with the textbook Fredman–Tarjan step bound.

The sharper reachable-vertex specification FibonacciSpec implies the textbook specification FibonacciLinearSpec with the same constant K.

Reachable-vertex Fibonacci-heap Dijkstra theorem (statement). Some word-RAM program over the exact basis meets FibonacciSpec.

Fibonacci-heap Dijkstra main theorem (statement). Some word-RAM program over the exact basis computes all shortest-path distances from the source of a weighted directed graph with n vertices and m edges, given by adjacency lists, within O(m + n (⌊log₂ n⌋ + 1)) instructions.