# 15-451/651: Design & Analysis of Algorithms March 28, 2016 Lecture #19 last changed: March 31, 2016

Save this PDF as:

Size: px
Start display at page:

Download "15-451/651: Design & Analysis of Algorithms March 28, 2016 Lecture #19 last changed: March 31, 2016"

## Transcription

1 15-451/651: Design & Analysis of Algorithms March 28, 2016 Lecture #19 last changed: March 31, 2016 While we have good algorithms for many optimization problems, the previous lecture showed that many others we d like to solve are NP-hard. What do we do? Suppose we are given an NPcomplete problem to solve. Assuming P NP, we can t hope for a polynomial-time algorithm for these problems. But can we (a) get polynomial-time algorithms that always produce a pretty good solution? (A.k.a. approximation algorithms) (b) get faster (though still exponential-time) algorithms than the naïve solutions? Today we consider approaches to combat intractability for several problems. Specific topics in this lecture include: 2-approximation (and better) for scheduling to minimize makespan. 2-approximation for vertex cover via greedy matchings. 2-approximation for vertex cover via LP rounding. Greedy O(log n) approximation for set-cover. A faster-than-o(n k ) time algorithm for exact vertex cover when k is small. (optional) 1 Introduction Given an NP-hard problem, we don t hope for a fast algorithm that always gets the optimal solution. But we can t just throw our hands in the air and say We can t do anything! Or even, We can t do anything other than the trivial solution!. There are (at least) two ways of being smarter. First approach: find a poly-time algorithm that guarantees to get at least a pretty good solution? E.g., can we guarantee to find a solution that s within 10% of optimal? If not that, then how about within a factor of 2 of optimal? Or, anything non-trivial? Second approach: find a faster algorithm than the naïve one. There are a bunch of ideas that you can use for this, often related to dynamic programming today we ll talk about one of them. 1 As seen in the last two lectures, the class of NP-complete problems are all equivalent in the sense that a polynomial-time algorithm to solve any one of them would imply a polynomial-time algorithm to solve all of them (and, moreover, to solve any problem in NP). However, the difficulty of getting faster exact algorithms, or good approximations to these problems varies quite a bit. In this lecture we will examine some important NP-complete problems and look at to what extent we can achieve both goals above. 2 Scheduling Jobs to Minimize Load Here s a scheduling problem. You have m identical machines on which you want to schedule some n jobs. Each job j {1, 2,..., n} has a processing time p j > 0. You want to partition the jobs among the machines to minimize the load of the most-loaded machine. In other words, if S i is the 1 You already saw an example: in Lecture II on Dynamic programming, we gave an algorithm for TSP that ran in time O(n 2 2 n ), which is much faster than the trivial O(n n!) n n/2 time algorithm. 1

3 Definition 3 Vertex-Cover: Given a graph G, find the smallest set of vertices such that every edge is incident to at least one of them. Decision problem: Given G and integer k, does G contain a vertex cover of size k? For instance, this problem is like asking: what is the fewest number of guards we need to place in a museum in order to cover all the corridors. Exercise: Find a vertex cover in the graphs above of size 3. Show that there is no vertex cover of size 2 in them. Exercise: Find a vertex cover in the graph above of size 2. Show that there is no vertex cover of size 1 in this graph. As we saw last time (via a reduction from Independent Set), this problem is NP-hard. 3.1 Poly-time Algorithms that Output Approximate Solutions OK, we don t expect to find the optimal solution in poly-time. However, any graph G we can get within a factor of 2 (or better). That is, if the graph G has a vertex cover of size k, we can return a vertex cover of size at most 2k. Let s start first, though, with some strategies that don t work. Strawman Alg #1: Pick an arbitrary vertex with at least one uncovered edge incident to it, put it into the cover, and repeat. What would be a bad example for this algorithm? [Answer: how about a star graph] Strawman Alg #2: How about picking the vertex that covers the most uncovered edges. This is very natural, but unfortunately it turns out this doesn t work either, and it can produce a solution Ω(log n) times larger than optimal. 2 How can we get factor of 2? It turns out there are actually several ways. We will discuss here two quite different algorithms. Interestingly, while we have several algorithms for achieving a factor of 2, nobody knows if it is possible to efficiently achieve a factor The bad examples for this algorithm are a bit more complicated however. One such example is as follows. Create a bipartite graph with a set S L of t nodes on the left, and then a collection of sets S R,1, S R,2,... of nodes on the right, where set S R,i has t/i nodes in it. So, overall there are n = Θ(t log t) nodes. We now connect each set S R,i to S L so that each node v S R,i has i neighbors in S L and no two vertices in S R,i share any neighbors in common (we can do that since S R,i has at most t/i nodes). Now, the optimal vertex cover is simply the set S L of size t, but this greedy algorithm might first choose S R,t then S R,t 1, and so on down to S R,1, finding a cover of total size n t. Of course, the fact that the bad cases are complicated means this algorithm might not be so bad in practice. 3

