A Simple Linear Time Algorithm for Computing Sparse Spanners in Weighted Graphs

Let be an undirected weighted graph with , and . A -spanner of the graph is a sub-graph , , such that the distance between any pair of vertices in the sub-graph is at most times the distance between the two in the given graph. A 1963 girth conjecture of Erd˝ os implies that edges are required in the worst case for any -spanner, which has been proved for . There exist polynomial time algorithms that can compute spanners with size matching the conjectured lower bound, and the previously best known algorithm takes expected running time. In this paper, we present an extremely simple linear time randomized algorithm that computes a -spanner of size matching the conjectured lower bound. Note that linear time is a severe limitation since it implies that only a negligible f raction of the distances can be exploited in the construction of the spanner. Nonetheless, all distances must be faithfully approximated. An important feature of our algorithm is its local approach. Unlike all the previous algorithms that require computation of shortest paths, the new algorithm merely explores the edges in the neighborhood of a vertex or a group of vertices. This feature leads to desig ning simple external-memory and parallel algorithms for computing sparse spanners, whose running times are near optimal.