algorithms
algorithms copied to clipboard
Implementation of blossom algorithm for maximal cardinality matching
Code by D. Eppstein, UC Irvine, 6 Sep 2003. Implementation of maximum cardinality matching code taken from https://code.activestate.com/recipes/221251-maximum-cardinality-matching-in-general-graphs/
I recently used this code on a Google Foobar challenge and it would be a nice addition to this repository.
Nice work. :)
I am thinking of checking in a fast UnionFind (#830) and even though I have written a good number of tests for it, I would like to test its integration with the blossom algorithm implementation as well.
If you find some time to add your tests, I can refactor the API myself and test out the integration. Thanks!
Thanks @aalekhpatel07, I've added unit tests for blossom algorithm implementation. You can test your union find integration now. All the best and let me know if there's any way I can help!
Nice. (927e73) contains the new blossom that uses the UnionFind API from algorithms.unionfind
.
The tests are passing, so yay! :smile:
Looks great!