4 Algorithm 1: Pick an arbitrary edge. We know any vertex cover must have at least 1 endpoint of it, so let s take both endpoints. Then, throw out all edges covered and repeat. Keep going until there are no uncovered edges left. Theorem 4 The above algorithm is a factor 2 approximation to Vertex-Cover. Proof: What Algorithm 1 finds in the end is a matching (a set of edges no two of which share an endpoint) that is maximal (meaning that you can t add any more edges to it and keep it a matching). This means if we take both endpoints of those edges. we must have a vertex cover. In particular, if the algorithm picked k edges, the vertex cover found has size 2k. But, any vertex cover must have size at least k since it needs to have at least one endpoint of each of these edges, and since these edges don t touch, these are k different vertices. So the algorithm is a 2-approximation as desired. Here is now another 2-approximation algorithm for Vertex Cover: Algorithm 2: First, solve a fractional version of the problem. Have a variable x i for each vertex with constraint 0 x i 1. Think of x i = 1 as picking the vertex, and x i = 0 as not picking it, and in-between as partially picking it. Then for each edge (i, j), add the constraint that it should be covered in that we require x i + x j 1. Then our goal is to minimize i x i. We can solve this using linear programming. This is called an LP relaxation because any true vertex cover is a feasible solution, but we ve made the problem easier by allowing fractional solutions too. So, the value of the optimal solution now will be at least as good as the smallest vertex cover, maybe even better (i.e., smaller), but it just might not be legal any more. [Give examples of triangle-graph and star-graph] Now that we have a super-optimal fractional solution, we need to somehow convert that into a legal integral solution. We can do that here by just picking each vertex i such that x i 1/2. This step is called rounding of the linear program (which literally is what we are doing here by rounding the fraction to the nearest integer for other problems, the rounding step might not be so simple). Theorem 5 The above algorithm is a factor 2 approximation to Vertex-Cover. Proof: Claim 1: the output of the algorithm is a legal vertex cover. Why? [get at least 1 endpt of each edge] Claim 2: The size of the vertex cover found is at most twice the size of the optimal vertex cover. Why? Let OP T frac be the value of the optimal fractional solution, and let OP T V C be the size of the smallest vertex cover. First, as we noted above, OP T frac OP T V C. Second, our solution has cost at most 2 OP T frac since it s no worse than doubling and rounding down. So, put together, our solution has cost at most 2 OP T V C. Interesting fact: nobody knows any algorithm with approximation ratio 1.9. Best known is 2 O(1/ log n), which is 2 o(1). 3.2 Hardness of Approximation There are results showing that a good-enough approximation algorithm will end up showing that P=NP. Clearly, a 1-approximation would find the exact vertex cover, and show this. Håstad showed that if you get a 7/6-approximation, you would prove P=NP. This 7/6 was improved to by Dinur and Safra. Beating 2 ε has been related to some other open problems (it is unique games hard ), but is not known to be NP-hard. 4

5 4 Set Cover The Set-Cover problem is defined as follows: Definition 6 Set-Cover: Given a domain X of n points, and m subsets S 1, S 2,..., S m of these points. Goal: find the fewest number of these subsets needed to cover all the points. The decision problem also provides a number k and asks whether it is possible to cover all the points using k or fewer sets. Set-Cover is NP-Complete. However, there is a simple algorithm that gets an approximation ratio of ln n (i.e., that finds a cover using at most a factor ln n more sets than the optimal solution). Greedy Algorithm (Set-Cover): Pick the set that covers the most points. Throw out all the points covered. Repeat. What s an example where this algorithm doesn t find the best solution? Theorem 7 If the optimal solution uses k sets, the greedy algorithm finds a solution with at most O(k ln n) sets. Proof: Since the optimal solution uses k sets, there must some set that covers at least a 1/k fraction of the points. The algorithm chooses the set that covers the most points, so it covers at least that many. Therefore, after the first iteration of the algorithm, there are at most n(1 1/k) points left. Again, since the optimal solution uses k sets, there must some set that covers at least a 1/k fraction of the remainder (if we got lucky we might have chosen one of the sets used by the optimal solution and so there are actually k 1 sets covering the remainder, but we can t count on that necessarily happening). So, again, since we choose the set that covers the most points remaining, after the second iteration, there are at most n(1 1/k) 2 points left. More generally, after t rounds, there are at most n(1 1/k) t points left. After t = k ln n rounds, there are at most n(1 1/k) k ln n < n(1/e) ln n = 1 points left, which means we must be done. 3 Also, you can get a slightly better bound by using the fact that after k ln(n/k) rounds, there are at most n(1/e) ln(n/k) = k points left, and (since each new set covers at least one point) you only need to go k more steps. This gives the somewhat better bound of k ln(n/k) + k. So, we have: Theorem 8 If the optimal solution uses k sets, the greedy algorithm finds a solution with at most k ln(n/k) + k sets. For set cover, this may be about the best you can do. Dinur and Steurer (improving on results of Feige) showed that if you get a (1 ɛ) ln(n)-approximation algorithm for any constant ɛ > 0, you will prove that P=NP. 5 Faster Exact Algorithms for Vertex Cover Let s see if we can solve the vertex cover problem faster than the obvious solution. To solve the decision version of the vertex cover problem, here s the trivial algorithm taking about n k time. Iterate over all subsets S V of size k. If S is a vertex cover, output YES and stop. output NO. 3 Notice how the above analysis is similar to the analysis we used of Edmonds-Karp #1. 5

