Reconnect 04 Introduction to Integer Programming

Similar documents
- Well-characterized problems, min-max relations, approximate certificates. - LP problems in the standard form, primal and dual linear programs

Computational Integer Programming. Lecture 2: Modeling and Formulation. Dr. Ted Ralphs

Integer programming: an introduction. Alessandro Astolfi

Integer Linear Programming Modeling

1 Column Generation and the Cutting Stock Problem

Introduction to Integer Linear Programming

CS675: Convex and Combinatorial Optimization Fall 2016 Combinatorial Problems as Linear and Convex Programs. Instructor: Shaddin Dughmi

Introduction into Vehicle Routing Problems and other basic mixed-integer problems

Introduction to integer programming III:

Lectures 6, 7 and part of 8

CHAPTER 3: INTEGER PROGRAMMING

Totally unimodular matrices. Introduction to integer programming III: Network Flow, Interval Scheduling, and Vehicle Routing Problems

CS675: Convex and Combinatorial Optimization Fall 2014 Combinatorial Problems as Linear Programs. Instructor: Shaddin Dughmi

Integer Programming (IP)

COT 6936: Topics in Algorithms! Giri Narasimhan. ECS 254A / EC 2443; Phone: x3748

Linear and Integer Programming - ideas

Outline. Relaxation. Outline DMP204 SCHEDULING, TIMETABLING AND ROUTING. 1. Lagrangian Relaxation. Lecture 12 Single Machine Models, Column Generation

3.7 Cutting plane methods

Introduction to optimization and operations research

5 Integer Linear Programming (ILP) E. Amaldi Foundations of Operations Research Politecnico di Milano 1

Section Notes 9. IP: Cutting Planes. Applied Math 121. Week of April 12, 2010

Integer Programming ISE 418. Lecture 16. Dr. Ted Ralphs

Computational Integer Programming Universidad de los Andes. Lecture 1. Dr. Ted Ralphs

Integer Programming ISE 418. Lecture 12. Dr. Ted Ralphs

Chapter 3: Discrete Optimization Integer Programming

Computational Complexity. IE 496 Lecture 6. Dr. Ted Ralphs

Operations Research Lecture 6: Integer Programming

Integer Programming ISE 418. Lecture 8. Dr. Ted Ralphs

Combinatorial optimization problems

Topic: Primal-Dual Algorithms Date: We finished our discussion of randomized rounding and began talking about LP Duality.

Week Cuts, Branch & Bound, and Lagrangean Relaxation

Lecture 9: Dantzig-Wolfe Decomposition

On the Tightness of an LP Relaxation for Rational Optimization and its Applications

Lecture 8: Column Generation

Duality of LPs and Applications

15.081J/6.251J Introduction to Mathematical Programming. Lecture 24: Discrete Optimization

1 T 1 = where 1 is the all-ones vector. For the upper bound, let v 1 be the eigenvector corresponding. u:(u,v) E v 1(u)

MVE165/MMG630, Applied Optimization Lecture 6 Integer linear programming: models and applications; complexity. Ann-Brith Strömberg

Integer Programming Methods LNMB

BBM402-Lecture 20: LP Duality

Chapter 3: Discrete Optimization Integer Programming

Section Notes 8. Integer Programming II. Applied Math 121. Week of April 5, expand your knowledge of big M s and logical constraints.

Integer Linear Programming (ILP)

Integer Programming Chapter 15

Lecture 2. MATH3220 Operations Research and Logistics Jan. 8, Pan Li The Chinese University of Hong Kong. Integer Programming Formulations

Introduction to Integer Programming

Optimization of Submodular Functions Tutorial - lecture I

Network Flows. 6. Lagrangian Relaxation. Programming. Fall 2010 Instructor: Dr. Masoud Yaghini

Semidefinite and Second Order Cone Programming Seminar Fall 2001 Lecture 5

OPTIMIZATION. joint course with. Ottimizzazione Discreta and Complementi di R.O. Edoardo Amaldi. DEIB Politecnico di Milano

Mathematical Optimization Models and Applications

Optimisation and Operations Research

16.410/413 Principles of Autonomy and Decision Making

19. Fixed costs and variable bounds

Integer Linear Programs

