Lecture 7. s.t. e = (u,v) E x u + x v 1 (2) v V x v 0 (3)

Similar documents
Lecture Overview. 2 Shortest s t path. 2.1 The LP. 2.2 The Algorithm. COMPSCI 530: Design and Analysis of Algorithms 11/14/2013

4 Greedy Approximation for Set Cover

Repetition: Primal Dual for Set Cover

1 Linear programming relaxation

Approximation Algorithms

Lecture 2. 1 Introduction. 2 The Set Cover Problem. COMPSCI 632: Approximation Algorithms August 30, 2017

Linear Programming Duality and Algorithms

Approximation Algorithms: The Primal-Dual Method. My T. Thai

Steiner Trees and Forests

Algorithm Design and Analysis

val(y, I) α (9.0.2) α (9.0.3)

Lecture 8: The Traveling Salesman Problem

CPSC 536N: Randomized Algorithms Term 2. Lecture 10

/ Approximation Algorithms Lecturer: Michael Dinitz Topic: Linear Programming Date: 2/24/15 Scribe: Runze Tang

College of Computer & Information Science Fall 2007 Northeastern University 14 September 2007

In this lecture, we ll look at applications of duality to three problems:

Approximation slides 1. An optimal polynomial algorithm for the Vertex Cover and matching in Bipartite graphs

Mathematical and Algorithmic Foundations Linear Programming and Matchings

15-854: Approximations Algorithms Lecturer: Anupam Gupta Topic: Direct Rounding of LP Relaxations Date: 10/31/2005 Scribe: Varun Gupta

Trees. Arash Rafiey. 20 October, 2015

CS 473: Algorithms. Ruta Mehta. Spring University of Illinois, Urbana-Champaign. Ruta (UIUC) CS473 1 Spring / 36

CS599: Convex and Combinatorial Optimization Fall 2013 Lecture 14: Combinatorial Problems as Linear Programs I. Instructor: Shaddin Dughmi

11.1 Facility Location

A List Heuristic for Vertex Cover

Approximation Algorithms

The k-center problem Approximation Algorithms 2009 Petros Potikas

Approximation Algorithms

CSE 331: Introduction to Algorithm Analysis and Design Graphs

1 Bipartite maximum matching

Lecture 4: Primal Dual Matching Algorithm and Non-Bipartite Matching. 1 Primal/Dual Algorithm for weighted matchings in Bipartite Graphs

/633 Introduction to Algorithms Lecturer: Michael Dinitz Topic: Approximation algorithms Date: 11/27/18

CS270 Combinatorial Algorithms & Data Structures Spring Lecture 19:

2 Solving the Online Fractional Algorithm and Online Rounding Scheme

The complement of PATH is in NL

Theory of Computing. Lecture 10 MAS 714 Hartmut Klauck

6 Randomized rounding of semidefinite programs

Approximation Algorithms

Distributed Algorithms 6.046J, Spring, Nancy Lynch

CS369G: Algorithmic Techniques for Big Data Spring

12.1 Formulation of General Perfect Matching

Lecture Overview. 2 The Steiner Tree Problem. 2.1 Steiner tree: a 2-approximation algorithm. COMPSCI 590.1: Graph Algorithms March 22, 2015

Lecture 14: Linear Programming II

1. Lecture notes on bipartite matching

Graph Representations and Traversal

CS261: A Second Course in Algorithms Lecture #16: The Traveling Salesman Problem

4 Integer Linear Programming (ILP)

Primal-Dual Methods for Approximation Algorithms

Traveling Salesman Problem (TSP) Input: undirected graph G=(V,E), c: E R + Goal: find a tour (Hamiltonian cycle) of minimum cost

Dual-fitting analysis of Greedy for Set Cover

Solutions for the Exam 6 January 2014

Introduction to Mathematical Programming IE496. Final Review. Dr. Ted Ralphs

Combinatorial Optimization

CS 580: Algorithm Design and Analysis. Jeremiah Blocki Purdue University Spring 2018

