0% found this document useful (0 votes)
40 views7 pages

Simplex Method for Linear Programming

Uploaded by

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

Simplex Method for Linear Programming

Uploaded by

Yogendra Kshetri
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Unit 2 Optimization

Unit 2.2 Linear programming II: Simplex Method

Simplex method, Solution to maximization problems, solution to minimization problems, Big-M method, some
special cases in linear programming

Algorithm of General Form into Standard Form:

1. Check whether the objective function of LPP is maximized or minimized. If it is to be minimized then we convert
'
it into a problem of maximization by Max 𝑍 = - Min Z

RI
2. Check all the decision variables are ≥ 0 if any decision variables are unrestricted.

PA
2𝑥1 + 𝑥2 ≤ 4; 𝑥1≥0 and 𝑥2 is unrestricted.

( ' ''
)
2𝑥1 + 𝑥2 − 𝑥2 ≤ 4; 𝑥1, 𝑥2, 𝑥2 ≥ 0
' ''

A
3. Express the problem in standard form by introducing slack or surplus variable to convert the inequality constraints

K
into equation. When,

≤ Add slack variable


SH
≥ Subtract surplus variable

= Nothing
A

4. Check whether all 𝑏𝑖(𝑖 = 1, 2, ……, 𝑛) are positive or not. If any𝑏𝑖 is negative then multiply the in equation of
constraints by – 1.
K

Algorithm of Simplex Method:


A

1. Convert the given general LPP into standard LPP.


PR

(i) Objective function of LPP must be maximized. If it is to be minimized then we convert it into a problem of
'
maximization by Maximize 𝑍 = Maximize Z

(ii) Check all the decision variable is greater than zero.


Y

(iii) Express the problem in standard form by introducing slack or surplus variable to convert the inequality
JA

constraints into equation.

(iv) All the values of right hand side must be positive.

2. Write the values of initial basic feasible solution.

3. Write the standard form LPP into matrix form.

4. Construct the initial Simplex table.

5. Calculate the values of 𝑍𝑗 − 𝐶𝑗 and check the basic feasible solution for optimality.
𝑍𝑗 − 𝐶𝑗 = 𝐶𝑗 × 𝐵𝑥 − 𝐶𝑗

(i) If all 𝑍𝑗 − 𝐶𝑗≥0, the optimal solution will obtained.

(ii) If at least one 𝑍𝑗 − 𝐶𝑗 is negative value then indicate by an arrow and this column is called key-column.

(iii) If more than one 𝑍𝑗 − 𝐶𝑗 is negative value then choose the most negative value of them and this column is
called key-column.

6. Calculate the minimum ratio.

RI
𝑆𝑜𝑙𝑢𝑡𝑖𝑜𝑛
Minimum ratio = 𝐶𝑘
, 𝐶𝑘= key-column > 0 but less than or equal to zero, then not find ratio.

PA
7. Construct the new Simplex table by entering incoming vector.

8. Repeat the step 5 and 6.

A
Artificial variable:

K
Example: Use the Simplex Method to solve the following LP problem.

Maximize Z = 3x1 + 5x2 + 4x3


SH
Subject to the constraints:

2x1 +3 x2 ≤ 8
A

2𝑥2 + 5𝑥3 ≤ 10
K

3x1 + 2x2 + 4x3 ≤ 15


A

𝑥1, 𝑥2, 𝑥3 ≥ 0
PR

General form of LP problem change in standard form of LPP, we have

Maximize Z = 3x1 + 5x2 + 4x3 + 0 s1 + 0 s2 + 0 s3

Subject to the constraints:


Y

2x1 + 3x2 +0x3 + s1 + 0s2 + 0s3 = 8


JA

0𝑥1 + 2𝑥2 + 5x3 + 0s1 + s2 + 0s3 = 10

3x1 + 2x2 + 4x3 + 0s1 + 0s2 + s3 = 15

𝑥1, 𝑥2, 𝑥3 ≥ 0
Where, s1, s2 and s3 are slack variable (unused resources) with cost zero.

Simplex table I

Basic 𝐶𝑗 3 5 4 0 0 0 Solution Ratio


variable
coefficient
Basic variable 𝑥1 𝑥2 𝑥3 𝑠1 𝑠2 𝑠3
𝐶𝑗
Bx
0 𝑠1 2 3 0 1 0 0 8 8/3

RI
0 𝑠2 0 2 5 0 1 0 10 5
0 𝑠3 3 2 4 0 0 1 15 15/2

