PHP Class Trismegiste\Mondrian\Graph\Tarjan

Tarjan is a decorator of Graph for finding strongly connected components in a directed graph (a.k.a digraph)
Inheritance: extends Algorithm
ファイルを表示 Open project: trismegiste/mondrian

Public Methods

Method Description
getStronglyConnected ( ) : array Get the strongly connected components of this digraph by the Tarjan algorithm.

Private Methods

Method Description
recursivStrongConnect ( Vertex $v )

Method Details

getStronglyConnected() public method

Starting from : http://en.wikipedia.org/wiki/Tarjan%27s_strongly_connected_components_algorithm Corrected with the help : https://code.google.com/p/jbpt/source/browse/trunk/jbpt-core/src/main/java/org/jbpt/algo/graph/StronglyConnectedComponents.java
public getStronglyConnected ( ) : array
return array the partition of this graph : an array of an array of vertices