cse, iit kgp application of network flows: matrix rounding

11
CSE, IIT KGP Application of Network Flows: Matrix Rounding

Upload: shon-king

Post on 18-Jan-2016

219 views

Category:

Documents


5 download

TRANSCRIPT

Page 1: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP

Application of Network Flows: Matrix Rounding

Page 2: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP

Matrix Rounding

• Consider the following matrix:

16.5

13.5

10.9

9.8

18.5

14.4Ʃ

Ʃ

[16,17] [14,15] [10,11]

[18,19]

[9,10]

[13,14]

x1

x2

x3

y1 y2 y3

Page 3: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP

Solution

• Step 1: Represent the consistent rounding problem as a feasible flow problem.

• Step 2: Convert the feasible flow problem into a feasible circulation problem.

• Step 3: Convert the feasible circulation problem into a Demand and Supplies problem.

• Step 4: Convert the transportation problem into a network flows problem.

Page 4: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP

Solution

• Step 1: Represent the consistent rounding problem as a feasible flow problem.

• Step 2: Convert the feasible flow problem into a feasible circulation problem.

• Step 3: Convert the feasible circulation problem into a Demand and Supplies problem.

• Step 4: Convert the transportation problem into a network flows problem.

Page 5: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP [16,17] [14,15] [10,11]

[18,19]

[9,10]

[13,14](6 .3 7.6 4.6

4.7 2.3 2.85.5 4.5 3.5)x1

x2

x3

y1 y2 y3

[18,19]

[9,10]

[13,14]

[16,17]

[14,15]

[10,11]

x1

x2

x3

y1

y2

y3

s t

[6,7]

[3,4]

[7,8][4,5]

[4,5][2,3]

[5,6]

[2,3]

[4,5]

Feasible Flow Problem Formulation

Page 6: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP

Solution

• Step 1: Represent the consistent rounding problem as a feasible flow problem.

• Step 2: Convert the feasible flow problem into a feasible circulation problem.

• Step 3: Convert the feasible circulation problem into a Demand and Supplies problem.

• Step 4: Convert the transportation problem into a network flows problem.

Page 7: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP

[18,19]

[9,10]

[13,14]

[16,17]

[14,15]

[10,11]

x1

x2

x3

y1

y2

y3

s t

[6,7]

[3,4]

[7,8][4,5]

[4,5][2,3]

[5,6]

[2,3]

[4,5]

Feasible Circulation Problem

[0,∞]

Add an edge from t → s with bounds [0,∞]

Page 8: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP

Solution

• Step 1: Represent the consistent rounding problem as a feasible flow problem.

• Step 2: Convert the feasible flow problem into a feasible circulation problem.

• Step 3: Convert the feasible circulation problem into a Demand and Supplies problem.

• Step 4: Convert the transportation problem into a network flows problem.

Page 9: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP

Transportation Problem

[18,19]

[9,10]

[13,14]

[16,17]

[14,15]

[10,11]

x1

x2

x3

y1

y2

y3

s t

[6,7]

[3,4]

[7,8][4,5]

[4,5][2,3]

[5,6]

[2,3]

[4,5]

[0,∞]

c

c(x1,y1) = 1

l-(x1) = 18l+(x1) = 6+7+4=17b(x1) = 18-17 = 1

Page 10: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP

v l-(v) l+(v) b(v)=l-(v)-l+(v)

s 0 40 -40 (D)

x1 18 17 +1 (S)

x2 9 8 +1 (S)

x3 13 12 +1 (S)

y1 15 16 -1 (D)

y2 13 14 -1 (D)

y3 9 10 -1 (D)

t 40 0 +40 (S)

[18,19]

[9,10]

[13,14]

[16,17]

[14,15]

[10,11]

x1

x2

x3

y1

y2

y3

s t

[6,7]

[3,4]

[7,8][4,5]

[4,5][2,3]

[5,6]

[2,3]

[4,5]

[0,∞]

S – Supply NodeD – Demand Node

Page 11: CSE, IIT KGP Application of Network Flows: Matrix Rounding

CSE, IIT KGP

1

1

1

1

1

1

x1

x2

x3

y1

y2

y3

s t

1

1

11

11

1

1

1

Back to a Network Flows Problem

s' t'

If b(v) ≥ 0, add an edge from s’ to v else add an edge from v to t’, with capacity b(v).Add a new source s’ and a new sink t’.

1

1

1

1

1

1

4040

Is there a flow equal to the total capacity on the edges leaving s’? (In this case 43)