Open In App

What is Bipartite Graph

A bipartite graph is a graph in which the vertices can be divided into two disjoint sets, such that no two vertices within the same set are adjacent. In other words, it is a graph in which every edge connects a vertex of one set to a vertex of the other set.

An alternate definition: Formally, a graph G = (V, E) is bipartite if and only if its vertex set V can be partitioned into two non-empty subsets X and Y, such that every edge in E has one endpoint in X and the other endpoint in Y. This partition of vertices is also known as bi-partition.



Bipartite Graph

Note: In the above image nodes of the same colour belong to the same set.

Characteristics of Bipartite Graph

The characteristics of a bipartite graph are as follows:



How to identify Bipartite Graph?

To identify whether a given graph is bipartite, you can use the following algorithm:

  1. Choose any vertex in the graph and assign it to one of the two sets, say X.
  2. Assign all of its neighbors to the other set, say Y.
  3. For each vertex in set Y, assign its neighbors to set X, and for each vertex in set X, assign its neighbors to set Y.
  4. Repeat step 3 until all vertices have been assigned to a set.
  5. Check if any two adjacent vertices are in the same set. If yes, then the graph is not bipartite. Otherwise, it is bipartite.

To learn more about “How to identify”, refer to this article.

Application of Bipartite Graph

Bipartite graphs have many applications in different fields, including:

What else can you read?

Article Tags :