strongly Connected Components
Compute the strongly connected components of this network. A strongly connected component (SCC) is a maximal set of agents where every agent can reach every other agent via directed paths.
For an undirected network this returns the standard connected components (every undirected edge contributes a 2-cycle, so SCC and connected component coincide).
Only agents currently incident to at least one edge are considered nodes of the network and appear in the result. Agents in the context with no edges are not in any returned SCC; callers can identify them by comparing context.members with the union of all returned SCCs.
Implemented with the iterative form of Tarjan's algorithm: one DFS pass with explicit DFS index and lowlink tracking. Time complexity O(V + E); space O(V) for the bookkeeping maps plus the explicit-frame stack (depth bounded by the longest simple path, not by JVM call stack).
The order of SCCs in the returned list corresponds to a reverse-topological order of the condensation: an SCC that has only outgoing inter-SCC edges (a "source SCC" in the condensation) appears later, an SCC that has only incoming inter-SCC edges (a "sink SCC") appears earlier. This is a consequence of how Tarjan's algorithm emits SCCs in DFS post-order.