Sei sulla pagina 1di 150

Lecture 1d:

TWO ARTIFICIAL VARIABLE TECHNIQUES


Jeff Chak-Fu WONG
Department of Mathematics
Chinese University of Hong Kong

jwongmath. uhk.edu.hk

MAT581SS
Mathematics for Logistics
Produced by Jeff Chak-Fu WONG

ABLE OF

TABLE OF C ONTENTS
1. GRAPHICAL SOLUTIONS TO A LINEAR PROGRAMMING PROBLEM
2. SIMPLEX METHOD
3. ARTIFICIAL VARIABLE TECHNIQUE
(a) The Big M method
(b) The Two-phase simplex method
4. VARIANTS OF SIMPLEX METHOD

C ONTENTS

ARTIFICIAL VARIABLE TECHNIQUE

ARTIFICIAL VARIABLE TECHNIQUE

The last lecture dealt with LPPs with less than or equal () type
constraints.
This property together with the fact that the right-hand side of
all the constraints is non-negative, i.e.,
b0
provides us with a ready starting basic feasible solution that
comprises of all slack variables.
There are however, many linear programming problems for
which mere slack variables cannot provide such a solution.

ARTIFICIAL VARIABLE TECHNIQUE

For those, we accomplish by adding artificial variables which


play the role of slack variables.
However, since such artificial variables have no physical
meaning in the original model (hence the name artificial),
provisions must be made to make them zero level at the
optimum iteration.
In other words, we
use them to start the solution, and
abandon them once their work has been over.
A logical way to achieve this objective is to penalise the
artificial variables in the objective function.

ARTIFICIAL VARIABLE TECHNIQUE

Two (closely related) networks based on the use of penalties are


available to solve this type of LPP.

They are:
1. Big M method or method of penalty due to A. Charnes
2. The Two-phase simplex method due to Dantzig, Orden and
Wolfe.

ARTIFICIAL VARIABLE TECHNIQUE

T HE B IG M M ETHOD
Step 1:
Convert the LPP into maximisation form.
Express it in the standard form by introducing slack and/or
surplus variables as the case may be.

HE

B IG M M ETHOD

Step 2:
Introduce non-negative variables to the left-hand side of all the
constraints of ( or =) type.
These variables are called artificial variables.
The purpose of introducing artificial variables is just to obtain
an initial basic feasible solution.
In order to get rid of the artificial variables in the final optimum
iteration, we assign a very large penalty M to these artificial
variables in the objective function for maximisation objective
function.

HE

B IG M M ETHOD

Step 3:
Solve the modified linear programming problem by simplex
method.
While making iterations by this method, one of the following
three cases may arise.

HE

B IG M M ETHOD

(a) If no artificial variable remains in the basis and the optimality


condition is satisfied, then the current solution is an optimal
basic feasible solution.
(b) If at least one artificial variable appears in the basis at zero
level (with zero value in the XB column) and the optimality
condition is satisfied, then the current solution is an optimal
basic feasible (though degenerated) solution.
(c)
If at least one artificial variable appears in the basis at
non-zero level (with positive value in XB column) and the
optimality condition is satisfied, then the original problem has
no feasible solution.
The solution satisfies the constraints but does not optimise the
objective function since it contains a very large penalty M
and is called pseudo optimal solution.
HE

B IG M M ETHOD

10

XB

y1

y2

yj

yn

x1

x2

xj

xn

(z1 c1 )

(z2 c2 )

(zj cj )

(zn cn )

xB1
xB2
.
.
.
xBr
.
.
.
xBm
z(XB )

HE

B IG M M ETHOD

11

(a) If no artificial variable remains in the basis and the optimality


condition is satisfied, then the current solution is an optimal
basic feasible solution.
(b) If at least one artificial variable appears in the basis at zero
level (with zero value in the XB column) and the optimality
condition is satisfied, then the current solution is an optimal
basic feasible (though degenerated) solution.
(c)
If at least one artificial variable appears in the basis at
non-zero level (with positive value in XB column) and the
optimality condition is satisfied, then the original problem has
no feasible solution.
The solution satisfies the constraints but does not optimise the
objective function since it contains a very large penalty M
and is called pseudo optimal solution.
HE

B IG M M ETHOD

12

XB

Ar

B IG M M ETHOD

y2

yj

yn

x1

x2

xj

xn

(z1 c1 )

(z2 c2 )

(zj cj )

(zn cn )

=0

z(XB )

HE

y1

13

(a) If no artificial variable remains in the basis and the optimality


condition is satisfied, then the current solution is an optimal
basic feasible solution.
(b) If at least one artificial variable appears in the basis at zero
level (with zero value in the XB column) and the optimality
condition is satisfied, then the current solution is an optimal
basic feasible (though degenerated) solution.
(c)
If at least one artificial variable appears in the basis at
non-zero level (with positive value in XB column) and the
optimality condition is satisfied, then the original problem has
no feasible solution.
The solution satisfies the constraints but does not optimise the
objective function since it contains a very large penalty M
and is called pseudo optimal solution.
HE

B IG M M ETHOD

14

XB

Ar

B IG M M ETHOD

y2

yj

yn

x1

x2

xj

xn

(z1 c1 )

(z2 c2 )

(zj cj )

(zn cn )

>0

z(XB )

HE

y1

15

While applying simplex method, whenever an artificial variable


happens to leave the basis, we
drop that artificial variable and
omit all the entries corresponding to its column from the simplex
tableau.

HE

B IG M M ETHOD

16

Step 4:
Application of simplex method is continued until either
an optimum basic feasible solution is obtained
or
there is an indication of the existence of an unbounded solution
to the given LPP.

HE

B IG M M ETHOD

17

Example 1 Use penalty (or Big M ) method to


Minimise z = 4x1 + 3x2
subject to
2x1 + x2 10
3x1 + 2x2 6
x1 + x2 6
x1 , x2 0
Solution:
Convert the problem into maximisation type then objective function
becomes
Maximise (z) = 4x1 3x2 .

HE

B IG M M ETHOD

18

Introducing surplus variables s1 , s3 0 and a slack variable s2 0 in the


given constraints the LPP becomes
Maximise (z) = 4x1 3x2 + 0s1 + 0s2 + 0s3
subject to
2x1

x2

3x1

2x2

x1

x2

s1
+

s2

s3

10

x1 , x2 , s1 , s2 , s3 , 0.
Clearly, no a basic feasible solution, since the surplus variables carry negative
coefficients (1).
Introduce two new artificial variables A1 0 and A2 0 in the first and third
equation, respectively. It provides a starting basic feasible solution.
We assign a very high penalty cost (say M, M 0) to these variables in the
objective function so that they may be driven to zero at the optimality step.

HE

B IG M M ETHOD

19

Then, the LPP becomes


Maximise (z) = 4x1 3x2 + 0s1 + 0s2 + 0s3 M A1 M A2
subject to
2x1

x2

s1

0s2

0s3

3x1

2x2

0s1

s2

0s3

x1

x2

0s1

0s2

s3

A1
+

A2

10

x1 , x2 , s1 , s2 , s3 , A1 , A2 0.
If we take the basic variables as A1 , s2 , A2 then an obvious initial basic
feasible solution is A1 = 10, s2 = 6, A2 = 6.

HE

B IG M M ETHOD

20

Then, the LPP becomes


Maximise (z) = 4x1 3x2 + 0s1 + 0s2 + 0s3 M A1 M A2
subject to
2x1

x2

s1

0s2

0s3

3x1

2x2

0s1

s2

0s3

x1

x2

0s1

0s2

s3

A1
+

A2

10

x1 , x2 , s1 , s2 , s3 , A1 , A2 0.
If we take the basic variables as A1 , s2 , A2 then an obvious initial basic
feasible solution is A1 = 10, s2 = 6, A2 = 6.

HE

B IG M M ETHOD

21

XB = B 1 b = I3 [10 6 6]T = [10 6 6]T


