# 5.1 Bipartite Matching

Save this PDF as:

Size: px
Start display at page:

## Transcription

1 CS787: Advanced Algorithms Lecture 5: Applications of Network Flow In the last lecture, we looked at the problem of finding the maximum flow in a graph, and how it can be efficiently solved using the Ford-Fulkerson algorithm. We also proved the Min Cut-Max Flow Theorem which states that the size of the maximum flow is exactly equal to the size of the minimum cut in the graph. In this lecture, we will see how various different problems can be solved by reducing the problem to an instance of the network flow problem. 5.1 Bipartite Matching A Bipartite Graph G = (V, E) is a graph in which the vertex set V can be divided into two disjoint subsets X and Y such that every edge e E has one end point in X and the other end point in Y. A matching M is a subset of edges such that each node in V appears in at most one edge in M. X Y Figure 5.1.1: A bipartite graph We are interested in matchings of large size. defined as follows. Formally, maximal and maximum matchings are Definition (Maximal Matching) A maximal matching is a matching to which no more edges can be added without increasing the degree of one of the nodes to two; it is a local maximum. Definition (Maximum Matching) A maximum matching is a matching with the largest possible number of edges; it is globally optimal. Our goal is to find the maximum matching in a graph. Note that a maximal matching can be found very easily just keep adding edges to the matching until no more can be added. Moreover, it can be shown that for any maximal matching M, we have that M 1 2 M where M is the maximum matching. Therefore we can easily construct a 2-approximation to the maximum matching. The problem of finding the maximum matching can be reduced to maximum flow in the following manner. Let G(V, E) be the bipartite graph where V is divided into X and Y. We will construct a 1

2 directed graph G (V, E ), in which V which contains all the nodes of V along with a source node s and a sink node t. For every edge in E, we add a directed edge in E from X to Y. Finally we add a directed edge from s to all nodes in X and from all nodes of Y to t. Each edge is given unit capacity. X Y s t Let f be an integral flow of G of value k. Then we can make the following observations: 1. There is no node in X which has more than one outgoing edge where there is a flow. 2. There is no node in Y which has more than one incoming edge where there is a flow. 3. The number of edges between X and Y which carry flow is k. By these observations, it is straightforward to conclude that the set of edges carrying flow in f forms a matching of size k for the graph G. Likewise, given a matching of size k in G, we can construct a flow of size k in G. Therefore, solving for maximum flow in G gives us a maximum matching in G. Note that we used the fact that when edge capacities are integral, Ford-Fulkerson produces an integral flow. Let us now analyze the running time of this algorithm. Constructing the graph G takes O(n + m) time where n = V and m = E. The running time for the Ford-Fulkerson algorithm is O(m F ) where m is the number of edges in E and F = e δ(s) (c e). In case of bipartite matching problem, F V since there can be only V possible edges coming out from source node. So the total running time is O(m n) = O((m + n)n). An interesting thing to note is that at any iteration of the algorithm, any s-t path in the residual graph will have alternating matched and unmatched edges. Such paths are called alternating paths. This property can be used to find maximum matchings even in general graphs Perfect Matching A perfect matching is a matching in which each node has exactly one edge incident on it. One possible way of finding out if a given bipartite graph has a perfect matching is to use the above algorithm to find the maximum matching and checking if the size of the matching equals the number of nodes in each partition. There is another way of determining this, using Hall s Theorem. 2

