Heuristic Optimization Today: Linear Programming. Tobias Friedrich Chair for Algorithm Engineering Hasso Plattner Institute, Potsdam

Similar documents
Linear programming and duality theory

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

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

Linear Programming Motivation: The Diet Problem

11 Linear Programming

An example of LP problem: Political Elections

Finite Math Linear Programming 1 May / 7

Mathematical and Algorithmic Foundations Linear Programming and Matchings

Linear Programming: Introduction

Outline. CS38 Introduction to Algorithms. Linear programming 5/21/2014. Linear programming. Lecture 15 May 20, 2014

Linear Programming. Linear programming provides methods for allocating limited resources among competing activities in an optimal way.

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

Combinatorial Optimization

Linear Programming and its Applications

What s Linear Programming? Often your try is to maximize or minimize an objective within given constraints

Artificial Intelligence

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

Design and Analysis of Algorithms (V)

Linear Programming. Course review MS-E2140. v. 1.1

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

DM545 Linear and Integer Programming. Lecture 2. The Simplex Method. Marco Chiarandini

4 LINEAR PROGRAMMING (LP) E. Amaldi Fondamenti di R.O. Politecnico di Milano 1

Chapter 29 Linear Programming 771. policy urban suburban rural build roads gun control farm subsidies 0 10 gasoline tax

Outline. Combinatorial Optimization 2. Finite Systems of Linear Inequalities. Finite Systems of Linear Inequalities. Theorem (Weyl s theorem :)

Linear Programming. Readings: Read text section 11.6, and sections 1 and 2 of Tom Ferguson s notes (see course homepage).

OPERATIONS RESEARCH. Linear Programming Problem

Some Advanced Topics in Linear Programming

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

Linear Programming. Linear Programming. Linear Programming. Example: Profit Maximization (1/4) Iris Hui-Ru Jiang Fall Linear programming

Linear Programming in Small Dimensions

Linear and Integer Programming :Algorithms in the Real World. Related Optimization Problems. How important is optimization?

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

6.854 Advanced Algorithms. Scribes: Jay Kumar Sundararajan. Duality

Linear Programming Duality and Algorithms

Introduction to Linear Programming

Advanced Algorithms Linear Programming

Applications of Linear Programming

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

Section Notes 4. Duality, Sensitivity, and the Dual Simplex Algorithm. Applied Math / Engineering Sciences 121. Week of October 8, 2018

Civil Engineering Systems Analysis Lecture XIV. Instructor: Prof. Naveen Eluru Department of Civil Engineering and Applied Mechanics

Discrete Optimization 2010 Lecture 5 Min-Cost Flows & Total Unimodularity

Homework 2: Multi-unit combinatorial auctions (due Nov. 7 before class)

Introduction. Linear because it requires linear functions. Programming as synonymous of planning.

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

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

Linear Programming. Presentation for use with the textbook, Algorithm Design and Applications, by M. T. Goodrich and R. Tamassia, Wiley, 2015

16.410/413 Principles of Autonomy and Decision Making

5. DUAL LP, SOLUTION INTERPRETATION, AND POST-OPTIMALITY

Chapter II. Linear Programming

Lecture Notes 2: The Simplex Algorithm

Integer Programming Theory

MATHEMATICS II: COLLECTION OF EXERCISES AND PROBLEMS

AM 121: Intro to Optimization Models and Methods Fall 2017

Discrete Optimization. Lecture Notes 2

1. Lecture notes on bipartite matching February 4th,

4 Integer Linear Programming (ILP)

Linear Programming. them such that they

5.3 Cutting plane methods and Gomory fractional cuts

Math 5490 Network Flows

1 Linear programming relaxation

Linear Programming. Larry Blume. Cornell University & The Santa Fe Institute & IHS

Simulation. Lecture O1 Optimization: Linear Programming. Saeed Bastani April 2016

CS599: Convex and Combinatorial Optimization Fall 2013 Lecture 1: Introduction to Optimization. Instructor: Shaddin Dughmi

R n a T i x = b i} is a Hyperplane.

CS 372: Computational Geometry Lecture 10 Linear Programming in Fixed Dimension

GENERAL ASSIGNMENT PROBLEM via Branch and Price JOHN AND LEI

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

Tribhuvan University Institute Of Science and Technology Tribhuvan University Institute of Science and Technology

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

Lecture 5: Duality Theory

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

The Simplex Algorithm

Notes for Lecture 20