CS261: A Second Course in Algorithms Lecture #8: Linear Programming Duality (Part 1)

3.3 Easy ILP problems and totally unimodular matrices

MS-E2140. Lecture 1. (course book chapters )

Office of Naval Research contract no. N K-0377 (9) FINAL TECHNICAL REPORT

3. Linear Programming and Polyhedral Combinatorics

Lecture 13: Linear programming I

Multicriteria approximation through decomposition

This means that we can assume each list ) is

1 Primals and Duals: Zero Sum Games

a 1 a 2 a 3 a 4 v i c i c(a 1, a 3 ) = 3

Lecture #21. c T x Ax b. maximize subject to

Resource Constrained Project Scheduling Linear and Integer Programming (1)

What is an integer program? Modelling with Integer Variables. Mixed Integer Program. Let us start with a linear program: max cx s.t.

CSE541 Class 22. Jeremy Buhler. November 22, Today: how to generalize some well-known approximation results

Integer Programming ISE 418. Lecture 13. Dr. Ted Ralphs

Multicommodity Flows and Column Generation

Welcome to CPSC 4850/ OR Algorithms

4/12/2011. Chapter 8. NP and Computational Intractability. Directed Hamiltonian Cycle. Traveling Salesman Problem. Directed Hamiltonian Cycle

THE EXISTENCE AND USEFULNESS OF EQUALITY CUTS IN THE MULTI-DEMAND MULTIDIMENSIONAL KNAPSACK PROBLEM LEVI DELISSA. B.S., Kansas State University, 2014

Introduction to Bin Packing Problems

Lecture 23 Branch-and-Bound Algorithm. November 3, 2009

Motivating examples Introduction to algorithms Simplex algorithm. On a particular example General algorithm. Duality An application to game theory

Recoverable Robustness in Scheduling Problems

Integer and Combinatorial Optimization: Introduction

Linear Programming Duality

Chapter 11. Approximation Algorithms. Slides by Kevin Wayne Pearson-Addison Wesley. All rights reserved.

Lecture 8: Column Generation

0-1 Reformulations of the Network Loading Problem

CSC373: Algorithm Design, Analysis and Complexity Fall 2017 DENIS PANKRATOV NOVEMBER 1, 2017

CS264: Beyond Worst-Case Analysis Lecture #15: Smoothed Complexity and Pseudopolynomial-Time Algorithms

Notes on Dantzig-Wolfe decomposition and column generation

CO759: Algorithmic Game Theory Spring 2015

23. Cutting planes and branch & bound

MS-E2140. Lecture 1. (course book chapters )

15-780: LinearProgramming

Nonconvex Quadratic Programming: Return of the Boolean Quadric Polytope

with Binary Decision Diagrams Integer Programming J. N. Hooker Tarik Hadzic IT University of Copenhagen Carnegie Mellon University ICS 2007, January

Mathematical Programs Linear Program (LP)

Lecture Note 1: Introduction to optimization. Xiaoqun Zhang Shanghai Jiao Tong University

3. Linear Programming and Polyhedral Combinatorics

On the Polyhedral Structure of a Multi Item Production Planning Model with Setup Times

Lecture 15 (Oct 6): LP Duality

Linear Programming Duality P&S Chapter 3 Last Revised Nov 1, 2004

A General Framework for Designing Approximation Schemes for Combinatorial Optimization Problems with Many Objectives Combined into One

Transcription:

Sandia is a multiprogram laboratory operated by Sandia Corporation, a Lockheed Martin Company, Reconnect 04 Introduction to Integer Programming Cynthia Phillips, Sandia National Laboratories Integer programming (IP) Min c T x Subject to: Ax = b l x u x = (x I, x C ) x I Z n (integer values) x C Q n (rational values) Can also have inequalities in either direction (slack variables): a T i x b i a T i x + s i = b i, s i 0 If x I and x C, then this is a mixed-integer program (MIP) Linear programming (LP) has no integrality constraints x I = (in P) IP (easily) expresses any NP-complete problem for the United States Department of Energy under contract DE-AC04-94AL8000. Slide Terminology In this context programming means making decisions. Leading terms say what kind: (Pure) Integer programming: all integer decisions Linear programming Quadratic programming: quadratic objective function Nonlinear programming: nonlinear constraints Stochastic programming: finite probability distribution of scenarios Decisions The IPs I ve encountered in practice involve either Allocation of scarce resources Study of a natural system Computational biology Mathematics Maybe during or after this course, you can add to the list Came from operations research (practical optimization discipline) Computer programming (by someone) is required to solve these. Slide Slide 4