11. APPROXIMATION ALGORITHMS

Lecture 1. 2 Motivation: Fast. Reliable. Cheap. Choose two.

6. Lecture notes on matroid intersection

CMSC 451: Lecture 22 Approximation Algorithms: Vertex Cover and TSP Tuesday, Dec 5, 2017

Vertex Cover Approximations

Theorem 2.9: nearest addition algorithm

1. Lecture notes on bipartite matching February 4th,

Lecture #7. 1 Introduction. 2 Dijkstra s Correctness. COMPSCI 330: Design and Analysis of Algorithms 9/16/2014

2 The Fractional Chromatic Gap

Number Theory and Graph Theory

Coping with the Limitations of Algorithm Power Exact Solution Strategies Backtracking Backtracking : A Scenario

Notes for Lecture 20

Lecture 5: Duality Theory

Introduction to Algorithms / Algorithms I Lecturer: Michael Dinitz Topic: Approximation algorithms Date: 11/18/14

Matchings in Graphs. Definition 1 Let G = (V, E) be a graph. M E is called as a matching of G if v V we have {e M : v is incident on e E} 1.

Section Notes 5. Review of Linear Programming. Applied Math / Engineering Sciences 121. Week of October 15, 2017

CS 161 Lecture 11 BFS, Dijkstra s algorithm Jessica Su (some parts copied from CLRS) 1 Review

In this chapter we introduce some of the basic concepts that will be useful for the study of integer programming problems.

Design and Analysis of Algorithms (V)

Advanced Operations Research Techniques IE316. Quiz 2 Review. Dr. Ted Ralphs

CS2 Algorithms and Data Structures Note 10. Depth-First Search and Topological Sorting

LECTURES 3 and 4: Flows and Matchings

Introduction to Mathematical Programming IE406. Lecture 20. Dr. Ted Ralphs

Duality. Primal program P: Maximize n. Dual program D: Minimize m. j=1 c jx j subject to n. j=1. i=1 b iy i subject to m. i=1

Approximability Results for the p-center Problem

CS 6783 (Applied Algorithms) Lecture 5

31.6 Powers of an element

CS473-Algorithms I. Lecture 13-A. Graphs. Cevdet Aykanat - Bilkent University Computer Engineering Department

Jessica Su (some parts copied from CLRS / last quarter s notes)

15-451/651: Design & Analysis of Algorithms October 11, 2018 Lecture #13: Linear Programming I last changed: October 9, 2018

Advanced Operations Research Techniques IE316. Quiz 1 Review. Dr. Ted Ralphs

PCP and Hardness of Approximation

Approximation Algorithms

9.1 Cook-Levin Theorem

Dual-Based Approximation Algorithms for Cut-Based Network Connectivity Problems

Algorithm and Complexity of Disjointed Connected Dominating Set Problem on Trees

2. True or false: even though BFS and DFS have the same space complexity, they do not always have the same worst case asymptotic time complexity.

Notes for Lecture 24

Decision Problems. Observation: Many polynomial algorithms. Questions: Can we solve all problems in polynomial time? Answer: No, absolutely not.

Lecture 10,11: General Matching Polytope, Maximum Flow. 1 Perfect Matching and Matching Polytope on General Graphs

Approximation Algorithms

CS 4407 Algorithms. Lecture 8: Circumventing Intractability, using Approximation and other Techniques

Introduction to Graph Theory

1 Matching in Non-Bipartite Graphs

Approximation Algorithms

Lecture 4: September 11, 2003

1 Minimum Cut Problem

Transcription:

