approximation algorithms

21
Approximation Algorithms Department of Mathematics and Computer Science Drexel University

Upload: dutch

Post on 24-Jan-2016

89 views

Category:

Documents


0 download

DESCRIPTION

Approximation Algorithms. Department of Mathematics and Computer Science Drexel University. The Generalized Steiner Tree Problem :. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Approximation Algorithms

Approximation Algorithms

Department of Mathematics and Computer ScienceDrexel University

Page 2: Approximation Algorithms

The Generalized Steiner Tree Problem :

We are given a graph G=(V,E) with edge weights and a set of vertices selected out of V say pairs si,ti such that si

and ti need to communicate. We'd like to find a minimum cost sub-graph such that all the <si,ti> pairs are connected.

Given: G=(V,E) w.l.o.g. fully connected, weights we>= 0, for every edge e in E

<s1,t1>, <s2,t2>,…, <sk,tk> paris of communicating edges

Find: A min cost subgraph H of G such that for all values of i in {1,…,k} the pairs <si,ti> ’s are connected in H.

Page 3: Approximation Algorithms

Two Definitions: Define L(S) as the indicator of subset S of V if S forms a

cut that separates one of the <si ,ti> pairs. More formally:

Also, for a graph G=(V,E) and a subset of vertices S define (S)={e=(u,v) in E : u in S and v not in S}. That is, (S) is the set of edges that cross the cut boundary.

