nocad.structural.control_centrality#

nocad.structural.control_centrality(A, B=None, nodes=None, method='generic', random_state=0)[source]#

Control centrality: generic dimension of the controllable subspace from one node.

Parameters:
Aarray_like or sparse, shape (N, N)

State-transition matrix (structure, or weights for method="sprank").

Barray_like, optional

If given, centralities are computed for its driver nodes only (MATLAB controlCentrality); other entries are zero.

nodesarray_like of int, optional

Nodes to evaluate (overrides B); default all nodes.

method{“generic”, “sprank”}

"generic": dimension of the controllable subspace of a random realization (Liu et al. 2012, Hosoe’s generic dimension); "sprank": structural rank of the numerically computed Kalman matrix, as in the MATLAB toolbox (an upper bound).

Returns:
ccndarray of shape (N,)

References

[1]

Y.-Y. Liu, J.-J. Slotine, A.-L. Barabási, “Control centrality and hierarchical structure in complex networks”, PLoS ONE 7 (2012) e44459.

Examples

>>> A = [[0, 0, 0], [1, 0, 0], [0, 1, 0]]   # chain x1 -> x2 -> x3
>>> control_centrality(A)
array([3, 2, 1])