y1 = B 1 a1 = I3 [2 3 1]T = [2 3 1]T
y2 = B 1 a2 = I3 [1 2 1]T = [1 2 1]T
y3 = B 1 s1 = I3 [1 0 0]T = [1 0 0]T
y4 = B 1 s2 = I3 [0 1 0]T = [0 1 0]T
y5 = B 1 s3 = I3 [0 0 1]T = [0 0 1]T
yA1 = B 1 sA1 = I3 [1 0 0]T = [1 0 0]T
yA2 = B 1 sA2 = I3 [0 0 1]T = [0 0 1]T

HE

B IG M M ETHOD

22

z1 c1 = CB y1 c1 = [M 0 M ][2 3 1]T (4) = 3M + 4


z2 c2 = CB y2 c2 = [M 0 M ][1 2 1]T 3 = 2M 3
z3 c3 = CB y3 c3 = [M 0 M ][1 0 0]T 0 = M
z4 c4 = CB y4 c4 = [M 0 M ][0 1 0]T 0 = 0
z5 c5 = CB y5 c5 = [M 0 M ][0 0 1]T 0 = M
z6 c6 = CB yA1 c6 = [M 0 M ][1 0 0]T (M ) = 0
z7 c7 = CB yA2 c7 = [M 0 M ][0 0 1]T (M ) = 0

HE

B IG M M ETHOD

23

Starting Tableau:
Tableau 5.1.1
cj

CB

XB

(-4

-3

M )

y1

y2

y3

y4

y5

yA1

yA2

x1

x2

s1

s2

s3

A1

A2

A1

10

-1

s2

-3

A2

-1

3M + 4

2M + 3

zj cj

z(XB )

6
1

the most negative net evaluation is 3M + 4 (since M is very large);


the non-basic variable x1 enters into the basis;
the basic variable A1 (variable with min. ratio) enters into the basis.
B IG M M ETHOD

Ratio
10
2

From Tableau 5.1.1 we observe that

HE

Min.

24

=5
=6

Starting Tableau:
Tableau 5.1.2
cj

CB

XB

(-4

-3

M )

y1

y2

y3

y4

y5

yA1

yA2

x1

x2

s1

s2

s3

A1

A2

A1

10

-1

s2

-3

A2

-1

3M + 4

2M + 3

zj cj

z(XB )

Min.
Ratio

From Tableau 5.1.2 we observe that


the most negative net evaluation is 3M + 4 (since M is very large);
the non-basic variable x1 enters into the basis;
the basic variable A1 (variable with min. ratio) enters into the basis.
HE

B IG M M ETHOD

25

Starting Tableau:
Tableau 5.1.3
cj

CB

XB

(-4

-3

M )

y1

y2

y3

y4

y5

yA1

yA2

x1

x2

s1

s2

s3

A1

A2

A1

10

-1

s2

-3

A2

-1

3M + 4

2M + 3

zj cj

z(XB )

Min.
Ratio

From Tableau 5.1.3 we observe that


the most negative net evaluation is 3M + 4 (since M is very large);
the non-basic variable x1 enters into the basis;
the basic variable A1 (variable with min. ratio) enters into the basis.
HE

B IG M M ETHOD

26

Starting Tableau:
Tableau 5.1.4
cj

CB

XB

(-4

-3

M )

y1

y2

y3

y4

y5

yA1

yA2

x1

x2

s1

s2

s3

A1

A2

A1

10

-1

s2

-3

A2

-1

3M + 4

2M + 3

zj cj

z(XB )

6
1

the most negative net evaluation is 3M + 4 (since M is very large);


the non-basic variable x1 enters into the basis;
the basic variable A1 (variable with min. ratio) enters into the basis.
B IG M M ETHOD

Ratio
10
2

From Tableau 5.1.4 we observe that

HE

Min.

27

=5
=6

Starting Tableau:
Tableau 5.1.5
cj :
CB

-3

M )

x1

x2

s1

s2

s3

A1

A2

A1

10

-1

s2

-3

A2
6
z(XB )

-1

M
zj cj

HE

XB

(-4

B IG M M ETHOD

Min.
Ratio


1
2

R1

28

Starting Tableau:
Tableau 5.1.6
cj :
CB
M
0
M
zj cj

HE

B IG M M ETHOD

(-4

-3

M )

x1

x2

s1

s2

s3

A1

A2

1/2

-1/2

-3

A2
6
z(XB )

-1

XB
A1
s2

Min.
Ratio
R2 + 3 R1
R3 + (1) R1

29

Starting Tableau:
Tableau 5.1.7
(-4

-3

M )

x1

x2

s1

s2

s3

A1

A2

1/2

-1/2

21

7/2

-3/2

A2
1
z(XB )

1/2

1/2

-1

cj :
CB
4
0
M
zj cj

HE

B IG M M ETHOD

XB
x1
s2

Min.
Ratio

30

The new basis matrix is:


h
B = sA1 s2

sA2

a1

=
= I3 B

i.e., B
1 , we have
Find the inverse of B,
h
i h
I3 I3
B

s2

sA2

That is,

HE

B IG M M ETHOD

0
0
1
0

1/2

0
.
1

3/2

1/2

31

0
0

1/2

1
2

R1

0
R2 + 3 R1
1
R3 R1

3/2

1/2

Thus
1
B

HE

B IG M M ETHOD

1/2

3/2

1/2

0
.
1

32

1 a1 = [1 0 0]T
y1 = B
1 a2 = [1/2 7/2 1/2]T
y2 = B
1 s1 = [1/2 3/2 1/2]T
y3 = B
1 s2 = [0 1 0]T
y4 = B
1 s3 = [0 0 1]T
y5 = B
1 sA2 = [0 0 1]T
yA2 = B

HE

B IG M M ETHOD

33

z1 c1 = CB y1 c1 = [4 0 M ][1 0 0]T (4) = 0


M
+1
2
M
z3 c3 = CB y3 c3 = [4 0 M ][1/2 3/2 1/2]T 0 =
+2
2
z4 c4 = CB y4 c4 = [4 0 M ][0 1 0]T 0 = 0

z2 c2 = CB y2 c2 = [4 0 M ][1/2 7/2 1/2]T 3 =

z5 c5 = CB y5 c5 = [4 0 M ][0 0 1]T 0 = M
z6 c6 = CB yA2 c6 = [4 0 M ][0 0 1]T (M ) = 0

HE

B IG M M ETHOD

34

First iteration:
Tableau 5.2.1
cj :

CB

XB

(-4

-3

M )

y1

y2

y3

y4

y5

yA2

x1

x2

s1

s2

s3

A2

-4

x1

1/2

-1/2

s2

21

7/2

-3/2

A2

1/2

1/2

-1

M
+1
2

M
+2
2

zj cj

z(XB ) = M 20

Min.
Ratio
5
= 10
1/2
21
= 42
7/2
7
0
=0
1/2

we have omitted all entries of column vector A1 , because the artificial variable A1 has left
the basis and so the re-entering of the variable in any subsequent iterations can be
avoided.
Since the most negative net evaluation is M
2 + 1, the non-basic vector x2 enters the
basis.

HE

B IG M M ETHOD

35

Minimum ratio column implies that the variable A2 leaves the basis.

HE

B IG M M ETHOD

36

First iteration:
Tableau 5.2.2

cj :

CB

XB

(-4

-3

M )

y1

y2

y3

y4

y5

yA2

x1

x2

s1

s2

s3

A2

-4

x1

1/2

-1/2

s2

21

7/2

-3/2

A2

1/2

1/2

-1

M
+1
2

M
+2
2

zj cj

z(XB ) = M 20

Min. R.

we have omitted all entries of column vector A1 , because the artificial variable
A1 has left the basis and so the re-entering of the variable in any subsequent
iterations can be avoided.
Since the most negative net evaluation is M
2 + 1, the non-basic vector x2 enters
the basis.
Minimum ratio column implies that the variable A2 leaves the basis.

HE

B IG M M ETHOD

37

First iteration:
Tableau 5.2.3

cj :

CB

XB

(-4

-3

M )

y1

y2

y3

y4

y5

yA2

x1

x2

s1

s2

s3

A2

Min. Ratio
5
= 10
1/2
21
42
=
7/2
7
1
=2
1/2

-4

x1

1/2

-1/2

s2

21

7/2

-3/2

A2

1/2

1/2

-1

M
+1
2

M
+2
2

zj cj

z(XB ) = M 20

we have omitted all entries of column vector A1 , because the artificial variable
A1 has left the basis and so the re-entering of the variable in any subsequent
iterations can be avoided.
Since the most negative net evaluation is M
2 + 1, the non-basic vector x2 enters
the basis.
Minimum ratio column implies that the variable A2 leaves the basis.

HE

B IG M M ETHOD

38

First iteration:
Tableau 5.2.4
(-4

-3

M )

x1

x2

s1

s2

s3

A2

1/2

-1/2

21

7/2

-3/2

A2
1
z(XB )

1/2

1/2

-1

cj :
CB
-4
0
M
zj cj

HE

B IG M M ETHOD

XB
x1
s2

Min.
Ratio

(2) R3

39

First iteration:
Tableau 5.2.5
cj :
CB

-3

M )