Integer Variables Use x i { 0,} (binary variables) to model: Yes/no decisions Disjunctions Logical conditions Piecewise linear functions (this not covered in this lecture) General Integer Variables Use general integer variables to choose a number of indivisible objects such as the number of planes to produce Integer range should be small (e.g. -0) Computational tractability Larger ranges may be well approximated by rational variables (number of bags of potato chips to produce) Slide Slide 6 Example: Binary Knapsack Given set of objects..n total weight W, item weight/size w i, value v i If we select item i x i 0 Otherwise n max v i x i i= Subject to n w i x i W i= Example: Shortest-Path Network Interdiction Delay an adversary moving through a network. Adversary moves start target along a shortest path (in worst case) Start Path length = sum of edge lengths. Measure of time, exposure, etc. 4 6 Target Shortest Path Length: 8 Slide 7 Slide 8

Example: Shortest-Path Network Interdiction Defender blocks the intruder by paying to increase edge lengths. Goal: Maximize the resulting shortest path. Path Interdiction Mixed-Integer Program Graph G = (V,E) Edge lengths l uv for edge (u,v) Can increase length of (u,v) by λ uv at cost c uv Budget B Start + 4 6 + Target Variables: if we pay to lengthen edge (u,v) x uv 0 Otherwise d u : shortest distance from start s to node u Shortest Path Length: Slide 9 Slide 0 Path Interdiction Integer Program Modeling Dependent Decisions Objective: maximize the shortest path to the target maximize d t Suppose x,y are two binary variables that represent a decision (where means yes and 0 means no ) Subject to: Path to the start has length 0: d s = 0 Calculate a shortest path length: u l uv The constraint x y allows x to be yes only if y is yes d u d v + l uv + λ uv x uv for all (u,v) E d v d u + l uv + λ uv x uv for all (u,v) E v + λ uv Respect the budget: (u,v) E c uv x uv B Slide Slide

Example: Unconstrained Facility Location Given potential facility locations, n customers to be served c j = cost to build facility j h ij = cost to meet all of customer i s demand from facility j if facility j built if customer i is served by facility j x j y 0 Otherwise ij 0 Otherwise min c j x j + j i, j h ij y ij st. y ij = i (each customer satisfied) j y ij x j i, j (facility built before use) x j, y i { 0,} Formulation is really important in practice Unconstrained facility location Could sum constraints y ij x i i, j over all customers i to get: i y ij nx j j Recall n is the number of customers. Still requires a facility is built before use (IPs are equivalent at optimality) But, for 40 customers, 40 facilities, random costs First formulation solves in seconds Second formulation solves in, seconds (4.7 hours) Sometimes it s OK to satisfy customers from multiple facilities: y ij becomes a percentage : y ij Q, 0 y ij Slide Slide 4 What makes one formulation so much better? Understanding this fully is an open problem. Some performance differences can be explained by the way IPs are solved in practice by branch-and-bound-like algorithms: the LP relaxation Recall Integer Programming (IP) Min c T x Subject to: Ax = b l x u x = (x I, x C ) x I Z n (integer values) x C Q n (rational values) Slide Slide 6

Linear programming (LP) relaxation of an IP Linear Programming Geometry Min c T x Subject to: Ax = b l x u x = (x I,x C ) x I Z n (integer values) x C Q n (rational values) The solutions to a single inequality (in n-dimensional space) a T x b, x Q n form a half space a T x = b LP can be solved efficiently (in theory and practice) Relaxation = removing constraints All feasible IP solutions are feasible LP gives a lower bound feasible Slide 7 Slide 8 Linear Programming Geometry IP Geometry Intersection of all the linear (in)equalities form a convex polytope For simplicity, we ll always assume polytope is bounded Feasible integer points form a lattice inside the LP polytope feasible Slide 9 Slide 0