PA
𝑧𝑗 0 0 0 0 0 0
𝐶𝑗 − 𝑍𝑗 3 5 4 0 0 0

A
Where, for Maximize 𝐶𝑗 − 𝑍𝑗 ≤ 0 and Minimize 𝐶𝑗 − 𝑍𝑗 ≥ 0, key column, key row and key element, x3 is entering

K
variable and s1 is leaving variable.

𝑘𝑒𝑦 𝑟𝑜𝑤 𝑒𝑙𝑒𝑚𝑒𝑛𝑡 2 3 0 1 0 0 8


New R1 element = 𝑘𝑒𝑦 𝑒𝑙𝑒𝑚𝑒𝑛𝑡
= 3
, 3
, 3
, 3
, 3
, 3
, 3
= 2/3, 1, 0, 1/3, 0, 0, 8/3
SH
Old R2 element – key column element × New R1 Old R3 element – key column element × New R1
0 – 2 × 2/3 = -4/3 3 – 2 × 2/3 = 5/3
2–2×1=0 2–2×1=0
A

5–2×0=5 4–2×0=4
0 – 2 × 1/3 = -2/3 0 – 2× 1/3 = - 2/3
1–2×0=1 0 – 2× 0 = 0
K

0–2×0=0 1 – 2× 0 = 1
10 – 2 × 8/3= 14/3 15 – 2× 8/3 = 29/3
A

Iteration I
PR

Basic 𝐶𝑗 3 5 4 0 0 0 Solution Min Ratio


variable
Basic variable 𝑥1 𝑥2 𝑥3 𝑠1 𝑠2 𝑠3
coefficient
B
CB
5 𝑥2 2/3 1 0 1/3 0 0 8/3 ---
Y

0 𝑠2 -4/3 0 5 -2/3 1 0 14/3 14/15


JA

0 𝑠3 5/3 0 4 -2/3 0 1 29/3 29/12


𝑧𝑗 10/3 5 0 5/3 0 0

𝐶𝑗 − 𝑍𝑗 -1/3 0 4 -5/3 0 0

−4 −2 14
𝑘𝑒𝑦 𝑟𝑜𝑤 𝑒𝑙𝑒𝑚𝑒𝑛𝑡 0 5 1 0
New R2 element = 𝑘𝑒𝑦 𝑒𝑙𝑒𝑚𝑒𝑛𝑡
= 5
3
, 5
, 5
, 3
5
, 5
, 5
, 3
5
= -4/15, 0, 1, -2/15, 1/5, 0, 14/15

Old R1 element – key column element × New R2 Old R3 element – key column element × New R2
2/3 –0 × (-4/15) = 2/3 5/3 – 4× (-4/5) = 41/15
1 – 0×0 = 1 0–4×0=0
0 – 0×1 = 0 4–4×1=0
1/3 – 0×(-2/15) = 1/3 -2/3– 4× (-2/15) = - 2/15
0 – 0×1/5 = 0 0 – 4× 1/5 = -4/5
0 – 0×0 = 0 1 – 4× 0 = 1
8/3 – 0×14/15 = 8/3 29/3 – 4× 14/15 = 89/15
Iteration II

Basic 𝐶𝑗 3 5 4 0 0 0 Solution Min Ratio


variable
coefficient Basic variable 𝑥1 𝑥2 𝑥3 𝑠1 𝑠2 𝑠3

RI
𝐶𝑗 B
5 𝑥2 2/3 1 0 1/3 0 0 8/3 4
4 𝑥3 -4/15 0 1 - 2/15 1/5 0 14/15 -2/7

PA
0 𝑠3 41/15 0 0 -2/15 -4/5 1 89/15 89/41
𝑧𝑗 34/15 5 4 17/15 4/5 0
11/15 0 0 -17/15

A
𝐶𝑗 − 𝑍𝑗 -4/5 0

K
𝑘𝑒𝑦 𝑟𝑜𝑤 𝑒𝑙𝑒𝑚𝑒𝑛𝑡 41 15 15 15 −2 15 −4 15 15 89 15
New R3 element = 𝑘𝑒𝑦 𝑒𝑙𝑒𝑚𝑒𝑛𝑡
= 15
× 41
, 0× 41
, 0× 41
, 15
× 41
, 5
× 41
, 1× 41
, 15
× 41
SH
= 1, 0, 0, -2/41, -12/41, 15/41, 89/41

