Find the k-cores of a graph.

The k-core is found by recursively pruning nodes with degrees less than k.

See the following reference for details:

An O(m) Algorithm for Cores Decomposition of Networks Vladimir Batagelj and Matjaz Zaversnik, 2003.

core_number(G) Return the core number for each vertex.
k_core(G[, k, core_number]) Return the k-core of G.
k_shell(G[, k, core_number]) Return the k-shell of G.
k_crust(G[, k, core_number]) Return the k-crust of G.
k_corona(G, k[, core_number]) Return the k-corona of G.