COMPSCI 632: Approximation Algorithms September 18, 2017 Lecturer: Debmalya Panigrahi Lecture 7 Scribe: Xiang Wang 1 Overview In this lecture, we will use Primal-Dual method to design approximation algorithms for several problems, including vertex cover problem, set cover problem and feedback vertex set problem. 2 Vertex Cover Given an undirected graph G = (V,E), a subset of vertices U V is called a vertex cover if for each edge in E, at least one of its adjacent vertex is in U. Finding a minimum vertex cover is called vertex cover problem. Now, let s first relax this problem as a linear programming problem: min x v (1) v V s.t. e = (u,v) E x u + x v 1 (2) v V x v 0 (3) We call the above linear programming problem the Primal problem. Let s write down its Dual form, where E v denotes all the edges adjacent to vertex v: max y e (4) e E s.t. v V e:e Ev y e 1 (5) e E y e 0 (6) Before introducing the primal-dual algorithm for vertex cover problem. Let s first give some general ideas for primal-dual method. As Figure 1 shows, due to weak duality, the cost of any primal solution is larger than or equal to the cost of any dual solution. In any Primal-Dual algorithm, we will construct an integral primal solution (Algo. (P)) and a (fractional) dual solution (Algo. (D)), and bound the approximation ratio (Approx. Ratio) by the ratio (Algo. Ratio) between the cost of primal solution and the cost of dual solution. We note that in a Primal-Dual algorithm, we don t need to solve the primal linear programming. This is a central difference from the Rounding method. Now let s see the Primal-Dual algorithm for vertex cover problem. Initially, we set all x v, v V and all y e, e E to zero. Then, we choose an arbitrary dual variable y e. We increase y e until one of the related dual constraint becomes tight, which means this constraint becomes a equality. Suppose the primal variable corresponding to this tight dual constraint is x v, we set x v to 1. Repeat this process until all primal constraints are satisfied. In other words, we start from an infeasible primal solution and a feasible but far 7-1

Figure 1: Primal-Dual Method. from optimal dual solution, then we gradually increase primal variables and dual variables to make primal solution feasible and dual solution near optimal. Obviously, this algorithm outputs a vertex cover. Now we claim this algorithm achieves 2-approximation. Theorem 1. There is an algorithm achieving 2-approximation for minimizing vertex cover. Proof. We can just bound the ratio between the cost of primal solution and the cost of dual solution. Denote the cost of primal solution by P, and the cost of dual solution by D. P = x v (7) v V :x v =1 = y e e E v (8) v V :x v =1 2 y e (9) e E = 2D (10) The second equality is because that a primal variable is set to 1 only if its corresponding dual constraint is tight. The only inequality is due to the fact that each edge has only two adjacent vertices, which means each dual variable at most appears twice in the sum. 3 Set Cover Next, let s see a more general problem, set cover problem. Given a set of elements U = {1,2,...,n} (called the universe) and a collection C of m sets whose union equals the universe, the set cover problem is to find the smallest sub-collection of C whose union equals the universe. Just as before, let s first write down the primal and dual formulation. Primal: min x S (11) S C s.t. e U S:e S x S 1 (12) S C x S 0 (13) 7-2

Dual: max y e (14) e U s.t. S C e S y e 1 (15) e U y e 0 (16) The Primal-Dual algorithm for set cover problem is exactly the same one for vertex cover. We claim that this algorithm can achieve f -approximation ratio for set cover problem, where f is the maximum number of sets that an element belongs to. Theorem 2. There is an algorithm achieving f-approximation for minimizing set cover, where f is the maximum number of sets that an element belongs to. Proof. Just as before, we can just bound the ratio between the cost of primal solution and the cost of dual solution. Denote the cost of primal solution by P, and the cost of dual solution by D. P = x S (17) S C:x S =1 = y e (18) S C:x S =1 e S f y e (19) e U = f D (20) The second equality is because a primal variable is set to 1 only if its corresponding dual constraint is tight. The only inequality is due to the fact that each element belongs to at most f sets, which means each dual variable appears at most f times in the sum. 4 Feedback Vertex Set Next, let s move on to a more interesting problem, feedback vertex set problem. Given an undirected graph G = (V,E), the feedback vertex set problem is to find the smallest subset of vertices, whose removal makes the graph acyclic. An immediate observation is that this is just a special case of set cover problem, if we view cycles as elements and vertices as sets. Let s first write down the primal and dual formulation of feedback vertex set problem. Dual: min x v (21) v V s.t. cycle C v C x v 1 (22) v V x v 0 (23) 7-3