6 How can you do better? Here s one cool way to do it: Theorem 9 Given G = (V, E) and k n = V, we can output (in time poly(n)) another graph H with at most 2k 2 vertices, and an integer k H k such that: (G, k) is a YES-instance (H, k H ) is a YES-instance. Since H is so much smaller, we can use the trivial algorithm above on (H, k ) to run in time V (H) k (2k 2 ) k 2 k(2 lg k+1). Hence solve the problem on (G, k) in the time it takes to produce H (which is poly(n)), plus about 2 2k lg k time. Much faster than n k when k n. It remains to prove Theorem 9. Proof: Here s a simple observation: suppose G has an isolated vertex v, i.e., there are no edges hitting v. Then (G, k) is a YES-instance (G {v}, k) is a YES-instance. The second observation: suppose G has a vertex v of degree at least k + 1. Then v must be in any vertex cover of size k. Why? If not, these k + 1 edges incident to v would have to be covered by their other endpoints, which would require k + 1 vertices. So (G, k) is a YES-instance (G {v}, k 1) is a YES-instance. (In this step, G {v} removes these edges incident to v as well.) And the final observation: if G has maximum degree k and has a vertex cover of size at most k, G has at most k 2 edges. Why? Each of the vertices in the cover can cover at most k edges (their degree is at most k). So now the construction of H is easy: start with G. Keep dropping isolated vertices (without changing k), or dropping high-degree vertices (and decrementing k) until you have some graph G and parameter k. By the first two observations, (G, k) is a YES-instance (G, k ) is a YES-instance. Now either G has more than (k ) 2 edges, then by the final observation (G, k ) is a NO-instance, so then let H be a single edge and k H = 0 (which is also a NO-instance.) Else return H = G and k H = k. Since H has (k ) 2 k 2 edges, it has at most 2k 2 nodes. Finally, the time to produce H? You can do all the above in linear time in G. 6

Approximation Algorithms Chapter Approximation Algorithms Q. Suppose I need to solve an NP-hard problem. What should I do? A. Theory says you're unlikely to find a poly-time algorithm. Must sacrifice one

### Algorithm Design and Analysis

Algorithm Design and Analysis LECTURE 27 Approximation Algorithms Load Balancing Weighted Vertex Cover Reminder: Fill out SRTEs online Don t forget to click submit Sofya Raskhodnikova 12/6/2011 S. Raskhodnikova;

### Approximation Algorithms

Approximation Algorithms or: How I Learned to Stop Worrying and Deal with NP-Completeness Ong Jit Sheng, Jonathan (A0073924B) March, 2012 Overview Key Results (I) General techniques: Greedy algorithms

### Applied Algorithm Design Lecture 5

Applied Algorithm Design Lecture 5 Pietro Michiardi Eurecom Pietro Michiardi (Eurecom) Applied Algorithm Design Lecture 5 1 / 86 Approximation Algorithms Pietro Michiardi (Eurecom) Applied Algorithm Design

### ! Solve problem to optimality. ! Solve problem in poly-time. ! Solve arbitrary instances of the problem. #-approximation algorithm.

Approximation Algorithms 11 Approximation Algorithms Q Suppose I need to solve an NP-hard problem What should I do? A Theory says you're unlikely to find a poly-time algorithm Must sacrifice one of three

### ! Solve problem to optimality. ! Solve problem in poly-time. ! Solve arbitrary instances of the problem. !-approximation algorithm.

Approximation Algorithms Chapter Approximation Algorithms Q Suppose I need to solve an NP-hard problem What should I do? A Theory says you're unlikely to find a poly-time algorithm Must sacrifice one of

### Near Optimal Solutions

Near Optimal Solutions Many important optimization problems are lacking efficient solutions. NP-Complete problems unlikely to have polynomial time solutions. Good heuristics important for such problems.

### Guessing Game: NP-Complete?

Guessing Game: NP-Complete? 1. LONGEST-PATH: Given a graph G = (V, E), does there exists a simple path of length at least k edges? YES 2. SHORTEST-PATH: Given a graph G = (V, E), does there exists a simple

### Outline. NP-completeness. When is a problem easy? When is a problem hard? Today. Euler Circuits

Outline NP-completeness Examples of Easy vs. Hard problems Euler circuit vs. Hamiltonian circuit Shortest Path vs. Longest Path 2-pairs sum vs. general Subset Sum Reducing one problem to another Clique

### 8.1 Min Degree Spanning Tree

CS880: Approximations Algorithms Scribe: Siddharth Barman Lecturer: Shuchi Chawla Topic: Min Degree Spanning Tree Date: 02/15/07 In this lecture we give a local search based algorithm for the Min Degree

### THE PROBLEM WORMS (1) WORMS (2) THE PROBLEM OF WORM PROPAGATION/PREVENTION THE MINIMUM VERTEX COVER PROBLEM

