Advanced Algorithms (II) Chihao Zhang Shanghai Jiao Tong University - - PowerPoint PPT Presentation

advanced algorithms ii
SMART_READER_LITE
LIVE PREVIEW

Advanced Algorithms (II) Chihao Zhang Shanghai Jiao Tong University - - PowerPoint PPT Presentation

Advanced Algorithms (II) Chihao Zhang Shanghai Jiao Tong University Mar. 4, 2019 Advanced Algorithms (II) 1/11 We show that this ratio can also be achieved via direct rounding. Recall that we have the following linear programming relaxation.


slide-1
SLIDE 1

Advanced Algorithms (II)

Chihao Zhang

Shanghai Jiao Tong University

  • Mar. 4, 2019

Advanced Algorithms (II) 1/11

slide-2
SLIDE 2

MaxSAT

Recall that we can obtain a

  • approximation by choosing the betuer
  • f the two.

We show that this ratio can also be achieved via direct rounding. Recall that we have the following linear programming relaxation. max

m j

zj subject to

i Pj

yi

k Nj

yk zj Cj

i Pj

xi

k Nj

xk zj j m yi i n

Advanced Algorithms (II) 2/11

slide-3
SLIDE 3

MaxSAT

Recall that we can obtain a 3

4-approximation by choosing the betuer

  • f the two.

We show that this ratio can also be achieved via direct rounding. Recall that we have the following linear programming relaxation. max

m j

zj subject to

i Pj

yi

k Nj

yk zj Cj

i Pj

xi

k Nj

xk zj j m yi i n

Advanced Algorithms (II) 2/11

slide-4
SLIDE 4

MaxSAT

Recall that we can obtain a 3

4-approximation by choosing the betuer

  • f the two.

We show that this ratio can also be achieved via direct rounding. Recall that we have the following linear programming relaxation. max

m j

zj subject to

i Pj

yi

k Nj

yk zj Cj

i Pj

xi

k Nj

xk zj j m yi i n

Advanced Algorithms (II) 2/11

slide-5
SLIDE 5

MaxSAT

Recall that we can obtain a 3

4-approximation by choosing the betuer

  • f the two.

We show that this ratio can also be achieved via direct rounding. Recall that we have the following linear programming relaxation. max

m

j=1

zj subject to ∑

i∈Pj

yi + ∑

k∈Nj

(1 − yk) ≥ zj, ∀Cj = ∨

i∈Pj

xi ∨ ∨

k∈Nj

¯ xk zj ∈ [0, 1], ∀j ∈ [m] yi ∈ [0, 1], ∀i ∈ [n]

Advanced Algorithms (II) 2/11

slide-6
SLIDE 6

Let { y∗

i

}

i∈[n] ,

{ z∗

j

}

j∈[m] be an optimal solution of the LP.

Instead of tossing yi -biased coins, we toss f yi -biased coins for some function f . For Cj

i Pj xi k Nj xk,

Pr Cj is not satisfied

i Pj

f yi

k Nj

f yk We can choose a suitable f to get approximation.

Advanced Algorithms (II) 3/11

slide-7
SLIDE 7

Let { y∗

i

}

i∈[n] ,

{ z∗

j

}

j∈[m] be an optimal solution of the LP.

Instead of tossing y∗

i -biased coins, we toss f(y∗ i )-biased coins for

some function f(·) ∈ [0, 1]. For Cj

i Pj xi k Nj xk,

Pr Cj is not satisfied

i Pj

f yi

k Nj

f yk We can choose a suitable f to get approximation.

Advanced Algorithms (II) 3/11

slide-8
SLIDE 8

Let { y∗

i

}

i∈[n] ,

{ z∗

j

}

j∈[m] be an optimal solution of the LP.

Instead of tossing y∗

i -biased coins, we toss f(y∗ i )-biased coins for

some function f(·) ∈ [0, 1]. For Cj = ∨

i∈Pj xi ∨ ∨ k∈Nj ¯

xk, Pr [ Cj is not satisfied ] = ∏

i∈Pj

(1 − f(y∗

i ))

k∈Nj

f(y∗

k).

We can choose a suitable f to get approximation.

Advanced Algorithms (II) 3/11

slide-9
SLIDE 9

Let { y∗

i

}

i∈[n] ,

{ z∗

j

}

j∈[m] be an optimal solution of the LP.

Instead of tossing y∗

i -biased coins, we toss f(y∗ i )-biased coins for

some function f(·) ∈ [0, 1]. For Cj = ∨

i∈Pj xi ∨ ∨ k∈Nj ¯

