Class ShortestPathAllPairsCardinality

  • All Implemented Interfaces:
    ShortestPathAllPairs

    public class ShortestPathAllPairsCardinality
    extends ShortestPathAllPairsAbstract
    All pairs cardinality shortest path algorithm.

    The cardinality length of a path is the number of edges in it. The cardinality shortest path from a source vertex to some other vertex is the path with the minimum number of edges. This algorithm compute the cardinality shortest path between each pair of vertices in a graph. The algorithm simple perform ShortestPathSingleSourceCardinality \(n\) times.

    This algorithm runs in \(O(n(n+m))\).

    Author:
    Barak Ugav
    See Also:
    ShortestPathSingleSourceCardinality