1 THE PROBLEM OF WORM PROPAGATION/PREVENTION I.E. THE MINIMUM VERTEX COVER PROBLEM Prof. Tiziana Calamoneri Network Algorithms A.y. 2014/15 2 THE PROBLEM WORMS (1)! A computer worm is a standalone malware

### 11. APPROXIMATION ALGORITHMS

11. APPROXIMATION ALGORITHMS load balancing center selection pricing method: vertex cover LP rounding: vertex cover generalized load balancing knapsack problem Lecture slides by Kevin Wayne Copyright 2005

### Distributed Computing over Communication Networks: Maximal Independent Set

Distributed Computing over Communication Networks: Maximal Independent Set What is a MIS? MIS An independent set (IS) of an undirected graph is a subset U of nodes such that no two nodes in U are adjacent.

### A Working Knowledge of Computational Complexity for an Optimizer

A Working Knowledge of Computational Complexity for an Optimizer ORF 363/COS 323 Instructor: Amir Ali Ahmadi TAs: Y. Chen, G. Hall, J. Ye Fall 2014 1 Why computational complexity? What is computational

### 3. Mathematical Induction

3. MATHEMATICAL INDUCTION 83 3. Mathematical Induction 3.1. First Principle of Mathematical Induction. Let P (n) be a predicate with domain of discourse (over) the natural numbers N = {0, 1,,...}. If (1)

### CSC2420 Fall 2012: Algorithm Design, Analysis and Theory

CSC2420 Fall 2012: Algorithm Design, Analysis and Theory Allan Borodin November 15, 2012; Lecture 10 1 / 27 Randomized online bipartite matching and the adwords problem. We briefly return to online algorithms

### On the Unique Games Conjecture

On the Unique Games Conjecture Antonios Angelakis National Technical University of Athens June 16, 2015 Antonios Angelakis (NTUA) Theory of Computation June 16, 2015 1 / 20 Overview 1 Introduction 2 Preliminary

### NP-Completeness I. Lecture 19. 19.1 Overview. 19.2 Introduction: Reduction and Expressiveness

Lecture 19 NP-Completeness I 19.1 Overview In the past few lectures we have looked at increasingly more expressive problems that we were able to solve using efficient algorithms. In this lecture we introduce

### Exponential time algorithms for graph coloring

Exponential time algorithms for graph coloring Uriel Feige Lecture notes, March 14, 2011 1 Introduction Let [n] denote the set {1,..., k}. A k-labeling of vertices of a graph G(V, E) is a function V [k].

### SIMS 255 Foundations of Software Design. Complexity and NP-completeness

SIMS 255 Foundations of Software Design Complexity and NP-completeness Matt Welsh November 29, 2001 mdw@cs.berkeley.edu 1 Outline Complexity of algorithms Space and time complexity ``Big O'' notation Complexity

### Lecture 19: Introduction to NP-Completeness Steven Skiena. Department of Computer Science State University of New York Stony Brook, NY 11794 4400

Lecture 19: Introduction to NP-Completeness Steven Skiena Department of Computer Science State University of New York Stony Brook, NY 11794 4400 http://www.cs.sunysb.edu/ skiena Reporting to the Boss Suppose

### CSC 373: Algorithm Design and Analysis Lecture 16

CSC 373: Algorithm Design and Analysis Lecture 16 Allan Borodin February 25, 2013 Some materials are from Stephen Cook s IIT talk and Keven Wayne s slides. 1 / 17 Announcements and Outline Announcements

### Scheduling Shop Scheduling. Tim Nieberg

Scheduling Shop Scheduling Tim Nieberg Shop models: General Introduction Remark: Consider non preemptive problems with regular objectives Notation Shop Problems: m machines, n jobs 1,..., n operations

### Single machine parallel batch scheduling with unbounded capacity

Workshop on Combinatorics and Graph Theory 21th, April, 2006 Nankai University Single machine parallel batch scheduling with unbounded capacity Yuan Jinjiang Department of mathematics, Zhengzhou University

### Small Maximal Independent Sets and Faster Exact Graph Coloring

Small Maximal Independent Sets and Faster Exact Graph Coloring David Eppstein Univ. of California, Irvine Dept. of Information and Computer Science The Exact Graph Coloring Problem: Given an undirected

### Topic: Greedy Approximations: Set Cover and Min Makespan Date: 1/30/06

CS880: Approximations Algorithms Scribe: Matt Elder Lecturer: Shuchi Chawla Topic: Greedy Approximations: Set Cover and Min Makespan Date: 1/30/06 3.1 Set Cover The Set Cover problem is: Given a set of

### Factoring & Primality

Factoring & Primality Lecturer: Dimitris Papadopoulos In this lecture we will discuss the problem of integer factorization and primality testing, two problems that have been the focus of a great amount

### Nan Kong, Andrew J. Schaefer. Department of Industrial Engineering, Univeristy of Pittsburgh, PA 15261, USA

A Factor 1 2 Approximation Algorithm for Two-Stage Stochastic Matching Problems Nan Kong, Andrew J. Schaefer Department of Industrial Engineering, Univeristy of Pittsburgh, PA 15261, USA Abstract We introduce

### Lecture 15 An Arithmetic Circuit Lowerbound and Flows in Graphs

