C&O 355 Mathematical Programming Fall 2010 Lecture 20 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A.

Slides:



Advertisements
Similar presentations
February 14, 2002 Putting Linear Programs into standard form
Advertisements

C&O 355 Lecture 22 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A A A A A A A A A.
C&O 355 Lecture 15 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A A A A A A A A.
C&O 355 Lecture 6 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A.
C&O 355 Mathematical Programming Fall 2010 Lecture 6 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A A.
Incremental Linear Programming Linear programming involves finding a solution to the constraints, one that maximizes the given linear function of variables.
C&O 355 Mathematical Programming Fall 2010 Lecture 9
C&O 355 Lecture 5 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A.
C&O 355 Lecture 23 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A A A A A A A A A.
Lecture #3; Based on slides by Yinyu Ye
Linear Programming (LP) (Chap.29)
C&O 355 Mathematical Programming Fall 2010 Lecture 22 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A A.
MS&E 211 Quadratic Programming Ashish Goel. A simple quadratic program Minimize (x 1 ) 2 Subject to: -x 1 + x 2 ≥ 3 -x 1 – x 2 ≥ -2.
Introduction to Algorithms
Dragan Jovicic Harvinder Singh
OR Simplex method (algebraic interpretation) Add slack variables( 여유변수 ) to each constraint to convert them to equations. (We may refer it as.
C&O 355 Lecture 4 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A.
C&O 355 Mathematical Programming Fall 2010 Lecture 21 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A.
C&O 355 Mathematical Programming Fall 2010 Lecture 15 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A.
C&O 355 Lecture 20 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A A A A A A A A A.
C&O 355 Lecture 12 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A A A A A A A A A.
How should we define corner points? Under any reasonable definition, point x should be considered a corner point x What is a corner point?
Basic Feasible Solutions: Recap MS&E 211. WILL FOLLOW A CELEBRATED INTELLECTUAL TEACHING TRADITION.
Linear programming Thomas S. Ferguson University of California at Los Angeles Compressive Sensing Tutorial PART 3 Svetlana Avramov-Zamurovic January 29,
Totally Unimodular Matrices Lecture 11: Feb 23 Simplex Algorithm Elliposid Algorithm.
Design and Analysis of Algorithms
Job Scheduling Lecture 19: March 19. Job Scheduling: Unrelated Multiple Machines There are n jobs, each job has: a processing time p(i,j) (the time to.
ISM 206 Lecture 3 The Simplex Method. Announcements.
MIT and James Orlin © Chapter 3. The simplex algorithm Putting Linear Programs into standard form Introduction to Simplex Algorithm.
Course: Advanced Algorithms CSG713, Fall 2008 CCIS Department, Northeastern University Dimitrios Kanoulas.
Chapter 15 Constrained Optimization. The Linear Programming Model Let : x 1, x 2, x 3, ………, x n = decision variables Z = Objective function or linear.
C&O 355 Mathematical Programming Fall 2010 Lecture 17 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A.
Linear Programming David Kauchak cs161 Summer 2009.
Decision Procedures An Algorithmic Point of View
C&O 355 Mathematical Programming Fall 2010 Lecture 1 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A A.
C&O 355 Lecture 2 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A.
C&O 355 Mathematical Programming Fall 2010 Lecture 2 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A A.
C&O 355 Mathematical Programming Fall 2010 Lecture 19 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A.
C&O 355 Mathematical Programming Fall 2010 Lecture 4 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A A.
Simplex method (algebraic interpretation)
TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A A A A A A A A Image:
C&O 355 Mathematical Programming Fall 2010 Lecture 8 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A A.
C&O 355 Mathematical Programming Fall 2010 Lecture 16 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A A.
Optimization - Lecture 4, Part 1 M. Pawan Kumar Slides available online
X y x-y · 4 -y-2x · 5 -3x+y · 6 x+y · 3 Given x, for what values of y is (x,y) feasible? Need: y · 3x+6, y · -x+3, y ¸ -2x-5, and y ¸ x-4 Consider the.
C&O 355 Mathematical Programming Fall 2010 Lecture 5 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A A.
OR Chapter 8. General LP Problems Converting other forms to general LP problem : min c’x  - max (-c)’x   = by adding a nonnegative slack variable.
OR Simplex method (algebraic interpretation) Add slack variables( 여유변수 ) to each constraint to convert them to equations. (We may refer it as.
C&O 355 Lecture 7 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A.
CPSC 536N Sparse Approximations Winter 2013 Lecture 1 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AAAAAAAAAA.
C&O 355 Lecture 24 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A A A A A A A A.
Linear Programming: Formulations, Geometry and Simplex Method Yi Zhang January 21 th, 2010.
Simplex “walk on the vertices of the feasible region” v = current vertex if  neighbor v’ of v with better objective then move to v’
C&O 355 Lecture 19 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A A A A A A A A A A.
TU/e Algorithms (2IL15) – Lecture 12 1 Linear Programming.
Linear Programming Chap 2. The Geometry of LP  In the text, polyhedron is defined as P = { x  R n : Ax  b }. So some of our earlier results should.
TU/e Algorithms (2IL15) – Lecture 12 1 Linear Programming.
Discrete Optimization
EMGT 6412/MATH 6665 Mathematical Programming Spring 2016
Lap Chi Lau we will only use slides 4 to 19
Topics in Algorithms Lap Chi Lau.
Uri Zwick – Tel Aviv Univ.
Chapter 8. General LP Problems
Flow Feasibility Problems
C&O 355 Lecture 3 N. Harvey Review of Lecture 2:
Chapter 8. General LP Problems
Chapter 2. Simplex method
Chapter 8. General LP Problems
Chapter 2. Simplex method
Presentation transcript:

C&O 355 Mathematical Programming Fall 2010 Lecture 20 N. Harvey TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A A A A A A A A

The “Simplex Method” “The obvious idea of moving along edges from one vertex of a convex polygon to the next” [Dantzig, 1963] Objective Function Start Here End Here Image:

The “Simplex Method” “The obvious idea of moving along edges from one vertex of a convex polygon to the next” [Dantzig, 1963] Algorithm Let x be any vertex of P For each neighbor y of x If c T y>c T x then Set x=y and go to start Halt Remarks The name sounds fancy, but is meaningless. In practice, very fast. Used in all LP software. In theory, we don’t know whether it’s fast or not. (Because we don’t understand the diameter of polyhedra, i.e., Hirsch Conjecture) LP: Polyhedron: This is a simplex

Pitfalls The simplex method is very simple… …if we can handle a few issues 1.What if there are no vertices? 2.How can I find a starting vertex? 3.What are the “neighboring” vertices? 4.Does the algorithm terminate? 5.Does it produce the right answer? Algorithm Let x be any vertex of P For each neighbor y of x If c T y>c T x then Set x=y and go to start Halt LP: Polyhedron:

Issue #1 What if there are no vertices? Not all polyhedrons have vertices! Recall: Any polyhedron that does not contain a line has at least one vertex. A fix: Instead of max { c T x : Ax · b } we could solve max { c T ( u-v) : A(u-v)+w=b, u,v,w ¸ 0 }. These LPs are equivalent. The feasible region of the new LP contains no line. Summary: Can assume we’re solving an LP with a vertex. x1x1 x2x2 x 2 · 2 x 2 ¸ 0

Pitfalls The simplex method is very simple… …if we can handle a few issues 1.What if there are no vertices? Can modify polyhedron so that it has a vertex. 2.How can I find a starting vertex? 3.What are the “neighboring” vertices? 4.Does the algorithm terminate? 5.Does it produce the right answer?

Issue #2 How can I find a starting vertex? This is non-trivial! As shown in Lecture 3, maximizing the LP is equivalent to finding a feasible point for: So, in general, finding a feasible point is not easy. A fix: The problem “find a feasible point for my LP” can be solved by a new LP. How does this help?!? The new LP has an obvious feasible point! So we solve the new LP, get feasible point for old LP. Once you have a feasible point, it’s easy to find a vertex: Lecture 10: Any LP whose feasible region contains no line has an optimal solution at a vertex. That proof actually gives an algorithm to find a vertex.

Finding a starting point Consider LP max { c T x : x 2 P } where P={ x : Ax=b, x ¸ 0 } We’ll find a feasible point by solving a new LP! – Note: c is irrelevant. We can introduce a new objective function – WLOG, b ¸ 0 (Can multiply constraints by -1) – Allow “Ax=b” constraint to be violated via “artificial variables”: Q = { (x,y) : Ax+y=b, x ¸ 0, y ¸ 0 } – Note: (x,0) 2 Q, x 2 P. Can we find such a point? – Solve the new LP min { § i y i : (x,y) 2 Q } – If the optimal value is 0, then x 2 P. If not, P is empty! – How do we find feasible point for the new LP? (x,y)=(0,b) is a trivial solution!

Pitfalls The simplex method is very simple… …if we can handle a few issues 1.What if there are no vertices? Can modify polyhedron so that it has a vertex. 2.How can I find a starting vertex? Can find a feasible point by solving a different LP. Can move from that feasible point towards a vertex. 3.What are the “neighboring” vertices? 4.Does the algorithm terminate? 5.Does it produce the right answer?

Issue #4 Does the algorithm terminate? This is easy! In every iteration, the algorithm sets x to a new vertex. Note that the objective function strictly improves by moving to the new vertex. So the algorithm cannot have visited that vertex before. Recall from Lecture 10: Every polyhedron has only finitely many vertices. So the algorithm must terminate after finitely many steps.

Pitfalls The simplex method is very simple… …if we can handle a few issues 1.What if there are no vertices? Can modify polyhedron so that it has a vertex. 2.How can I find a starting vertex? Can find a feasible point by solving a different LP. Can move from that feasible point towards a vertex. 3.What are the “neighboring” vertices? 4.Does the algorithm terminate? Yes: objective function increases only finitely many times. 5.Does it produce the right answer?

Edges 0-face (vertex) 1-face (edge) Image: From Lecture 11: Summary: Two vertices are neigboring if the constraints that are tight at both vertices have rank n-1.

Issue #3 What are the “neighboring” vertices? Consider a vertex x. It is also a BFS, so the tight constraints at x have rank n. Choose a subset of these constraints of rank n-1. Consider the set of points for which this subset of constraints are all tight. This is an edge. (By Asst 3, Question 3) Uh oh! If there are t tight constraints at x, then the number of such subsets could be. Enumerating all of these subsets could be very slow. A fix: Add very small “noise” to every entry of the matrix A defining the constraints. Then every vertex has exactly n tight constraints, and at most n edges leaving it.

Issue #3 What are the “neighboring” vertices? x A fix: Add very small “noise” to every entry of the matrix A defining the constraints. Then every vertex has exactly n tight constraints, and at most n edges leaving it. Example: Want only 3 edges leaving x, but there are 5.

Issue #3 What are the “neighboring” vertices? x A fix: Add very small “noise” to every entry of the matrix A defining the constraints. Then every vertex has exactly n tight constraints, and at most n edges leaving it. Example: Want only 3 edges leaving x, but there are 5. If we perturb the constraints slightly, every vertex has only 3 tight constraints and 3 edges.

Issue #3 What are the “neighboring” vertices? A Fix: Add very small “noise” to every entry of the matrix A defining the constraints. Then every vertex has exactly n tight constraints, and at most n edges leaving it. Finding the neighbors: For each edge leaving the vertex Move along edge while remaining in feasible region When a new constraint becomes tight, we’ve arrived at a neighboring vertex If no constraint becomes tight, it’s an unbounded edge Check if the objective function increases when moving along the edge. If so, LP is unbounded.

Pitfalls The simplex method is very simple… …if we can handle a few issues 1.What if there are no vertices? Can modify polyhedron so that it has a vertex. 2.How can I find a starting vertex? Can find a feasible point by solving a different LP. Can move from that feasible point towards a vertex. 3.What are the “neighboring” vertices? Add noise to constraints so that only each vertex has few edges. Find edges by choosing n-1 tight constraints. 4.Does the algorithm terminate? Yes: objective function increases only finitely many times. 5.Does it produce the right answer?

Issue #5 Does algorithm produce the right answer? Yes! If you cannot increase the objective function by moving along any edge leaving x, then x must be optimal. That is very intuitive, but formalizing it takes some work: See Notes for Lecture 20.

Pitfalls The simplex method is very simple… …if we can handle a few issues 1.What if there are no vertices? Can modify polyhedron so that it has a vertex. 2.How can I find a starting vertex? Can find a feasible point by solving a different LP. Can move from that feasible point towards a vertex. 3.What are the “neighboring” vertices? Add noise to constraints so that only each vertex has few edges. Find edges by choosing n-1 tight constraints. 4.Does the algorithm terminate? Yes: objective function increases only finitely many times. 5.Does it produce the right answer? Yes: if no edge increases objective function, x is optimal.

Summary The idea is very simple There are many pitfalls which complicate things. – Main idea to handle complications is to modify P so that it becomes “nice” in various ways. Finding neighbors is conceptually simple, but to formalize it, the notation gets a bit messy. We used Farkas’ Lemma to prove optimality. “The obvious idea of moving along edges from one vertex of a convex polygon to the next” [Dantzig, 1963] Algorithm Let x be any vertex of P For each neighbor y of x If c T y>c T x then Set x=y and go to start Halt