max y C (24) cycle C s.t. v V C:v C y C 1 (25) cycle C y C 0 (26) Since feedback vertex set problem is a special case of set cover problem, a natural question is can we directly use the previous algorithm to tackle feedback vertex set problem? Let s see what s the value of f in feedback vertex set problem. We find f equals the maximum number of vertices on a cycle, which could be n if the graph is just a giant cycle. An n-approximation algorithm is totally useless, since even simply removing all vertices yields an n-approximation algorithm (assume at least one cycle exists). It seems like we need to modify the algorithm and give a more careful analysis. Let s investigate the relationship between primal solution and dual solution in feedback vertex problem (suppose the feedback vertex set chosen is F): P = x v (27) v F = y C (28) v F C:v C = F C y C (29) cycle C One observation is that if all F C for nonzero y C is small, we can gain a much better approximation ratio. It seems like we d better only increase dual variables whose corresponding cycles are short. However, what if the graph is just a giant cycle? Actually, in this case, just removing one vertex is enough. In order to exploit this observation, we add a degree-1 removal step into the original algorithm. In each step, before we choose a dual variable to increase, we first remove all degree-1 vertices of the graph until there is no degree-1 vertices. Another observation is that degree-2 vertex is not a big trouble. Given a long degree-2 path, we can just choose one of them, and the degree-1 removal step will remove the remainings. What we should really worry about is vertices with high degree ( 3). Thus, instead of choosing an arbitrary dual variable to increase, now we choose the dual variable whose corresponding cycle contains smallest number of high degree ( 3) vertices. This selection procedure can be solved using a BFS-like algorithm within polynomial time. We first prove a crucial lemma claiming that on a degree-1 free graph, there must exist a cycle whose high degree ( 3) vertices are no more than 2logn, where n is the number of vertices on this graph. Lemma 3. Given a graph with no degree-1 vertex, it must contain a cycle with no more than 2logn high degree ( 3) vertices, where n is the total number of vertices on this graph. Proof. In this proof, we define high degree vertices as vertices with degree larger than or equal to 3. First, we shortcut all degree-2 vertices on the graph. If there is a path containing only degree-2 vertices between two high degree vertices, we simply substitute this path by an edge between these two high degree vertices. After shortcuting all degree-2 paths, we have a graph containing only high degree vertices. The number of high degree vertices is no more than n. Starting from any vertex, we do a Breadth-First Search of this graph. On the search tree, each vertex has at least two children. Thus, the depth of the search tree cannot be larger than log n. There must exist an edge crossing different paths of this search tree, which immediately constitutes a cycle with no more than 2logn high degree vertices. 7-4

With the above lemma, we know the cycle we choose in the algorithm has no more than 2logn high degree vertices. Between these high degree vertices, there could be no more than 2logn degree-2 segments. We claim for each degree-2 segment, at most one vertex can be put into the feedback vertex set. This is because once we put one vertex from the degree-2 segment into the feedback set, the degree-1 removal procedure will remove all the remaining vertices on this degree-2 segments. It turns out that on each chosen cycle, at most 4logn vertices in total can be put into the feedback vertex set. In other words, we have proven that for any nonzero dual variable y C, F C is upper bounded by 4logn, which immediately implies that our algorithm achieves 4logn approximation ratio. Theorem 4. There is an algorithm achieving 4 log n-approximation ratio for minimizing feedback vertex set. The major lesson from this algorithm is that sometimes we should be careful on choosing which dual variable to increase, instead of just arbitrarily choosing any dual variable. 5 Summary In this lecture, we have given the general framework of Primal-Dual method. We have showed how to design and analyze Primal-Dual algorithms through three examples, vertex cover problem, set cover problem and feedback vertex set problem. Through the analysis of feedback vertex set problem, we have learned that sometimes we should be careful on choosing which dual variable to increase. 7-5