NetworkX

Previous topic

networkx.algorithms.components.strongly_connected.strongly_connected_components_recursive

Next topic

networkx.algorithms.components.strongly_connected.condensation

networkx.algorithms.components.strongly_connected.kosaraju_strongly_connected_components

kosaraju_strongly_connected_components(G, source=None)

Return nodes in strongly connected components of graph.

Parameters:

G : NetworkX Graph

An directed graph.

Returns:

comp : list of lists

A list of nodes for each component of G. The list is ordered from largest connected component to smallest.

See also

connected_components

Notes

Uses Kosaraju’s algorithm.