Old R1 element – key column element × New R3 Old R2 element – key column element × New R3
2/3 –2/3 × 1= 0 -4/15 + 4/15× 1 = 0
A

1 – 2/3×0 = 1 0 + 4/15 × 0 = 0
0 – 2/3×0 = 0 1 + 4/15 × 0 = 1
1/3 – 2/3×(-2/41) = 15/41 -2/15 + 4/15× (-2/41) = - 6/41
K

0 – 2/3×(-12/41) = 8/41 1/5 + 4/15× (-12/41) = 5/41


0 – 2/3×15/41 = -10/41 0 + 4/15× 15/41 = 4/41
A

8/3 – 2/3×89/41 = 50/41 14/15 + 4/15× 89/41 = 62/41


Iteration III
PR

Basic 𝐶𝑗 3 5 4 0 0 0 Solution Min Ratio


variable
Basic variable 𝑥1 𝑥2 𝑥3 𝑠1 𝑠2 𝑠3
coefficient
B
𝐶𝑗
Y

5 𝑥2 0 1 0 15/41 8/41 -10/41 50/41


4 𝑥3 0 0 1 - 6/41 5/41 4/41 62/41
JA

3 𝑥1 1 0 0 -2/41 -12/41 15/41 89/15


𝑧𝑗 3 5 4 45/41 24/41 11/41
𝐶𝑗 − 𝑍𝑗 0 0 0 -45/41 -24/41 -11/41

In maximize 𝐶𝑗 − 𝑍𝑗 ≤ 0 follows then closed after, then solution is x1 = 89/41, x2 = 50/41, x3 = 62/41, then
maximum value of Z = 3 × 89/41 + 5×50/41+4×62/41 = 765/41.

Example: Solve the following LPP using Simplex method.


Minimize Z = 2x1 – 3x2 + 6x3

Subject to:

3x1 – x2 + 2x3 ≤ 7

2x1 – 4x2 ≥ - 12

- 4x1 + 3x2 + 8x3 ≤ 10

𝑥1, 𝑥2, 𝑥3 ≥ 0

RI
Example 2: A company makes two kinds of leather belts, belt A and belt B. Belt A is a high quality belt and belt B is
of lower quality. The respective profits are Rs 4 and Rs 3 per belt. The production of each of type A requires twice

PA
as much time as a belt of type B, and if all belts were of type B, the company could make 1,000 belts per day. The
supply of leather is sufficient for only 800 belts per day (both A and B combined). Belt A requires a fancy buckle
and only 400 of these are available per day. There are only 700 buckles a day available for belt B.

A
What should be the daily production of each type of belt? Formulate this problem as an LP model and solve it using
the simplex method.

K
Solution:

Let x1 and x2 be the number of belts of type A and B, respectively, manufactured each day. Then the LP
SH
model would be as follows:

Maximize Z = 4x1 + 3x2


A

Subject to the constraints


K

Time availability: 2x1 + x2 ≤ 1,000

Supply of leather: x1 + x2 ≤ 800


A

Buckles availability x1 ≤ 400 and x2 ≤ 700


PR

And x1, x2 ≥ 0

Example 3: Solve the following LPP using Simplex method.


Y

Maximize Z = 16x1 + 17x2 + 10x3

Subject to:
JA

𝑥1 + 𝑥2 + 4𝑥3 ≤ 2000

2x1 + x2 + x3 ≤ 3600

𝑥1 + 2𝑥2 + 2𝑥3 ≤ 2400

𝑥1 ≤ 30
𝑥1, 𝑥2, 𝑥3 ≥ 0

Big M Method Maximization Problem:

In Big M Method to convert to standard form

≤ Add slack variable

≥ Subtract surplus variable and add an artificial variable

= Add an artificial variable

RI
Artificial variable:

It is a fictitious and cannot have any physical meaning. It is merely a device to get the starting basic feasible

PA
solution, so that the Simplex procedure may be adopted as usual until the optimal solution is obtained. Cost of
artificial variable is – M. M is very-very large value and – M is very-very small value, i.e. – 10M is less than – 5M

A
Steps for Big M Method:

Solve the modified LPP by Simplex method until the any one of the three cases may arise.

K
(i) If no artificial variable appear in the basis and the optimality conditions are satisfied, then the current solution is
an optimal basic feasible solution.
SH
(ii) If at least one artificial variable is there in the basis at zero level and the optimality conditions is satisfied, then
the current solution is an optimal basic feasible solution.
A