xk, Pr [ Cj is not satisfied ] = ∏

i∈Pj

(1 − f(y∗

i ))

k∈Nj

f(y∗

k).

We can choose a suitable f to get 3

4 approximation.

Advanced Algorithms (II) 3/11

slide-10
SLIDE 10

Integrality Gap

In most LP based approximation algorithms, the upper bound for the OPT is OPT OPT LP Then we establish OPT OPT LP OPT If we alreadly know OPT OPT LP then we cannot have ! The ratio is called the integrality gap of the LP relaxation.

Advanced Algorithms (II) 4/11

slide-11
SLIDE 11

Integrality Gap

In most LP based approximation algorithms, the upper bound for the OPT is OPT ≤ OPT(LP). Then we establish OPT OPT LP OPT If we alreadly know OPT OPT LP then we cannot have ! The ratio is called the integrality gap of the LP relaxation.

Advanced Algorithms (II) 4/11

slide-12
SLIDE 12

Integrality Gap

In most LP based approximation algorithms, the upper bound for the OPT is OPT ≤ OPT(LP). Then we establish OPT∗ ≥ α · OPT(LP) ≥ α · OPT. If we alreadly know OPT OPT LP then we cannot have ! The ratio is called the integrality gap of the LP relaxation.

Advanced Algorithms (II) 4/11

slide-13
SLIDE 13

Integrality Gap

In most LP based approximation algorithms, the upper bound for the OPT is OPT ≤ OPT(LP). Then we establish OPT∗ ≥ α · OPT(LP) ≥ α · OPT. If we alreadly know OPT ≤ β · OPT(LP), then we cannot have ! The ratio is called the integrality gap of the LP relaxation.

Advanced Algorithms (II) 4/11

slide-14
SLIDE 14

Integrality Gap

In most LP based approximation algorithms, the upper bound for the OPT is OPT ≤ OPT(LP). Then we establish OPT∗ ≥ α · OPT(LP) ≥ α · OPT. If we alreadly know OPT ≤ β · OPT(LP), then we cannot have α > β! The ratio is called the integrality gap of the LP relaxation.

Advanced Algorithms (II) 4/11

slide-15
SLIDE 15

Integrality Gap

In most LP based approximation algorithms, the upper bound for the OPT is OPT ≤ OPT(LP). Then we establish OPT∗ ≥ α · OPT(LP) ≥ α · OPT. If we alreadly know OPT ≤ β · OPT(LP), then we cannot have α > β! The ratio β is called the integrality gap of the LP relaxation.

Advanced Algorithms (II) 4/11

slide-16
SLIDE 16

Integrality Gap for MaxSAT

Consider the instance, x x x x x x x x OPT and OPT LP . The integrality gap of our LP is .

  • Corollary. We cannot beat

if we use OPT OPT LP upper bound.

Advanced Algorithms (II) 5/11

slide-17
SLIDE 17

Integrality Gap for MaxSAT

Consider the instance, (x1 ∨ x2) ∧ (x1 ∨ ¯ x2) ∧ (¯ x1 ∨ x2) ∧ (¯ x1 ∨ ¯ x2) OPT and OPT LP . The integrality gap of our LP is .

  • Corollary. We cannot beat

if we use OPT OPT LP upper bound.

Advanced Algorithms (II) 5/11

slide-18
SLIDE 18

Integrality Gap for MaxSAT

Consider the instance, (x1 ∨ x2) ∧ (x1 ∨ ¯ x2) ∧ (¯ x1 ∨ x2) ∧ (¯ x1 ∨ ¯ x2) OPT = 3 and OPT(LP) = 4. The integrality gap of our LP is .

  • Corollary. We cannot beat

if we use OPT OPT LP upper bound.

Advanced Algorithms (II) 5/11

slide-19
SLIDE 19

Integrality Gap for MaxSAT

Consider the instance, (x1 ∨ x2) ∧ (x1 ∨ ¯ x2) ∧ (¯ x1 ∨ x2) ∧ (¯ x1 ∨ ¯ x2) OPT = 3 and OPT(LP) = 4. The integrality gap of our LP is 3

4.

  • Corollary. We cannot beat

if we use OPT OPT LP upper bound.

Advanced Algorithms (II) 5/11

slide-20
SLIDE 20

Integrality Gap for MaxSAT

Consider the instance, (x1 ∨ x2) ∧ (x1 ∨ ¯ x2) ∧ (¯ x1 ∨ x2) ∧ (¯ x1 ∨ ¯ x2) OPT = 3 and OPT(LP) = 4. The integrality gap of our LP is 3

4.

  • Corollary. We cannot beat 3