x1

x2

s1

s2

s3

A2

-4

x1

1/2

-1/2

s2

21

7/2

-3/2

A2
2
z(XB )

-2

M
zj cj

HE

XB

(-4

B IG M M ETHOD

Min.
Ratio

1 R3
 2
R2 + 7 R3
2
R1 +

40

First iteration:
Tableau 5.2.7
(-4

-3

M )

x1

x2

s1

s2

s3

A2

-1

14

-5

x2
2
z(XB )

-2

cj :
CB
-4
0
-3
zj cj

HE

B IG M M ETHOD

XB
x1
s2

Min.
Ratio

41

The new basis matrix is:


h
= a1 s2
B

sA2

=
B

a1

s2

a2

i.e., (B)
1 , we have
Find the inverse of B,
h
i h
i

1
I3 I3 (B)

.
B
That is,

HE

B IG M M ETHOD

0
0
1
0

7
.
2

42

3
1

0
0

B IG M M ETHOD

1/2

1/2
0

0
R2 + 3 R1
1
R3 R1

1/2

1/2

1/2

3/2

1/2

7/2

R1

0
R2 + 3 R1
1
R3 R1

1/2

1/2

1
2

0
0

HE

2
2 R3

7/2

3/2

43

0
0

1/2

1/2

7/2

3/2

0
0

HE

B IG M M ETHOD

R1

0
R2
2
1

1
2

7
2

7
.
2

R3
R3

44


1 a1 = [1 0 0]T
y1 = (B)

1 a2 = [0 0 1]T
y2 = (B)

1 s1 = [1 5 1]T
y3 = (B)

1 s2 = [0 1 0]T
y4 = (B)

1 s3 = [1 7 2]T
y5 = (B)

HE

B IG M M ETHOD

45

z1 c1 = CB y1 c1 = [4 0 3][1 0 0]T (4) = 0


z2 c2 = CB y2 c2 = [4 0 3][0 0 1]T 3 = 0
z3 c3 = CB y3 c3 = [4 0 3][1 5 1]T 0 = 1
z4 c4 = CB y4 c4 = [4 0 3][0 1 0]T 0 = 0
z5 c5 = CB y5 c5 = [4 0 3][1 7 2]T 0 = 2

HE

B IG M M ETHOD

46

Second iteration:
Tableau 5.3.1
CB
XB

x1

x2

s1

s2

s3

-4

x1

-1

s2

14

-5

-3

x2

-2

zj cj

z(XB ) = 22

Since all zj cj 0 for all j, the optimum basic feasible solution is


given by
x1 = 4, x2 = 2 with minimum of z = 22

HE

B IG M M ETHOD

47

Example 2
Maximise z = 3x1 + 2x2
subject to
2x1 + x2 2
3x1 + 4x2 12
x1 , x2 0.

HE

B IG M M ETHOD

48

Solution:
Introducing slack variable s1 0, surplus variable s2 0 and an
artificial variable A1 0, the LPP can be written as
Maximise z = 3x1 + 2x2 + 0s1 + 0s2 M A1
subject to
2x1

x2

3x1

4x2

s1

s2

A1

12

x1 , x2 , s1 , s2 0 and A1 0.

HE

B IG M M ETHOD

49

The initial basis matrix is:


B=

s1

sA1

= I2 .

An obvious initial basis feasible solution is s1 = 2, A2 = 12, i.e.,


XB = B 1 b = I2 b = [2 12]T

HE

B IG M M ETHOD

50

y1 = B 1 a1 = I2 [2 3]T = [2 3]T
y2 = B 1 a2 = I2 [1 4]T = [1 4]T
y1 = B 1 s1 = I2 [1 0]T = [1 0]T
y2 = B 1 s2 = I2 [0 1]T = [0 1]T
yA1 = B 1 sA1 = I2 [0 1]T = [0 1]T

z1 c1 = CB x1 c1 = [0 M ][2 3]T 3 = 3M 3
z2 c2 = CB x2 c2 = [0 M ][1 4]T 2 = 4M 2
z3 c3 = CB s1 c3 = [0 M ][1 0]T 0 = 0
z4 c4 = CB s2 c4 = [0 M ][0 1]T 0 = M
z5 c5 = CB yA1 c5 = [0 M ][0 1]T (M ) = 0

HE

B IG M M ETHOD

51

Starting Tableau:
Tableau 5.4.1
cj :

CB

XB

(3

M )

y1

y2

y3

y4

y5

x1

x2

s1

s2

A1

s1

A1

12

-1

3M 3

4M 2

zj cj

z(XB ) = 12M 2

Min Ratio
2
1
12
4

From Tableau 5.4.1 we observe that


The non-basic variable x2 enters into the basis.
The basic variable s1 leaves the basis.

HE

B IG M M ETHOD

52

=2
=3

Starting Tableau:
Tableau 5.4.2
CB
0
M
zj cj

HE

B IG M M ETHOD

cj :

(3

M )

x2
1

s1

s2

x1
2

A1
0

-1

XB
s1

A1
12
z(XB )

Min Ratio

R2 + (4) R1

53

Starting Tableau:
Tableau 5.4.2
CB
0
M
zj cj

HE

B IG M M ETHOD

cj :

(3

M )

x2
1

s1

s2

x1
2

A1
0

-5

-4

-1

XB
s1

A1
4
z(XB )

Min Ratio

54

The new basis matrix is:


h
i
h
= a2
B = s1 sA1 = I2 B

sA1

i.e., B
1 , we have
Find the inverse of B,
h
i h
i
1
I2 I2 B

.
B
That is,

HE

B IG M M ETHOD

55

1 a1 = [2 5]T
y1 = B
1 a2 = [1 0]T
y2 = B
1 s1 = [1 4]T
y3 = B
1 s2 = [0 1]T
y4 = B
1 sA1 = [0 1]T
yA1 = B

z1 c1 = CB y1 c1 = [2 M ][2 5]T 3 = 5M + 1
z2 c2 = CB y2 c2 = [2 M ][1 0]T 2 = 0
z3 c3 = CB y3 c3 = [2 M ][1 4]T 0 = 4M + 2
z4 c4 = CB y4 c4 = [2 M ][0 1]T 0 = M
z5 c5 = CB yA1 c5 = [2 M ]0 1]T (M ) = 0

HE

B IG M M ETHOD

56

First iteration:
Tableau 5.4.2
cj :
CB

XB

(3

M )

x1

x2

s1

s2

A1

x2

A1

-5

-4

-1

5M + 1

4M + 2

zj cj

z(XB ) = 4M + 4

Here, the coefficient of M in each zj cj 0, and an artificial variable


A1 appears in the basis at non-zero level.
Thus, the given LPP does not possess any feasible solution.
We can say the LPP possess a pseudo-optimal solution.

HE

B IG M M ETHOD

57

First iteration:
Tableau 5.4.2
cj :
CB

XB

(3

M )

x1

x2

s1

s2

A1

x2

A1

-5

-4

-1

5M + 1

4M + 2

zj cj

z(XB ) = 4M + 4

Here, the coefficient of M in each zj cj 0, and an artificial variable