(iii) If at least one artificial variable is appear in basis at positive level and the optimality conditions is satisfied, then
the original problem has no feasible solution.
K

Example: Charne’s Big M Method or Penalty Method to solve the following LP Problem.
A

Max Z = 𝑥1 − 𝑥2 + 3𝑥3
PR

Subject to:

𝑥1 + 𝑥2 ≤ 20

𝑥1 + 𝑥3 = 5
Y
JA

𝑥2 + 𝑥3 ≥ 20

𝑥1, 𝑥2, 𝑥3 ≥ 0

Solution: Given,
JA
Y
PR
A
K
A
SH
K
A
PA
RI

Common questions

Powered by AI

Slack variables are added to less-than-or-equal-to constraints to convert them into equalities, representing unused resources with no cost . Artificial variables are introduced when addressing equality constraints or greater-than inequalities in the Big M method . Unlike slack variables, artificial variables are not physically meaningful; they are temporary constructs used to find basic feasible solutions. Their high costs in the objective function ensure they leave the basis, highlighting differences in use and purpose .

The Big M method is employed to handle artificial variables in linear programming problems, especially when constraints include equalities or greater-than inequalities . By assigning large costs to artificial variables, it ensures they are removed from the solution basis, allowing the method to either find a feasible solution or confirm infeasibility when artificial variables remain in the basis at positive levels . This method thus facilitates handling cases that cannot initially be expressed in standard Simplex form .

In the Simplex method, the entering variable is chosen based on the most negative zj – cj value, indicating the greatest potential for improving the objective function . The leaving variable is determined by the minimum ratio test, calculated as the ratio between basic variable values and corresponding coefficients in the key column, ensuring non-negativity constraints are satisfied. This dual selection process continues iteratively, facilitating stepwise optimization towards an optimal solution .

The Simplex method indicates no feasible solution when one or more artificial variables remain in the basis with a positive value even after achieving what would normally be an optimal solution . This scenario arises when constraints inherently conflict or lack feasible intersections with the objective function's requirements. The continued presence of artificial variables signifies constraints that cannot be satisfied simultaneously, confirming infeasibility .

The Simplex method assesses optimality through the evaluation of the differences between the coefficients of the objective function and the current basic feasible solution, known as the zj - cj values . If all these differences are non-negative, the solution is considered optimal. If any are negative, the corresponding column is identified as a key column, and a pivot operation is performed to improve the solution iteratively until optimality is achieved or no further improvements are possible .

To solve a linear programming problem using the Simplex method, one must first convert the linear program into its standard form, ensuring the objective function is maximized and all constraints are expressed as equations through the introduction of slack or surplus variables . Next, a Simplex table is constructed, and the initial basic feasible solution is calculated. The values of variables are checked for optimality, and the process continues by selecting entering and leaving variables to update the Simplex table iteratively until an optimal solution is obtained or no solution is found .

Duality in the Simplex method provides a theoretical framework where every linear program has a corresponding dual problem, and solutions to these are linked . Solving the primal using the Simplex method concurrently solves the dual, allowing insights into economic interpretations like shadow prices and resource valuations. Advantages include verifying solution optimality, understanding the cost impacts of constraints, and informing sensitivity analysis, thus broadening problem-solving perspectives and application scopes .

The Simplex method can identify multiple optimal solutions if, upon reaching an optimal solution, one or more non-basic variables have a zj – cj value of zero, indicating an alternate optimal solution is possible . By performing additional pivots on these non-basic variables with zero difference, different optimal solutions can be explored. This property allows for flexibility in selecting from equally optimal outcomes based on additional criteria or preferences in practical scenarios .

Computational tools have drastically improved the efficiency and accessibility of the Simplex method by automating iterative calculations, managing complex datasets, and reducing human error in operations . Advanced software can handle large-scale problems with multiple constraints and variables faster than manual computations, extending the method's applicability to real-world scenarios such as logistics and finance. Moreover, these tools allow practitioners to focus on model quality and results interpretation, enhancing decision-making processes grounded in optimization .

In the Simplex method, it is essential to convert minimization problems into maximization problems to apply the algorithm consistently, as it is originally designed for maximization . This conversion is achieved by multiplying the objective function by -1, thereby changing the minimization objective to a maximization one that can be processed by the algorithm . This transformation facilitates uniformity and avoids altering algorithmic steps for different types of optimization objectives .

You might also like