3 Theorem A Bipartite graph G(V,E) has a Perfect Matching iff for every subset S XorS Y, the size of the neighbors of S is at least as large as S, i.e Γ(S) S This theorem can be proven using induction. We will not discuss the proof in detail here. 5.2 Scheduling Problems We will now see how the Max Flow algorithm can be used to solve certain kinds of scheduling problems. The first example we will take will be of scheduling jobs on a machine. Let J = {J 1, J 2,..., J n } be the set of jobs, and T = {T 1, T 2,.., T k } be slots available on a machine where these jobs can be performed. Each job J has a set of valid slots S j T when it can be scheduled. The constraint is that no two jobs can be scheduled at the same time. The problem is to find the largest set of jobs which can be scheduled. This problem can be solved by reducing it to a bipartite matching problem. For every job, create a node in X, and for every timeslot create a node in Y. For every timeslot T in S j, create an edge between J and T. The maximum matching of this bipartite graph is the maximum set of jobs that can be scheduled. We can also solve scheduling problems with more constraints by having intermediate nodes in the graph. Let us consider a more complex problem: A hospital has n doctors, each with a set of vacation days when he or she is available. There are k vacation periods, each spanning multiple contiguous days. Let D j be the set of days included in the j th vacation period. We need to maximize the assignment of doctors to days (one doctor per day) under the following constraints: 1. Each doctor has a capacity c i which is the maximum total number of days he or she can be scheduled. 2. For every vacation period, any given doctor is scheduled at most once. We will solve this problem by network flow. As was done earlier, for every doctor i we create a node u i and for every vacation day j we create a node v j. We add a directed edge from start node s to u i and from v j to sink t. Other edges and capacities are added as follows to satisfy the above constraints: The doctor capacities are modeled as capacities of the edge from the source to the vertex corresponding to the doctor. The capacities of edges from nodes v j to the sink t are all set to 1, to represent choosing one doctor for each vacation day. To prevent the doctor to be scheduled more than once in a vacation period, we introduce intermediate nodes. For any doctor i and a vacation period j, we create an intermediate node w ij. We create an edge with unit capacity from u i to w ij. For every day in the vacation period that the doctor is available, we create an edge from w ij to the node corresponding to that day with unit capacity. 3

4 doctors intermediate nodes 1 1 vacation periods 1 s ci t Figure 5.2.2: Scheduling problem with constraints Let us see if the an integral flow through the graph produces a valid schedule. Since the edge connecting s to the node corresponding to the doctor has the capacity equal to the total availability of the doctor, the flow through the doctor node cannot exceed it. So the first constraint is satisfied. From any doctor to any vacation period the flow is atmost one, since the intermediate node has only one incoming edge of unit capacity. This makes sure that the second criteria is met. So the flow produced satisfies all the constraints. If k is the size of an integral flow through the graph, then the total number of vacation days which have been assigned is also k, since the edges which connect the nodes corresponding to the vacation days to the sink node have unit capacity each. So the size of the scheduling is equal to the size of the flow. From this we can conclude that the largest valid scheduling is produced by the maximum flow. 5.3 Partitioning Problems Now we will see how certain kinds of paritioning problems can be solved using the network flow algorithm. The general idea is to reduce it to a min-cut rather than a max-flow instance. The first example we will see is the image segmentation problem Image Segmentation Consider the following simplification of an image segmentation problem. Assume every pixel in an image belongs to either the foreground of an image or the background. Using image analysis techniques based on the values of the pixels its possible to assign probabilites that an individual pixel belongs to the foreground or the background. These probabilites can then be translated to costs for assigning a pixel to either foreground or background. In addition, since adjacent pixels are expected to be mapped in the same way, there are costs for assigning a pixel to the foreground and its neighbor to the background. The goal then is to find an assignment of all pixels such that the costs are minimized. 4

5 Formally, let f i be the cost of assigning pixel i to the foreground, b i be the cost of assigning pixel i to the background, and s ij be the cost of separating neighboring pixels i and j into different regions. Goal: Find a partition of pixels into S, the set of foreground pixels, and S, the set of background pixels, such that the global cost of this assignment is minimized. Let (S, S) be the partition of pixels into foreground and background respectively. Then the cost of this partition is defined as: cost(s) = i S f i + i/ S b i + i S,j / S i and j are neighbors s ij (5.3.1) We need to find an S which minimizes cost. This problem can be reduced to a min-cut max-flow problem. The natural reduction is to a min-cut problem. Let each pixel be a node, with neighboring pixels connected to each other by undirected edges with capacity s ij. Create additional source and sink nodes, B and F, respectively which have edges to every pixel. The edges from B to each pixel have capacity f i. The edges from each pixel to F have capacity b i. background v_i foreground b_i F f_i B s_ij Figure 5.3.3: Image segmentation flow graph Any cut in the graph will then naturally separate the pixels into two groups S (the foreground) representing the group of pixels not reachable from B (see the figure above). Now it s easy to see that for any B-F cut, the cost of the cut is exactly equal to the cost associated with the corresponding partition. The min-cut max-flow algorithm will find such a partition of minimum cost Image Segmentation cont. Consider a modification of the original problem. Replace f i and b i with values representing the benefit/value for assigning the pixel i to either the foreground or background. 5

