This preview shows pages 1–5. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: Algorithms Flows and Cuts Flows and Cuts Design and Analysis of Algorithms Andrei Bulatov Algorithms Flows and Cuts 102 Flows and Flow Networks A flow network is a digraph with a unique source and sink nodes Arcs have capacities A flow is a function f: E such that (1) ( Capacity condition ) For each e E, we have ) ( onservation condition irchhoff principle e c e f ) ( + R (2) ( Conservation condition , Kirchhoff principle for each node except s and t The value of the flow is = v e v e e f e f of out into ) ( ) ( s e e f of out ) ( u v s t 20 10 20 10 30 Algorithms Flows and Cuts 103 Residual Graph Starting with the zero flow push a flow along (s,u), (u,v), (v,t) such that f(s,u) = f(u,v) = f(v,t) = 20 construct the residual graph w.r.t. f push a flow along (s,v), (v,u), (u,t) s. t. g(s,v) = g(v,u) = g(u,t) = 10 nstruct the residual graph .r.t g construct the residual graph w.r.t. g we cannot push any flow anymore.  is f + g maximal? u v s t 20 10 20 10 30 u v s t 20 10 20 10 20 10 u v s t 20 10 20 10 10 20 Algorithms Flows and Cuts 104 FordFalkerson: Analysis Let Theorem If all the capacities are integers then the FordFalkerson algorithm = s e e c C of out L can be implemented to run in O(mC) time Theorem If all the capacities are integers then the FordFalkerson algorithm finds a maximal flow. Algorithms Flows and Cuts...
View
Full
Document
 Fall '09
 Bulatov
 Algorithms

Click to edit the document details