NetworkX

Previous topic

networkx.algorithms.bipartite.centrality.betweenness_centrality

Next topic

networkx.algorithms.bipartite.basic.is_bipartite_node_set

networkx.algorithms.bipartite.basic.is_bipartite

networkx.algorithms.bipartite.basic.is_bipartite(G)

Returns True if graph G is bipartite, False if not.

Parameters :G : NetworkX graph

Examples

>>> from networkx.algorithms import bipartite
>>> G = nx.path_graph(4)
>>> print(bipartite.is_bipartite(G))
True