0% found this document useful (0 votes)
9 views

SIMPLEX METHOD

The document explains the Simplex method for solving linear programming problems, highlighting its effectiveness and applicability to problems with multiple variables under linear constraints. It details key terminology such as slack, surplus, and artificial variables, and outlines the systematic steps involved in the Simplex method, including converting inequalities to equalities and constructing the initial simplex table. Additionally, the document provides examples of linear programming problems solved using the Simplex method, illustrating the computational procedure and optimality tests.

Uploaded by

stephen rahul
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views

SIMPLEX METHOD

The document explains the Simplex method for solving linear programming problems, highlighting its effectiveness and applicability to problems with multiple variables under linear constraints. It details key terminology such as slack, surplus, and artificial variables, and outlines the systematic steps involved in the Simplex method, including converting inequalities to equalities and constructing the initial simplex table. Additionally, the document provides examples of linear programming problems solved using the Simplex method, illustrating the computational procedure and optimality tests.

Uploaded by

stephen rahul
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 45

Simplex method of

solving Linear
programming
problem[L.P.P]
SIMPLEX METHOD

Many different methods have been proposed to solve


linear programming problems, but simplex method has
proved to be the most effective. This technique will
nurture your insight needed for a sound understanding of
several approaches to other programming models, which
will be studied in subsequent chapters.

This method is applicable to any problem with a larger


number of variables(More than two variables) ,subject
to a set of linear constraints.
Basic Terminology
 Slack variable
It is a variable that is added to the left-hand side of a less
than or equal to type constraint to convert the constraint
into an equality.
In economic terms, slack variables represent left-over or
unused capacity.

Specifically:
a11x1 + a12x2 + a13x3 + .........+ a1nxn £ b1 can
be written as
a11x1 + a12x2 + a13x3 + .........+ a1nxn + si = bi
Where si = slack Variable
Surplus variable
It is a variable subtracted from the left-hand side of a greater than
or equal to type constraint to convert the constraint into equality. It
is also known as negative slack variable.
In economic terms, surplus variables represent over fulfillment of
the requirement.

Specifically:
a11x1 + a12x2 + a13x3 + .........+ a1nxn ³ bi can be
written as
a11x1 + a12x2 + a13x3 + .........+ a1nxn - si = bi
Where si = surplus variable.
Artificial variable

It is a non negative variable introduced to


facilitate the computation of an initial basic
feasible solution. In other words, a variable
added to the left-hand side of a greater than or
equal to type constraint to convert the
constraint into equality is called an artificial
variable.
STEPS OF SIMPLEX METHOD
Consider the general linear programming problem
Maximize z = c1x1 + c2x2 + c3x3 + .........+ cnxn

Subject to
a11x1 + a12x2 + a13x3 + .........+ a1nxn £ b1
a21x1 + a22x2 + a23x3 + .........+ a2nxn £ b2
.........................................................................
am1x1 + am2x2 + am3x3 + .........+ amnxn £ bm
x1, x2,....., xn ³ 0

Where:
cj (j = 1, 2, ...., n) in the objective function are called the cost or profit
coefficients.
bi (i = 1, 2, ...., m) are called resources constraints.
aij (i = 1, 2, ...., m; j = 1, 2, ...., n) are called technological
coefficients or input-output coefficients.
Converting inequalities to equalities

Introducing slack variables to convert inequalities to


equalities
a11x1 + a12x2 + a13x3 + .........+ a1nxn + s1 = b1
a21x1 + a22x2 + a23x3 + .........+ a2nxn + s2 = b2
........................................................................
am1x1 + am2x2 + am3x3 + .........+ amnxn + sm = bm
x1, x2,....., xn ³ 0
s1, s2,....., sm ³ 0
Computational procedure of simplex method

It consists of the following steps systematically:-

STEP I: - If the given problem is of minimization, Convert it


into the maximization problem.

For this, multiply both sides of the objective function


by -1 and put – Z = Z

If v is the maximum value of Z then -V will be the


minimum value of Z.
STEP II: - Make all the bi’s non-negative.
The right hand side (R.H.S) of each of the constraint
should be non-negative. If the Linear Programming
problem (L.P.P) has a constraint for which a negative bi is
given, it should be converted into positive value by
multiplying both side of the constraints by -1.

