1 lecture 4 maximal flow problems set covering problems

21
1 Lecture 4 Lecture 4 Maximal Flow Problems Maximal Flow Problems Set Covering Problems Set Covering Problems

Upload: ginger-cobb

Post on 24-Dec-2015

234 views

Category:

Documents


1 download

TRANSCRIPT

1

Lecture 4 Lecture 4 Maximal Flow ProblemsMaximal Flow ProblemsSet Covering ProblemsSet Covering Problems

2

AgendaAgenda

maximal flow problemsmaximal flow problems

set covering problems set covering problems

3

Maximal Flow ProblemsMaximal Flow Problems

4

Maximal Flow ProblemsMaximal Flow Problems

arcs labeled with their capacitiesarcs labeled with their capacities

question: LP formulation of the total question: LP formulation of the total

maximal total maximal flow from the maximal total maximal flow from the

sources to the sinks sources to the sinks

5

Maximal Flow ProblemsMaximal Flow Problems

obvious maximum: 9 obvious maximum: 9

unitsunits

LP formulation, letLP formulation, let xx be the flow from node 0 be the flow from node 0

xxijij be the flow from node be the flow from node ii

to node to node jj

5

4

81

20

01 02

01 12

02 12

01

02

12

max ,

. .

,

,

,

0 5,

0 4,

0 8,

0.

x

s t

x x x

x x

x x x

x

x

x

x

01 02

01 12

02 12

01 02

12

max ,

. .

= 0,

= 0,

- + = 0,

0 5, 0 4,

0 8, 0.

x

s t

x x x

x x

x x x

x x

x x

6

Maximal Flow ProblemMaximal Flow Problem

let let xxijij be the flow from node be the flow from node ii to node to node j j

7

Maximal Flow ProblemMaximal Flow Problem

,

0 1

0 02

1 13

02 23 24 25 42

13 23 34 37

24 34 42 45 46

25 45 5

46 76 6

37 76 7

5 6 7

max

. .

0,

0,

0,

0,

,0,

0,

0,

0,

0,

0,

0 , 0

TS

TS S S

S

S

T

T

T

TS T T T

TS

x

s t

x x x

x x

x x

x x x x x

x x x x

x x x x x

x x x

x x x

x x x

x x x x

x

0 1 02 13 23 24 25 34

37 42 45 46 76 5 6 7

, 0 , 0 12, 0 20, 0 6, 0 3, 0 6, 0 7,

0 9, 0 2, 0 5, 0 8, 0 4, 0 , 0 , 0 . S S

T T T

x x x x x x x x

x x x x x x x x

S T

8

Maximal Flow ProblemMaximal Flow Problem

,

0 1

0 02

1 13

02 23 24 25 42

13 23 34 37

24 34 42 45 46

25 45 5

46 76 6

37 76 7

5 6 7

max

. .

0,

0,

0,

0,

,0,

0,

0,

0,

0,

0,

0 , 0

TS

TS S S

S

S

T

T

T

TS T T T

TS

x

s t

x x x

x x

x x

x x x x x

x x x x

x x x x x

x x x

x x x

x x x

x x x x

x

0 1 02 13 23 24 25 34

37 42 45 46 76 5 6 7

, 0 , 0 12, 0 20, 0 6, 0 3, 0 6, 0 7,

0 9, 0 2, 0 5, 0 8, 0 4, 0 , 0 , 0 . S S

T T T

x x x x x x x x

x x x x x x x x

S T

9

Comments for Comments for the Maximal Flow Problemthe Maximal Flow Problem

special structure of network flowspecial structure of network flow

integral solutions for integral capacitiesintegral solutions for integral capacities

10

Further Comments for Further Comments for Network Flow ProblemsNetwork Flow Problems

network components in many practical network components in many practical

problems problems easier to solve with packages easier to solve with packages

more likely to have integral optimal solutionsmore likely to have integral optimal solutions

many practical LP problems being dual of many practical LP problems being dual of

network flow problems network flow problems optimal integral solutionsoptimal integral solutions

11

Set Covering ProblemsSet Covering Problems

12

Set CoversSet Covers

a set a set S S = {1, 2, 3, 4, 5} = {1, 2, 3, 4, 5}

a collection of subsets of a collection of subsets of SS,, = {{1, 2}, {1, 3, 5}, {2, 4, 5}, = {{1, 2}, {1, 3, 5}, {2, 4, 5}, {3}, {1}, {4, 5}} {3}, {1}, {4, 5}}

a cost associated with each subset of a cost associated with each subset of SS in in e.g., cost = 1 for each subset of e.g., cost = 1 for each subset of SS in in

a subset of a subset of is a cover of is a cover of SS if the subset contains all if the subset contains all elements of elements of SS {1, 2}, {1, 3, 5}, and {2, 4, 5} forms a cover of {1, 2}, {1, 3, 5}, and {2, 4, 5} forms a cover of SS

{1}, {3}. and {4, 5} do not form a cover of {1}, {3}. and {4, 5} do not form a cover of SS

