Slides on Approximation algorithms, part 2: Basic approximation algorithms

Similar documents
Basic Approximation algorithms

Slides on Approximation algorithms, part 2: Basic approximation algorithms

Approximation Algorithms

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

1 Minimum Spanning Trees (MST) b 2 3 a. 10 e h. j m

Outline. CS38 Introduction to Algorithms. Approximation Algorithms. Optimization Problems. Set Cover. Set cover 5/29/2014. coping with intractibility

Lecture 8: The Traveling Salesman Problem

Theorem 2.9: nearest addition algorithm

Best known solution time is Ω(V!) Check every permutation of vertices to see if there is a graph edge between adjacent vertices

An O(log n/ log log n)-approximation Algorithm for the Asymmetric Traveling Salesman Problem

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

1 The Traveling Salesperson Problem (TSP)

Institute of Operating Systems and Computer Networks Algorithms Group. Network Algorithms. Tutorial 4: Matching and other stuff

Algorithm Design and Analysis

11. APPROXIMATION ALGORITHMS

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

Module 6 NP-Complete Problems and Heuristics

Introduction to Approximation Algorithms

Approximation Algorithms

APPROXIMATION ALGORITHMS FOR GEOMETRIC PROBLEMS

NP-Hard (A) (B) (C) (D) 3 n 2 n TSP-Min any Instance V, E Question: Hamiltonian Cycle TSP V, n 22 n E u, v V H

COMP 355 Advanced Algorithms Approximation Algorithms: VC and TSP Chapter 11 (KT) Section (CLRS)

Approximation Algorithms

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

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

Module 6 NP-Complete Problems and Heuristics

NP Completeness. Andreas Klappenecker [partially based on slides by Jennifer Welch]

Partha Sarathi Mandal

Unit 8: Coping with NP-Completeness. Complexity classes Reducibility and NP-completeness proofs Coping with NP-complete problems. Y.-W.

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

Fall CS598CC: Approximation Algorithms. Chandra Chekuri

Technische Universität München, Zentrum Mathematik Lehrstuhl für Angewandte Geometrie und Diskrete Mathematik. Combinatorial Optimization (MA 4502)

Module 6 P, NP, NP-Complete Problems and Approximation Algorithms

Approximation Algorithms

Module 6 NP-Complete Problems and Heuristics

CS270 Combinatorial Algorithms & Data Structures Spring Lecture 19:

Greedy algorithms Or Do the right thing

The k-center problem Approximation Algorithms 2009 Petros Potikas

Introduction to Algorithms

Final. Name: TA: Section Time: Course Login: Person on Left: Person on Right: U.C. Berkeley CS170 : Algorithms, Fall 2013

Solutions for the Exam 6 January 2014

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

11. APPROXIMATION ALGORITHMS

Notes for Recitation 9

Steiner Trees and Forests

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

P and NP (Millenium problem)

V1.0: Seth Gilbert, V1.1: Steven Halim August 30, Abstract. d(e), and we assume that the distance function is non-negative (i.e., d(x, y) 0).

Coping with NP-Completeness

Approximation Algorithms

Design and Analysis of Algorithms

Traveling Salesperson Problem (TSP)

Assignment 5: Solutions

Graphs and Algorithms 2015

Matching 4/21/2016. Bipartite Matching. 3330: Algorithms. First Try. Maximum Matching. Key Questions. Existence of Perfect Matching

Optimal tour along pubs in the UK

1 Variations of the Traveling Salesman Problem

Chapter 9 Graph Algorithms

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

Mathematical Tools for Engineering and Management

The Subtour LP for the Traveling Salesman Problem

NP-Complete Reductions 2

Lokale Netzstrukturen Exercise 5. Juli 19, 2017

Notes for Lecture 24

Prove, where is known to be NP-complete. The following problems are NP-Complete:

Polynomial time approximation algorithms

! Greed. O(n log n) interval scheduling. ! Divide-and-conquer. O(n log n) FFT. ! Dynamic programming. O(n 2 ) edit distance.

Introduction to Algorithms. Lecture 24. Prof. Patrick Jaillet

11. APPROXIMATION ALGORITHMS

Chapter 9 Graph Algorithms

Travelling Salesman Problem. Algorithms and Networks 2015/2016 Hans L. Bodlaender Johan M. M. van Rooij

GRAPH THEORY and APPLICATIONS. Matchings

Traveling Salesman Problem. Algorithms and Networks 2014/2015 Hans L. Bodlaender Johan M. M. van Rooij

Solutions to Assignment# 4

NP-complete Reductions

COMP Analysis of Algorithms & Data Structures

Advanced Methods in Algorithms HW 5

Presentation for use with the textbook, Algorithm Design and Applications, by M. T. Goodrich and R. Tamassia, Wiley, Approximation Algorithms

Iterative Methods in Combinatorial Optimization. R. Ravi Carnegie Bosch Professor Tepper School of Business Carnegie Mellon University

Questions? You are given the complete graph of Facebook. What questions would you ask? (What questions could we hope to answer?)

ACO Comprehensive Exam October 12 and 13, Computability, Complexity and Algorithms

Minimum-weight tree shortcutting for Metric TSP


Exercise set 2 Solutions

1 Better Approximation of the Traveling Salesman

Constructive and destructive algorithms

Theory of Computing. Lecture 10 MAS 714 Hartmut Klauck

MITOCW watch?v=zm5mw5nkzjg

CMPSCI611: The SUBSET-SUM Problem Lecture 18

P and NP CISC5835, Algorithms for Big Data CIS, Fordham Univ. Instructor: X. Zhang

Problem Set 6 (Due: Wednesday, December 6, 2006)

Graphs and Network Flows IE411. Lecture 21. Dr. Ted Ralphs

Exam 3 Practice Problems

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