STEP III: - Convert inequalities of constraints


into equations.
For this introduce slack or surplus variables. The
coefficients of slack or surplus variables in the objective
functions are zero.

STEP IV: - Find the initial basic feasible


solution.
STEP V: - Construct the initial simplex table
B CB CJ C1 C2 ... CK … Cn Cn+1 Cn+2 … Cn+m Min.
Ratio
XB X1(=α1) Y2(=α2) YK(=αk) Yn(=αn) Yn+1(β1) Yn+2(β2) Yn+m(βm)

Yn+1 CB1 = o XB1 = b1 Y11 = a11 Y12 = a12 Y1k = a1k Y1n = a1n 1 0 0

Yn+2 CB2 = o XB2 = b2 Y21 = a21 Y22 = a22 Y2k = a2k Y2n = a2n 0 1 0

Yn + r CBr = o XBr=br Yr1 = ar1 Yr2 = ar2 Yr n = a r n


Yrk = ark

XBm=bm Ym1 = am1 Ym2 = am2 Ymk = amk Ymn = amn 0 0 1


Yn + m CBm

Z = CB XB = 0 ∆J ∆1 ∆2 ∆K ∆n ∆n+1 ∆n+2 ∆n+m


STEP VI: - Test the solution for optimality.
Compute the net evaluation ∆J for each variable XJ by
using the formula
ZJ = CJ - CBXJ
Note that in the starting simplex table ∆J’S are same as CJ’S.

Optimality test:-

(A) If ZJ ≤ 0 for all J, the solution under consideration is


optimal
(i) Alternative optimal solution will exist if any ∆J (for non-
basic variable) is also zero.

(ii) If ZJ ˂ 0 for all J, corresponding to non-basic variables,


then the solution is unique optimal solution.
(b) If ZJ ˃ 0 for any J i.e., if at least one ZJ is positive
the solution under test is not optimal.

(c) If corresponding to maximum positive ZJ , all


elements of the column ZJ are negative or Zero, the
solution under test will be unbounded

(d) If optimality condition is satisfied but the value of


at least one artificial variable present in the basis is
non-zero, the problem will have no feasible
solution
STEP VII: - Select the entering (incoming)
vector and departing (outgoing) vector.)

(a) To find incoming vector: - The incoming vector αk is


always selected corresponding to the largest positive
value of ZJ. If maximum value of ZJ occurs for more than
one αJ then we select any of these vectors as incoming
vector
(b) To find outgoing vector: - The departing vector βr is
selected corresponding to that value of r for which

XBr = Min XBi , XiK ˃ 0


i XiK

If αk is the incoming vector.


STEP VII: - Find out key element (Pivot
element)

If αk is the entering vector and βr is the outgoing vector


then the element Yrk which lies at the intersection of
minimum ratio arrow ( ) and the incoming vector
arrow ( ) is called the pivot element (key element)
We put this element in the bracket

STEP IX: - Test the improved basic


feasible solution (B.F.S) for optimality

If it is not optimum, repeat steps 7 & 8 until we obtain an


optimum solution.
Q1. Solve the following LPP by simplex
method:
Maximize Z = 40 X1 + 35X2
Subject to
2X1 + 3X2 ≤ 60
4X1 + 3X2 ≤ 96
and Non-Negative Restriction
X1, X2 ≥ 0
Solution:-

Step I: - The given problem is of maximization and all the


bi’s are already positive.

Step II: - converting the inequalities of constraints into


equations by introducing slack variables S1 and S2
Maximize Z = 40 X1 + 35X2 + 0S1 + 0S2
Subject to
2X1 + 3X2 + S1 = 60
4X1 + 3X2 + S2 = 96
And Non-Negative Restriction (N.R) X1, X2 ≥ 0
The above problem can be converted into the
standardized form as given below:-
Maximize Z = 40 X1 + 35X2 + 0S1 + 0S2
Subject to
2X1 + 3X2 + S1 + 0S2 = 60
4X1 + 3X2 + 0S1 + S2 = 96
and Non-Negative Restriction
X1, X2, ≥ 0
Step III: - Construct the initial simplex table:-

