in reply to floyd warshall trans closure
The algorithm to use to find the (shortest) path from one node in a graph to another node is Dijkstra's algorithm, which is linear in the number of edges in the graph. Floyd Warshall is cubic in the number of vertices, and solves the connectivity problem for all pairs of nodes at once.
I presume the Graph module on CPAN has a method for applying Dijkstra's algorithm.
Abigail
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: floyd warshall trans closure
by Anonymous Monk on Oct 21, 2003 at 15:18 UTC | |
by Abigail-II (Bishop) on Oct 21, 2003 at 15:54 UTC | |
by Anonymous Monk on Oct 22, 2003 at 09:56 UTC |