IP Geometry The convex hull of this lattice forms the integer polytope IP/LP Geometry A good formulation keeps this region small Every node for which the LP bound is lower than the integer optimal must be processed (e.g. expanded) Slide Slide IP/LP Geometry Unconstrained Facility Location Revisited A good formulation keeps this region small One measure of this is the Integrality Gap: Integrality gap = max instances I (IP (I))/(LP(I)) Given potential facility locations, customers to be served c j = cost to build facility j h ij = cost to meet all of customer i s demand from facility j if facility j built if customer i is served by facility j x j y 0 Otherwise j 0 Otherwise min c j x j + j i, j h ij y ij st. y ij = i (each customer satisfied) j y ij x j i, j (facility built before use) x j,y i { 0,} Slide Slide 4

How the weaker LP cheats Using y ij n x j j i Allows the LP to completely satisfy customer i with facility j (y ij = ) even with x j = /n. Can t we just round the LP Solution? Not generally feasible If (miraculously) it is feasible, it s not generally good With these constraints: y ij x i i, j If x i = /n, then y ij <= /n Slide Slide 6 Example: Maximum Independent Set Example: Maximum Independent Set 4 4 7 7 6 6 Find a maximum-size set of vertices that have no edges between any pair Slide 7 Slide 8 if vertex i is in the MIS v i 0 otherwise max v i s.t. v i + v j v i { 0,} ( i, j) E

Example: Maximum Independent Set Can t we project the lattice onto the objective gradient? / / / 4 / / 7 c T x = opt max / v i s.t. v i + v j 6 ( i, j) E / gradient The zero-information solution (v i =. for all i) is feasible and it s optimal if the optimal MIS has size at most V /. Rounding everything (up) is infeasible. Hard to find a feasible solution to project (NP-complete!) Make the objective a constraint and do binary search This is a lot harder in n dimensions than it looks like in Slide 9 Slide 0 Perfect formulations Perfect Formulation Example: Minimum Cut Sometimes solving an LP is guaranteed to give an integer solution All polytope corners have integer coefficients (naturally integer) Sometimes only for specific objectives (e.g. c 0 ) s 7 4 9 Capacity u e 8 0 t Slide Special nodes s and t Each edge e has capacity u e. Set of edges S has capacity Partition vertex set V into S,T where s S and t T A cut is the edges (u,v) such that u S and v T Find a cut with minimum capacity Slide e S u e

Perfect Formulation Example: Minimum Cut IP 0 if node v is on the s side v i if node v is on the t side Helper variables y e = if e is in the cut and 0 otherwise min u e y e st y e v i v j e = (i, j) y e v j - v i e = (i, j) v s = 0, v t = v e { 0,} The y variables will be integral if the v variables are. Total Unimodularity The minimum cut matrix (possibly with slack variables) is totally unimodular (TU): all subdeterminants (including the matrix entries) have value 0,, or -. All corner solutions x satisfy Ax=b By Kramer s rule x will be integral Network matrices (adjacency matrices of graphs) are TU. Nemhauser and Wolsey (Integer and Combinatorial Optimization, Wiley, 988) give some sufficient conditions for a matrix to be TU. Note: if a matrix is TU, there is always an efficient combinatorial algorithm to solve the problem (not necessarily obvious) Slide Slide 4 Total Unimodularity is Fragile Network Flow Example: Network Interdiction Expend a limited budget to maximally damage the transport capacity of a network /7 s / / / 0/ / Source(s) s, sink (consumers) t Capacity (bottom number) Flow (top number) Maximize flow from s to t obeying Capacity constraints on edges Conservation constraints on all nodes other than s,t /8 4 / 8/0 9/9 / t Slide Slide 6

