Skip to main content

k_core

Function k_core 

Source
pub fn k_core(graph: &Subgraph, k: usize) -> BTreeSet<String>
Expand description

k-core decomposition: the maximal induced subgraph in which every node has degree at least k (§5.4).

Treats the graph as undirected, summing in- and out-degree. Parallel edges count once each — a node held in by three edges to one neighbour has degree three, which is what makes this a multigraph core.