6 background foreground v_i f_i F b_i B s_ij Figure 5.3.4: Flow graph for maximizing benefit Goal: Find a partition of all pixels into S, the set of foreground pixels, and S, the set of background pixels, such that the global value is maximized. Here value is defined as val(s) = i S f i + i/ S b i i S,j / S i and j are neighbors s ij (5.3.2) Since the min-cut approach is a minimization problem, we need to convert it into a minimization problem in order to reduce it to min-cost. Let (S, S) be the partition of pixels into foreground and background respectively. We can relate cost (defined as per 5.4.1) and val by assuming cost to mean lost benefit : cost(s) = i (b i + f i ) val(s) (5.3.3) Since i (b i + f i ) is a constant for any given instance, the problem of maximising val reduces to minimizing the cost. We can reformulate cost as cost(s) = i S b i + i/ S f i + i S,j / S i and j are neighbors s ij (5.3.4) Comparing this to the previous problem, we see that this is the same as interchanging b i and f i in the graph we used to solve the first problem; i.e. the weight of the nodes from B to v i is set as f i and weight of v i to F is set as b i. Solving this using min-cut will give us the partition which maximizes the benefit. 6

7 5.4 Finding maximum flows via linear programming We now discuss a different way of finding maximum flows in polynomial time Linear programming Linear Programming is a kind of optimization problem where one optimizes a linear multivariate function over linear constraints. Definition A linear program is a collection of linear constraints on some real-valued variables with a linear objective function. Example: Maximize 5x + y subject to the constraints 2y x 3 x y 2 x, y 0 Figure 5.4.5: The feasible region in some linear programming problem. To get an idea of what this looks like plot the set of pairs (x, y) that satisfy the constraints. See Figure for a plot of the feasible region. The feasible region, the region of all points that satisfy the constraints, is the shaded region. Any point inside the polytope satisfies the constraints. Our goal is to find a pair that maximizes 5x + y. The solution is the point (x, y) = (7, 5). Note that the optimum is achieved at a corner point of the feasible region. Definition (Convex Polytope) A polytope is an n-dimensional body with flat faces. A polytope is called convex if for any two points in the polytope, the line segment joining the two points lies entirely within the polytope. The feasible region of a linear program is a convex polytope. Definition (Extreme point or basic solution) An extreme point or a basic solution is a corner point of the feasible region. An equivalent definition of an extreme point is any point that cannot be expressed as the convex combination of two or more points in the polytope. 7

8 The optimal solution to a linear program always occurs at an extreme point. The following are standard ways of writing a linear program: or, maximize c T x subject to Ax b x 0 minimize c T x subject to Ax b x 0 Here A is an m by n real matrix, A R m n, b is an m 1 real vector, c is an n 1 real vector, and x is an n 1 vector of variables. It is easy to see how to convert any given linear program into standard form. For example, can be written as Solving a Linear Program maximize 3x + 5y z subject to x 2 z 5y 4 2y + z = 1 y, z 0 maximize 3(x 1 x 2 ) + 5y z subject to Given a linear program, three things can happen: 1. The feasible region is empty x 1 x 2 2 5y z 4 2y + z 1 2y z 1 x 1, x 2, y, z 0 2. The feasible region and the optimal value are unbounded 3. The feasible region is a bounded convex polytope and an optimal value exists. 8

