Note

This is the documentation for the current state of the development branch of rustworkx. The documentation or APIs here can change prior to being released.

rustworkx.is_bipartite

is_bipartite(graph)[source]

Determine if a given graph is bipartite

Parameters:

graph – The graph to check if it’s bipartite

Returns:

True if the graph is bipartite and False if it is not

Return type:

bool