4 if we use OPT ≤ OPT(LP) upper

bound.

Advanced Algorithms (II) 5/11

slide-21
SLIDE 21

Minimum Label Cut

Minimum Label s-t Cut Input: A graph G V E ; a set of labels L L such that each e E is labelled with

  • ne

e L ; two vertices s t V. Problem: Compute a minimum set of labels L L such that the removal of all edges with label in L disconnects s and t. NP-hard, and even hard to approximate with any constant ratio (unless NP P).

Advanced Algorithms (II) 6/11

slide-22
SLIDE 22

Minimum Label Cut

Minimum Label s-t Cut Input: A graph G = (V, E); a set of labels [L] = {1, 2, . . . , L} such that each e ∈ E is labelled with

  • ne ℓ(e) ∈ [L]; two vertices s, t ∈ V.

Problem: Compute a minimum set of labels L′ ⊆ [L] such that the removal of all edges with label in L′ disconnects s and t. NP-hard, and even hard to approximate with any constant ratio (unless NP P).

Advanced Algorithms (II) 6/11

slide-23
SLIDE 23

Minimum Label Cut

Minimum Label s-t Cut Input: A graph G = (V, E); a set of labels [L] = {1, 2, . . . , L} such that each e ∈ E is labelled with

  • ne ℓ(e) ∈ [L]; two vertices s, t ∈ V.

Problem: Compute a minimum set of labels L′ ⊆ [L] such that the removal of all edges with label in L′ disconnects s and t. NP-hard, and even hard to approximate with any constant ratio (unless NP = P).

Advanced Algorithms (II) 6/11

slide-24
SLIDE 24

LP Relaxation

We introduce a variable zj for each label j L . Let

s t be the

collection of paths between s and t. min

L j

zj subject to

e P

z

e

P

s t

zj j L Q1: How to solve this LP efgiciently? Q2: What is the integrality gap of this LP? m .

Advanced Algorithms (II) 7/11

slide-25
SLIDE 25

LP Relaxation

We introduce a variable zj for each label j ∈ [L]. Let Ps,t be the collection of paths between s and t. min

L j

zj subject to

e P

z

e

P

s t

zj j L Q1: How to solve this LP efgiciently? Q2: What is the integrality gap of this LP? m .

Advanced Algorithms (II) 7/11

slide-26
SLIDE 26

LP Relaxation

We introduce a variable zj for each label j ∈ [L]. Let Ps,t be the collection of paths between s and t. min

L

j=1

zj subject to ∑

e∈P

zℓ(e) ≥ 1, ∀P ∈ Ps,t zj ∈ [0, 1], ∀j ∈ [L] Q1: How to solve this LP efgiciently? Q2: What is the integrality gap of this LP? m .

Advanced Algorithms (II) 7/11

slide-27
SLIDE 27

LP Relaxation

We introduce a variable zj for each label j ∈ [L]. Let Ps,t be the collection of paths between s and t. min

L

j=1

zj subject to ∑

e∈P

zℓ(e) ≥ 1, ∀P ∈ Ps,t zj ∈ [0, 1], ∀j ∈ [L] Q1: How to solve this LP efgiciently? Q2: What is the integrality gap of this LP? m .

Advanced Algorithms (II) 7/11

slide-28
SLIDE 28

LP Relaxation

We introduce a variable zj for each label j ∈ [L]. Let Ps,t be the collection of paths between s and t. min

L

j=1

zj subject to ∑

e∈P

zℓ(e) ≥ 1, ∀P ∈ Ps,t zj ∈ [0, 1], ∀j ∈ [L] Q1: How to solve this LP efgiciently? Q2: What is the integrality gap of this LP? m .

Advanced Algorithms (II) 7/11

slide-29
SLIDE 29

LP Relaxation

We introduce a variable zj for each label j ∈ [L]. Let Ps,t be the collection of paths between s and t. min

L

j=1

zj subject to ∑

e∈P

zℓ(e) ≥ 1, ∀P ∈ Ps,t zj ∈ [0, 1], ∀j ∈ [L] Q1: How to solve this LP efgiciently? Q2: What is the integrality gap of this LP? Ω(m).

Advanced Algorithms (II) 7/11

slide-30
SLIDE 30

Separation Oracle

We can solve the LP in poly-time using ellipsoid method provided a separation oracle: Given a point, in PTIME either confirm it is a feasible solution; or find a violated constraint. Oracle here: shortest s-t path

Advanced Algorithms (II) 8/11

slide-31
SLIDE 31

Separation Oracle

