You are on page 1of 4

MATH39011

Mathematical Programming I
SOLUTIONS to Examples 2
1. min x
1
x
2
s
1
-1 2 10
s
2
5 3 41
s
3
2 -3 8
z 1 -1 0
min s
3
x
2
s
1
1
2
1
2
14
s
2

5
2
21
2
21
x
1
1
2

3
2
4
z
1
2
1
2
-4
min s
3
s
2
s
1
13
x
2
2
x
1
7
z
8
21

1
21
-5
n.b. It is unnecessary to calculate remaining tableau entries
so x

= (7; 2) with z
min
= 5.
2. min x
1
x
2
x
3
s
1
1 1 2 6
s
2
1 4 -1 4
z -2 -1 1 0
min x
1
x
2
s
1
x
3
3
s
2
7
z
5
2

3
2

1
2
-3
x

= (0; 0; 3) with z
min
= 3
max x
1
x
2
x
3
s
1
1 1 2 6
s
2
1 4 -1 4
z -2 -1 1 0
max s
2
x
2
x
3
s
1
-1 -3 3 2
x
1
1 4 -1 4
z -2 7 -1 8
max s
2
x
2
s
1
x
3
2
3
x
1
14
3
z
5
3
6
1
3
8
2
3
x

=

14
3
; 0;
2
3

with z
max
= 8
2
3
After the rst constraint is modied, both min and max problems are unbounded :
Tableau for min problem is
min x
1
x
2
x
3
s
1
1 1 -2 6
s
2
1 4 -1 4
z -2 -1 1 0
Pivot column q is x
3
but we cannot pivot further because y
iq
0; 8i:
For the maximization problem, the tableaux are
max x
1
x
2
x
3
s
1
1 1 -2 6
s
2
1 4 -1 4
z -2 -1 1 0
max s
2
x
2
x
3
s
1
-1 -3 -1 2
x
1
1 4 -1 4
z 2 7 -1 8
Again the unboundedness condition is seen in x
3
column.
We can show the unboundedness explicitly. If we keep s
2
= x
2
= 0 then the nal tableau represents
s
1
x
3
= 2
x
1
x
3
= 4
1
Let x
3
= then x
1
= 4 + and s
1
= 2 + remain feasible as " without bound. The objective
function 2x
1
+ x
2
x
3
= + 8 is also seen to be unbounded above.
3. The problem is slightly more interesting (only because x

2
becomes negative) if we state it as
minimize z = x
1
3x
2
+ 4x
3
subject to x
1
2x
2
+ x
3
= 5
2x
1
3x
2
+ x
3
= 6
x
1
0; x
3
0
with x
2
unrestricted in sign. We now anticipate the optimal solution to be x

= (0; 1; 3) with
z
min
= 15: Introduce the articial variables (AVs) R
1
; R
2
: The Phase 1 problem is stated as
minimize r = R
1
+ R
2
subject to x
1
2 (u
2
v
2
) + x
3
+ R
1
= 5
2x
1
3 (u
2
v
2
) + x
3
+ R
2
= 6
x
1
; u
2
; v
2
; x
3
; R
1
; R
2
0
and the original problem has a BFS if and only if r
min
= 0. The tableaux are
min x
1
u
2
v
2
x
3
R
1
1 -2 2 1 5
R
2
2 -3 3 1 6
r 3 -5 5 2 11
min x
1
u
2
R
2
x
3
R
1

1
3
0
1
3
1
v
2
2
3
1
1
3
2
r
1
3
0
1
3
1
min x
1
u
2
R
2
R
1
x
3
1 0 3
v
2
1 1 1
r 0 0 0
which corresponds to x = (0; 1; 3) :
The nal tableau above is optimal for Phase 1 and all AVs have left the basis giving z
min
= 0: We
now recompute the bottom row using the problems objective function.
1 -3
min x
1
u
2
4 x
3
1 0 3
3 v
2
1 1 1
z 2 0 15
No further pivots are necessary in this case as the tableau is optimal. The optimal solution is therefore
x

= (0; 1; 3) with z
min
= 15:
4. Initial reduced tableau is
max x
1
x
2
x
3
x
3
x
5
b
s
1
*1 3 5 6 3 90
z -5 6 -3 5 -12 0
Pivot in the x
1
column. This is not Dantzigs rule as in standard simplex procedure which gives x
5
as the pivot column. However there is no reason why we shouldnt pivot using the x
1
column since
we have reasoned in Sheet 1 that the optimal solution should be to ll the knapsack with as much as
possible of x
1
: This leads to the following tableau which is seen to be optimal:
max s
1
x
2
x
3
x
3
x
5
b
x
1
1 3 5 6 3 90
z 5 21 22 35 3 450
2
5. This question is dealt with in my notes. Since c
T
x

1
= c
T
x

2
= z

any linear combination of x

1
; x

2
will
also have value z

as
c
T
[x

1
+ (1 ) x

2
] = c
T
x

1
+ (1 ) c
T
x

2
= z

