I am trying to implement the job assignment Hungarian algorithm. http://en.wikipedia.org/wiki/Hungarian_algorithm#The_algorithm_in_terms_of_bipartite_graphs
[I think I understand the algorithm, but am not able to appreciate why is it O(n^3). But that is just a curiosity.]
What I am looking for is a PHP implementation of Hungarian algorithm. The Wikipedia link does have a link to implementations, but I have not found PHP version yet.
Most likely you want to look at this article Floyd-Warshall and the all-pairs-shortest-path problem. Unfortunately it is in C but it can help you with the implementation in php ( http://wilanw.blogspot.com/2010/01/floyd-warshall-all-pairs-shortest-path.html ).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With