We can solve the LP in poly-time using ellipsoid method provided a separation oracle: Given a point, in PTIME either confirm it is a feasible solution; or find a violated constraint. Oracle here: shortest s-t path

Advanced Algorithms (II) 8/11

slide-32
SLIDE 32

Separation Oracle

We can solve the LP in poly-time using ellipsoid method provided a separation oracle: Given a point, in PTIME either ▶ confirm it is a feasible solution; or ▶ find a violated constraint. Oracle here: shortest s-t path

Advanced Algorithms (II) 8/11

slide-33
SLIDE 33

Separation Oracle

We can solve the LP in poly-time using ellipsoid method provided a separation oracle: Given a point, in PTIME either ▶ confirm it is a feasible solution; or ▶ find a violated constraint. Oracle here: shortest s-t path

Advanced Algorithms (II) 8/11

slide-34
SLIDE 34

Beat the Interality Gap

Obtain a partial solution via rounding; Complement the solution by combinatorial construction. Let zj

j L be an optimal solution of the LP. Let

be a parameter.

  • 1. Let L

j L zj .

  • 2. Let G be the graph obtained from G by removing

edges with label in L .

  • 3. Let F be the minimum s-t cut of G , L be the labels
  • f edges in F.
  • 4. Return L

L .

Advanced Algorithms (II) 9/11

slide-35
SLIDE 35

Beat the Interality Gap

▶ Obtain a partial solution via rounding; Complement the solution by combinatorial construction. Let zj

j L be an optimal solution of the LP. Let

be a parameter.

  • 1. Let L

j L zj .

  • 2. Let G be the graph obtained from G by removing

edges with label in L .

  • 3. Let F be the minimum s-t cut of G , L be the labels
  • f edges in F.
  • 4. Return L

L .

Advanced Algorithms (II) 9/11

slide-36
SLIDE 36

Beat the Interality Gap

▶ Obtain a partial solution via rounding; ▶ Complement the solution by combinatorial construction. Let zj

j L be an optimal solution of the LP. Let

be a parameter.

  • 1. Let L

j L zj .

  • 2. Let G be the graph obtained from G by removing

edges with label in L .

  • 3. Let F be the minimum s-t cut of G , L be the labels
  • f edges in F.
  • 4. Return L

L .

Advanced Algorithms (II) 9/11

slide-37
SLIDE 37

Beat the Interality Gap

▶ Obtain a partial solution via rounding; ▶ Complement the solution by combinatorial construction. Let zj

j L be an optimal solution of the LP. Let

be a parameter.

  • 1. Let L

j L zj .

  • 2. Let G be the graph obtained from G by removing

edges with label in L .

  • 3. Let F be the minimum s-t cut of G , L be the labels
  • f edges in F.
  • 4. Return L

L .

Advanced Algorithms (II) 9/11

slide-38
SLIDE 38

Beat the Interality Gap

▶ Obtain a partial solution via rounding; ▶ Complement the solution by combinatorial construction. Let { z∗

j

}

j∈[L] be an optimal solution of the LP. Let β > 0

be a parameter.

  • 1. Let L

j L zj .

  • 2. Let G be the graph obtained from G by removing

edges with label in L .

  • 3. Let F be the minimum s-t cut of G , L be the labels
  • f edges in F.
  • 4. Return L

L .

Advanced Algorithms (II) 9/11

slide-39
SLIDE 39

Beat the Interality Gap

▶ Obtain a partial solution via rounding; ▶ Complement the solution by combinatorial construction. Let { z∗

j

}

j∈[L] be an optimal solution of the LP. Let β > 0

be a parameter.

  • 1. Let L1 ≜

{ j ∈ L : z∗

j ≥ β

} .

  • 2. Let G be the graph obtained from G by removing

edges with label in L .

  • 3. Let F be the minimum s-t cut of G , L be the labels
  • f edges in F.
  • 4. Return L

L .

Advanced Algorithms (II) 9/11

slide-40
SLIDE 40

Beat the Interality Gap

▶ Obtain a partial solution via rounding; ▶ Complement the solution by combinatorial construction. Let { z∗

j

}

j∈[L] be an optimal solution of the LP. Let β > 0

be a parameter.

  • 1. Let L1 ≜

{ j ∈ L : z∗

j ≥ β

} .

  • 2. Let G′ be the graph obtained from G by removing

edges with label in L1.

  • 3. Let F be the minimum s-t cut of G , L be the labels
  • f edges in F.
  • 4. Return L

L .

Advanced Algorithms (II) 9/11

slide-41
SLIDE 41

Beat the Interality Gap