9 Generally the goal is to determine whether (1) happens, and if (3) happens, what the optimal value is. These problems are reducible to each other. Linear programs can be solved in time polynomial in n and m, where n is the number of variables and m is the number of constraints. There are three ways of solving a linear program: 1. The simplex method. This approach starts on an extreme point of the polytope and follows the edges of the polytope from one extreme point to another doing hill-climbing of some sort, until it reaches a local optimum. Note that a local optimum is always a global optimum due to convexity. The worst-case complexity of this algorithm is exponential (the polytope may contain an exponential number of extreme points). However its average case complexity, defined appropriately, is polynomial-time. In practice, the simplex method is the most frequently used approach to solve linear programs. 2. The ellipsoid method. This was the first polynomial time algorithm developed for linear programming. The idea is to start with some ellipsoid containing the feasible region. The center of the ellipsoid is then checked for feasibility. If it is found to be feasible, the algorithm terminates. Otherwise, there is some constraint that is violated. This constraint divides the ellipsoid into two equal halves, one of which entirely contains the feasible region. The algorithm then encloses this half into a smaller ellipsoid and continues. The main insight behind the algorithm is that the size of the ellipsoid is cut by a constant fraction at every iteration. Unfortunately this algorithm is quite slow in practice. 3. Interior point methods. These methods start with a feasible point and move towards the optimum within the interior of the polytope, as opposed to the exterior in the simplex method. This approach leads to polynomial time algorithms that are also reasonably efficient in practice Max flow via linear programming Linear Programming is interesting to us because 1. it is solvable in polynomial time, 2. a closely related problem (Integer Programming) is NP-hard, and 3. LP-duality, which we will study a little later, gives us insights connecting different optimization problems. We will see later that we can take any NP-complete problem, reduce it to an instance of Integer Programming, and then try to solve the new problem using the same techniques that solve Linear Programming problems. For now, we show that max flow can be reduced to linear programming. Consider an instance G = (V, E) of the max flow problem with edge capacities c e for e E. Let f e be the variable representing the amount of flow on edge e. Then the following LP encodes the max flow problem. 9

10 maximize v:(s,v) E u:(u,v) E f s,v f (u,v) = subject to u:(v,u) E f (v,u) v V, v s, t (Conservation) f e c e e E (Capacity constraints) f e 0 e E Note that the Ford-Fulkerson algorithm is greatly preferable to this approach in terms of running time as well as because the linear program doesn t necessarily return an integral solution, which may sometimes be preferable. Nevertheless this reduction lets us determine quickly what variants of max-flow are likely to be solvable in polynomial time. References [1] Eva Tardos, Jon Kleinberg Algorithm Design. Pearson Education,

### 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

### Introduction to Algorithms Review information for Prelim 1 CS 4820, Spring 2010 Distributed Wednesday, February 24

Introduction to Algorithms Review information for Prelim 1 CS 4820, Spring 2010 Distributed Wednesday, February 24 The final exam will cover seven topics. 1. greedy algorithms 2. divide-and-conquer algorithms

### Linear Programming. Widget Factory Example. Linear Programming: Standard Form. Widget Factory Example: Continued.

Linear Programming Widget Factory Example Learning Goals. Introduce Linear Programming Problems. Widget Example, Graphical Solution. Basic Theory:, Vertices, Existence of Solutions. Equivalent formulations.

### ! 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

### Lecture 3: Linear Programming Relaxations and Rounding

Lecture 3: Linear Programming Relaxations and Rounding 1 Approximation Algorithms and Linear Relaxations For the time being, suppose we have a minimization problem. Many times, the problem at hand can

### Lecture 7: Approximation via Randomized Rounding

Lecture 7: Approximation via Randomized Rounding Often LPs return a fractional solution where the solution x, which is supposed to be in {0, } n, is in [0, ] n instead. There is a generic way of obtaining

### Proximal mapping via network optimization

L. Vandenberghe EE236C (Spring 23-4) Proximal mapping via network optimization minimum cut and maximum flow problems parametric minimum cut problem application to proximal mapping Introduction this lecture:

### 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

### 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

### Minimize subject to. x S R

Chapter 12 Lagrangian Relaxation This chapter is mostly inspired by Chapter 16 of [1]. In the previous chapters, we have succeeded to find efficient algorithms to solve several important problems such

### 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 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

### Lecture 7 - Linear Programming

COMPSCI 530: Design and Analysis of Algorithms DATE: 09/17/2013 Lecturer: Debmalya Panigrahi Lecture 7 - Linear Programming Scribe: Hieu Bui 1 Overview In this lecture, we cover basics of linear programming,

