or-1 20101 chapter 8. general lp problems converting other forms to general lp problem : min c’x ...
TRANSCRIPT
OR-1 2010 1
Chapter 8. General LP Problems
njuxl
mibxa
xc
jjj
nj ijij
nj jj
,...,1 ,
,...,1 ,1
1
max max
uxl
bAx
xc
'
jj ul
variableted)(unrestric free :, with jjj ulx
Converting other forms to general LP problem :min c’x - max (-c)’x = by adding a nonnegative slack variable = by subtracting a nonnegative surplus variable
jjjjjj xxxxxx freefor ,0, ,
ation transform theusenot do that weNote
OR-1 2010 2
Note that the standard problem, augmented with slack variables, is a special case of the general LP with lower bounds 0 and upper bounds +.
Def: Basic solution x* : Partition the components of x* into m basic and n-m nonbasic variables such that
1) m columns of A corresponding to basic variables are linearly independent
2)
( For free variable, no restriction. But usually 0 is used in the algorithm)
(Note that the choice of basic variables does not determine a basic solution as the standard LP case. Upper and lower bound for nonbasic bounded variables must be determined too.)
Def: A basic solution x* is called feasible if l x* u.
variablesnonbasic boundedeach for or *jjj ulx
OR-1 2010 3
Modification of the simplex method to handle the general LP directly :
Given a b.f.s. , choose an entering nonbasic variable. Then change (increase or decrease depending on the status of the entering nonbasic variable) the value of the entering nonbasic variable while other nonbasic variables are fixed at current values. Then the value of the basic variables must be changed to satisfy the equations Ax = b.
Change the value of the entering variable while the value of the basic variables satisfy the bound constraints.
If one of the basic variables attains lower or upper bound values, let it become the nonbasic variable.
The entering variable becomes basic.
Update the dictionary (tableau). Here, we searches only the extreme points of the polyhedron if we do
not have a free nonbasic variable.
OR-1 2010 4
Suppose we have a b.f.s. x* = (xB*, xN
* ) and corresponding
dictionary (dictionary form not affected by the bound constr)
Note that xB* may not be equal to B-1b and the objective value of
the current solution may not be equal to y’b.
Candidates for entering nonbasic variable : 2 cases
Nj jjB
Nj jjj
xABbBx
xAycbyz
)(
)'('
11
) increases valueobjective and increasecan (
,0)'()1( *
j
jjjj
x
NjuxandAyc
) increases valueobjective and decreasecan (
,0)'()2( *
j
jjjj
x
NjlxandAyc
OR-1 2010 5
Suppose xj is selected as the entering nonbasic variable.
Let
while other nonbasic variables are fixed at the current values.
Then the values of basic variables must change to
and so that the new solution satisfy the equations.
Let t* be the largest t such that
New solution obtained :
0,** ttxortxx jjj
))(())(( 1*1* tABxortABxx jBjBB
tAycxcz jj )'(' *
BjBB utABxl ))(( 1*
** txx jj ))(( *1* tABxx jBB
** )'(' tAycxcz jj
jjj utxl *
OR-1 2010 6
( continued )
If the bound on the entering nonbasic variable becomes tight first when we change the value of the entering variable the entering nonbasic variable changes the bound status (at lower bound at upper bound) but still remains nonbasic.
Otherwise, at least one of the basic variables takes on value of upper or lower bound. The variable becomes nonbasic and the entering nonbasic variable becomes basic as in the ordinary simplex method.
A degenerate solution is defined as the b.f.s. such that at least one of the basic variables has the value equal to the bound.
( in that case, t* may be zero, in which case only basis change occurs. But solution does not change. )
OR-1 2010 7
c = [ 2, 1, -2, -2, 3, 2, 3, -4, 0, -2, -3, 3 ]T
l = [ -5, -, -4, -2, 2, 0, 0, 3, -, -, -, - ]T
u = [ +, 3, -2, 3, 5, 1, +, +, 0, 5, +, + ]T
Example
Maximize c’x, subject to Ax = b, l x u.
197872185901
546743496513A
62
72b
Let x1, x2 be basic variables. Then the following x* is a basic feasible solution.
x* = [ 1 0 -2 3 2 0 0 3 0 5 -1 1 ]
OR-1 2010 8
We first find y vector from y’B = cB’
1201
13'
y 11' y
.6)8 ( ,0)'( * NjuxandAyc jjjj
.7)8 ( ,0)'( * NjlxandAyc jjjj
Next, check whether any nonbasic variable satisfies the following conditions.
Satisfying (8.6) x5, x7, x11
Satisfying (8.7) x4, x10, x12
Suppose we choose x5 as the entering nonbasic variable.
OR-1 2010 9
Find d vector from Bd = Aj
8
9
01
13d
15
8d
Find t in xj(t) = xj* + t
For entering variable x5 , 2 2 + t 5
For basic variable x1 , -5 1 – 8 t
For basic variable x2 , 15 t 3
t 0.2 and x2 reaches its upper bound, hence leaves basis.
New basic solution is
x* = [ -0.6 3 -2 3 2.2 0 0 3 0 5 -1 1 ]
x1 and x5 are basic variables.
( compare, x* = [ 1 0 -2 3 2 0 0 3 0 5 -1 1 ] )
OR-1 2010 10
Current dictionary when x1, x2 basic:
z = 10 + 2x3 - 3x4 + 2x5 - x6 + 2x7 - x8 + x9 - x10 + 2x11 - x12
x1 = 62 - 9x3 - 5x4 - 8x5 - x6 - 2x7 - 7x8 - 8x9 - 7x10 - 9x11 - x12
x2 = -114 + 22x3 +9x4 + 15x5 - x6 + 3x7 + 17x8 + 17x9 + 15x10 + 23x11 - 2x12
Nj jjB
Nj jjj
xABbBx
xAycbyz
)(
)'('
11
l = [ -5, -, -4, -2, 2, 0, 0, 3, -, -, -, - ]T
u = [ +, 3, -2, 3, 5, 1, +, +, 0, 5, +, + ]T
x1* = 1, x2* = 0 (x5 entering nonbasic, increasing)
x1* 1 – 8t , x2* 0 + 15t , x5* 2 + t ,
- 5 1 – 8t + , - 0 + 15t 3 , 2 2 + t 5 t 0.2
OR-1 2010 11
Remarks
Note that a free nonbasic variable can always be a candidate for entering variable as long as
(Although , we may let it enter the basis without changing the objective value)
Moreover, a free basic variable never become nonbasic in subsequent iterations. (There are no bounds for free variables)
Hence we may let all free variables become basic in early iterations and let them remain basic in subsequent iterations.
In commercial software, simplex algorithm for general LP is used. (also called bounded variable simplex method)
Convenient to use when we want to solve the problem again with a little bit of data change (e.g. fix the values of the variables, change the bounds, etc. )
0)'( jj Ayc
0)'( jj Ayc
OR-1 2010 12
Two-phase simplex method
Need initial b.f.s. to apply the simplex method for general LP
Use idea similar to the one we used earlier for standard LP
njuxl
mibxa
xc
jjj
nj ijij
nj jj
,...,1 ,
,...,1 ,1
1
max
(8.9)
Introduce artificial variables xn+1, xn+2 , … xn+m
),...,1( ,
),...,1( ,1
mnjuxl
mibxxa
jjj
nj iinjij
For the above problem, we can find an initial b.f.s. easily and (8.9) has a feasible solution if and only if (8.10) has a solution with all artificial variables 0.
(8.10)
OR-1 2010 13
Let
Set
Now set the bounds for artificial variables
Above solution is a b.f.s. to (8.10).
Also let
and consider minimize
njxuxlx jjjjj ,...,1, variableboundedevery for ~or ~
njxx jj ,...,1, variablefreeevery for 0~
nj jijiin mixabx 1 ,...,2,1 allfor ~~
ininin ulx ,0set ,0~ If
0,set ,0~ If ininin ulx
0 if 1 and 0 if 1 inininin uwlw
(8.10) subject to ,1 mi inin xw
OR-1 2010 14
For all feasible solutions to (8.10), we have
If the optimal value of the auxiliary problem is > 0, the problem is infeasible.
If the optimal value is equal to 0, all xn+i = 0, i =1,…, m, hence the
solution xj , j = 1, …, n is feasible to (8.9).
We restore the original objective function and solve the following problem after resetting the bounds on the artificial variables to 0.
Note that the solution we have at the end of phase one is a b.f.s.
01 mi inin xw
),...,2,1( 00
),...,2,1(
),...,2,1( 1
1
mix
njuxl
mibxxa
xc
in
jjj
nj iinjij
nj jj
max
OR-1 2010 15
Remarks
At the end of phase one, the artificial variables which are nonbasic (hence have value 0) can be dropped before phase two is applied.
Artificial variables which are basic cannot be dropped since we need m basic variables to denote a basic solution. However, the procedure given in p130 replaces each artificial basic variable in the basis by an original variable which is nonbasic.
If the procedure fails to replace an artificial basic variable, it indicates that the constraint to which the artificial variable is attached is a redundant equation, hence the equation can be removed from the formulation and the feasible solution set is not changed. (Also the artificial variable can be dropped from the basis and eliminated from the formulation)