A1 appears in the basis at non-zero level.
Thus, the given LPP does not possess any feasible solution.
We can say the LPP possess a pseudo-optimal solution.

HE

B IG M M ETHOD

58

Example 3 Use penalty method to


Maximise z = 2x1 + x2 + x3
subject to
4x1 + 6x2 + 3x3 8
3x1 6x2 4x3 1
2x1 + 3x2 5x3 4
and,

HE

B IG M M ETHOD

x1 , x2 , x3 0.

59

Solution:
Introducing slack variables s1 , s2 0 and a surplus variable s3 0 and
artificial variable A1 0, the LPP can be written as
Maximise z = 2x1 + x2 + x3 + 0s1 + 0s2 + 0s3 M A1
subject to
4x1

6x2

3x3

3x1

6x2

4x3

2x1

3x2

5x3

s1
+

s2

s3

A1

x1 , x2 , s1 , s2 , s3 0, and A1 0.
An obvious IBFS s1 = 8, s2 = 1, A1 = 4.

HE

B IG M M ETHOD

60

y1 = B 1 x1 = I3 [4 3 2]T = [4 3 2]T
y2 = B 1 x2 = I3 [6 6 3]T = [6 6 3]T
y3 = B 1 x3 = I3 [3 4 5]T = [3 4 5]T
y4 = B 1 s1 = I3 [1 0 0]T = [1 0 0]T
y5 = B 1 s2 = I3 [0 1 0]T = [0 1 0]T
y6 = B 1 s3 = I3 [0 0 1]T = [0 0 1]T
yA1 = B 1 sA1 = I3 [0 0 1]T = [0 0 1]T

HE

B IG M M ETHOD

61

z1 c1 = CB y1 c1 = [0 0 M ][4 3 2]T 2 = 2M 2
z2 c2 = CB y2 c2 = [0 0 M ][6 6 3]T 1 = 3M 1
z3 c3 = CB y3 c3 = [0 0 M ][3 4 5]T 1 = 5M 1
z4 c4 = CB y4 c4 = [0 0 M ][1 0 0]T 0 = 0
z5 c5 = CB y5 c5 = [0 0 M ][0 1 0]T 0 = 0
z6 c6 = CB y6 c6 = [0 0 M ][0 0 1]T 0 = M
z7 c7 = CB yA1 c7 = [0 0 M ][0 0 1]T (M ) = 0

HE

B IG M M ETHOD

62

Starting Tableau:
Tableau 5.5.1
cj :
XB

CB

M )

y1

y2

y3

y4

y5

y6

yA1

x1

x2

x3

s1

s2

s3

A1

Min Ratio

s1

8/6=1.33

s2

-6

-4

A1

-5

-1

4/3=1.33

2M 2

3M 1

5M 1

zj c j

HE

(2

B IG M M ETHOD

z(XB ) = 4M

63

Starting Tableau:
Tableau 5.5.2
cj :
CB

XB

(2

M )

x1

x2

x3

s1

s2

s3

A1

s1

s2

-6

-4

A1

-5

-1

Min Ratio

1
3

R3

zj c j

HE

B IG M M ETHOD

64

Starting Tableau:
Tableau 5.5.3
cj :
CB

XB

(2

M )

x1

x2

x3

s1

s2

s3

A1

M.R.

s1

R1 + (6) R3

s2

-6

-4

R2 + (6) R3

A1

4/3

2/3

-5/3

-1/3

zj c j

HE

B IG M M ETHOD

65

Starting Tableau:
Tableau 5.5.4
cj :
CB

XB

(2

M )

x1

x2

x3

s1

s2

s3

A1

s1

13

s2

-14

-2

x2

4/3

2/3

-5/3

-1/3

Min Ratio

zj c j

HE

B IG M M ETHOD

66

The new basis matrix is:


h
B = s1 s2

sA1

s1

=
= I3 B

i.e., B
1 , we have
Find the inverse of B,
h
i h
I3 I3
B

s2

a2

That is,

HE

B IG M M ETHOD

0
0
1
0

2
.
1/3

67

HE

B IG M M ETHOD

0
0
1
0

0
0

0
0


1
1/3
R3
3

0
R1 6 R3

0
R2 + 6 R3
1/3

1/3

68

y1 = B 1 a1 = [0 7 2/3]T
y2 = B 1 a2 = [0 0 1]T
y3 = B 1 a3 = [13 14 5/3]T
y4 = B 1 s1 = [1 0 0]T
y5 = B 1 s2 = [0 1 0]T
y6 = B 1 s3 = [2 2 1/3]T

HE

B IG M M ETHOD

69

z1 c1 = CB y1 c1 = [0 0 1][0 7 2/3]T 2 = 4/3


z2 c2 = CB y2 c2 = [0 0 1][0 0 1]T 1 = 0
z3 c3 = CB y3 c3 = [0 0 1][13 14 5/3]T 1 = 8/3
z4 c4 = CB y4 c4 = [0 0 1][1 0 0]T 0 = 0
z5 c5 = CB y5 c5 = [0 0 1][0 1 0]T 0 = 0
z6 c6 = CB y6 c6 = [0 0 1][2 2 1/3]T 0 = 1/3

HE

B IG M M ETHOD

70

First iteration: Introduce x2 and drop A1 .


Tableau 5.5.5
cj :
(2
1
1

CB

0)

y1

y2

y3

y4

y5

y6

x1

x2

x3

s1

s2

s3

Min. Ratio

s1

13

s2

-14

-2

x2

4/3

2/3

-5/3

-1/3

-4/3

-8/3

-1/3

zj cj

HE

XB

B IG M M ETHOD

z(XB )

71

First iteration:
Tableau 5.5.6
cj :

(2

0)

x2
0

x3
13

s1

s2

s3

CB
0

s1

x1
0

s2

-14

-2

x2

4/3

2/3

-5/3

-1/3

XB

Min Ratio


1
13

R1

zj cj

HE

B IG M M ETHOD

72

First iteration:
Tableau 5.5.7
cj :

(2

0)

x2
0

x3
1

s1

s2

s3

1/13

2/13

CB
0

s1

x1
0

s2

-14

-2

x2

4/3

2/3

-5/3

-1/3

XB

Min Ratio
R2 + (14) R1
 
R3 + 5 R1
3

zj cj

HE

B IG M M ETHOD

73

First iteration:
Tableau 5.5.8
cj :

(2

0)

x2
0

x3
1

s1

s2

s3

1/13

2/13

x3
s2

x1
0

14/13

2/13

x2

4/3

2/3

5/39

-1/13

CB
1

XB

Min Ratio

zj cj

HE

B IG M M ETHOD

74

The new basis matrix is:


h
= s1 s2
B

a2

=
B

a3

s2

a2

i.e., (B)
1 , we have
Find the inverse of B,
h
i h
i

1
I3 I3 (B)

.
B
That is,

HE

B IG M M ETHOD

0
0
0
1

1/13

2/13

2/13
.
1/13

14/13

5/39

75


1 a1 = [0 7 2/3]T
y1 = (B)

1 a2 = [0 0 1]T
y2 = (B)

1 a3 = [1 0 0]T
y3 = (B)

1 s1 = [1/13 14/13 5/39]T


y4 = (B)

1 s2 = [0 1 0]T
y5 = (B)

1 s3 = [2/13 2/13 1/13]T


y6 = (B)

HE

B IG M M ETHOD

76

z1 c1 = CB y1 c1 = [1 0 1][0 7 2/3]T 2 = 4/3


z2 c2 = CB y2 c2 = [1 0 1][0 0 1]T 1 = 0
z3 c3 = CB y3 c3 = [1 0 1][1 0 0]T 1 = 0
z4 c4 = CB y4 c4 = [1 0 1][1/13 14/13 5/39]T 0 = 8/39
z5 c5 = CB y5 c5 = [1 0 1][0 1 0]T 0 = 0
z6 c6 = CB y6 c6 = [1 0 1][2/13 2/13 1/13]T 0 = 1/13

HE

B IG M M ETHOD

77

Second iteration:
Tableau 5.5.9
cj :
CB

0)

x1

x2

x3

s1

s2

s3

Min Ratio

x3

