{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

08 - The preflow-push algorithm for maximum flow

08 - The preflow-push algorithm for maximum flow - 20 The...

Info iconThis preview shows pages 1–6. Sign up to view the full content.

View Full Document Right Arrow Icon
2/29/08 - The preflow-push algorithm... The Preflow-Push Algorithm Def. A preflow in a flow network is a function f: E -> + s.t. (i) 0 f(e) c e (ii) v s e In(v) f(e) - e Out(v) f(e) =: e f (v) 0 “excess at v” Def. A labeling is a function h: V -> 0 . It is compatible with a preflow f if (i) h(s) = n, h(t) = 0. n = |V(G)| (ii) “steepness” If (v,w) E(G f ) then h(v) 1 + h(w) Lemma. If f is a flow and (f, h) are compatible then f is a maximum flow. Proof. If f is not a max flow then path s = v 0 -> v 1 -> v 2 -> ... -> v k = t in the residual graph. h(v k ) = 0, h(v k-1 ) 1, ..., h(s) = h(v 0 ) k. < n =><= Init h(s) = n h(v) = 0 v s. f(e) = {c e if e Out(s) {0 otherwise Push(f,h,v,w) Require e f (v) > 0 h(v) > h(w) (v,w) E(G f ) if e=(v,w) is forward δ = min{e f (v), c e - f(e)} f(e) <- f(e) + δ if e = (v,w) is backward 20-1 20
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
δ = min{e f (v), f(e)} f(e) + f(e) - δ return (f,h) Relabel(f,h,v) Require e f (v) > 0 e = (v,w) E(G f ) s.t. h(v) > h(w). h(v) <- h(v) + 1 return (f,h) Preflow-push Init. while v t s.t. e f (v) > 0 push(f,h,v,w) if w such that push is possible else relabel(f,h,v) endwhile return f 20-2
Background image of page 2
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Background image of page 4
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Background image of page 6
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}