Professional Documents
Culture Documents
Facts: 1. To start, we need a canonical form 2. If we have a constraint with a nonnegative right-hand side, it will contain an obvious basic variable (which?) after introducing a slack var. 3. If we have an equality constraint, it contains no obvious basic variable 4. If we have a constraint with a nonnegative right-hand side, it contains no obvious basic variable even after introducing a surplus var.
1
2008 MGS
Compare!
2x + 3y 5 2x + 3y + s = 5, s 0 (s basic)
2x + 3y = 5 ??????? Infeasible if x=y=0!
2008 MGS
One Equality???
2x + 3y = 5 2x + 3y + a = 5, a = 0 (E) (a is basic, but it should be 0!)
2008 MGS
One Equality???
2x + 3y = 5 2x + 3y + a = 5, a = 0 (E) (a basic, but it should be 0!) How do we force a = 0? This is of course not feasible if x=y=0, as 0+0+0 5
Idea: solve a first problem with Min {a | constraint (E) + a 0 + other constraints }!
4
2008 MGS
Artificial Variables
Notice: In an equality constraint, the extra variable is called an artificial variable. For instance, in 2x + 3y + a = 5, a = 0 a is an artificial variable.
(E)
2008 MGS
2008 MGS
2008 MGS
2008 MGS
Artificial Variables
Notice: In a inequality constraint, the extra variable a is called an artificial variable. For instance, in 2x + 3y s + a = 5, s 0, a 0 (E) a is an artificial variable.
In a sense, we allow temporarily a small amount of cheating, but in the end we cannot allow it!
9
2008 MGS
2008 MGS
Then What?
We have two objectives: Get a feasible canonical form Maximize our original problem Two methods: 2-phase method (phase 1, then phase 2) big M method
11
2008 MGS
2-Phase Method
Phase I: find a BFS Minimize the sum of the artificial variables If min = 0, we have found a BFS If min > 0, then we cannot find a solution without cheating the original problem is infeasible Phase 2: solve original LP Start from the phase 1 BFS, and maximize the original objective function.
12
2008 MGS
Big-M Method
Combine both objectives : (1) Min i ai (2) Max j cj xj into a single one: (3) Max M i ai + j cj xj where M is a large number, larger than anything subtracted from it. If one minimizes j cj xj then the combined objective function is Min M i ai + j cj xj
13
2008 MGS
The simplex method algorithm requires a starting bfs. Previous problems have found starting bfs by using the slack variables as our basic variables. If an LP have or = constraints, however, a starting bfs may not be readily apparent. In such a case, the Big M method may be used to solve the problem. Consider the following problem.
14
2003 Brooks/Cole
Example
Bevco manufactures an orange-flavored soft drink called Oranj by combining orange soda and orange juice. Each orange soda contains
2003 Brooks/Cole
x1
x2
16
20 = 10 0
17
2003 Brooks/Cole
- s2 = 20 = 10
In order to use the simplex method, a bfs is needed. To remedy the predicament, artificial variables are created. The variables will be labeled according to the row in which they are used as seen below. The basic variables are in red: Row 1:-z + 2x1 + 3x2 =0
Row 2:
Row 3: Row 4:
18
0.5x1 + 0.25x2 + s1
x1 + x1 + 3x2 x2 - s2 + a2
= 4
= 20 + a3 = 10 2003 Brooks/Cole
Row 0 1 2 3
z -1.00
s1 1.00
e2
a2 M 1.00
a3 M
-1.00
1.00
2003 Brooks/Cole
z 1.00
z 1.00
e2 a2 (M-3)/3 (3-4M)/3
z 1.00
e2 a2 (M-3)/3 (3-4M)/3 0.08 -0.08 -0.33 0.33 e2 a2 (M-3)/3 (3-4M)/3 0.08 -0.08 -0.33 0.33 0.33 -0.33
z 1.00
s1 1.00
1.00 a3
ero
1.00
Row 3 - Row 2
z 1.00
z 1.00
z 1.00
z 1.00
ero
Optimal Solution
Row 2 -(1/3)*Row 3