1 / 9

Complexity of Ford-Fulkerson

Complexity of Ford-Fulkerson. Let U = max {(i,j) in A} u ij . If S = {s} and T = N{s}, then u[S,T] is at most nU. The maximum flow is at most nU. At most nU augmentations. Each iteration of the inner while loop is O(m): Each arc is inspected at most once Finding  is O(n)

Download Presentation

Complexity of Ford-Fulkerson

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Complexity of Ford-Fulkerson • Let U = max {(i,j) in A} uij. • If S = {s} and T = N\{s}, then u[S,T] is at most nU. • The maximum flow is at most nU. • At most nU augmentations. • Each iteration of the inner while loop is O(m): • Each arc is inspected at most once • Finding  is O(n) • Updating the flow on P is O(n) • Complexity is O(nmU).

  2. (0,106) (0,106) 2 1 5 (0,1) s t 3 (0,106) (0,106) Pathological Example

  3. An Augmenting Path (0,106) (1,106) 2 1 5 (1,1) s t 3 (0,106) (1,106) v = 1

  4. Residual Network 106 106-1 2 1 1 5 s t 0 1 1 106 3 106-1

  5. An Augmenting Path in the Residual Network 106 106-1 2 1 1 5 s t 0 1 1 106 3 106-1

  6. Updated Flow (1,106) (1,106) 2 1 5 (0,1) s t 3 (1,106) (1,106) v = 2

  7. Updated Residual Network 106 -1 106-1 2 1 1 1 5 s t 1 0 1 1 106 -1 3 106-1

  8. Next Augmenting Path in the Residual Network 106 -1 106-1 2 1 1 1 5 s t 1 0 1 1 106 -1 3 106-1 This will take 2 million iterations to find the maximum flow!

  9. Polynomial Max Flow Algorithms (Chapter 7) • Always augment along the shortest augmenting path in the residual network. • O(n2m) • Always augment along the maximum-capacity augmenting path in the residual network. • O(nm log U) • Goldberg’s algorithm (preflow-push) with highest-label implementation. • O(n2m1/2)

More Related