Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to apply Ford-Fulkerson algorithm to a graph to find maximum flow in a flow network?

Can someone please direct me to a site where step-by-step instruction is given on how to apply ford-fulkerson method on a graph to find the maximum flow.

Thank you so much in advance.

like image 624
sap Avatar asked Jan 29 '26 10:01

sap


1 Answers

Best I know ( link ), wikipedia ( link ) and first alternative Google hit ( Link ).

Ford-Fulkerson Labeling Algorithm

  • (Initialization) Let x be an initial feasible flow (e.g. x(e) = 0 for all e in E).
  • (Flow augmentation) If there are no augmenting path from s to t on the residual network, then stop. The present x is a max flow. If there is a flow augmenting path p, replace the flow x as 2.
    • x(e)=x(e)+delta if e is a forward arc on p.
    • x(e)=x(e)-delta if e is a backward arc on p. where delta is a minimum value of residual capacity on p. Repeat this step.

Source code example: Java

like image 101
Margus Avatar answered Feb 01 '26 00:02

Margus



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!