NETWORK FLOW

Concepts

      Intuition - How to make the flow larger?

      Residual Network

Residual Network Introduction: Represent how we can change flow in on the edges of G, notation Gf

How much can we change on the flow?

      - Send more on this edge? The possible amount to send more is based on current flow but not exceed current capacity

            cf(u,v) = c(u,v) - f(u,v)

      - When already sent some flow, what about send less(similar to send the flow back)?

          The amount we can send back is same as current flow, in reversed direction.

            cf(v,u) = f(u,v)

      - Otherwise when there's no edge in G, there's also no change of flow

ek1

Residual Network definition:

      Given a flow network G=(V,E) and a flow f. The residual network of G induced by f is Gf=(V, Ef), where

            Ef = { (u,v) ∈ V x V: cf > 0 }       (Click to see explaination of each part, refresh if a bad color appears)

           

Build a residual network here:

S V1 V2 V3 V4 T 11/16 12/12 4/9 11/14 4/4 8/13 1/4 7/7 15/20
S V1 V2 V3 V4 T

Augmentation: A flow in residual network Gf is a hint for adding flow in G

If f is a flow in G and f' is a flow in Gf, we define augmentation:

            (f ↑ f') = f(u,v) + f'(u,v) - f'(v,u)       (Click to see explaination of each part, refresh if a bad color appears)

           

con2

Lemma 26.1 |f ↑ f'| = |f| + |f'|

Augmenting Path: A simple path from s to t in the residual network Gf

Residual Capacity: The maximum amount by which we can increase the flow on each edge in an augmenting path p.

            cf(p) = min { cf(u, v): (u, v) is on p }       (Click to see explaination of each part, refresh if a bad color appears)

           

con3

      Cuts of flow networks

Cut: A cut(S, T) of flow network G is a partition of V into 2 parts:

      S, which contains supply s;

      T, which contains target t

Net Flow: If f is a flow, the net flow(S, T) across the cut(S, T) is defined to be:

      f(S,T) = u ∈ S v ∈ T f(u,v)   -   u ∈ S v ∈ T f(v,u)     (Click to see explaination of each part, refresh if a bad color appears)

con4

Net Flow on Example cuts:

S V1 V2 V3 V4 T 11/16 12/12 4/9 11/14 4/4 8/13 1/4 7/7 15/20

Observation(Lemma 26.4): The net flow acorss any cut is the same, which equals the value of the flow

Capacity of cut: The capacity of cut(S, T) is sum of capacity of edges from node in set S to T

      c(S,T) = u ∈ S v ∈ T c(u,v)     (Click to see explaination of each part, refresh if a bad color appears)

Capacity on example cuts:

S V1 V2 V3 V4 T 11/16 12/12 4/9 11/14 4/4 8/13 1/4 7/7 15/20

Minimum Cut: A cut whose capacity is minimum over all cuts of the network

Corollary 26.5: The value of any flow f in a flow network G is bounded from above by the capacity of any cut of G.

      Max-flow min-cut Theorem

Content: If f is a flow in a flow network G=(V,E) with source s and sink t, then the following conditions are equivalent:

      1. f is a maximum flow in G

      2. The residual network Gf contains no augmenting paths.

      3. |f| = c(S,T) for some cut(S,T) of G.

Proof: 1 ⇒ 2

      Suppose for the sake of contradiction that f is maximum flow in G, but Gf has an augmenting path p.

      Then, by Corollary 26.3, if we augment f by fp we can get a flow |f ↑ fp| strictly greater than |f|

      That contradicts the the assumption that f is a maximum flow

Proof: 2 (No augmenting path) ⇒ 3 (Flow = capacity of some cut)

      Suppose Gf has no augmenting path, that is same as Gf contains no path from s to t.

      Define S={ v ∈ V: there exist a path from s to v in Gf }

      And T - V - S, that is the vertices for which there's no path from s to them

      This partition must be a cut, since we already know there's no path from s to t thus t is in set T.

      Consider a pair of vertices u ∈ S and v ∈ T.

      If there's an edge from u to v, we must have f(u,v) = c(u,v)

        Because if we have f(u, v) ≤ c(u, v), this flow can possibly be raised

        If it is possible to raise it, then there's an edge cf from u to v = c(u,v) - f(u,v)

        In this way v is reachable from u, which means v is reachable from s, and v should be in set S,
        which contradicts the assumption that v is in T

con5

      If there's an edge from v to u, we must have f(v,u) = 0

        Because if we have f(u, v) ≠ 0, it is possible to send flow back from u to v in cf

        Same idea, in this way v is reachable from s.

      Thus we have:

      f(S,T) = u ∈ S v ∈ T f(u,v)   -   ∑ u ∈ S v ∈ T f(v,u)

                         

              = u ∈ S v ∈ T c(u,v)   -   u ∈ S v ∈ T 0

                         

              = c(S, T)

                         

      Then, by Lemma 26.4, |f| = f(S,T) = c(S,T)

Proof: 3 (Flow = capacity of some cut) ⇒ 1 (Is a max flow)

      By by Corollary 26.5 |f| ≤ c(S, T) for all cuts (S, T). The condition |f| = c(S, T) implies that f is a maximum flow.

Yuye.Jiang@tufts.edu       Comp150-ALG-Summer2020