Network Interdiction /7 s / / / 0/ / /8 Each edge e now has a destruction cost d e (cost to remove e; assume linear) Budget B Expend at most B removing (pieces of) edges in the network so resulting max flow is minimized 4 / 8/0 9/9 / t Network Interdiction By LP duality (we ll see later) value of max flow = value of min cut So min attacks max flow = min attacks min cut Pay to knock out transport capacity from s to t 7 4 s 9 0 8 t Slide 7 Slide 8 A Mixed Integer Program for Network Inhibition Network Inhibition IP 0 if node v is on the s side v i if node v is on the t side S V 0 s t Based on min-cut LP Find best cut to attack Decision variables place vertices on the s or t side as before All edges going across the cut must be destroyed (consume budget) or contribute to residual cut capacity S Helper variables y e = percent of an edge in cut that is not removed z e = percent of an edge in the cut that is destroyed min u e y e st y e + z e v i v j e = (i, j) y e + z e v j - v i e = (i, j) v s = 0, v t = d e e v e { 0,} z e B Slide 9 Slide 40

Total Unimodularity is Fragile The matrix is still TU without the budget constraint Adding the budget constraint makes the problem strongly NP-complete No known polynomial-time approximation algorithms Still has some very nice structure that gives a pseudo-approximation Pseudo-approximation might give a superoptimal solution that slightly exceeds the budget or it could give a true approximation Slide 4 min u e y e st y e + z e v i v j e = (i, j) y e + z e v j - v i e = (i, j) v s = 0, v t = e d e z e B v e { 0,} Modeling Sets Given a set T, means select at least element of T i T x i Making sure at least one local warehouse has inventory for each customer means select at most element of T i T x i Conflicts (e.g. modeled by a maximum independent set problem) Resource constraints x i = means select exactly element of T i T Time indexed scheduling variables x jt, schedule job j at time t. This picks a single time for job j. Slide 4 Modeling Disjunctive Constraints Let a T x b and a T x b be two constraints with nonnegative coefficients (a i 0, i =,) To force satisfaction of at least one of these constraints: a T x yb a T x ( y)b y { 0,} Modeling Disjunctive Constraints - General Number Let a T i x b i, i =Km be m constraints with nonnegative coefficients (a i 0) To force satisfaction of at least k of these constraints: a T i x b i y i i =Km m i= y i k y { 0,} Slide 4 Slide 44

Modeling a Restricted Set of Values Variable x can take on only values in Frequently the v i are sorted Example: capacity of an airplane assigned to a flight x = v i y i The y i s are a special ordered set. m i= m y i= i = y { 0,} { v,v,kv m } Some simple logical constraints Want y = x x (logical or) y x y x Suffices if there is pressure in the objective function to keep y low. Saw this in minimum cut Similarly if we want y = x x y x y x (logical and) Suffices if there is pressure in the objective function to keep y high. Slide 4 Slide 46 Example: Protein Structure Comparison Example: Protein Structure Comparison Contact Map nonadjacent amino acids share an edge if they re physically close when folded nonadjacent amino acids share an edge if they re physically close folded Noncrossing alignment of two proteins to maximize shared contacts Measure of similarity Slide 47 Slide 48

Protein Structure Comparison Variables x ij = if amino acid in position i of the top protein is matched to amino acid in position j of the bottom protein, 0 otherwise Helper variables y ijkl = x ij x kl Non-crossing alignment For any pair of edges, we can tell if they cross y ijkl = 0 if the pair is forbidden (simply don t create this variable). There are more clever ways to do this (e.g. using Ramsey theory). See what you can come up with. Slide 49 Slide 0 Protein Structure Comparison Only consider y ijkl if this is a shared contact ((i,k) a contact, (j,l) a contact) max st yijkl exists y ijkl y ijkl = 0 if (i, j) and (k,l) cross (doesn't exist) y ijkl x ij y ijkl x kl x ij { 0,} MIP Applications (Small Sample) Logistics Capacity planning, scheduling, workforce planning, military spares management Infrastructure/network security Vulnerability analysis, reinforcement, reliability, design, integrity of physical transport media Sensor placement (water systems, roadways) Waste remediation Vehicle routing, fleet planning Bioinformatics: protein structure prediction/comparison, drug docking VLSI, robot design Tools for high-performance computing (scheduling, node allocation, domain decomposition, meshing) Slide Slide

Solving Integer Programs NP-hard Many special cases have efficient solutions or provably-good approximation bounds Need time to explore structure General IPs can be hard due to size and/or structure (Sufficiently) optimal solution is important When lives or big $ at stake For rigorous benchmarking of heuristic/approximation methods To gain structural insight for better algorithms/proofs. Slide