ieor 4004 maximum flow problems. connectivity t t s s q1: can alice send a message to bob ? yes if...

Post on 31-Mar-2015

212 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

IEOR 4004Maximum flow problems

Connectivity

ts

Q1: Can Alice senda message to Bob ?

𝐴 𝐴

Yes if every (s,t)-cut contains at least one forward edge

forward

backward

Connectivity

ts

Q2: How fast?Send datain parallel

Q1: Can Alice senda message to Bob ?

Edge capacity

ts

Idea: Data packetscan share edges(bandwidth)

1234

Two packets in parallel

From -paths to a flow

ts

1234

1

1

3

2

11

2 1

1

1

21

1

Conservation of flow

ts

1234

1

1

3

1

2

2

11

2

1

1

1

v

incoming outgoing

incoming outgoing

incoming outgoing

𝑓 π‘₯ (𝑠)=βˆ’4

𝑓 π‘₯ (𝑑 )=4

𝑓 π‘₯ (𝑖 )=βˆ‘π‘—βˆˆπ‘‰π‘—π‘–βˆˆ 𝐸

π‘₯ π‘—π‘–βˆ’βˆ‘π‘— βˆˆπ‘‰π‘–π‘—βˆˆ 𝐸

π‘₯ 𝑖𝑗

net flow (excess)

valueof flow

incoming outgoing

Feasible flow to -paths

ts

1234

2

1 1

2

4

111

21

1

2

11

1

2

1

𝑓 π‘₯ (𝑠)=βˆ’4

𝑓 π‘₯ (𝑑 )=4

value of flow outgoing from

incoming outgoing

...after finite

# of stepswe reach

11

32

𝑓 π‘₯ (𝑠)=βˆ’3𝑓 π‘₯ (𝑠)=βˆ’2𝑓 π‘₯ (𝑠)=0

𝑓 π‘₯ (𝑑 )=3𝑓 π‘₯ (𝑑 )=2𝑓 π‘₯ (𝑑 )=0

Forward paths do not suffice

ts

1234

1

1

1

11

1 1

11

1

22

2

3

2 3

4

Augmenting chain

ts

1234

1

1

11

1 4

32

12

1

1

1 1

Exponentially many steps

ts

1234

MM

MM

augmenting steps

Exponentially many steps

ts

1234

1

11

1

1

2

22

2

3

3

3

3

MM

MM

bad choice of augmenting chain augmenting steps

ts

Residual network

ts

1

1

11

14

3

2

12

2

and flow residual networkwith respect to flow

saturated edges (residual edges in reverse)no flow

edges (edges in both directions)

1

11 1

Forward pathAugmenting chain

Recall: Connectivity

ts

Q1: Is there a path from s to t?

𝐴 𝐴

Yes if every (s,t)-cut contains at least one forward edge

Else No

forward

backward

Flows and cuts

ts

1234

2

1 1

2

4

111

21

1

2

11

1

2

1

𝑓 π‘₯ (𝑑 )=4

𝐴( 𝐴)

𝐴

π‘₯ ( 𝐴 )flow across a cut (forward flow – backward flow)

value of a flow

ΒΏ1+4+1+1βˆ’2βˆ’1=4

capacity of a cut (forward edges)𝑒 ( 𝐴 )=3+4+1+2=10

flow across a cut ≀ capacity of the cut

Weak duality

Maximum flow = Minimum cut

t

1234

2

4

21

1

1

1

1

1

3

s

1

2

cut capacity (forward edges): flow value (forward – backward)

optimal solution

Strong duality

1

𝐴 𝐴

Transportation problem

Factories Retail stores

Requirementfor goods

Productioncapacity

... ...

Can factories satisfy the demand of retail stores ?

ai bj

edge

if i-th factorycan deliver to j-th store

t

Maximum flow

capacity

production(capacity)

demand(capacity)

source target

necessary condition

a1

a2

an bm

b1

b2

s

Yes, if Maximum flowNo, otherwise

Transportation problem

Factories Retail stores

Requirementfor goods

Productioncapacity

... ...

Can factories satisfy the demand of retail stores ?

t

Maximum flow

capacitylimitedproduction

(capacity)

limiteddemand(capacity)

Units of flow123

source target

necessary condition

bm

b1b2

Example 1: n=m=3a1=a2=a3=1b1=b2=b3=1

Answer: Yes!

Yes, if Maximum flowNo, otherwise

a1a2

an

s

XX

X

XX

X

Transportation problem

Factories Retail stores

Requirementfor goods

Productioncapacity

Can factories satisfy the demand of retail stores ?

t

Maximum flow

capacity

production(capacity)

demand(capacity)

source target

necessary condition

Yes, if Maximum flowNo, otherwise

Example 2: n=m=3a1=a2=1 a3=3b1=3 b2=b3=1

Answer: No!

Maximum flow = 4 < 53rd factory does

not deliver to1st retail store

s

XX

X

XX

X

Example 1: n=m=3a1=a2=a3=1b1=b2=b3=1

𝐴

𝐴cut

of capacity 4

top related