1/13

2/13

s2

14/13

2/13

9/7

x2

4/3

2/3

5/39

-1/13

-4/3

8/39

1/13

zj cj

HE

XB

(2

B IG M M ETHOD

z(XB ) = 4/3

78

Second iteration:
Tableau 5.5.10
cj :

(2

0)

x3
1

s2

s3

x2
0

s1
1/13

2/13

x3
s2

x1
0

14/13

2/13

x2

4/3

2/3

5/39

-1/13

CB
1

XB

Min Ratio


1
7

R2

zj cj

HE

B IG M M ETHOD

79

Second iteration:
Tableau 5.5.11
cj :

(2

0)

x2
0

x3
1

s1

s2

s3

1/13

2/13

x3
s2

x1
0

9/7

2/13

1/7

2/91

x2

4/3

2/3

5/39

-1/13

CB
1

XB

Min Ratio

2
3

R2 + R3

zj cj

HE

B IG M M ETHOD

80

Second iteration:
Tableau 5.5.12
cj :

(2

0)

x2
0

x3
1

s1

s2

s3

1/13

2/13

x3
x1

x1
0

9/7

2/13

1/7

2/91

x2

10/21

1/39

-2/21

-25/273

CB
1

XB

Min Ratio

zj cj

HE

B IG M M ETHOD

81

The new basis matrix is:

=
B

a3

s2

a2

= a3
B

a1

a2

1 , we have
Find the inverse of B, i.e., (B)
h

I3

I3

1
(B)

That is,

HE

0
0
1
0

B IG M M ETHOD

1/13

2/13

1/7

1/39

2/21

2/13

2/91
.
25/273

82

1 a1 = [0 1 0]T
y1 = (B)

1 a2 = [0 0 1]T
y2 = (B)

1 a3 = [1 0 0]T
y3 = (B)

1 s1 = [1/13 2/13 1/39]T


y4 = (B)

1 s2 = [0 1/7 2/21]T
y5 = (B)

1 s3 = [2/13 2/91 25/273]T


y6 = (B)

HE

B IG M M ETHOD

83

z1 c1 = CB y1 c1 = [1 2 1][0 1 0]T 2 = 0
z2 c2 = CB y2 c2 = [1 2 1][0 0 1]T 1 = 0
z3 c3 = CB y3 c3 = [1 2 1][1 0 0]T 1 = 0
z4 c4 = CB y4 c4 = [1 2 1][1/13 2/13 1/39]T 0 = 16/39
z5 c5 = CB y5 c5 = [1 2 1][0 1/7 2/21]T 0 = 4/21
z6 c6 = CB y6 c6 = [1 2 1][2/13 2/91 25/273]T 0 = 29/273

HE

B IG M M ETHOD

84

Third iteration:
Tableau 5.5.12
cj :
CB

XB

(2

0)

x1

x2

x3

s1

s2

s3

x3

1/13

2/13

x1

9/7

2/13

1/7

2/91

x2

10/21

1/39

-2/21

-25/273

16/39

4/21

29/273

zj cj

z(XB ) = 64/21

Min Ratio

Since all zj cj 0, the current solution is optimal. The optimal solution


is
x1 = 9/7, x2 = 10/21, x3 = 0 with maximum of z = 64/21

HE

B IG M M ETHOD

85

T HE T WO - PHASE S IMPLEX M ETHOD

HE T WO - PHASE

S IMPLEX M ETHOD

86

The two-phase simplex method is another method to solve an LPP in


which some artificial variables are involved.
The solution can be obtained in two phases.

HE T WO - PHASE

S IMPLEX M ETHOD

87

Phase I It consists of the following steps:


Step 1:
Convert the LPP into maximisation form and ensure that all bi
(constant terms) are non-negative, i.e., bi 0.
If some of them are negative, make them non-negative by
multiplying both sides of those inequations/equations by 1.
Step 2: Add artificial variables Ai ( 0) to the LHS of the constraints
of (= and ) to complete the identity matrix In .
Step 3: Express the given LPP in standard form.
Step 4: Obtain an initial basic feasible solution.

HE T WO - PHASE

S IMPLEX M ETHOD

88

Step 5:
Assign a cost 1 to each artificial variable
Assign a cost 0 to all other variables (in place of their original
cost) in the objective function.
The new objective function is
max z = A1 A2 An ,
where Ai s are the artifical variables.
Step 6: Write down the auxiliary LPP in which the new objective
function is to be maximised subject to the given set of
constraints.

HE T WO - PHASE

S IMPLEX M ETHOD

89

Step 7: Solve the auxiliary LPP by simplex method until either of the
following three possibilities arise:
(i) max z < 0 and at least one artificial variable appears in the
optimum basis at a +ve level. In this case no feasible solution
exist, stop the procedure.
(ii) max z = 0 and at least one artificial variable appears in the
optimum basis at zero level.
(iii) max z = 0 and no artificial variable appears in the optimum
basis.

HE T WO - PHASE

S IMPLEX M ETHOD

90

XB

Ar

y1

y2

yj

yn

x1

x2

xj

xn

>0

z < 0

HE T WO - PHASE

S IMPLEX M ETHOD

91

Step 7: Solve the auxiliary LPP by simplex method until either of the
following three possibilities arise:
(i) max z < 0 and at least one artificial variable appears in the
optimum basis at a +ve level. In this case no feasible solution
exist, stop the procedure.
(ii) max z = 0 and at least one artificial variable appears in
the optimum basis at zero level.
(iii) max z = 0 and no artificial variable appears in the
optimum basis.

HE T WO - PHASE

S IMPLEX M ETHOD

92

XB

Ar

y1

y2

yj

yn

x1

x2

xj

xn

=0

z = 0

HE T WO - PHASE

S IMPLEX M ETHOD

93

Step 7: Solve the auxiliary LPP by simplex method until either of the
following three possibilities arise:
(i) max z < 0 and at least one artificial variable appears in the
optimum basis at a +ve level. In this case no feasible solution
exist, stop the procedure.
(ii) max z = 0 and at least one artificial variable appears in
the optimum basis at zero level.
(iii) max z = 0 and no artificial variable appears in the
optimum basis.

HE T WO - PHASE

S IMPLEX M ETHOD

94

XB

y1

y2

yj

yn

x1

x2

xj

xn

xB1
xB2
..
.
xBr
..
.
xBm
z = 0

HE T WO - PHASE

S IMPLEX M ETHOD

95

If case (ii) and (iii) arise proceed to Phase II.


Phase II
Use the optimum basic feasible solution of Phase I as a starting
solution for the original LPP.
Assign
the actual costs to the variables in the objective function
and
a cost 0 to every artificial variable in the basis at zero level.
Delete the artificial variables column from the simplex tableau
which is eliminated from the basis in Phase I.
Apply simplex method to the modified simplex tableau
obtained at the end of Phase I till an optimum basic feasible
solution is obtained or till there is an indication of unbounded
solution.
HE T WO - PHASE

S IMPLEX M ETHOD

96

Remark 1

1. In Phase I, the iterations are stopped as soon as the value of the new
(artificial) objective function becomes zero because this is its
minimum value. There is no need to continue till the optimality
reached if this value becomes zero earlier than that.
2. Note that the new objective function is always of maximisation type
whether the given original problem is maximisation or minimisation
type.
3. Before starting Phase II, remove all artificial variables from Tableau
which were non-basic at the end of Phase I.

HE T WO - PHASE

S IMPLEX M ETHOD

97

Example 4 Use two-phase simplex method to solve


maximise z = 5x1 + 8x2
subject to the constraints
3x1 + 2x2 3
x1 + 4x2 4
x1 + x2 5
x1 , x2 0.

HE T WO - PHASE

S IMPLEX M ETHOD

98

Solution:
By introducing the non-negative slack, surplus and artificial
variables, the standard form of the LPP becomes
Maximise z = A1 A2
subject to
3x1

2x2

s1

0s2

0s3

x1

4x2

0s1

s2

0s3

x1

x2

0s1

0s2

s3

A1
+

A2

x1 , x2 , s1 , s2 , s3 , A1 , A2 0.
An obvious initial basic feasible solution is A1 = 3, A2 = 4, s3 = 5.

HE T WO - PHASE

S IMPLEX M ETHOD

99

Phase I Construct the auxiliary LPP


Maximise z = A1 A2
subject to the given set of constraints.

HE T WO - PHASE

S IMPLEX M ETHOD

100

The basis matrix is:


B=

HE T WO - PHASE

S IMPLEX M ETHOD

sA1

sA2

s3

= I3 .

101

y1 = B 1 a1 = I3 [3 1 1]T = [3 1 1]T
y2 = B 1 a2 = I3 [2 4 1]T = [2 4 1]T
y3 = B 1 s1 = I3 [1 0 0]T = [1 0 0]T
y4 = B 1 s2 = I3 [0 1 0]T = [0 1 0]T
y5 = B 1 s3 = I3 [0 0 1]T = [0 0 1]T
yA1 = B 1 sA1 = I3 [1 0 0]T = [1 0 0]T
yA2 = B 1 sA2 = I3 [0 1 0]T = [0 1 0]T

HE T WO - PHASE

S IMPLEX M ETHOD

102

z1 c1 = CB y1 c1 = [1 1 0][3 1 1]T 0 = 4
z2 c2 = CB y2 c2 = [1 1 0][2 4 1]T 0 = 6
z3 c3 = CB y3 c3 = [1 1 0][1 0 0]T 0 = 1
z4 c4 = CB y4 c4 = [1 1 0][0 1 0]T 0 = 1
z5 c5 = CB y5 c5 = [1 1 0][0 0 1]T 0 = 0
z6 c6 = CB yA1 c6 = [1 1 0][1 0 0]T (1) = 0
z7 c7 = CB yA2 c7 = [1 1 0][0 1 0]T (1) = 0

HE T WO - PHASE

S IMPLEX M ETHOD

103

Starting Tableau:
Tableau 5.6.1
cj :

CB

XB

(0

-1

-1)

y1

y2

y3

y4

y5

yA1

yA2

x1

x2

s1

s2

s3

A1

A2

Min Ratio

-1

A1

-1

3/2

-1

A2

-1

4/4

s3

5/1

-4

-6

zj cj

Since there are some (zj cj ) < 0, the current basic feasible solution
is not optimal.

HE T WO - PHASE

S IMPLEX M ETHOD

104

Starting Tableau:
Tableau 5.6.2
CB
-1

(0

-1

-1)

x2
2

s1

s2

s3

-1

A1
1

A2
0

A1
A2

x1
3

-1

s3

XB

-1
0

zj cj

HE T WO - PHASE

cj :

S IMPLEX M ETHOD

Min Ratio


1
4

R2

105

Starting Tableau:
Tableau 5.6.3
cj :

(0

-1

-1)

s2

s3

x2
2

s1
-1

A1
1

A2
0

-1

A1
A2

x1
3

1/4

-1/4

1/4

s3

CB
-1

XB

Min Ratio
R1 + (2) R2
R3 + (1) R2

c
zj
j

HE T WO - PHASE

S IMPLEX M ETHOD

106

Starting Tableau:
Tableau 5.6.4
cj :

(0

-1

-1)

x2
0

s1

s2

s3

-1

1/2

A1
1

A2
-1/2

A1
x2

x1
5/2

1/4

-1/4

1/4

s3

3/4

1/4

-1/4

CB
-1

XB

Min Ratio

c
zj
j

HE T WO - PHASE

S IMPLEX M ETHOD

107

The new basis matrix is:


h
B = sA1 sA2

s3

=
B

sA1

a2

s3

i.e., B
1 , we have
Find the inverse of B,
h
i h
i
I3 I3 B
1 .
B
That is,

HE T WO - PHASE

S IMPLEX M ETHOD

0
0
0
1

1/2

1/4

1/4

0
.
1

108

y1 = B 1 a1 = I3 [5/2 1/4 3/4]T = [5/2 1/4 3/4]T


y2 = B 1 a2 = I3 [0 1 0]T = [0 1 0]T
y3 = B 1 s1 = I3 [1 0 0]T = [1 0 0]T
y4 = B 1 s2 = I3 [1/2 1/4 1/4]T = [1/2 1/4 1/4]T
y5 = B 1 s3 = I3 [0 0 1]T = [0 0 1]T
yA1 = B 1 sA1 = I3 [1 0 0]T = [1 0 0]T
yA2 = B 1 sA2 = I3 [1/2 1/4 1/4]T = [1/2 1/4 1/4]T

HE T WO - PHASE

S IMPLEX M ETHOD

109

z1 c1 = CB y1 c1 = [1 0 0][5/2 1/4 3/4]T 0 = 5/2


z2 c2 = CB y2 c2 = [1 0 0][0 1 0]T 0 = 0
z3 c3 = CB y3 c3 = [1 0 0][1 0 0]T 0 = 1
z4 c4 = CB y4 c4 = [1 0 0][1/2 1/4 1/4]T 0 = 1/2
z5 c5 = CB y5 c5 = [1 0 0][0 0 1]T 0 = 0
z6 c6 = CB yA1 c6 = [1 0 0][1 0 0]T (1) = 0
z7 c7 = CB yA2 c7 = [1 0 0][1/2 1/4 1/4]T (1) = 3/2

HE T WO - PHASE

S IMPLEX M ETHOD

110

First iteration:
Tableau 5.6.4
cj :
CB

XB

(0

-1

-1)

x1

x2

s1

s2

s3

A1

A2

Min Ratio

-1

A1

5/2

-1

1/2

-1/2

2/5

x2

1/4

-1/4

1/4

s3

3/4

1/4

-1/4

16/3

-5/2

-1/2

3/2

zj cj

z (XB ) = 1

Since there are zj cj < 0, the current basic feasible solution is not
optimal.

HE T WO - PHASE

S IMPLEX M ETHOD

111

First iteration:
Tableau 5.6.5
CB
-1

(0

-1

-1)

s2

s3

x2
0

s1

A1

x1
5/2

-1

1/2

A1
1

A2
-1/2

x2
s3

1/4

-1/4

1/4

3/4

1/4

-1/4

XB

0
0

zj cj

HE T WO - PHASE

cj :

S IMPLEX M ETHOD

Min Ratio


2
5

R1

112

First iteration:
Tableau 5.6.6
cj :

(0

-1

-1)

s2

s3

2/5

x2
0

s1
-2/5

1/5

A1
2/5

A2
-1/5

A1
x2

x1
1

1/4

-1/4

1/4

s3

3/4

1/4

-1/4

CB
-1

XB

Min Ratio

1 R1
 4
R3 + 3 R1
4
R2 +

c
zj
j

HE T WO - PHASE

S IMPLEX M ETHOD

113

First iteration:
Tableau 5.6.7
cj :

(0

-1

-1)

x2
0

s1

s2

s3

-2/5

1/5

A1
2/5

A2
-1/5

2/5

x1
x2

x1
1

9/10

1/10

-3/10

-1/10

3/10

s3

37/10

3/10

1/10

-3/10

-1/10

CB
0

XB

Min Ratio

c
zj
j

HE T WO - PHASE

S IMPLEX M ETHOD

114

The new basis matrix is:


h
= sA
B
a2
1

s3

=
B

a1

a2

s3

i.e., (B)
1 , we have
Find the inverse of B,
h
i h
i

1
I3 I3 (B)

.
B
That is,

HE T WO - PHASE

S IMPLEX M ETHOD

0
0
1
0

2/5

1/5

0
.
1

1/10

3/10

3/10

1/10

115

y1 = B 1 a1 = I3 [1 0 0]T = [1 0 0]T
y2 = B 1 a2 = I3 [0 1 0]T = [0 1 0]T
y3 = B 1 s1 = I3 [2/5 1/10 3/10]T = [2/5 1/10 3/10]T
y4 = B 1 s2 = I3 [1/5 3/10 3/10]T = [1/5 3/10 3/10]T
y5 = B 1 s3 = I3 [0 0 1]T = [0 0 1]T
yA1 = B 1 sA1 = I3 [2/5 1/10 3/10]T = [2/5 1/10 3/10]T
yA2 = B 1 sA2 = I3 [1/5 3/10 1/10]T = [1/5 3/10 1/10]T

HE T WO - PHASE

S IMPLEX M ETHOD

116

z1 c1 = CB y1 c1 = [0 0 0][1 0 0]T 0 = 0
z2 c2 = CB y2 c2 = [0 0 0][0 1 0]T 0 = 0
z3 c3 = CB y3 c3 = [0 0 0][2/5 1/10 3/10]T 0 = 0
z4 c4 = CB y4 c4 = [0 0 0][1/5 3/10 3/10]T 0 = 0
z5 c5 = CB y5 c5 = [0 0 0][0 0 1]T 0 = 0
z6 c6 = CB yA1 c6 = [0 0 0][2/5 1/10 3/10]T (1) = 1
z7 c7 = CB yA2 c7 = [0 0 0][1/5 3/10 1/10]T (1) = 1

HE T WO - PHASE

S IMPLEX M ETHOD

117

Second iteration:
Tableau 5.6.8
cj :
CB

XB

(0

-1

-1)

x1

x2

s1

s2

s3

A1

A2

x1

2/5

-2/5

1/5

2/5

-1/5

x2

9/10

1/10

-3/10

-1/10

3/10

s3

37/10

3/10

1/10

-3/10

-1/10

z (XB ) = 0

Min Ratio

Since all zj cj 0, the current basic solution is optimum. Further,


no artificial variable appears in the optimum basis so we proceed to
Phase II.

HE T WO - PHASE

S IMPLEX M ETHOD

118

Second iteration:
Tableau 5.6.8
cj :
CB

XB

(0

-1

-1)

x1

x2

s1

s2

s3

A1

A2

x1

2/5

-2/5

1/5

2/5

-1/5

x2

9/10

1/10

-3/10

-1/10

3/10

s3

37/10

3/10

1/10

-3/10

-1/10

z (XB ) = 0

Min Ratio

Since all zj cj 0, the current basic solution is optimum. Further,


no artificial variable appears in the optimum basis so we proceed to
Phase II.

HE T WO - PHASE

S IMPLEX M ETHOD

119

Phase II
Consider the actual costs associated with the original variables.
The new objective function is
z = 5x1 + 8x2 + 0s1 + 0s2 + 0s3 .
The initial basic feasible for this phase is the one obtained at the
end of Phase I.

HE T WO - PHASE

S IMPLEX M ETHOD

120

The basis matrix is:


B=

a1

a2

s3

= I3 .

Tableau 5.6.8
cj :

CB

XB

(0

-1

-1)

y1

y2

y3

y4

y5

yA1

yA2

x1

x2

s1

s2

s3

A1

A2

x1

2/5

-2/5

1/5

2/5

-1/5

x2

9/10

1/10

-3/10

-1/10

3/10

s3

37/10

3/10

1/10

-3/10

-1/10

z(XB ) = 0

HE T WO - PHASE

S IMPLEX M ETHOD

Min Ratio

121

y1 = B 1 a1 = I3 [1 0 0]T = [1 0 0]T
y2 = B 1 a2 = I3 [0 1 0]T = [0 1 0]T
y3 = B 1 s1 = I3 [2/5 1/10 3/10]T = [2/5 1/10 3/10]T
y4 = B 1 s2 = I3 [1/5 3/10 3/10]T = [1/5 3/10 3/10]T
y5 = B 1 s3 = I3 [0 0 1]T = [0 0 1]T

z1 c1 = CB y1 c1 = [5 8 0][1 0 0]T 5 = 0
z2 c2 = CB y2 c2 = [5 8 0][0 1 0]T 8 = 0
z3 c3 = CB y3 c3 = [5 8 0][2/5 1/10 3/10]T 0 = 6/5
z4 c4 = CB y4 c4 = [5 8 0][1/5 3/10 3/10]T 0 = 7/5
z5 c5 = CB y5 c5 = [5 8 0][0 0 1]T 0 = 0

HE T WO - PHASE

S IMPLEX M ETHOD

122

The iterative simplex tableau for this phase is


Tableau 5.6.9
cj :
(5
8
0
0

CB

XB

0)

y1

y2

y3

y4

y5

x1

x2

s1

s2

s3

Min Ratio

x1

2/5

-2/5

1/5

(2/5)/(1/5)=2

x2

9/10

1/10

-3/10

s3

37/10

3/10

1/10

(37/10)/(1/10)=37

z(XB ) = 46/5

-6/5

-7/5

zj cj

From Table 5.6.9, we observe that s2 enters into the basis and x1
leaves the basis.

HE T WO - PHASE

S IMPLEX M ETHOD

123

The iterative simplex tableau for this phase is


Tableau 5.6.10
(5
cj :

0)

x2
0

s1

s2

s3

-2/5

1/5

2/5

x1
x2

x1
1

9/10

1/10

-3/10

s3

37/10

3/10

1/10

CB
5

XB

Min Ratio
(5) R1

zj cj

HE T WO - PHASE

S IMPLEX M ETHOD

124

The iterative simplex tableau for this phase is


Tableau 5.6.11
(5
cj :

0)

x2
0

s1

s2

s3

-2

x1
x2

x1
5

9/10

1/10

-3/10

s3

37/10

3/10

1/10

CB
5

XB

Min Ratio


3
R2 +
R1
 10 
1
R3 +
R1
10

zj cj

HE T WO - PHASE

S IMPLEX M ETHOD

125

The iterative simplex tableau for this phase is


Tableau 5.6.12
(5
8
cj :
CB
0
0

0)

s2

x1
5

x2
s3

3/2

3/2

-1/2

7/2

-1/2

1/2

XB

x2
0

s1

s2

s3

-2

Min Ratio

zj cj

HE T WO - PHASE

S IMPLEX M ETHOD

126

The new basis matrix is:


h
B = a1 a2

s3

=
B

s2

a2

s3

i.e., B
1 , we have
Find the inverse of B,
h
i h
i
I3 I3 B
1 .
B
That is,

1/5

3/10

1/10

HE T WO - PHASE

S IMPLEX M ETHOD

0
0
0
1

0
.
1

3/2

1/2

127

y1 = B 1 a1 = [5 3/2 1/2]T
y2 = B 1 a2 = [0 1 0]T
y3 = B 1 s1 = [2 1/2 1/2]T
y4 = B 1 s2 = [1 0 0]T
y5 = B 1 s3 = [0 0 1]T

z1 c1 = CB y1 c1 = [0 8 0][5 3/2 1/2]T 5 = 7


z2 c2 = CB y2 c2 = [0 8 0][0 1 0]T 8 = 0
z3 c3 = CB y3 c3 = [0 8 0][2 1/2 1/2]T 0 = 4
z4 c4 = CB y4 c4 = [0 8 0][1 0 0]T 0 = 0
z5 c5 = CB y5 c5 = [0 8 0][0 0 1]T 0 = 0

HE T WO - PHASE

S IMPLEX M ETHOD

128

First iteration:
Tableau 5.6.13
ci :

CB

XB

(5

0)

y1

y2

y3

y4

y5

x1

x2

s1

s2

s3

Min Ratio

s2

-2

x2

3/2

3/2

-1/2

s3

7/2

-1/2

1/2

-4

zj cj

z(XB ) = 12

Since there are some zj cj < 0, current basic feasible solution


is not optimal.
From Tableau 5.6.13, we observe that s1 enters into the basis
and s3 leaves the basis.

HE T WO - PHASE

S IMPLEX M ETHOD

129

First iteration:
Tableau 5.6.14
CB
0

ci :

(5

0)

s2

s3

x2
0

s1

s2

x1
5

-2

x2
s3

3/2

3/2

-1/2

7/2

-1/2

1/2

XB

8
0

Min Ratio

(2) R3

zj cj

HE T WO - PHASE

S IMPLEX M ETHOD

130

First iteration:
Tableau 5.6.15
ci :

(5

0)

x2
0

s1

s2

s3

-2

CB
0

s2

x1
5

x2

3/2

3/2

-1/2

s3

-1

XB

Min Ratio
R1 + (2) R3
 
R2 + 1 R3
2

zj cj

HE T WO - PHASE

S IMPLEX M ETHOD

131

First iteration:
Tableau 5.6.16
ci :
CB
0
0

0)

