Shortest paths in trees
T.Beyer, S.Hedetniemi, S.Mitchell
Committee:
Technical Report(May 1977)
Keywords: trees, shortest paths, algorithms, analysis

This paper contains four algorithms involving shortest paths in trees: they determine:

  1. the shortest path from one vertex to another (O(logM))
  2. the shortest distances from one vertex to all other vertices (O(M))
  3. the shortest distances from all vertices to all other vertices (O(M ))
  4. the expected distance between two vertices(O(M))

The expected time complexities for a tree T with M vertices, for each of these algorithms is indicated above. Algorithm A first appeared in [8] but is included here for completeness, the remaining three algorithms are new.