Presentation is loading. Please wait.

Presentation is loading. Please wait.

Ford Fulkerson. Ford-Fulkerson (N=(G, c, s, t)) ; G = (V, E) for each edge, while exists a path P from s to t in residual network N f do for each edge.

Similar presentations


Presentation on theme: "Ford Fulkerson. Ford-Fulkerson (N=(G, c, s, t)) ; G = (V, E) for each edge, while exists a path P from s to t in residual network N f do for each edge."— Presentation transcript:

1 Ford Fulkerson

2 Ford-Fulkerson (N=(G, c, s, t)) ; G = (V, E) for each edge, while exists a path P from s to t in residual network N f do for each edge do return f

3 s t v1v2 v4v3 13 16 12 20 14 4 10 4 9 7 דוגמא : s t v1v2 v4v3 0/13 0/16 0/12 0/20 0/14 0/4 0/100/4 0/9 0/7

4 s t v1v2 v4v3 13 16 12 20 14 4 10 4 9 7 דוגמא : s t v1v2 v4v3 0/13 0/16 0/12 0/20 0/14 0/4 0/100/4 0/9 0/7 4/16 4/12 4/9 4/14 4/4

5 4/9 4/12 4/16 s t v1v2 v4v3 13 12 8 20 10 4 4 5 7 דוגמא : s t v1v2 v4v3 0/13 0/20 0/100/4 0/7 4/14 4 4 4 4

6 4/4 4/9 4/12 4/16 s t v1v2 v4v3 13 12 8 20 10 4 4 5 7 דוגמא : s t v1v2 v4v3 0/13 0/20 0/100/4 0/7 4/14 4 4 4 4 11/16 7/10 11/14 7/7 7/20

7 7/7 11/14 7/10 11/16 4/4 4/9 4/12 s t v1v2 v4v3 13 5 8 3 4 3 11 5 7 דוגמא : s t v1v2 v4v3 0/13 0/4 11 4 4 7/20 7

8 7/7 11/14 7/10 11/16 4/4 4/9 4/12 s t v1v2 v4v3 13 5 8 3 4 3 11 5 7 דוגמא : s t v1v2 v4v3 0/13 0/4 11 4 4 7/20 7 8/13 1/40/10 12/12 15/20

9 12/12 1/40/10 8/13 7/7 11/14 11/16 4/4 4/9 s t v1v2 v4v3 8 5 5 3 4 3 11 5 7 דוגמא : s t v1v2 v4v3 11 12 4 11 15 5

10 15/20 12/12 1/40/10 8/13 7/7 11/14 11/16 4/4 4/9 s t v1v2 v4v3 8 5 5 3 4 3 11 5 7 דוגמא : s t v1v2 v4v3 11 12 4 11 15 5 12/13 0/9 19/20

11 0/9 12/13 12/12 1/40/107/7 11/14 11/16 4/4 s t v1v2 v4v3 12 5 1 3 4 3 11 9 7 דוגמא : s t v1v2 v4v3 11 12 11 19 1

12 זמן ריצה: בכל איטרציה :  מחושב מסלול בזמן לפי BFS.  עידכון הזרימה והרשת השיורית. מספר האיטרציות הוא לכל היותר כגודל הזרימה. סה''כ.


Download ppt "Ford Fulkerson. Ford-Fulkerson (N=(G, c, s, t)) ; G = (V, E) for each edge, while exists a path P from s to t in residual network N f do for each edge."

Similar presentations


Ads by Google