x2
0

s1

s2

s3

s2

16

x1
3

x2
s1

-1

XB

(5

Min Ratio

zj cj

HE T WO - PHASE

S IMPLEX M ETHOD

132

The new basis matrix is:


h
= s2 a2
B

s3

=
B

s2

a2

s1

i.e., (B)
1 , we have
Find the inverse of B,
h
i h
i

1
I3 I3 (B)

.
B
That is,

1/5

3/10

1/10

HE T WO - PHASE

2/5

1/10

3/10

S IMPLEX M ETHOD

0
1
1
1

0
.
1

133


1 a1 = [3 1 1]T
y1 = (B)

1 a2 = [0 1 0]T
y2 = (B)

1 s1 = [0 0 1]T
y3 = (B)

1 s2 = [1 0 0]T
y4 = (B)

1 s3 = [4 1 2]T
y5 = (B)

HE T WO - PHASE

S IMPLEX M ETHOD

134

z1 c1 = CB y1 c1 = [0 8 0][3 1 1]T 5 = 3
z2 c2 = CB y2 c2 = [0 8 0]0 1 0]T 8 = 0
z3 c3 = CB y3 c3 = [0 8 0][0 0 1]T 0 = 0
z4 c4 = CB y4 c4 = [0 8 0][1 0 0]T 0 = 0
z5 c5 = CB y5 c5 = [0 8 0][4 1 2]T 0 = 8