CSE599s: Extremal Combinatorics November 21, 2011 Lecture 15 An Arithmetic Circuit Lowerbound and Flows in Graphs Lecturer: Anup Rao 1 An Arithmetic Circuit Lower Bound An arithmetic circuit is just like

### Minimum cost maximum flow, Minimum cost circulation, Cost/Capacity scaling

6.854 Advanced Algorithms Lecture 16: 10/11/2006 Lecturer: David Karger Scribe: Kermin Fleming and Chris Crutchfield, based on notes by Wendy Chu and Tudor Leu Minimum cost maximum flow, Minimum cost circulation,

### Computer Algorithms. NP-Complete Problems. CISC 4080 Yanjun Li

Computer Algorithms NP-Complete Problems NP-completeness The quest for efficient algorithms is about finding clever ways to bypass the process of exhaustive search, using clues from the input in order

### Approximated Distributed Minimum Vertex Cover Algorithms for Bounded Degree Graphs

Approximated Distributed Minimum Vertex Cover Algorithms for Bounded Degree Graphs Yong Zhang 1.2, Francis Y.L. Chin 2, and Hing-Fung Ting 2 1 College of Mathematics and Computer Science, Hebei University,

### Energy Efficient Monitoring in Sensor Networks

Energy Efficient Monitoring in Sensor Networks Amol Deshpande, Samir Khuller, Azarakhsh Malekian, Mohammed Toossi Computer Science Department, University of Maryland, A.V. Williams Building, College Park,

### Fairness in Routing and Load Balancing

Fairness in Routing and Load Balancing Jon Kleinberg Yuval Rabani Éva Tardos Abstract We consider the issue of network routing subject to explicit fairness conditions. The optimization of fairness criteria

### An Approximation Algorithm for Bounded Degree Deletion

An Approximation Algorithm for Bounded Degree Deletion Tomáš Ebenlendr Petr Kolman Jiří Sgall Abstract Bounded Degree Deletion is the following generalization of Vertex Cover. Given an undirected graph

### Complexity Theory. IE 661: Scheduling Theory Fall 2003 Satyaki Ghosh Dastidar

Complexity Theory IE 661: Scheduling Theory Fall 2003 Satyaki Ghosh Dastidar Outline Goals Computation of Problems Concepts and Definitions Complexity Classes and Problems Polynomial Time Reductions Examples

### ARTICLE IN PRESS. European Journal of Operational Research xxx (2004) xxx xxx. Discrete Optimization. Nan Kong, Andrew J.

A factor 1 European Journal of Operational Research xxx (00) xxx xxx Discrete Optimization approximation algorithm for two-stage stochastic matching problems Nan Kong, Andrew J. Schaefer * Department of

### CAD Algorithms. P and NP

CAD Algorithms The Classes P and NP Mohammad Tehranipoor ECE Department 6 September 2010 1 P and NP P and NP are two families of problems. P is a class which contains all of the problems we solve using

Online Adwords Allocation Shoshana Neuburger May 6, 2009 1 Overview Many search engines auction the advertising space alongside search results. When Google interviewed Amin Saberi in 2004, their advertisement

### Private Approximation of Clustering and Vertex Cover

Private Approximation of Clustering and Vertex Cover Amos Beimel, Renen Hallak, and Kobbi Nissim Department of Computer Science, Ben-Gurion University of the Negev Abstract. Private approximation of search

### An Empirical Study of Two MIS Algorithms

An Empirical Study of Two MIS Algorithms Email: Tushar Bisht and Kishore Kothapalli International Institute of Information Technology, Hyderabad Hyderabad, Andhra Pradesh, India 32. tushar.bisht@research.iiit.ac.in,

### 9th Max-Planck Advanced Course on the Foundations of Computer Science (ADFOCS) Primal-Dual Algorithms for Online Optimization: Lecture 1

9th Max-Planck Advanced Course on the Foundations of Computer Science (ADFOCS) Primal-Dual Algorithms for Online Optimization: Lecture 1 Seffi Naor Computer Science Dept. Technion Haifa, Israel Introduction

### Max Flow, Min Cut, and Matchings (Solution)

Max Flow, Min Cut, and Matchings (Solution) 1. The figure below shows a flow network on which an s-t flow is shown. The capacity of each edge appears as a label next to the edge, and the numbers in boxes

### 1 The Brownian bridge construction

The Brownian bridge construction The Brownian bridge construction is a way to build a Brownian motion path by successively adding finer scale detail. This construction leads to a relatively easy proof

### JUST-IN-TIME SCHEDULING WITH PERIODIC TIME SLOTS. Received December May 12, 2003; revised February 5, 2004

Scientiae Mathematicae Japonicae Online, Vol. 10, (2004), 431 437 431 JUST-IN-TIME SCHEDULING WITH PERIODIC TIME SLOTS Ondřej Čepeka and Shao Chin Sung b Received December May 12, 2003; revised February

### CSC2420 Spring 2015: Lecture 3

CSC2420 Spring 2015: Lecture 3 Allan Borodin January 22, 2015 1 / 1 Announcements and todays agenda Assignment 1 due next Thursday. I may add one or two additional questions today or tomorrow. Todays agenda

