i4018's blog

By i4018, history, 9 years ago, In English

i'm looking for a well written, bug-free and fast code for the bipartite matching algorithm. can anyone share your code please?

  • Vote: I like it
  • +6
  • Vote: I do not like it

»
9 years ago, hide # |
 
Vote: I like it +13 Vote: I do not like it

Not my code but I think this is pretty good: http://zobayer.blogspot.com/2010/05/maximum-matching.html

»
9 years ago, hide # |
 
Vote: I like it +3 Vote: I do not like it

thanks.

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

I want to share my version of bipartite matching, in the hope that, if it is wrong on certain test cases, someone would notice. It is not conventional, in the sense that the "Match" function has one loop instead of two. I have never noticed any notable difference, and the code is pretty short and encapsulated.

https://github.com/bicsi/code_snippets/blob/master/bipartite_match.cpp