### Definition of a Linear Program

Definition of a Linear Program Definition: A function f(x 1, x,..., x n ) of x 1, x,..., x n is a linear function if and only if for some set of constants c 1, c,..., c n, f(x 1, x,..., x n ) = c 1 x 1

### 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

### Definition 11.1. Given a graph G on n vertices, we define the following quantities:

Lecture 11 The Lovász ϑ Function 11.1 Perfect graphs We begin with some background on perfect graphs. graphs. First, we define some quantities on Definition 11.1. Given a graph G on n vertices, we define

### max cx s.t. Ax c where the matrix A, cost vector c and right hand side b are given and x is a vector of variables. For this example we have x

Linear Programming Linear programming refers to problems stated as maximization or minimization of a linear function subject to constraints that are linear equalities and inequalities. Although the study

### ! 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

### Scheduling. Open shop, job shop, flow shop scheduling. Related problems. Open shop, job shop, flow shop scheduling

Scheduling Basic scheduling problems: open shop, job shop, flow job The disjunctive graph representation Algorithms for solving the job shop problem Computational complexity of the job shop problem Open

### 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

### 3. Linear Programming and Polyhedral Combinatorics

Massachusetts Institute of Technology Handout 6 18.433: Combinatorial Optimization February 20th, 2009 Michel X. Goemans 3. Linear Programming and Polyhedral Combinatorics Summary of what was seen in the

### Mathematics Notes for Class 12 chapter 12. Linear Programming

1 P a g e Mathematics Notes for Class 12 chapter 12. Linear Programming Linear Programming It is an important optimization (maximization or minimization) technique used in decision making is business and

### GRAPH THEORY and APPLICATIONS. Trees

GRAPH THEORY and APPLICATIONS Trees Properties Tree: a connected graph with no cycle (acyclic) Forest: a graph with no cycle Paths are trees. Star: A tree consisting of one vertex adjacent to all the others.

### The Simplex Method. yyye

Yinyu Ye, MS&E, Stanford MS&E310 Lecture Note #05 1 The Simplex Method Yinyu Ye Department of Management Science and Engineering Stanford University Stanford, CA 94305, U.S.A. http://www.stanford.edu/

CS787: Advanced Algorithms Topic: Online Learning Presenters: David He, Chris Hopman 17.3.1 Follow the Perturbed Leader 17.3.1.1 Prediction Problem Recall the prediction problem that we discussed in class.

### Transportation Polytopes: a Twenty year Update

Transportation Polytopes: a Twenty year Update Jesús Antonio De Loera University of California, Davis Based on various papers joint with R. Hemmecke, E.Kim, F. Liu, U. Rothblum, F. Santos, S. Onn, R. Yoshida,

### 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].

### princeton univ. F 13 cos 521: Advanced Algorithm Design Lecture 6: Provable Approximation via Linear Programming Lecturer: Sanjeev Arora

princeton univ. F 13 cos 521: Advanced Algorithm Design Lecture 6: Provable Approximation via Linear Programming Lecturer: Sanjeev Arora Scribe: One of the running themes in this course is the notion of

### Good luck, veel succes!

Final exam Advanced Linear Programming, May 7, 13.00-16.00 Switch off your mobile phone, PDA and any other mobile device and put it far away. No books or other reading materials are allowed. This exam

### Lecture 3. Linear Programming. 3B1B Optimization Michaelmas 2015 A. Zisserman. Extreme solutions. Simplex method. Interior point method

Lecture 3 3B1B Optimization Michaelmas 2015 A. Zisserman Linear Programming Extreme solutions Simplex method Interior point method Integer programming and relaxation The Optimization Tree Linear Programming

### 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

### 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

### 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

### Network Flow I. Lecture 16. 16.1 Overview. 16.2 The Network Flow Problem

Lecture 6 Network Flow I 6. Overview In these next two lectures we are going to talk about an important algorithmic problem called the Network Flow Problem. Network flow is important because it can be

### 2.3 Scheduling jobs on identical parallel machines

2.3 Scheduling jobs on identical parallel machines There are jobs to be processed, and there are identical machines (running in parallel) to which each job may be assigned Each job = 1,,, must be processed