Provided 0 < < 1; such a linear combination will be convex and hence feasible since the feasible
region is convex. Therefore all points on a line joining two vertices (extreme points of the FR) will
also be feasible and optimal. This extends naturally to the convex linear combination of two or more
optimal vertices

1
x

1
+
2
x

2
+ ::: +
k
x

k
6. In standard form the constraints are Ax = b where x
T
= (x
1
; x
2
; x
3
; s
2
; s
3
) and s
2
; s
3
are surplus and
slack variables for constraints 2 and 3
A =
2
4
1 1 1 0 0
1 1 0 1 0
1 3 1 0 1
3
5
The proposed BFS is x
T
= (6; 0; 4; 5; 0) implying that columns A
1
; A
3
; A
4
corresponding to x
1
; x
3
; s
2
form the basis matrix B: However
B =
2
4
1 1 0
1 0 1
1 1 0
3
5
is singular. (Row 1=Row 3 and jBj = 0 ) therefore (6; 0; 4; 5; 0) is not a BFS, nor can it be an
extreme point. Notice that By = 0 where y = (1; 1; 1)
T
and correspondingly we see that x
T
=
(6 + "; 0; 4 "; 5 + "; 0) is feasible for small +ve or -ve values of ": This again shows that (6; 0; 4; 5; 0)
is not an extreme point.
7. The substitutions
x = u
1
v
1
; y = u
2
v
2
; z = u
3
v
3
result in the formulation
minimize u
1
+ v
1
+ u
2
+ v
2
+ u
3
+ v
3
subject to u
1
v
1
+ u
2
v
2
+ s
1
= 1
2u
1
2v
1
+ u
3
v
3
= 3
all variables 0
The constraint matrix corresponding to
x
T
= (u
1
; v
1
; u
2
; v
2
; u
3
; v
3
; s
1
) is
A =

1 1 1 1 0 0 1
2 2 0 0 1 1 0

Observe that A
2
= A
1
; A
4
= A
3
; A
6
= A
5
showing it is impossible for, say, A
1
and A
2
to be in a
basis B simultaneously since A
1
+ A
2
= 0 ) they are linearly dependent and B would be singular.
We could use articial variables (i.e. Two Phase method) to obtain an initial BFS, but here a basis is
available using u
3
and s
1
since the corresponding columns of A form the identity matrix I
2
:
T1 u
1
v
1
u
2
v
2
v
3
s
1
*1 -1 1 -1 0 1
u
3
2 -2 0 0 -1 3
1 -3 -1 -1 -2 3
A single pivot (* denotes pivot element) leads to an optimal tableau T2.
T2 s
1
v
1
u
2
v
2
v
3
u
1
1 -1 1 -1 0 1
u
3
-2 0 -2 *2 -1 1
-1 -2 -2 0 -2 2
3
Some z
j
c
j
= 0 indicates that an alternative optimal solution might be present with the same value
as z = z
0

(z
q
c
q
) x
p
y
pq
= z
0
:
After one pivot we nd (T3)
T3 s
1
v
1
u
2
u
3
v
3
u
1
0 -1 0
1
2

1
2
3
2
v
2
1 0 1 *
1
2

1
2
1
2
-1 -2 -2 0 -2 2
The general solution may be written (x; y; z) = (1 + "; "; 1 2") for 0 "
1
2
(from direct logical
arguments) which are all convex linear combinations of the two extreme points (1; 0; 1) and

3
2
;
1
2
; 0

given in T2 and T3. To see this explicitly:


(1; 0; 1) + (1 )

3
2
;
1
2
; 0

=

3
2

1
2
;
1
2
+
1
2
;

= (1 + "; "; 1 2")


if " =
1
2
(1 ) :
8. Formulation of the bakers problem with x
2
= amount of our bought in
maximize 30x
1
4x
2
subject to 5x
1
30 + x
2
x
1
5
x
1
0; x
2
u.r.s.
Let x
2
= u
2
v
2
with u; v 0 and convert to standard form
maximize 30x
1
4u + 4v
subject to 5x
1
u + v + s
1
= 30
x
1
+ s
2
= 5
x
1
; u; v; s
1
; s
2
0
Corresponding tableaux are
x
1
u v
s
1
5 1 1 30
s
2

1 0 0 5
30 4 4 0
s
2
u v
s
1
5 1

1 5
x
1
1 0 0 5
30 4 4 150
s
2
u s
1
v 5 1 1 5
x
1
1 0 0 5
10 0 4 170
so the baker should bake 5 loaves and sell 5 oz. of remaining our.
When the baker has 8 oz. of yeast the corresponding tableaux are
x
1
u v
s
1

5 1 1 30
s
2
1 0 0 8
30 4 4 0
s
1
u v
x
1
1
5

1
5
1
5
6
s
2

1
5
1
5

1
5
2
6 2 2 180
s
1
s
2
s
1
x
1
0 1 0 8
u 1 5 1 10
4 10 0 200
so the baker should bake 8 loaves and purchase 10 oz. of our.
4

You might also like