Lecture 4 Linear Programming Models: Standard Form

Lecture 4
Linear Programming Models:
Standard Form
August 31, 2009
Lecture 4
Outline:
• Standard form LP
• Transforming the LP problem to standard form
• Basic solutions of standard LP problem
Operations Research Methods
1
Lecture 4
Why Standard Form?
• The simplex method had proven to be the most efficient (practical)
solver of LP problems
• The implementation of simplex method requires the LP problem in
standard form
Operations Research Methods
2
Lecture 4
What is the Standard Form
• It is the LP model with the specific form of the constraints:
max (or min)
subject to
z = c 1 x1 + c 2 x2 + · · · c n xn
a11x1 + a12x2 + · · · + a1nxn = b1
a21x1 + a22x2 + · · · + a2nxn = b2
..
am1x1 + am2x2 + · · · + amnxn = bm
x1 ≥ 0, x2 ≥ 0, . . . , xn ≥ 0
• m equalities and n nonnegativity constraints with m ≤ n
Operations Research Methods
3
Lecture 4
Bringing an LP to its Standard Form
• The inequality ≥
Introduce a surplus variable
• The inequality ≤
Introduce a slack variable
NOTE: The cost of surplus and slack variables is zero
• Unrestricted variable in sign:
Replace it with a difference of two new variables
• All new variables have to be nonnegative
Operations Research Methods
4
Lecture 4
Example
minimize z = 3x1 + 8x2 + 4x3
subject to
x1 + x2 ≥ 8
2x1 − 3x2 ≤ 0
x2 ≥ 9
x1 , x 2 ≥ 0
Operations Research Methods
5
Lecture 4
Its standard form:
minimize z = 3x1 + 8x2 + 4x7 − 4x8
subject to
x1 + x2 − x4 = 8
2x1 − 3x2 + x5 = 0
x2 − x6 = 9
x1 , x 2 , x 4 , x 5 , x 6 , x 7 , x 8 ≥ 0
x3 is substituted out of the problem
We have: m = 3 and n = 7
Operations Research Methods
6
Lecture 4
What are Basic Solutions? Illustration on Reddy Mikks’ Constraint set
Basic solutions are the corner points
Operations Research Methods
7
Lecture 4
What are the basic solutions?
• For a problem in the standard form a basic solution is a point
x̄ = (x̄1, . . . , x̄n) that has at least n − m coordinates equal to 0,
and satisfies all the equality constraints of the problem
a11x̄1 + a12x̄2 + · · · + a1nx̄n = b1
a21x̄1 + a22x̄2 + · · · + a2nx̄n = b2
..
am1x̄1 + am2x̄2 + · · · + amnx̄n = bm
• If the point x̄ has all components nonnegative, i.e., x̄i ≥ 0 for all i, then
x̄ is a basic feasible solution
• Otherwise, (i.e., if x̄j < 0 for some index j ), x̄ is basic infeasible
solution
Operations Research Methods
8
Lecture 4
How to find the basic solutions algebraically
• If the problem is not in standard form, bring it to the standard form
• Basic solutions are determined from the standard form as follows:
• Select n − m out of n nonnegative inequalities (coordinate indices) i,
xi ≥ 0, i = 1, . . . , m and set them to zero
xj = 0
for a total of n − m indices j
(nonbasic variables)
• Substitute these zero values in the equalities:
we have m unknown variables an m equalities
• Solve this m×m system of equations: we obtain values for the remaining
m variables (basic variables)
• If these m (basic) variables are nonnegative, we have a basic feasible
solution; otherwise, a basic infeasible solution
Operations Research Methods
9
Lecture 4
Example Reddy Mikks Problem
Original LP formulation
maximize z = 5x1 + 4x2
subject to 6x1 + 4x2 ≤ 24
x1 + 2x2 ≤ 6
x1 , x 2 ≥ 0
Standard LP form
maximize z = 5x1 + 4x2
subject to 6x1 + 4x2 + x3 = 24
x1 + 2x2 + x4 = 6
x1 , x 2 , x 3 , x 4 ≥ 0
• We have m = 2 and n = 4
Thus, when determining the basic solutions, we set 2 indices to zero
• Suppose we choose indices {1, 2} and set x1 = 0 and x2 = 0
• Substituting these in the equations yields: x3 = 24 and x4 = 6
• Corresponding basic solution is x = (0, 0, 24, 6) and it is a basic
feasible solution
• In this solution, x1 and x2 are nonbasic variables, while x3 and x4 are
basic variables
Operations Research Methods
10
Lecture 4
Determining an optimal solution by exhaustive search
• From the LP theory (take course IE 411), and optimal value of an LP
problem is always attained at a corner point
• Thus, we can find the optimal value and an optimal solution by
• Generating a list of all basic solutions
• Crossing out infeasible solutions
• Computing the objective value for each feasible solution
• Choosing the basic feasible solutions with the best value (min or max)
Operations Research Methods
11
Lecture 4
Example: Reddy Mikks case
Basic Variables Basic Solution Feasibility Status Objective Value
x1 , x 2
3, 1.5
Feasible
21
x1 , x 3
6, −12
Infeasible
XXX
x1 , x 4
4, 0
Feasible
20
x2 , x 3
3, 12
Feasible
15
x2 , x 4
6, −6
Infeasible
XXX
x3 , x 4
24, 6
Feasible
0
• Thus, the optimal solution is x1 = 3, x2 = 1.5, x3 = 0, and x4 = 0
and the optimal value is z = 21.
• In this case, we have only one solution
• Map each of the basic solutions to the corner point in the plot of the
Reddy Mikks Constraint Set
Operations Research Methods
12
Lecture 4
Reddy Mikks: Objective & Optimal Solution
Objective z = 5x1 + 4x2 to be maximized
Operations Research Methods
13
Lecture 4
Search Bottleneck: Large number of the basic solutions
• Blind search can be time consuming (inefficient)
• Given an LP in the standard form with m equations and n variables,
there are
n(n − 1)(n − 2) · · · (n − m + 1)
m!
many basic solutions
• Say m = 4 and n = 8, then there are 70 solutions
• It is hard to “manually” list them all and find the best
• We will use a more efficient method (simplex method) to perform a
“smarter” search (selectively moving to a better point)
Operations Research Methods
14