### On the Multiple Unicast Network Coding Conjecture

On the Multiple Unicast Networ Coding Conjecture Michael Langberg Computer Science Division Open University of Israel Raanana 43107, Israel miel@openu.ac.il Muriel Médard Research Laboratory of Electronics

### 15-750 Graduate Algorithms Spring 2010

15-750 Graduate Algorithms Spring 2010 1 Cheap Cut (25 pts.) Suppose we are given a directed network G = (V, E) with a root node r and a set of terminal nodes T V. We would like to remove the fewest number

### Why graph clustering is useful?

Graph Clustering Why graph clustering is useful? Distance matrices are graphs as useful as any other clustering Identification of communities in social networks Webpage clustering for better data management

### CSL851: Algorithmic Graph Theory Semester I Lecture 1: July 24

CSL851: Algorithmic Graph Theory Semester I 2013-2014 Lecture 1: July 24 Lecturer: Naveen Garg Scribes: Suyash Roongta Note: LaTeX template courtesy of UC Berkeley EECS dept. Disclaimer: These notes have

### 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

### 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

### 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

### Min-cost flow problems and network simplex algorithm

Min-cost flow problems and network simplex algorithm The particular structure of some LP problems can be sometimes used for the design of solution techniques more efficient than the simplex algorithm.

### 1 Polyhedra and Linear Programming

CS 598CSC: Combinatorial Optimization Lecture date: January 21, 2009 Instructor: Chandra Chekuri Scribe: Sungjin Im 1 Polyhedra and Linear Programming In this lecture, we will cover some basic material

### 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

### 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

### CSE 101: Design and Analysis of Algorithms Homework 4 Winter 2016 Due: February 25, 2016

CSE 101: Design and Analysis of Algorithms Homework 4 Winter 2016 Due: February 25, 2016 Exercises (strongly recommended, do not turn in) 1. (DPV textbook, Problem 7.11.) Find the optimal solution to the

### Inverse Optimization by James Orlin

Inverse Optimization by James Orlin based on research that is joint with Ravi Ahuja Jeopardy 000 -- the Math Programming Edition The category is linear objective functions The answer: When you maximize

### 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

### 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

### CIS 700: algorithms for Big Data

CIS 700: algorithms for Big Data Lecture 6: Graph Sketching Slides at http://grigory.us/big-data-class.html Grigory Yaroslavtsev http://grigory.us Sketching Graphs? We know how to sketch vectors: v Mv

### CSL851: Algorithmic Graph Theory Semester I Lecture 4: August 5

CSL851: Algorithmic Graph Theory Semester I 2013-14 Lecture 4: August 5 Lecturer: Naveen Garg Scribes: Utkarsh Ohm Note: LaTeX template courtesy of UC Berkeley EECS dept. Disclaimer: These notes have not

### Problem Set 7 Solutions

8 8 Introduction to Algorithms May 7, 2004 Massachusetts Institute of Technology 6.046J/18.410J Professors Erik Demaine and Shafi Goldwasser Handout 25 Problem Set 7 Solutions This problem set is due in

### Geometry of Linear Programming

Chapter 2 Geometry of Linear Programming The intent of this chapter is to provide a geometric interpretation of linear programming problems. To conceive fundamental concepts and validity of different algorithms

### 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,

### 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

### Linear programming and reductions

Chapter 7 Linear programming and reductions Many of the problems for which we want algorithms are optimization tasks: the shortest path, the cheapest spanning tree, the longest increasing subsequence,

### The multi-integer set cover and the facility terminal cover problem

The multi-integer set cover and the facility teral cover problem Dorit S. Hochbaum Asaf Levin December 5, 2007 Abstract The facility teral cover problem is a generalization of the vertex cover problem.

### Can linear programs solve NP-hard problems?

Can linear programs solve NP-hard problems? p. 1/9 Can linear programs solve NP-hard problems? Ronald de Wolf Linear programs Can linear programs solve NP-hard problems? p. 2/9 Can linear programs solve

### Comparison of Optimization Techniques in Large Scale Transportation Problems

