# grinpy.invariants.independence.k_independence_number¶

grinpy.invariants.independence.k_independence_number(G, k)

Return a the k-independence number of G.

The k-independence number of a graph is the cardinality of a largest k-independent set of nodes in the graph.

Parameters: G (NetworkX graph) – An undirected graph. k (int) – A positive integer. The k-independence number of G. int