### Pigeonhole Principle Solutions

Pigeonhole Principle Solutions 1. Show that if we take n + 1 numbers from the set {1, 2,..., 2n}, then some pair of numbers will have no factors in common. Solution: Note that consecutive numbers (such

### GENERATING LOW-DEGREE 2-SPANNERS

SIAM J. COMPUT. c 1998 Society for Industrial and Applied Mathematics Vol. 27, No. 5, pp. 1438 1456, October 1998 013 GENERATING LOW-DEGREE 2-SPANNERS GUY KORTSARZ AND DAVID PELEG Abstract. A k-spanner

### Lecture 5 - CPA security, Pseudorandom functions

Lecture 5 - CPA security, Pseudorandom functions Boaz Barak October 2, 2007 Reading Pages 82 93 and 221 225 of KL (sections 3.5, 3.6.1, 3.6.2 and 6.5). See also Goldreich (Vol I) for proof of PRF construction.

### Introduction to Algorithms. Part 3: P, NP Hard Problems

Introduction to Algorithms Part 3: P, NP Hard Problems 1) Polynomial Time: P and NP 2) NP-Completeness 3) Dealing with Hard Problems 4) Lower Bounds 5) Books c Wayne Goddard, Clemson University, 2004 Chapter

### OHJ-2306 Introduction to Theoretical Computer Science, Fall 2012 8.11.2012

276 The P vs. NP problem is a major unsolved problem in computer science It is one of the seven Millennium Prize Problems selected by the Clay Mathematics Institute to carry a \$ 1,000,000 prize for the

### MapReduce and Distributed Data Analysis. Sergei Vassilvitskii Google Research

MapReduce and Distributed Data Analysis Google Research 1 Dealing With Massive Data 2 2 Dealing With Massive Data Polynomial Memory Sublinear RAM Sketches External Memory Property Testing 3 3 Dealing With

### SHARP BOUNDS FOR THE SUM OF THE SQUARES OF THE DEGREES OF A GRAPH

31 Kragujevac J. Math. 25 (2003) 31 49. SHARP BOUNDS FOR THE SUM OF THE SQUARES OF THE DEGREES OF A GRAPH Kinkar Ch. Das Department of Mathematics, Indian Institute of Technology, Kharagpur 721302, W.B.,

### The Union-Find Problem Kruskal s algorithm for finding an MST presented us with a problem in data-structure design. As we looked at each edge,

The Union-Find Problem Kruskal s algorithm for finding an MST presented us with a problem in data-structure design. As we looked at each edge, cheapest first, we had to determine whether its two endpoints

### The Conference Call Search Problem in Wireless Networks

The Conference Call Search Problem in Wireless Networks Leah Epstein 1, and Asaf Levin 2 1 Department of Mathematics, University of Haifa, 31905 Haifa, Israel. lea@math.haifa.ac.il 2 Department of Statistics,

### Easy Casino Profits. Congratulations!!

Easy Casino Profits The Easy Way To Beat The Online Casinos Everytime! www.easycasinoprofits.com Disclaimer The authors of this ebook do not promote illegal, underage gambling or gambling to those living

### Lecture 7: NP-Complete Problems

IAS/PCMI Summer Session 2000 Clay Mathematics Undergraduate Program Basic Course on Computational Complexity Lecture 7: NP-Complete Problems David Mix Barrington and Alexis Maciel July 25, 2000 1. Circuit

### ON THE COMPLEXITY OF THE GAME OF SET. {kamalika,pbg,dratajcz,hoeteck}@cs.berkeley.edu

ON THE COMPLEXITY OF THE GAME OF SET KAMALIKA CHAUDHURI, BRIGHTEN GODFREY, DAVID RATAJCZAK, AND HOETECK WEE {kamalika,pbg,dratajcz,hoeteck}@cs.berkeley.edu ABSTRACT. Set R is a card game played with a

### The Goldberg Rao Algorithm for the Maximum Flow Problem