Approximating Node-Weighted Multicast Trees in Wireless Ad-Hoc Networks

Steiner Tree. Algorithms and Networks 2014/2015 Hans L. Bodlaender Johan M. M. van Rooij

P and NP CISC4080, Computer Algorithms CIS, Fordham Univ. Instructor: X. Zhang

NP Completeness. Andreas Klappenecker [partially based on slides by Jennifer Welch]

2 Approximation Algorithms for Metric TSP

Approximability Results for the p-center Problem

Transcription:

Approximation slides Slides on Approximation algorithms, part : Basic approximation algorithms Guy Kortsarz

Approximation slides Finding a lower bound; the TSP example The optimum TSP cycle P is an edge plus a spanning tree. Thus, the minimum cost spanning tree T has cost c(t ) c(p ) We use the idea of shortcuts If we are given a (not necessarily simple) a to b path P, replacing the path P by (a,b) can not increase the cost (because of triangle inequality). Claim: Given an Euler cycle (a cycle that crosses all edges once) of cost c there exists a TSP path of cost at most c Pf: Shortcut

Approximation slides 3 TSP, Cont. Getting an Euler cycle: double every edge in MST T Gives an Euler cycle (all degrees are even) T * a 4 a 4 b 3 c 4 d b 3 3 c d e f e f c a b a c d c f c e c c a b d f e

Approximation slides 4 Steiner tree Input: A graph G(V,E) a weight function w : E + and a subset S V of terminals Required: A subtree T of G that contains all of S and has minimum cost It is easy to see that we may assume that w is complete: add/replace e = (u,v) by the cost of the shortest u to v path. If an edge (u,v) is used and does not belong to G replace it by the edges of the shortest path. The cost does not increase. Thus, if we restrict ourself to G(S) spanned by S and find a minimum spanning tree on G(S) a ratio approximation results. The reason: The Euler path that result the optimum (by doubling edges) can first be shortcut to contain S vertices only and then shortcut to an Hamiltonian path which in particular is some spanning tree

Approximation slides 5 Improving the ratio to 3/ Idea due to Christophedes Any TSP solution is a Hamilton path; A simple path that contains all vertices. Any TSP tour of even length decomposes into two perfect matchings

Approximation slides 6. Find MST T(V,E ) The algorithm. Let X V be the vertices of odd degree in T 3. Compute the graph G X = (X,X X). Find a minimum cost perfect matching M in G X 4. Find an Euler cycle in T M 5. Shortcut Analysis: First, shortcut the tour to X Let M,M be the two perfect matchings of P on X c(p) = c(m )+C(M ) c(m) Thus c(t M) 3opt/ Hence 3/ ratio

Approximation slides 7 Finding lower bound: The Unweighted vertex-cover example Figure : VC M The size of any matching lower bounds the minimum VC A maximal matching gives a size M vertex-cover Hence, ratio.

Approximation slides 8 A lower bound is not always required: certificate of failure Say that for input I we want to find a feasible solution minimizing some integral function µ(i). Let opt be opt = mini µ(i). For an integer x say that we have a procedure P(I,x) that has one of the following inputs:. Either it determines that x < opt and then returns F alse. Or, it returns a solution S(I) False of cost at most µ(i) ρ x P(I, x) called a certificate of failure procedure (Hochbaum and Shmoys). Claim: The above procedure can be used as an oracle to produce a ρ approximation algorithm.

Approximation slides 9 Binary search Assume the costs are integral. lb min, ub max /* lb,ub some lower and upper bounds over minimum and maximum possible value of µ(i) */. 3. While max min > do (a) x (lb+up)/ (b) If P(I,lb) is false, then lb x (c) Else, ub x 4. Return ub Since opt > lb and opt integer, opt ub. So, ρ ratio

Approximation slides 0 Running time Claim: If, P(I,x) is polynomial in I and ub lb always O(exp( I )) then polynomial We now use this to give ratio approximation for the k center problem The input a complete graph on the vertices {,...,n}. A bound k on the number of centers. Every i,j have distance d ij. We assume the triangle inequality (otherwise, no approximation possible).

Approximation slides A approximation for undirected k center The algorithm. It is a certificate of failure algorithm with (I,x). Due to Hochbaum and Shmoys.. S. V V 3. While S is not a legal solution, do (a) Add to S and arbitrary vertex i V (b) Delete from V all vertices j so that l ij x 4. If S > k return False 5. Else, return S

Approximation slides The two properties x x x x Figure : An illustration of the algorithm in the special case of points in the plane. The distance between any two centers is more than x All centers have pairwise distance larger than x. Consider our centers that are non-centers in OPT

Approximation slides 3 Analysis cont. Let j and p be two centers in our algoritm but not in OPT If q OPT covers both j and p and opt x then by triangle inequality: d j,p d j,q +d p,q x. This is a contradiction. If j e.g. computed before p then p is removed So, since S > k the optimum would have more than k, contradiction. Thus S > k implies that there could not be a k subset that covers all of S. In other words, x < opt. This proves that the failure certificate is correct. Remark: It can be that x < opt but the procedure succeeds

Approximation slides 4 The two properties. Continued If returns a solution then by construction the solution has radios x. Hence ρ = We can use binary search, as opt max distance. Thus, approximation Also better than is as hard as solving: The dominating set problem: Input: G(V,E) and k Question: Is there a dominating set of size at most k, namely, a subset U V, U k so that U N(U) = V? This problem is NPC.

Approximation slides 5 Why a ratio better than is not possible Give edges of G length and non-edges in V V \E length This implies the triangle inequality holds There is a dominating set of size k if and only if there is a k center solution of size k Approximating within ǫ implies in the case of a yes instance an optimal solution... Figure 3: Edges are given length. Non-edges are gives length. Not all non-edges are shown