Journal of Undergraduate Research at Minnesota State University, Mankato Volume 4 Article 10 2004 Comparison of Optimization Techniques in Large Scale Transportation Problems Tapojit Kumar Minnesota State

### 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

### CMSC 451: Graph Properties, DFS, BFS, etc.

CMSC 451: Graph Properties, DFS, BFS, etc. Slides By: Carl Kingsford Department of Computer Science University of Maryland, College Park Based on Chapter 3 of Algorithm Design by Kleinberg & Tardos. Graphs

### 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

### 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.

### Outline. Linear Programming (LP): Simplex Search. Simplex: An Extreme-Point Search Algorithm. Basic Solutions

Outline Linear Programming (LP): Simplex Search Benoît Chachuat McMaster University Department of Chemical Engineering ChE 4G03: Optimization in Chemical Engineering 1 Basic Solutions

### 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,

### Steiner Tree Approximation via IRR. Randomized Rounding

Steiner Tree Approximation via Iterative Randomized Rounding Graduate Program in Logic, Algorithms and Computation μπλ Network Algorithms and Complexity June 18, 2013 Overview 1 Introduction Scope Related

### Minimum Makespan Scheduling

Minimum Makespan Scheduling Minimum makespan scheduling: Definition and variants Factor 2 algorithm for identical machines PTAS for identical machines Factor 2 algorithm for unrelated machines Martin Zachariasen,

### Optimal Bandwidth Reservation in Hose-Model VPNs with Multi-Path Routing

Optimal Bandwidth Reservation in Hose-Model VPNs with -Path Routing Thomas Erlebach Computer Engineering and Networks Laboratory (TIK) Dept. of Information Technology and Electrical Engineering ETH Zürich,

### 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

### Approximation Algorithms: LP Relaxation, Rounding, and Randomized Rounding Techniques. My T. Thai

Approximation Algorithms: LP Relaxation, Rounding, and Randomized Rounding Techniques My T. Thai 1 Overview An overview of LP relaxation and rounding method is as follows: 1. Formulate an optimization

### Classification - Examples

Lecture 2 Scheduling 1 Classification - Examples 1 r j C max given: n jobs with processing times p 1,...,p n and release dates r 1,...,r n jobs have to be scheduled without preemption on one machine taking

### Chapter 4. Trees. 4.1 Basics

Chapter 4 Trees 4.1 Basics A tree is a connected graph with no cycles. A forest is a collection of trees. A vertex of degree one, particularly in a tree, is called a leaf. Trees arise in a variety of applications.

### Discrete Mathematics & Mathematical Reasoning Chapter 10: Graphs

Discrete Mathematics & Mathematical Reasoning Chapter 10: Graphs Kousha Etessami U. of Edinburgh, UK Kousha Etessami (U. of Edinburgh, UK) Discrete Mathematics (Chapter 6) 1 / 13 Overview Graphs and Graph

### 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

### Linear Programming: Introduction

Linear Programming: Introduction Frédéric Giroire F. Giroire LP - Introduction 1/28 Course Schedule Session 1: Introduction to optimization. Modelling and Solving simple problems. Modelling combinatorial

### Part 2: Community Detection

Chapter 8: Graph Data Part 2: Community Detection Based on Leskovec, Rajaraman, Ullman 2014: Mining of Massive Datasets Big Data Management and Analytics Outline Community Detection - Social networks -

### CHAPTER 9. Integer Programming

CHAPTER 9 Integer Programming An integer linear program (ILP) is, by definition, a linear program with the additional constraint that all variables take integer values: (9.1) max c T x s t Ax b and x integral

### Lecture 9. 1 Introduction. 2 Random Walks in Graphs. 1.1 How To Explore a Graph? CS-621 Theory Gems October 17, 2012

CS-62 Theory Gems October 7, 202 Lecture 9 Lecturer: Aleksander Mądry Scribes: Dorina Thanou, Xiaowen Dong Introduction Over the next couple of lectures, our focus will be on graphs. Graphs are one of

### Introduction to Voronoi Diagrams