HE T WO - PHASE

S IMPLEX M ETHOD

135

Second iteration:
Tableau 5.6.17
ci :
CB

XB

(5

0)

x1

x2

s1

s2

s3

s2

16

x2

s1

-1

zj cj

z(XB ) = 40

Min Ratio

Since all zj cj 0, the current basic feasible solution is optimal.


The optimal solution is
x1 = 0, x2 = 5 with maximum of z = 40

HE T WO - PHASE

S IMPLEX M ETHOD

136

Example 5 Use two phase simplex method to


Maximise z = 5x1 + 2x2
subject to
2x1 + x2 1
x1 + 4x2 6
x1 , x2 0

HE T WO - PHASE

S IMPLEX M ETHOD

137

Solution:
Since the given LPP is having one constraint with type
constraint we can solve it by using two phase simplex method.
Convert the LPP into standard form by introducing slack variable
s1 0 and surplus variable s2 0 and artificial variable A1 0.

HE T WO - PHASE

S IMPLEX M ETHOD

138

The initial basis matrix is:


B=

s1

sA1

= I2 .

An obvious initial basic feasible solution is s1 = 1, A1 = 6., i.e.,


XB = B 1 b = I2 b = [1 6]T

HE T WO - PHASE

S IMPLEX M ETHOD

