Class BipartitePartitioning<V,E>

java.lang.Object
org.jgrapht.alg.partition.BipartitePartitioning<V,E>
Type Parameters:
V - the graph vertex type
E - the graph edge type
All Implemented Interfaces:
PartitioningAlgorithm<V>

public class BipartitePartitioning<V,E> extends Object implements PartitioningAlgorithm<V>
Algorithm for computing bipartite partitions thus checking whether a graph is bipartite or not.

The algorithm runs in linear time in the number of vertices and edges.

Author:
Dimitrios Michail, Alexandru Valeanu
  • Constructor Details

    • BipartitePartitioning

      public BipartitePartitioning(Graph<V,E> graph)
      Constructs a new bipartite partitioning.
      Parameters:
      graph - the input graph;
  • Method Details