CJ 40 35 0 0 Minimum Ratio
BASIC CB XB / X1
XB X1 X2 S1 S2

S1 0 60 2 3 1 0 60 / 2 = 30

96 / 4 = 24(Minimum)
S2 0 96 4 3 0 1

Z = CB XB = 0 Cj - ZJ 40 35 0 0

Since all ∆J are not less than or equal to zero, therefore the solution is
not optimal.
Cj - ZJ = CJ - CBXJ
Cj - Z j = C1 - CBX1 = 40 – (0, 0) (2, 4)
= 40
Step IV: - Divide the second row containing the key element by 4 to make it
unity R2 = R2 / 4
Subtracting 2times of the second row from the first row
R1 = R1 - 2R2
CJ 40 35 0 0 Minimum Ratio
BASIC CB XB / X2
XB X1 X2 S1 S2

S1 0 12 0 3/2 1 -1/2 8(Minimum)

X1 40 24 1 3/4 0 1/4 32

Z = CB XB = 960 Cj - ZJ 0 5 0 -10

Since all CJ – Zj are not less than or equal to zero, therefore the solution is not
optimal.
Z J = C J – C BX J
Z1 = CBX1 = (0, 40) (0, 1) = 0x 0 + 40x1 = 40
Z2 = CBX2 = (0, 40) (3 / 2 , 3 / 4) = 0x3/2 + 40 x 3/4= 30
Z3 = CBX3 =(0, 40) (1, 0) = 0x1 + 40 x0 = 0
Step V: -To bring Y2 in place of Y3 we proceed in the following manner
Dividing the first row by 3/2 to make the key element unity i.e.
R1 = 2 R 1 / 3

And R2 = R 2 - 3 R 1
CJ 440 35 0 0 Minimum Ratio
BASIC CB
XB X1 X2 S1 S2

X2 35 8 0 1 2/3 - 1/3

X1 40 18 1 0 -1/2 1/2

Z = CB XB = 1000 Cj - Zj 0 0 - 10/3 - 25/3

Since all Cj - Zj ≤ 0 therefore the above solution is optimal


Hence the optimal solution is
Max Z = 1000

X 1 = 18
Q2. Solve the following LPP by simplex
method:
Maximize Z = 5 X1 + 10X2 + 8X3
Subject to
3X1 + 5X2 + 2X3 ≤ 60
4X1 + 4X2 + 4X3 ≤ 72
2X1 + 4X2 + 4X3 ≤ 100
and Non-Negative Restriction (N.R)
X1, X2, X3 ≥ 0
Solution:-

Step I: - The given problem is of maximization and all the


bi’s are already positive.

Step II: - converting the inequalities of constraints into


equations by introducing slack variables X3 and X4
Maximize Z = 5 X1 + 10X2 + 8X3 + 0S1 + 0S2 + 0S3
Subject to
3X1 + 5X2 + 2X3 + S1 = 60
4X1 + 4X2 + 4X3 + S2 = 72
2X1 + 4X2 + 4X3 + S3 = 100
And Non-Negative Restriction (N.R) X1, X2, X3 ≥ 0
The above problem can be converted into the
standardized form as given below:
Maximize Z = 5 X1 + 10X2 + 8X3 + 0S1 + 0S2 + 0S3
Subject to
3X1 + 5X2 + 2X3 + 1S1 + 0S2 + 0S3 = 60
4X1 + 4X2 + 4X3 + 0S1 + 1S2 + 0S3 = 72
2X1 + 4X2 + 4X3 + 0S1 + 0S2 + 1S3 = 100

and Non-Negative Restriction X1, X2, X3 ≥ 0


Step III: - Construct the initial simplex table:-
CJ 5 10 8 0 0 0 Minimum Ratio
BASIC CB XB / X2
XB X1 X2 X3 S1 S2 S3

S1 0 60 3 2 1 0 0 60 / 5 = 12
5 (Minimum)
S2 0 72 4 4 4 0 1 0
72 /4 = 18

S3 0 100 2 4 5 0 0 1 100 / 4 = 25

Z = CB XB = 0 ∆J 5 10 8 0 0 0