139

y1 = B 1 a1 = I2 [2 1]T = [2 1]T
y2 = B 1 a2 = I2 [1 4]T = [1 4]T
y3 = B 1 s1 = I2 [1 0]T = [1 0]T
y4 = B 1 s2 = I2 [0 1]T = [0 1]T
yA1 = B 1 sA1 = I2 [0 1]T = [0 1]T

z1 c1 = CB x1 c1 = [0 1][2 1]T 0 = 1
z2 c2 = CB x2 c2 = [0 1][1 4]T 0 = 4
z3 c3 = CB s1 c3 = [0 1][1 0]T 0 = 0
z4 c4 = CB s2 c4 = [0 1][0 1]T 0 = 1
z5 c5 = CB yA1 c5 = [0 1][0 1]T (1) = 0

HE T WO - PHASE

S IMPLEX M ETHOD

140

Phase I The auxiliary LPP is

Maximise z = 0x1 + 0x2 + 0s1 + 0s2 A1


subject to
2x1

x2

x1

4x2

s1

s2

A1

x1 , x2 , s1 , s2 , A1 0.

HE T WO - PHASE

S IMPLEX M ETHOD

141

The iterative simplex tableaus for the auxiliary LPP are:


Initial iteration:
Tableau 5.7.1
cj :
CB

XB

(0

-1)

x1

x2

s1

s2

A1

Min Ratio

s1

1/1=1

-1

A1

-1

6/4=1.5

-1

-4

zj cj

z (XB ) = 6

From Tableau 5.7.1, we observe that x2 enters into the basis and s1
leaves the basis.

HE T WO - PHASE

S IMPLEX M ETHOD

142

The iterative simplex tableaus for the auxiliary LPP are:


Initial iteration:
Tableau 5.7.2
cj :
CB

XB

(0

-1)

x1

x2

s1

s2

A1

s1

-1

A1

-7

-4

-1

Min Ratio

R2 + (4) R1

zj cj

HE T WO - PHASE

S IMPLEX M ETHOD

143

The new basis matrix is:


h
i
h
= a2
B = s1 sA1 = I2 B

sA1

i.e., B
1 , we have
Find the inverse of B,
h
i h
i
1
I2 I2 B

.
B
That is,

HE T WO - PHASE

S IMPLEX M ETHOD

144

1 a1 = [2 7]T
y1 = B
1 a2 = [1 0]T
y2 = B
1 s1 = [1 4]T
y3 = B
1 s2 = [0 1]T
y4 = B

z1 c1 = CB y1 c1 = [0 1][2 7]T 0 = 7
z2 c2 = CB y2 c2 = [0 1][1 0]T 0 = 0
z3 c3 = CB y3 c3 = [0 1][1 4]T 0 = 4
z4 c4 = CB y4 c4 = [0 1][0 1]T 0 = 1

HE T WO - PHASE

S IMPLEX M ETHOD

145

First iteration:
Tableau 5.7.3
cj :
CB

XB

(0

-1)

x1

x2

s1

s2

A1

x2

-1

A1

-7

-4

-1

zj cj

z (XB ) = 2

Min Ratio

Since all (zj cj ) 0, an optimum basic feasible to the auxiliary


LPP is obtained.
But maximum of z < 0 and an artificial vector A1 appears at
the positive level.
Therefore, the original LPP does not possess any feasible solution.

HE T WO - PHASE

S IMPLEX M ETHOD

146

First iteration:
Tableau 5.7.3
cj :
CB

XB

(0

-1)

x1

x2

s1

s2

A1

x2

-1

A1

-7

-4

-1

zj cj

z (XB ) = 2

Min Ratio

Since all (zj cj ) 0, an optimum basic feasible to the auxiliary


LPP is obtained.
But maximum of z < 0 and an artificial vector A1 appears at
the positive level.
Therefore, the original LPP does not possess any feasible solution.

HE T WO - PHASE

S IMPLEX M ETHOD

147

First iteration:
Tableau 5.7.3
cj :
CB

XB

(0

-1)

x1

x2

s1

s2

A1

x2

-1

A1

-7

-4

-1

zj cj

z (XB ) = 2

Min Ratio

Since all (zj cj ) 0, an optimum basic feasible to the auxiliary


LPP is obtained.
But maximum of z < 0 and an artificial vector A1 appears at
the positive level.
Therefore, the original LPP does not possess any feasible solution.

HE T WO - PHASE

S IMPLEX M ETHOD

148

D ISADVANTAGES OF B IG -M M ETHOD OVER T WO - PHASE M ETHOD

D ISADVANTAGES OF B IG -M M ETHOD OVER T WO - PHASE M ETHOD

149

1.
Even though Big-M method can always be used to check
the existence of a feasible solution it may be
computationally inconvenient because of the manipulation
of the constant M .
On the other hand, two-phase method eliminates the
constant M from the calculations.
2.
Another difficulty arises especially when the problem is to be
solved on a digital computer.
To use a digital computer, M must be assigned some
numerical value which is much larger than the values
c1 , c2 , in the objective function.
But a computer has only a fixed number of digits.

D ISADVANTAGES OF B IG -M M ETHOD OVER T WO - PHASE M ETHOD

150

Potrebbero piacerti anche