1,:1)(

1,02:)(

ii

V

tsSiSL

SL

Page 4: Approximation Algorithms

ILP Formulations:

Eex

SSLx

xw

EeHe

Hex

e

See

Eeee

e

},1,0{

,)( :sConstraint

min :Objective

if0

if1 :Variables

)(

Page 5: Approximation Algorithms

Why is this formulation correct:

Let X=(x1,…, xm) be a feasible solution for previous ILP, and assume to the contrary that there exist a communicating pair (u,v) that is not connected using the edges in set {e | xe=1 (the entry e in X)}.

There are many cuts that separate u and v. Let S be once such cut that contains u. We will also add all the vertices in the same connected component as u to S.

Since u and v are disconnected with respect to edges selected by X. Sum of the xe with respect to cut S is zero, but L(S)=1, and the cut edges violate the constraint of cut S, that contradicts the feasibility of X.

Page 6: Approximation Algorithms

Relaxation:We will relax the integrality condition to

xe>=0. As a result:

Eeee

xxwOpt

0Steiner min

Page 7: Approximation Algorithms

Dual Problem:

0

, :sConstriant

)(max :Objective

)(:

y

s

eSeS

s

VSs

y

Eewy

ySL

Page 8: Approximation Algorithms

Some terminologies: A dual variable is raised if ys>0.

A set S of vertices is unsatisfied if L(S)=1 but no cut edge between S and V-S has been selected by algorithm yet.

The smallest unsatisfied set is referred to as active set. Edge e is said to be tight if:

)(: SeS

es wy

Page 9: Approximation Algorithms

Outline: The algorithm starts with no edges picked

and no cuts raised. During any iteration of the algorithm:

the current primal solution indicates which sets should be raised,

and the current dual solution indicates which edge needs to be picked.

Thus, the algorithm iteratively improves both the primal and dual solution integrally until the primal solution becomes feasible.

Page 10: Approximation Algorithms

Outline: Let us describe what happens in an iteration.

Let F denote the sub-graph the algorithm is constructing. Using the primal solution, the algorithm finds all the active

sets in F and raises the dual variables of these sets simultaneously until some edge goes tight.

Note that it is the dual solution at the beginning of the iteration that determines how high the dual variables of the active sets can be raised. Any one of the tight edges is picked and added to F.

The edge augmentation step terminates once F becomes a feasible primal solution.

Since F may contain redundant edges, that is edges whose deletion still makes F feasible, a final pruning step is necessary to achieve the desired approximation factor.

Page 11: Approximation Algorithms

Outline:

infeasible primal is -|return (Pruning) 3.

}.{

tight;goes edge some until ,set

activeeach for raisesly Simultanou

:doset dunsatisfiean exists there While

on)Augmentati (Edge.2

0 ,each For

;

ation)(Initializ.1

eFFeF'

eFF

eS

y

yS

F

s

s

Page 12: Approximation Algorithms

Some observations: before proving the correctness of the algorithm, we will show

that it is not difficult to find all the active sets in an iteration. In fact, it is sufficient to consider all the connected components of the current F .

Set S is active at iteration i if and only if it is a connected component of F (at iteration i) and L(S) = 1: if Set S is active then L(S) = 1 and is minimal, and hence

connected in the current sub-graph F . Next, if S is a connected component of F and L(S)=1,

then S is a minimal unsatisfied set, otherwise, there is a larger connected component of F that contains S.

Page 13: Approximation Algorithms

Some observations: At the end of the algorithm, F’ and y are feasible primal and

dual solutions: At the end of the edge augmentation step, F satisfies all

the connectivity requirements. Furthermore, it is not difficult to see that F is a forest, since only the dual variables of connected components are raised. That is, none of the edges in a connected component will become tight in later iterations. Since F is a forest, if u and v are a communicating pair, then there is a unique path from u to v. None of the edges along this path can be pruned and therefore, F’ remains primal feasible after the pruning step.

Page 14: Approximation Algorithms

Some observations: Moreover:

Suppose edge e becomes tight at an iteration. If e is picked, then all the sets S such that e belongs to (S) with L(S) = 1 becomes satisfied and none will be active in later iterations. Consequently, all the dual variables of these sets will never be raised in the future and the constraint corresponding to edge e remains valid. But suppose edge e is not picked at the end of the iteration nor at succeeding iterations before the algorithm raises the dual variables of some active sets. This implies that the sets S such that e belongs to (S) with L(S) = 1 are no longer active. We follow the same argument above that the constraint corresponding to e in the dual remains valid at the end of the algorithm.

Page 15: Approximation Algorithms

Lemma: Let degF’(S) denote the edges in F’ that cross the cut (S,V-S) then:

.

.2'

VS

sFe

e yw

VSs

VSsF

VSsF

VS FSes

Fee

Fe Ses

Fee

yyS

ySyw

yw

2).(deg

show tosufficient isit Thus,

).(deg

summation, oforder theChanging

tightis edge pickedevery Since

'

'')('

' )('

Page 16: Approximation Algorithms

Some observations: In fact, we can prove a stronger result: that in each iteration, the

increase in the l.h.s. of this inequality is bounded by the increase in the r.h.s. of the inequality. Consider an iteration. Let be the increase in the dual variables of the active sets in this iteration. Thus, we wish to show that:

.2sets active of #

)(deg

ly,equivalentor

sets active of #2)(deg

active '

active '

SF

SF

S

S

Page 17: Approximation Algorithms

Some observations: That is, we need to show that the average degree of the active sets

with respect to F’ is at most 2. Notice that these degrees are due to the edges that will be picked during or after the current iteration.

The heart of argument relies on the fact that the average degree of a tree or a forest is at most 2.

Consider the graph F’. Contract all the nodes in each active set S to a single node and let us call these nodes active.

Delete all the singletons. Call this new graph H. Then the degree of the active node corresponding to set S in H is degF’ (S).

Since F’ is a forest, H must also be a forest. To show that the average degree of the active nodes in H is at most 2, it is sufficient to show that all inactive nodes in H must have degree at least 2, since the average degree of all the nodes in a forest is at most 2.

Page 18: Approximation Algorithms

Claim At iteration i, let C be a connected component w.r.t. F. If

L(C) = 0 then degF’(C) is not 1.

Suppose there is a unique edge e of F’ that crosses the cut (C,V-C). Since F’ does not contain redundant edges, there must be a communicating pair u and v such that u belongs to C and v in V-C. This implies that L(C) = 1, leading to a contradiction.

Thus, if l in H is not active, l must be part of some connected component w.r.t. F at iteration i, say C, and L(C)=0. Furthermore, if l is a leaf in H then degF’(C)=1 contradicting the claim above. Thus, all leaves in H are active and all inactive nodes in H have degree at least 2.

Page 19: Approximation Algorithms

Primal-dual Algorithm: Initialization:

)represent will)(( 0)(Let

,...,,

of components connected thebe

0

0

)solution thebe willy (Eventuallsolution current thebe FLet

21

Ss:is

n

yididVi

vvv

F

y

k

F

HF

Page 20: Approximation Algorithms

The algorithm

Print

then feasible is }{if 1,...,For

}{},{

by )( increase 1)(

)(

1

)()( thatNote

)()(

))()(( minimizes that and with )( edgean Find

tight.becomes constarint edge some till increase will we1)( //

)1)( (i.e. feasiblenot is While

)(),(:

F

eFFe F-kj

SqSpSqSp

idS:LS

eFF

i,j e

kk

yjdi d

SqLSpL

jdidwSq jSpiEi,j

yS:LS

C:LSF

jj

k

k

SjiSs

e

S

Page 21: Approximation Algorithms

Example:

Communicating pairs:<u,v>, <s,t>.