Linear Programming Assignment 3: 1 Chapter 6 (Section 6.4)
Linear Programming Assignment 3: 1 Chapter 6 (Section 6.4)
1.1.1 Solution
Let,
x1 = number of brownies eaten daily
x2 = number of scoops of chocolate ice cream eaten daily
x3 = bottles of cola drunk daily
x4 = pieces of pineapple cheesecake eaten daily
The LP is
min z = 50x1 + 20x2 + 30x3 + 500x4
s.t.
400x1 + 200x2 + 150x3 + 500x4 >= 500
3x1 + 2x2 >= 6
2x1 + 2x2 + 4x3 + 4x4 >= 10
2x1 + 4x2 + x3 + 5x4 >= 8
x1 , x2 , x3 , x4 >= 0
S4
x1
x4
S2
S3
N on Basic variables, XN BV = A1
A2
A3
A4
1
Coef f icient of basic variables in row0, CBV = 20 30 0 0
Coef f icient of non − basic variables in row0, CN BV = 50 80 0 0 M M M M
200 150 −1 0
2 0 0 0
M atrix of basic variables B = 2
4 0 0
4 1 0 −1
400 500 0 0 1 0 0 0
3 0 −1 0 0 1 0 0
M atrix of nonbasic variables N =
2 4 0 −1 0 0 1 0
2 5 0 0 0 0 0 1
500
6
Right − hand side of the constraints b =
8
10
After changing the problem according to the question in basic and a non-basic variable, in row0 the current basis
will remain optimal if the co-efficient of the non-basic variables are non-positive in row0 of the optimal solution. Now,
After changing the problem
Coef f icient of basic variables in row0, CBV = 20 15 0 0
Coef f icient of non − basic variables in row0, CN BV = 50 60 0 0 M M M M
We know that the row0 of the optimal solution = XBV + (CBV B −1 N − CN BV )XN BV = CBV B −1 b
Now,
0 0.5 0 0
0 −0.25 0.25 0
B −1 = −1 62.5 37.5 0
0 1.75 0.25 −1
CBV B −1 N = 26.25
15 −6.25 −3.75 0 6.25 3.75 0
Coefficient of all the non-basic variable in row0 are non-positive.so we can say that the current basis remains
optimal.
New optimal solution = CBV B −1 b = 75
1.2 Exercise 6
The following questions refer to the diet problem:
If 8 oz of chocolate and 60 calories are required, show that the current basis remains optimal.
2
1.2.1 Solution
Since, changing in the right side of a constraint does not effect the row0. Changing aright-hand side cannot cause the
current basis to become sub-optimal.So the current basis will is optimal and will remain feasible if the constants of the
right hand side remains non-negative in the optimal tableau.
After changing the problem,
60
8
Right hand side of the constraints b =
10
8
4
0.5
Right hand side of the constraints of the optimal tableau B −1 b = 815 Since the right hand sides of all the
8.5
equations remain non-negative, so we can say that the current basis remains optimal and feasible.
New optimal solution = CBV B 1 b = 95
x1 + x2 <= 5
2x1 + x2 <= 7
2x2 + x3 >= 6
x1 + x3 = 4
x1, x2 , x3 >= 0
2.1.1 Solution
Standard Form:
max z = 4x1 − x2 + 2x3
s.t.
x1 + x2 <= 5
2x1 + x2 <= 7
− 2x2 − x3 <= −6
x1 + x3 <= 4
−x1 − x3 <= −4
x1, x2 , x3 >= 0
dual of this LP is :
y1 + 2y2 + y4 − y5 >= 4
y1 + y2 − 2y3 >= −1
− y3 + y4 + y5 >= 2
y1 , y2 , y3 , y4 , y5 >= 0
3
2.2 Exercise 4
Find the duals of the following LPs:
y1 + 2y2 <= 6
y1 − y2 + 2y3 = 8
y1 , y2 , y3 >= 0
2.2.1 Solution
Standard Form:
min w = 4y1 + 2y2 − y3
s.t.
dual of this LP is :
−x1 + x2 − x3 <= 4
−2x1 − x2 + x3 <= 2
+ 2x2 − 2x3 <= −1
x1, x2 , x3 >= 0