linear programming piyush kumar. graphing 2-dimensional lps example 1: x 3 012 y 0 1 2 4 3 feasible...
TRANSCRIPT
![Page 1: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/1.jpg)
Linear Programming
Piyush Kumar
![Page 2: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/2.jpg)
Graphing 2-Dimensional LPs
Example 1:
x30 1 2
y
0
1
2
4
3
Feasible Region
x 0 y 0
x + 2 y 2
y 4
x 3
Subject to:
Maximize x + y
Optimal Solution
These LP animations were created by Keely Crowston.
![Page 3: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/3.jpg)
Graphing 2-Dimensional LPs
Example 2:
Feasible Region
x 0 y 0
-2 x + 2 y 4
x 3
Subject to:
Minimize ** x - y
Multiple Optimal
Solutions!4
1
x31 2
y
0
2
0
3
1/3 x + y 4
![Page 4: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/4.jpg)
Graphing 2-Dimensional LPs
Example 3:
Feasible Region
x 0y 0
x + y 20
x 5
-2 x + 5 y 150
Subject to:
Minimize x + 1/3 y
Optimal Solution
x
3010 20
y
0
10
20
40
0
30
40
![Page 5: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/5.jpg)
y
x0
1
2
3
4
0 1 2
3
x3010 20
y
0
10
20
40
0
30
40
Do We Notice Anything From These 3 Examples?
x
y
0
1
2
3
4
0 1 2
3
Extreme point
![Page 6: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/6.jpg)
A Fundamental Point
If an optimal solution exists, there is always a corner point optimal solution!
y
x0
1
2
3
4
0 1 2
3
x3010 20
y
0
10
20
40
0
30
40x
y
0
1
2
3
4
0 1 2
3
![Page 7: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/7.jpg)
Graphing 2-Dimensional LPs
Example 1:
x30 1 2
y
0
1
2
4
3
Feasible Region
x 0y 0
x + 2 y 2
y 4
x 3
Subject to:
Maximize x + y
Optimal Solution
Initial Corner pt.
Second Corner pt.
![Page 8: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/8.jpg)
And We Can Extend this to Higher Dimensions
![Page 9: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/9.jpg)
Then How Might We Solve an LP?
The constraints of an LP give rise to a geometrical shape - we call it a polyhedron.
If we can determine all the corner points of the polyhedron, then we can calculate the objective value at these points and take the best one as our optimal solution.
The Simplex Method intelligently moves from corner to corner until it can prove that it has found the optimal solution.
![Page 10: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/10.jpg)
Linear Programs in higher dimensions
maximize z = -4x1 + x2 - x3
subject to -7x1 + 5x2 + x3 <= 8
-2x1 + 4x2 + 2x3 <= 10
x1, x2, x3 0
![Page 11: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/11.jpg)
In Matrix terms
Max
subject to
Tc x
Ax b
1 1, ,n dA c xx dx dx
![Page 12: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/12.jpg)
LP Geometry
Forms a d dimensional polyhedron
Is convex : If z1 and z2 are two feasible solutions then λz1+ (1- λ)z2 is also feasible.Extreme points can not be written as a convex combination of two feasible points.
![Page 13: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/13.jpg)
LP Geometry
Extreme point theorem: If there exists an optimal solution to an LP Problem, then there exists one extreme point where the optimum is achieved. Local optimum = Global Optimum
![Page 14: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/14.jpg)
LP: AlgorithmsSimplex. (Dantzig 1947) Developed shortly after WWII in response to logistical
problems:used for 1948 Berlin airlift.
Practical solution method that moves from one extreme point to a neighboring extreme point.
Finite (exponential) complexity, but no polynomial implementation known.
Courtesy Kevin Wayne
![Page 15: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/15.jpg)
LP: Polynomial Algorithms
Ellipsoid. (Khachian 1979, 1980) Solvable in polynomial time: O(n4 L) bit operations.
o n = # variables o L = # bits in input
Theoretical tour de force. Not remotely practical.
Karmarkar's algorithm. (Karmarkar 1984) O(n3.5 L). Polynomial and reasonably efficient
implementations possible.
Interior point algorithms. O(n3 L). Competitive with simplex!
o Dominates on simplex for large problems. Extends to even more general problems.
![Page 16: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/16.jpg)
LP: The 2D case
1 2 n
, ,
Let's suppose we are given n linear inequalities h ,h ,..., h
:i i x i y ih a x a y b
Wlog, we can assume that c=(0,-1). So now we want to find theExtreme point with the smallest y coordinate.
Lets also assume, no degeneracies, the solution is given by twoHalfplanes intersecting at a point.
![Page 17: Linear Programming Piyush Kumar. Graphing 2-Dimensional LPs Example 1: x 3 012 y 0 1 2 4 3 Feasible Region x 0y 0 x + 2 y 2 y 4 x 3 Subject](https://reader035.vdocument.in/reader035/viewer/2022062801/56649e605503460f94b5b9a5/html5/thumbnails/17.jpg)
Incremental Algorithm?
How would it work to solve a 2D LP Problem? How much time would it take in the worst case? Can we do better?