CodePlexProject Hosting for Open Source Software

// we need a graph, a source and a sink IMutableVertexAndEdgeListGraph<TVertex,TEdge> graph = ...; TVertex source = ...; TVertex sink = ...; // A function with maps an edge to its capacity Func<TEdge, double> capacityFunc = (edge => 1); // A function which takes a vertex and returns the edge connecting to its predecessor in the flow network TryFunc<TVertex, TEdge> flowPredecessors; // A function used to create new edges during the execution of the algorithm. These edges are removed before the computation returns EdgeFactory<TVertex, TEdge> edgeFactory = (source, target) => new Edge<TVertex>(source,target); // computing the maximum flow using Edmonds Karp. double flow = AlgorithmExtensions.MaximumFlowEdmondsKarp<TVertex, TEdge>( graph, capacityFunc, source, sink, out flowPredecessors, edgeFactory);

Last edited Aug 12, 2010 at 11:17 PM by rhennig, version 4

I have found the same thing. Latest version of QuickGraph for the MaximumFlowEdmondsKarp gives a 4 where it should be a 5 for the netowrk described http://en.wikipedia.org/wiki/Edmonds%E2%80%93Karp_algorithm This is a show stopper for me :(

Maxflow of network from http://en.wikipedia.org/wiki/Edmonds%E2%80%93Karp_algorithm is 5 , but i get answer 4 from MaximumFlowEdmondsKarp

apology

Last version of MaximumFlowEdmondsKarp dont work correct

Last version of MaximumFlowEdmondsKarp dont work correct