Since all ∆J are not less than or equal to zero, therefore the solution is
not optimal.
Step IV: - Divide the second row containing the key element by 5 to make it
unity R1 = R1 / 5
R2 = R2 - 4R1
R3 = R3 - 4R1
CJ 5 10 8 0 0 0 Minimum Ratio
BASIC CB XB / X3
XB X1 X2 X3 S1 S2 S3

X2 10 12 3/5 1 2/5 1/5 0 0 30

0 24 8/5 0 - 4/5 1 0 10
S2 12/5 (Minimum)

S3 0 52 -2/5 0 17/5 - 4/5 0 1 15.29

Z = CB XB = ZJ -1 0 4 -2 0 0
120
R1 = R 1 – 2 R2 R3 = R3 – 17 R2
Step V: - R2 = 5 R2
12
5 5

CJ 5 10 8 0 0 0 Minimum Ratio
BASIC CB
XB X1 X2 X3 S1 S2 S3

X2 10 8 1/3 1 0 1/3 - 1/6 0

X3 8 10 2/3 0 1 - 1/3 5/12 0

S3 0 18 -8/3 0 0 1/3 -17/12 1

Z = CB XB = ZJ - 11/3 0 0 - 2/3 -5/3 0


160
Since all ∆J ≤ 0 therefore the above solution is
optimal
Hence the optimal solution is
Max Z = 160

X1 = 0
X2 = 8
and X3 = 10
Q3. Solve the following LPP by simplex method:-
Maximize Z = 3 X1 + 2X2 + 2X3
Subject to
X1 + 2X2 + 2X3 ≤ 10
2X1 + 4X2 + 3X3 ≤ 15
And Non-Negative Restriction (N.R) X1, X2, X3 ≥ 0
Solution:-

Step I: - The given problem is of maximization and all the


bi’s are already positive.

Step II: - converting the inequalities of constraints into


equations by introducing slack variables X3 and X4
Maximize Z = 3X1 + 2X2 + 2X3 + 0S1 + 0S2
Subject to
X1 + 2X2 + 2X3 + S1 = 10
2X1 + 4X2 + 3X3 + S2 = 15
And Non-Negative Restriction (N.R) X1, X2, X3 ≥ 0
The above problem can be converted into the standardized form as given
below:-
Maximize Z = 3X1 + 2X2 + 2X3 + 0S1 + 0S2
Subject to
X1 + 2X2 + 2X3 + 1S1 + 0S2 = 10
2X1 + 4X2 + 3X3 + 0S1 + 1S2 = 15
And Non-Negative Restriction (N.R) X1, X2, X3 ≥ 0
Step III: - Construct the initial simplex table:-
CJ 3 2 2 0 0 Minimum Ratio
BASIC CB XB / X1
XB X1 X2 X3 S1 S2

S1 0 10 1 2 2 1 0 10

0 15 4 3 0 1 7.5
S2 2 (Minimum)

Z = CB XB = 0 Cj - ZJ 3↑ 2 2 0 0

Zj = (0, 0)( 1,2) = 0x1 + 0x2 = 0

Since all ZJ are not less than or equal to zero, therefore the solution is
not optimal.
Step IV: - Divide the second row containing the key element by 2 to make it unity
R2 = R2 / 2
R1 = R1 – R2

CJ 3 2 2 0 0 Minimum Ratio
BASIC CB XB
XB X1 X2 X3 S1 S2

S1 0 5/2 0 0 1/2 1 -1/2

X1 3 15/2 1 2 3/2 0 1/2

Z = CB XB = Cj - ZJ 0 - 4 - 5/2 0 -3/2
22.5

Since all ∆J ≤ 0 therefore the above solution is optimal


Hence the optimal solution is
Max Z = 22.5
X1 = 7.5

X2 = 0
And X = 0
Q4. Solve the following LPP by simplex method:-
Minimize Z = X1 - 3X2 + 2X3
Subject to
3X1 - X2 + 2X3 ≤ 7
-2X1 + 4X2 ≤ 12
-4X1 + 3X2 + 8X3 ≤ 10
and Non-Negative Restriction (N.R) X1, X2, X3 ≥ 0
Step I: -
The given problem is of Minimization so convert it to maximization
problem by taking the objective function as
Z = -Z
Max Z = - Z = - X1 + 3X2 - 2X3
and all the bi’s are already positive.
Step II: -
converting the inequalities of constraints into equations by
introducing slack variables S1, S2 and S3
Max Z = - Z = - X1 + 3X2 - 2X3 + 0S1 + 0S2 + 0S3
Subject to
3X1 - X2 + 2X3 + S1= 7
-2X1 + 4X2 + X5 + S2 = 12
-4X1 + 3X2 + 8X3 + S3 = 10