C.S. 252 Prof. Roberto Tamassia Computational Geometry Sem. II, 1992 1993 Lecture 13 Date: March 22, 1993 Scribe: Scott S. Snibbe 1 Introduction Introduction to Voronoi Diagrams This lecture introduces

### 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

### 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

### Improved Algorithms for Data Migration

Improved Algorithms for Data Migration Samir Khuller 1, Yoo-Ah Kim, and Azarakhsh Malekian 1 Department of Computer Science, University of Maryland, College Park, MD 20742. Research supported by NSF Award

### Linear Programming, Lagrange Multipliers, and Duality Geoff Gordon

lp.nb 1 Linear Programming, Lagrange Multipliers, and Duality Geoff Gordon lp.nb 2 Overview This is a tutorial about some interesting math and geometry connected with constrained optimization. It is not

### Linear Programming for Optimization. Mark A. Schulze, Ph.D. Perceptive Scientific Instruments, Inc.

1. Introduction Linear Programming for Optimization Mark A. Schulze, Ph.D. Perceptive Scientific Instruments, Inc. 1.1 Definition Linear programming is the name of a branch of applied mathematics that

### 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

### Graphical method. plane. (for max) and down (for min) until it touches the set of feasible solutions. Graphical method

The graphical method of solving linear programming problems can be applied to models with two decision variables. This method consists of two steps (see also the first lecture): 1 Draw the set of feasible

### Linear Programming. March 14, 2014

Linear Programming March 1, 01 Parts of this introduction to linear programming were adapted from Chapter 9 of Introduction to Algorithms, Second Edition, by Cormen, Leiserson, Rivest and Stein [1]. 1

### FUZZY CLUSTERING ANALYSIS OF DATA MINING: APPLICATION TO AN ACCIDENT MINING SYSTEM

International Journal of Innovative Computing, Information and Control ICIC International c 0 ISSN 34-48 Volume 8, Number 8, August 0 pp. 4 FUZZY CLUSTERING ANALYSIS OF DATA MINING: APPLICATION TO AN ACCIDENT

### Week 5 Integral Polyhedra

Week 5 Integral Polyhedra We have seen some examples 1 of linear programming formulation that are integral, meaning that every basic feasible solution is an integral vector. This week we develop a theory

### THEORY OF SIMPLEX METHOD

Chapter THEORY OF SIMPLEX METHOD Mathematical Programming Problems A mathematical programming problem is an optimization problem of finding the values of the unknown variables x, x,, x n that maximize

### Introduction to Linear Programming.

Chapter 1 Introduction to Linear Programming. This chapter introduces notations, terminologies and formulations of linear programming. Examples will be given to show how real-life problems can be modeled

### Lecture 11: 0-1 Quadratic Program and Lower Bounds

Lecture : - Quadratic Program and Lower Bounds (3 units) Outline Problem formulations Reformulation: Linearization & continuous relaxation Branch & Bound Method framework Simple bounds, LP bound and semidefinite

### Lecture notes 1: Introduction to linear and (mixed) integer programs

Lecture notes 1: Introduction to linear and (mixed) integer programs Vincent Conitzer 1 An example We will start with a simple example. Suppose we are in the business of selling reproductions of two different

### Page 1. CSCE 310J Data Structures & Algorithms. CSCE 310J Data Structures & Algorithms. P, NP, and NP-Complete. Polynomial-Time Algorithms

CSCE 310J Data Structures & Algorithms P, NP, and NP-Complete Dr. Steve Goddard goddard@cse.unl.edu CSCE 310J Data Structures & Algorithms Giving credit where credit is due:» Most of the lecture notes

### Discrete Applied Mathematics. The firefighter problem with more than one firefighter on trees

Discrete Applied Mathematics 161 (2013) 899 908 Contents lists available at SciVerse ScienceDirect Discrete Applied Mathematics journal homepage: www.elsevier.com/locate/dam The firefighter problem with

### Dynamic programming. Doctoral course Optimization on graphs - Lecture 4.1. Giovanni Righini. January 17 th, 2013

Dynamic programming Doctoral course Optimization on graphs - Lecture.1 Giovanni Righini January 1 th, 201 Implicit enumeration Combinatorial optimization problems are in general NP-hard and we usually

### 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.