Copyright 2007 Pearson Addison-Wesley. All rights reserved. A. Levitin Introduction to the Design & Analysis of Algorithms, 2 nd ed., Ch.

Submodularity Reading Group. Matroid Polytopes, Polymatroid. M. Pawan Kumar

INTRODUCTION TO LINEAR AND NONLINEAR PROGRAMMING

CS675: Convex and Combinatorial Optimization Spring 2018 Consequences of the Ellipsoid Algorithm. Instructor: Shaddin Dughmi

ORIE 6300 Mathematical Programming I September 2, Lecture 3

Approximation Algorithms

Lecture 16 October 23, 2014

Math Models of OR: The Simplex Algorithm: Practical Considerations

MVE165/MMG631 Linear and integer optimization with applications Lecture 9 Discrete optimization: theory and algorithms

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

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

Linear Programming. L.W. Dasanayake Department of Economics University of Kelaniya

1. Lecture notes on bipartite matching

Linear Programming Problems

ACTUALLY DOING IT : an Introduction to Polyhedral Computation

CMPSCI611: The Simplex Algorithm Lecture 24

Dual-fitting analysis of Greedy for Set Cover

The simplex method and the diameter of a 0-1 polytope

Identical text Minor difference Moved in S&W Wrong in S&W Not copied from Wiki 1

Read: H&L chapters 1-6

A Computer Technique for Duality Theory in Linear Programs

3 INTEGER LINEAR PROGRAMMING

CS675: Convex and Combinatorial Optimization Spring 2018 The Simplex Algorithm. Instructor: Shaddin Dughmi

Lecture 3. Corner Polyhedron, Intersection Cuts, Maximal Lattice-Free Convex Sets. Tepper School of Business Carnegie Mellon University, Pittsburgh

Applied Lagrange Duality for Constrained Optimization

CSE 460. Today we will look at" Classes of Optimization Problems" Linear Programming" The Simplex Algorithm"

II. Linear Programming

Transcription:

Heuristic Optimization Today: Linear Programming Chair for Algorithm Engineering Hasso Plattner Institute, Potsdam

Linear programming Let s first define it formally: A linear program is an optimization problem in finitely many variables having a linear objective function and a constraint region determined by a finite number of linear equality and/or inequality constraints.

Linear programming A linear function of the variables x 1, x 2,...,x n is any function f of the form f (x) =c 1 x 1 + c 2 x 2 + + c n x n for fixed c i 2 R i =1,...,n. 2 R A linear equality constraint is any equation of the form where, a 1, a 2,...,a n 2 R. 2 a 1 x 1 + a 2 x 2 + + a n x n =, A linear inequality constraint is any inequality of the form a 1 x 1 + a 2 x 2 + + a n x n apple, or a 1 x 1 + a 2 x 2 + + a n x n, where, a 1, a 2,...,a n 2 R.

Linear programming The standard compact representation is minimize c 1 x 1 + c 2 x 2 + + c n x n subject to a i1 x i + a i2 x 2 + + a in x n apple i i =1,...,s b i1 x i + b i2 x 2 + + b in x n = i i =1,...,r.

Linear programming The standard matrix representation is minimize c T x subject to Ax apple a and Bx = b A = c = 2 6 4 2 6 4 c 1. c n 3 7 5, a = a 11... a 1n... 2 6 4 3 1. s 3 7 5, B = 7 5, b = 2 6 4 2 6 4. 1 r 3 7 5. b 11... b 1n... 3 7 5 a s1... a sn b r1... b rn

Introductory Example #1: Optimization in Politics Assume you are a politician, who wants to get 50% of the votes u in metropolitan region #1 with 100k inhabitants u in suburban region #2 with 200k inhabitants u in rural region #3 with 50k inhabitants You want to buy advertisements; each commercial block costs 1000

Introductory Example #1: Optimization in Politics The commercial blocks have the following effect: Build more streets Disempower secret service More agriculture subvention Increase petrol taxes Metropolitan region #1 Suburban region #2 Rural region #3-2 5 3 8 2-5 0 0 10 10 0-2

Introductory Example #1: Optimization in Politics Some sample spending: Total Spending 33.000 Build more streets 20.000 Disempower secret service 0 More agriculture subvention 4.000 Increase petrol taxes 9.000

Introductory Example #1: Optimization in Politics Effect of our sample spending: Metropolitan region #1 Suburban region #2 Rural region #3 Build more streets Disempow er secret service More agriculture subvention Increase petrol taxes Resultiu ng Votes 20*(-2) +0*8 +4*0 +9*10 =50.000 20*5 +0*2 +4*0 +9*0 =100.000 20*3 +0*(-5) +4*10 +9*(-2) =82.000 Is there a cheaper way to win the election?