And Non-Negative Restriction (N.R) X1, X2, X3 ≥ 0


The above problem can be converted into the standardized form as given
below:-
Max Z = - Z = - X1 + 3X2 - 2X3 + 0S1 + 0S2 + 0S3
Subject to
3X1 - X2 + 2X3 + 1S1 + 0S2 + 0S3 = 7
-2X1 + 4X2 + 0X3 + 0S1 + 1S2 + 0S3 = 12
-4X1 + 3X2 + 8X3 + 0S1 + 0S2 + 1S3 = 10

And Non-Negative Restriction (N.R) X1, X2, X3 ≥ 0


Step III: - Construct the initial simplex table:-
CJ -1 3 -2 0 0 0 Minimum
BASIC CB Ratio
XB X1 X2 X3 S1 S2 S3
XB / S2

S1 0 7 3 -41 2 1 0 0 -7 (Negative)
S2 0 12 -2 0 0 1 0 3 (Minimum)
S3 0 10 -4 8 0 0 1 3.3
3

Z = CB XB = CJ -ZJ -1 3 -2 0 0 0
0
Since all CJ – Zj are not less than or equal to zero, therefore the solution is not optimal.
Step IV: - Divide the second row containing the key element by 4 to make it
unity R 2 = R2 / 4
R1 = R 1 + R 2
R3 = R3 -3 R2
CJ -1 3 -2 0 0 0 Minimum
Basic CB Ratio
XB X1 X2 X3 S1 S2 S3
XB / Y2

5/2
S1 0 10 0 2 1 1/4 0 3 (Minimum)
X2 3 3 -1/2 1 0 0 1/4 0 -6 (Negative)
S3 0 1 -5/2 0 8 0 -3/4 1 -2/5(Negative)

ZJ = CB X B CJ- ZJ 1/2 0 -2 0 -3/4 0


=9

Since all CJ – ZJ are not less than or equal to zero, therefore the solution is not
optimal.
Step V: -To bring Y1 in place of Y4 we proceed in the following manner
R1 = 2 R 1 R2 = R 2 + 1 R 1 and R 3 = R3 + 5R1
5 2 2

CJ -1 3 -2 0 0 0 Minimum
Basic CB Ratio
XB X1 X2 X3 S1 S2 S3

X1 -1 4 1 0 4/5 2/5 1/10 0


X2 3 5 0 1 2/5 1/5 3/10 0
S3 0 11 0 0 10 1 -1/2 1

Z = CB XB ∆J 0 0 -12/5 -1/5 -4/5 0


= 11

Since all ∆J ≤ 0 therefore the above solution is optimal


Hence the optimal solution is

Min Z = - Max Z = - 11

X1 = 4
X2 = 5
X3
=0
Simplex Method
Step 1:The given problem is of Minimization so
convert it to maximization problem by taking the
objective function as
Max Z = - Min Z
Step 2: Converting the inequalities of constraints into
equations by introducing slack variables (S1,S2,…Sn)
& convert ≥ constraints to ≤ constraints.

Step 3: Prepare Simplex table.


Simplex Method
Step 4: Compute Cj – Zj;
if all Cj – Zj ≤ 0, solution is unbounded
If at least one of Cj – Zj > 0;
we proceed to next step.

Step 5: Find Max Cj – Zj i.e Key column

Step 6: Find the Ratio (XB/Key column).

Step 7: Select Min Positive Ratio i.e Key row.

Step 8: Find Key element.


Simplex Method
Step 9: Prepare next table.

(i) Divide the key row by key element.


(ii) Convert basic variables to identity matrix.
(iii) Find new element by applying formula.

New element = old element _ Product of corresponding elements of key row & key column
Key element

Step 10: Find Initial Basic Feasible solution.


 60 – 96x2/4 = 12

You might also like