The Goldberg Rao Algorithm for the Maximum Flow Problem COS 528 class notes October 18, 2006 Scribe: Dávid Papp Main idea: use of the blocking flow paradigm to achieve essentially O(min{m 2/3, n 1/2 }

### ONLINE DEGREE-BOUNDED STEINER NETWORK DESIGN. Sina Dehghani Saeed Seddighin Ali Shafahi Fall 2015

ONLINE DEGREE-BOUNDED STEINER NETWORK DESIGN Sina Dehghani Saeed Seddighin Ali Shafahi Fall 2015 ONLINE STEINER FOREST PROBLEM An initially given graph G. s 1 s 2 A sequence of demands (s i, t i ) arriving

### Minimal Cost Reconfiguration of Data Placement in a Storage Area Network

Minimal Cost Reconfiguration of Data Placement in a Storage Area Network Hadas Shachnai Gal Tamir Tami Tamir Abstract Video-on-Demand (VoD) services require frequent updates in file configuration on the

### Bicolored Shortest Paths in Graphs with Applications to Network Overlay Design

Bicolored Shortest Paths in Graphs with Applications to Network Overlay Design Hongsik Choi and Hyeong-Ah Choi Department of Electrical Engineering and Computer Science George Washington University Washington,

### each college c i C has a capacity q i - the maximum number of students it will admit

n colleges in a set C, m applicants in a set A, where m is much larger than n. each college c i C has a capacity q i - the maximum number of students it will admit each college c i has a strict order i

### CS 598CSC: Combinatorial Optimization Lecture date: 2/4/2010

CS 598CSC: Combinatorial Optimization Lecture date: /4/010 Instructor: Chandra Chekuri Scribe: David Morrison Gomory-Hu Trees (The work in this section closely follows [3]) Let G = (V, E) be an undirected

### 1 Approximating Set Cover

CS 05: Algorithms (Grad) Feb 2-24, 2005 Approximating Set Cover. Definition An Instance (X, F ) of the set-covering problem consists of a finite set X and a family F of subset of X, such that every elemennt

### Euler Paths and Euler Circuits

Euler Paths and Euler Circuits An Euler path is a path that uses every edge of a graph exactly once. An Euler circuit is a circuit that uses every edge of a graph exactly once. An Euler path starts and

### Computational Game Theory and Clustering

Computational Game Theory and Clustering Martin Hoefer mhoefer@mpi-inf.mpg.de 1 Computational Game Theory? 2 Complexity and Computation of Equilibrium 3 Bounding Inefficiencies 4 Conclusion Computational

### Why? A central concept in Computer Science. Algorithms are ubiquitous.

Analysis of Algorithms: A Brief Introduction Why? A central concept in Computer Science. Algorithms are ubiquitous. Using the Internet (sending email, transferring files, use of search engines, online

### Midterm Practice Problems

6.042/8.062J Mathematics for Computer Science October 2, 200 Tom Leighton, Marten van Dijk, and Brooke Cowan Midterm Practice Problems Problem. [0 points] In problem set you showed that the nand operator

### Analysis of Approximation Algorithms for k-set Cover using Factor-Revealing Linear Programs

Analysis of Approximation Algorithms for k-set Cover using Factor-Revealing Linear Programs Stavros Athanassopoulos, Ioannis Caragiannis, and Christos Kaklamanis Research Academic Computer Technology Institute

### What s next? Reductions other than kernelization

What s next? Reductions other than kernelization Dániel Marx Humboldt-Universität zu Berlin (with help from Fedor Fomin, Daniel Lokshtanov and Saket Saurabh) WorKer 2010: Workshop on Kernelization Nov

### CoNP and Function Problems

CoNP and Function Problems conp By definition, conp is the class of problems whose complement is in NP. NP is the class of problems that have succinct certificates. conp is therefore the class of problems

### Permutation Betting Markets: Singleton Betting with Extra Information

Permutation Betting Markets: Singleton Betting with Extra Information Mohammad Ghodsi Sharif University of Technology ghodsi@sharif.edu Hamid Mahini Sharif University of Technology mahini@ce.sharif.edu

### Approximating Minimum Bounded Degree Spanning Trees to within One of Optimal

Approximating Minimum Bounded Degree Spanning Trees to within One of Optimal ABSTACT Mohit Singh Tepper School of Business Carnegie Mellon University Pittsburgh, PA USA mohits@andrew.cmu.edu In the MINIMUM

### Section 1.4. Difference Equations

Difference Equations to Differential Equations Section 1.4 Difference Equations At this point almost all of our sequences have had explicit formulas for their terms. That is, we have looked mainly at sequences

### Lecture 6 Online and streaming algorithms for clustering

CSE 291: Unsupervised learning Spring 2008 Lecture 6 Online and streaming algorithms for clustering 6.1 On-line k-clustering To the extent that clustering takes place in the brain, it happens in an on-line

### Persistent Data Structures

6.854 Advanced Algorithms Lecture 2: September 9, 2005 Scribes: Sommer Gentry, Eddie Kohler Lecturer: David Karger Persistent Data Structures 2.1 Introduction and motivation So far, we ve seen only ephemeral

### Decimal Notations for Fractions Number and Operations Fractions /4.NF

Decimal Notations for Fractions Number and Operations Fractions /4.NF Domain: Cluster: Standard: 4.NF Number and Operations Fractions Understand decimal notation for fractions, and compare decimal fractions.

### The Online Set Cover Problem

The Online Set Cover Problem Noga Alon Baruch Awerbuch Yossi Azar Niv Buchbinder Joseph Seffi Naor ABSTRACT Let X = {, 2,..., n} be a ground set of n elements, and let S be a family of subsets of X, S

### Security-Aware Beacon Based Network Monitoring

Security-Aware Beacon Based Network Monitoring Masahiro Sasaki, Liang Zhao, Hiroshi Nagamochi Graduate School of Informatics, Kyoto University, Kyoto, Japan Email: {sasaki, liang, nag}@amp.i.kyoto-u.ac.jp

### THE SCHEDULING OF MAINTENANCE SERVICE

THE SCHEDULING OF MAINTENANCE SERVICE Shoshana Anily Celia A. Glass Refael Hassin Abstract We study a discrete problem of scheduling activities of several types under the constraint that at most a single

### Discrete Mathematics and Probability Theory Fall 2009 Satish Rao, David Tse Note 10

CS 70 Discrete Mathematics and Probability Theory Fall 2009 Satish Rao, David Tse Note 10 Introduction to Discrete Probability Probability theory has its origins in gambling analyzing card games, dice,

### NP-complete? NP-hard? Some Foundations of Complexity. Prof. Sven Hartmann Clausthal University of Technology Department of Informatics

NP-complete? NP-hard? Some Foundations of Complexity Prof. Sven Hartmann Clausthal University of Technology Department of Informatics Tractability of Problems Some problems are undecidable: no computer

### Generating models of a matched formula with a polynomial delay

Generating models of a matched formula with a polynomial delay Petr Savicky Institute of Computer Science, Academy of Sciences of Czech Republic, Pod Vodárenskou Věží 2, 182 07 Praha 8, Czech Republic

### Scheduling Home Health Care with Separating Benders Cuts in Decision Diagrams

Scheduling Home Health Care with Separating Benders Cuts in Decision Diagrams André Ciré University of Toronto John Hooker Carnegie Mellon University INFORMS 2014 Home Health Care Home health care delivery

### Mathematical Induction

Mathematical Induction (Handout March 8, 01) The Principle of Mathematical Induction provides a means to prove infinitely many statements all at once The principle is logical rather than strictly mathematical,

### Algorithm Design for Performance Aware VM Consolidation

Algorithm Design for Performance Aware VM Consolidation Alan Roytman University of California, Los Angeles Sriram Govindan Microsoft Corporation Jie Liu Microsoft Research Aman Kansal Microsoft Research

### Discuss the size of the instance for the minimum spanning tree problem.

3.1 Algorithm complexity The algorithms A, B are given. The former has complexity O(n 2 ), the latter O(2 n ), where n is the size of the instance. Let n A 0 be the size of the largest instance that can

### Lecture 4 Online and streaming algorithms for clustering

CSE 291: Geometric algorithms Spring 2013 Lecture 4 Online and streaming algorithms for clustering 4.1 On-line k-clustering To the extent that clustering takes place in the brain, it happens in an on-line

### An Innocent Investigation

An Innocent Investigation D. Joyce, Clark University January 2006 The beginning. Have you ever wondered why every number is either even or odd? I don t mean to ask if you ever wondered whether every number

### Lecture 2: August 29. Linear Programming (part I)

10-725: Convex Optimization Fall 2013 Lecture 2: August 29 Lecturer: Barnabás Póczos Scribes: Samrachana Adhikari, Mattia Ciollaro, Fabrizio Lecci Note: LaTeX template courtesy of UC Berkeley EECS dept.

### Math 181 Handout 16. Rich Schwartz. March 9, 2010

Math 8 Handout 6 Rich Schwartz March 9, 200 The purpose of this handout is to describe continued fractions and their connection to hyperbolic geometry. The Gauss Map Given any x (0, ) we define γ(x) =

### Short Cycles make W-hard problems hard: FPT algorithms for W-hard Problems in Graphs with no short Cycles

Short Cycles make W-hard problems hard: FPT algorithms for W-hard Problems in Graphs with no short Cycles Venkatesh Raman and Saket Saurabh The Institute of Mathematical Sciences, Chennai 600 113. {vraman

### The last three chapters introduced three major proof techniques: direct,

CHAPTER 7 Proving Non-Conditional Statements The last three chapters introduced three major proof techniques: direct, contrapositive and contradiction. These three techniques are used to prove statements

### Lecture 3: One-Way Encryption, RSA Example

ICS 180: Introduction to Cryptography April 13, 2004 Lecturer: Stanislaw Jarecki Lecture 3: One-Way Encryption, RSA Example 1 LECTURE SUMMARY We look at a different security property one might require

### Efficiency of algorithms. Algorithms. Efficiency of algorithms. Binary search and linear search. Best, worst and average case.

Algorithms Efficiency of algorithms Computational resources: time and space Best, worst and average case performance How to compare algorithms: machine-independent measure of efficiency Growth rate Complexity

### Linear Programming I

Linear Programming I November 30, 2003 1 Introduction In the VCR/guns/nuclear bombs/napkins/star wars/professors/butter/mice problem, the benevolent dictator, Bigus Piguinus, of south Antarctica penguins

### Introduction to Logic in Computer Science: Autumn 2006

Introduction to Logic in Computer Science: Autumn 2006 Ulle Endriss Institute for Logic, Language and Computation University of Amsterdam Ulle Endriss 1 Plan for Today Now that we have a basic understanding

### arxiv:1203.1525v1 [math.co] 7 Mar 2012

Constructing subset partition graphs with strong adjacency and end-point count properties Nicolai Hähnle haehnle@math.tu-berlin.de arxiv:1203.1525v1 [math.co] 7 Mar 2012 March 8, 2012 Abstract Kim defined

### INCIDENCE-BETWEENNESS GEOMETRY

INCIDENCE-BETWEENNESS GEOMETRY MATH 410, CSUSM. SPRING 2008. PROFESSOR AITKEN This document covers the geometry that can be developed with just the axioms related to incidence and betweenness. The full