▶ Obtain a partial solution via rounding; ▶ Complement the solution by combinatorial construction. Let { z∗

j

}

j∈[L] be an optimal solution of the LP. Let β > 0

be a parameter.

  • 1. Let L1 ≜

{ j ∈ L : z∗

j ≥ β

} .

  • 2. Let G′ be the graph obtained from G by removing

edges with label in L1.

  • 3. Let F be the minimum s-t cut of G′, L2 be the labels
  • f edges in F.
  • 4. Return L

L .

Advanced Algorithms (II) 9/11

slide-42
SLIDE 42

Beat the Interality Gap

▶ Obtain a partial solution via rounding; ▶ Complement the solution by combinatorial construction. Let { z∗

j

}

j∈[L] be an optimal solution of the LP. Let β > 0

be a parameter.

  • 1. Let L1 ≜

{ j ∈ L : z∗

j ≥ β

} .

  • 2. Let G′ be the graph obtained from G by removing

edges with label in L1.

  • 3. Let F be the minimum s-t cut of G′, L2 be the labels
  • f edges in F.
  • 4. Return L1 ∪ L2.

Advanced Algorithms (II) 9/11

slide-43
SLIDE 43

Bounding L1 and L2

It is clear that L

j L

zj OPT LP OPT On the otherhand, there cannot be too many edge disjoint paths between s and t in G : at least edges on each s-t path; at most m

L

m L such paths; therefore L F m L (Menger’s theorem).

Advanced Algorithms (II) 10/11

slide-44
SLIDE 44

Bounding L1 and L2

It is clear that |L1| ≤ ∑

j∈[L]

1 β · z∗

j = 1

β · OPT(LP) ≤ 1 β · OPT. On the otherhand, there cannot be too many edge disjoint paths between s and t in G : at least edges on each s-t path; at most m

L

m L such paths; therefore L F m L (Menger’s theorem).

Advanced Algorithms (II) 10/11

slide-45
SLIDE 45

Bounding L1 and L2

It is clear that |L1| ≤ ∑

j∈[L]

1 β · z∗

j = 1

β · OPT(LP) ≤ 1 β · OPT. On the otherhand, there cannot be too many edge disjoint paths between s and t in G′: at least edges on each s-t path; at most m

L

m L such paths; therefore L F m L (Menger’s theorem).

Advanced Algorithms (II) 10/11

slide-46
SLIDE 46

Bounding L1 and L2

It is clear that |L1| ≤ ∑

j∈[L]

1 β · z∗

j = 1

β · OPT(LP) ≤ 1 β · OPT. On the otherhand, there cannot be too many edge disjoint paths between s and t in G′: ▶ at least 1

β edges on each s-t path;

▶ at most m−|L1 |

1/β

= β(m − |L1|) such paths; ▶ therefore |L2| ≤ |F| ≤ β(m − |L1|) (Menger’s theorem).

Advanced Algorithms (II) 10/11

slide-47
SLIDE 47

The Choice of β

We already have L L OPT m L OPT m Setuing

OPT m

yields an O m approximation.

Remark

Instead of using Menger’s theorem, we can find a small cut by BFS from s.

  • Exercise. Find an O n
  • approx algorithm via rounding + BFS.

Advanced Algorithms (II) 11/11

slide-48
SLIDE 48

The Choice of β

We already have |L1| + |L2| ≤ 1 β · OPT + β(m − |L1|) ≤ 1 β · OPT + βm. Setuing β = √

OPT m

yields an O ( m

1 2

) approximation.

Remark

Instead of using Menger’s theorem, we can find a small cut by BFS from s.

  • Exercise. Find an O n
  • approx algorithm via rounding + BFS.

Advanced Algorithms (II) 11/11

slide-49
SLIDE 49

The Choice of β

We already have |L1| + |L2| ≤ 1 β · OPT + β(m − |L1|) ≤ 1 β · OPT + βm. Setuing β = √

OPT m

yields an O ( m

1 2

) approximation.

Remark

Instead of using Menger’s theorem, we can find a small cut by BFS from s.

  • Exercise. Find an O n
  • approx algorithm via rounding + BFS.

Advanced Algorithms (II) 11/11

slide-50
SLIDE 50

The Choice of β

We already have |L1| + |L2| ≤ 1 β · OPT + β(m − |L1|) ≤ 1 β · OPT + βm. Setuing β = √

OPT m

yields an O ( m

1 2

) approximation.

Remark

Instead of using Menger’s theorem, we can find a small cut by BFS from s.

  • Exercise. Find an O

( n

2 3

)

  • approx algorithm via rounding + BFS.

Advanced Algorithms (II) 11/11