13

Set Covering ProblemsSet Covering Problems

given given SS, , , and all costs of subsets in , and all costs of subsets in = 1, find = 1, find the minimum cost cover of the minimum cost cover of S S S S = {1, 2, 3, 4, 5} = {1, 2, 3, 4, 5}

= {{1, 2}, {1, 3, 5}, {2, 4, 5}, {3}, {1}, {4, 5}} = {{1, 2}, {1, 3, 5}, {2, 4, 5}, {3}, {1}, {4, 5}}

what are the decisions?what are the decisions? a subset is selected or nota subset is selected or not

what are the constraints? what are the constraints? elements of elements of SS are covered are covered

14

Set Covering ProblemsSet Covering Problems

S S = {1, 2, 3, 4, 5} = {1, 2, 3, 4, 5}

= {{1, 2}, {1, 3, 5}, {2, 4, 5}, {3}, {1}, {4, 5}} = {{1, 2}, {1, 3, 5}, {2, 4, 5}, {3}, {1}, {4, 5}}

examplesexamples 11 = = 33 = = 44 = 1 and = 1 and 22 = = 55 = 0: {1, 2}, {2, 4, 5}, {3} = 0: {1, 2}, {2, 4, 5}, {3}

22 = = 55 = 1 and = 1 and 11 = = 33 = = 44 = = 66 = 0: {1, 3, 5}, {1} = 0: {1, 3, 5}, {1}

1, if the th member of is in the cover,

0, otherwise.ii

15

Set Covering ProblemsSet Covering Problems

S S = {1, 2, 3, 4, 5} = {1, 2, 3, 4, 5}

= {{1, 2}, {1, 3, 5}, {2, 4, 5}, {3}, {1}, {4, 5}}= {{1, 2}, {1, 3, 5}, {2, 4, 5}, {3}, {1}, {4, 5}}

1 2 3 4 5 6

1 2 5

1 3

2 4

3 6

2 3 6

min ,

. .

1,

1,

1,

1,

1,

s t

i {0, 1}

element 1:

element 2:

element 3:

element 4:

element 5:

set

1: set

2: set

3: set

4: set

5: set

6:

Property 9.1: minimization

with all constraints

Property 9.2: all RHS

coefficients = 1

Property 9.3: all matrix

coefficients = 0 or 1

16

Generalization of Generalization of Set Covering ProblemsSet Covering Problems

weighted set covering problems: RHS weighted set covering problems: RHS

coefficient coefficient positive integers > 1 positive integers > 1 some elements covered multiple timessome elements covered multiple times

generalized set covering problems: a generalized set covering problems: a

weighted set covering problem + matrix weighted set covering problem + matrix

coefficients 0 or coefficients 0 or 1 1

17

Applications of Applications of Set Covering ProblemsSet Covering Problems

aircrew schedulingaircrew scheduling SS: the collection of flights legs to cover : the collection of flights legs to cover

: the collection of feasible rosters of air : the collection of feasible rosters of air

crewcrew

18

Comments for Comments for Set Covering ProblemsSet Covering Problems

“Set covering problems have an important property that often makes them comparatively easy to solve by the branch and bound method. It can be shown that the optimal solution to a set covering problem must be a vertex solution in the same sense as for LP problems. Unfortunately, this vertex solution will not generally be (but sometimes is) the optimal vertex solution to the corresponding LP model. It is, however, often possible to move from this continuous optimum to the integer optimum in comparatively few steps.” (pp 191 of [7])

19

Optimal Solution at a Vertex Optimal Solution at a Vertex for a Set Covering Problemfor a Set Covering Problem

suppose there are optima not at a vertexsuppose there are optima not at a vertex

let {let {xxii} and {} and {yyii} be two different optimal solutions } be two different optimal solutions

then {then {xxii+(1+(1))yyii} are optimal solution } are optimal solution

there must be at least one there must be at least one ii such that such that xxii yyi i

for for xxii yyi i , , xxii+(1+(1))yyii {0, 1} iff {0, 1} iff = 0 or 1 = 0 or 1

either case there is only one optimaleither case there is only one optimal

LP: optimal at a vertex 1 2 3 4 5 6

1 2 5

1 3

2 4

3 6

2 3 6

min ,

. .

1,

1,

1,

1,

1,

s t

i {0, 1}

20

LP LP Optimum Not Optimum Not Set Covering OptimumSet Covering Optimum

Set Covering: optimal at a vertex, but not

necessarily at that of LP

LP: optimal at a vertex

21

Comments for Comments for Set Covering ProblemsSet Covering Problems

relatively easy to solve by Branch and Boundrelatively easy to solve by Branch and Bound optimal solution at a vertex, though not that optimal solution at a vertex, though not that

by LP relaxationby LP relaxation possible to move from possible to move from LPLP optimum to the set optimum to the set

covering optimum in a few stepscovering optimum in a few steps

in applications, usually many more variables in applications, usually many more variables than constraintsthan constraints solved by column generationssolved by column generations