Introductory Example #1: Optimization in Politics Let s formulate this mathematically: u x 1 = #commercial blocks for building more streets u x 2 = #commercial blocks for disempower secret service u x 3 = #commercial blocks for more agriculture subvention u x 4 = #commercial blocks for increasing petrol taxes

Introductory Example #1: Optimization in Politics Mathematically speaking, our target is: Minimize x 1 +x 2 +x 3 +x 4 such that u -2 x 1 + 8 x 2 + 0 x 3 + 10 x 4 50 u 5 x 1 + 2 x 2 + 0 x 3 + 0 x 4 100 u 3 x 1-5 x 2 + 10 x 3-2 x 4 25 u x 1, x 2, x 3, x 4 0

Introductory Example #2: Optimization in Economics Let s look at another problem: Maximize profit G(x 1,x 2 ) = 300 x 1 + 500 x 2 such that (1) x 1 + 2 x 2 170 (2) x 1 + x 2 150 (3) 3 x 2 180 (4) x 1, x 2 0

Introductory Example #2: Optimization in Economics

Introductory Example #2: Optimization in Economics Wort-Bild-Marke CMYK Größe 40 Name: hpi_logo_cmyk_wb à see white board Conclusion: Look for y 0, such that yta is an upper bound for yta ct

Primal vs. Dual P Primal: max c T x D Dual: min b T y s.t. Ax apple b 0 apple x s.t. A T y c 0 apple y

Weak Duality Theorem Weak Duality Theorem: If x 2 R n is feasible for P and y 2 R m is feasible for D, then c T x apple y T Ax apple b T y. Thus, if P is unbounded, then D is necessarily infeasible, and if D is unbounded, then P is necessarily infeasible.

Weak Duality Theorem Proof of Weak Duality Theorem: c T x = n P apple j=1 P n j=1 c j x j ( m P i=1 = y T Ax P = m P ( n apple i=1 P m i=1 = b T y j=1 a ij y i )x j a ij x j )y i b i y i [0 apple y i, [0 apple x j, c j apple m P np j=1 i=1 a ij y i a ij x j apple b i ) c j x j apple ( m P ) ( n P j=1 i=1 a ij y i )x j ] a ij x j )y i apple b i y i ]

Strong Duality Theorem Theorem: If either P or D has a finite optimal value, then so does the other, the optimal values coincide, and optimal solutions to both P and D exist.

Fundamental Theorem Theorem: Every LP has the following three properties: (i) If it has no optimal solution, then it is either infeasible or unbounded. (ii) If it has a feasible solution, then it has a basic feasible solution. (iii) If it is bounded, then it has an optimal basic feasible solution.

Reduction to Standard Form Any linear program can be brought into standard form: I elimination of free (unbounded) variables x j : replace x j with x + j, x j 0: x j = x + j x j I elimination of non-positive variables x j : replace x j apple 0 with ( x j ) 0. I elimination of inequality constraint a T i x apple b i : introduce slack variable s 0 and rewrite: a T i x + s = b i I elimination of inequality constraint a T i x b i : introduce slack variable s 0 and rewrite: a i T x s = b i

Simplex Algorithm Observations: Feasible region (Ax b, x 0) is a (possibly unbounded) convex polytope Maximum value on the feasible region occurs on one of the extreme points Number of extreme points is finite, but exponentially large It is enough to check corners of the polytope

Simplex Algorithm Walks along edges of the polytope to extreme points with greater and greater objective values Continues until the maximum value is reached or an unbounded edge is visited (i.e. problem has no solution) Runtime Finite as the number of vertices in the polytope is finite For every deterministic Pivot rule there is a worstcase which need exponential time Still very efficient in practice There are other algos for LPs with poly. time

Integer Linear Program Adding integrality constraints make things MUCH harder; example Weighted Vertex Cover Problem: Given: undirected graph G =(V, E), weight function w : V! R 0. Task: find U V of minimum total weight such that every edge e 2 E has at least one endpoint in U. Formulation as an integer linear program (IP): Variables: x v 2 {0, 1} for v 2 V with x v = 1 if and only if v 2 U. X minimize w(v) x v v2v subject to x v + x v 0 1 for all e = {v, v 0 } 2 E, x v 2 {0, 1} for all v 2 V.