public class BipartiteGraphMatching extends Object
Constructor and Description |
---|
BipartiteGraphMatching(int[][] adj,
int m,
int n)
Constructs data structure for Hopcroft Karp algorithm for maximum matching.
|
BipartiteGraphMatching(int m,
int n)
Constructs empty data structure for Hopcroft Karp algorithm for maximum matching
edges can be added by addEdge method.
|
Modifier and Type | Method and Description |
---|---|
int |
hopcroftKarp() |
public BipartiteGraphMatching(int m, int n)
m
- m is number of vertices on left side (u)n
- n is a maximum number of vertices on right side (v)public BipartiteGraphMatching(int[][] adj, int m, int n)
adj
- adjency matrix; adj stores adjacents vertices of vertex 'u'm
- m is number of vertices on left side (u)n
- n is a maximum number of vertices on right side (v)Copyright © 2022. All rights reserved.