Chap 2 (Linear Programing by Simplex)
Chap 2 (Linear Programing by Simplex)
Yabsiel Gashaw
Yabsiel Gashaw
• Step 1 Formulate LPP Model
• Step 2 Standardize the problem
• i.e. Convert constraint inequality into equality form by introducing a
variable called Slack variable.
• Slack Variables:
• A slack variable(s) is added to the left hand side of a < constraint to
covert the constraint inequality in to equality. The value of the slack
variable shows unused resource.
• A slake variable emerges when the LPP is a maximization problem.
• Slack variables represent unused resource or idle capacity.
• Thus, they don’t produce any product and their contribution to profit is
zero.
• Slack variables are added to the objective function with zero
coefficients.
• Let that s1, s2, and s3 are unused labor, machine and marketing hrs
respectively.
Yabsiel Gashaw
The Simplex Method
Yabsiel Gashaw
Basic Terms Involved in Simplex
Procedure
1. Standard Form: when all constraints are written
as equalities it is called standard form
2. Utilization of Resources
I. Slack Variable: A Variable added to the LHS of a ‘less-
than or equal to’ constraint to convert the constraint into
an equality is called a slack variable.
II. Surplus variable: A variable subtracted from the LHS of
the “greater than or equal to” constraints to convert the
constraints into equality is called a surplus variable.
Yabsiel Gashaw
3. Basic variable: for m simultaneous linear
equations in n variables(n>m), a solution obtained by
setting (n-m) variables equal to zero and solving for
the remaining m variables is called a basic variables
4. Basic feasible solution: a basic feasible solution
is a basic solution for which the variables have a
value of greater than or equal zero.
5. Simplex Tableau: is a table used to keep track of
the calculation that made at each of the iteration
when the simplex solution method is employed.
7. Zj Row: the numbers in this row under each
variable represents the total contribution of outgoing
profit when one unit of a non-basic variable is
introduced into this in place of a basic variable.
Yabsiel Gashaw
8. Cj – Zj Row: the row containing the net profit that will result
from introducing one unit of the variable indicated in that
column in the solution numbers in index rows are also known
as shadow prices.
9. Pivot column: the column with the largest positive number
in the net evaluation row of maximization problem, or the
largest negative number in the net evaluation row in the cost
minimization problem(Cj-Zj)
Incoming variables
▪ An incoming variable is currently a non-basic variable (the current
value is zero) and will be changed to a basic variable (introduced
into the solution).
11/29/2022
Yabsiel Gashaw
10. Pivot row: the row corresponding to the variable
that will leave the basis in order to make room for the
entering variable.
Outgoing Variable
▪ To determine the outgoing variable, compute the
ratio of the Quantity to the coefficient of the incoming
variable for each basis row.
▪ For both the maximization and minimization
problems, the outgoing variable is the basic variable
with the smallest ratio.
▪ The coefficient of the incoming variable in the
outgoing row is called the pivot element/number.
Yabsiel Gashaw
11. Pivot number: the element at the
intersection of the pivot row and pivot column
11/29/2022
Yabsiel Gashaw
The procedures of Simplex Method
11/29/2022
Yabsiel Gashaw
• To convert a ≤ constraint to an equality, define for each
constraint a slack variable [si] (si = the slack variable for
the ith constraint).
– A slack variable is the amount of the resource unused
in the ith constraint.
• To convert a ≥ constraint to an equality constraint, define
a surplus variable [Si] (si = the excess variable for the ith
≥ constraint.
• Since, slack and surplus variables are insignificant with
no contribution, they are represented with coefficient of
zero in the objective function.
Yabsiel Gashaw
Example: Constraints with ≤ sign
• Non Standard form Standard form
X1+2X2 ≤ 6 X1+2X2+S1= 6
• where X1 and X2 are decision variables and S1 is a slack
variable, added to the smaller side of the inequality.
Example: Constraints with ≥ sign
• Non Standard form Standard form
X1+2X2 ≥ 6 X1+2X2-s1= 6
• where X1 and X2 are decision variables and s1 is a surplus
variable, added to the smaller side of the inequality.
Yabsiel Gashaw
• To find a unique solution, the number of variables should
not exceed the number of equations.
• When the number of variables is more than the number of
equations, the number of solutions is unlimited.
• So as to get a unique solution, we have to set at least (n-
m) variables to zero, where:
n = the number of variables and
m = the number of equalities.
• Those variables that are set to zero are called non basic
variables indicating they are not in the solution.
• The variables that are in solution are called basic variable.
Yabsiel Gashaw
• For a set of m simultaneous equations in n variables (
n>m), a solution obtained by setting ( n-m) variables
equal to zero and solving for remaining m equations
in m variables is called a basic solution
• Any basic solution in which all variables are
nonnegative is called a basic feasible solution
(or BFS).
Yabsiel Gashaw
Let Us do the one we did in Graphics method
A Maximization Problem
Example 1:
Consider two models of color TV sets; Model A and B, are
produced by a company to maximize profit. The profit realized
is $300 from A and $250 from set B. The limitations are
a. availability of only 40hrs of labor each day in
the production department.
b. a daily availability of only 45 hrs on machine time
c. ability to sale 12 set of model A.
How many sets of each model will be produced each day so
that the total profit will be as large as possible?
Yabsiel Gashaw 15
A Maximization Problem
Yabsiel Gashaw 16
A Maximization Problem
Solution
Formulation of mathematical modeling of LPP
Max Z = 300X1 +250X2
St:
2X1 +X2 < 40
LPP Model
X1 +3X2 < 45
X1 < 12
X1, X2 >0
Yabsiel Gashaw
• Step 4 construct the initial tabula
Yabsiel Gashaw
• Step 5 choose the entering variable with
maximum positive number in cj-zj row
• Step 6 choosing the leaving variable ration
RHS
Yabsiel Gashaw
Cont.…
Yabsiel Gashaw
Yabsiel Gashaw
Case 1: Simplex Method for the Maximization
Problem
Example1: Max z= 40x1 +30x2
S.T x1 + 2x2 ≤ 40 hour of labour
4x1 + 3x2 ≤ 120 Ib of clay
X1, x2 ≥ 0
Required:
▪ Standardize the model
▪ Generate an initial solution and the initial simplex
tableau
▪ Determine the value of x1 and x2 at the optimal
simplex tableau Yabsiel Gashaw
▪ What is the z-value at the optimal solution?
11/29/2022
▪ Does the problem have a multiple solution? Why?
Solution:
A.
Convert the model into standard form by adding slack
variables to each constraint as follows.
N.B: slack variables are added to ≤ constraints and represent
unused resources.
Max Z = Max z= 40x1 +30x2+0s1 + 0s2
S.T x1 + 2x2 +s1 +0s2 = 40
4x1 + 3x2 + 0s1+ s2 =120
X1, x2,s1, s2 ≥ 0
11/29/2022
Yabsiel Gashaw
Cont…
B.
At the origin where nothing is being produced, the values of all
the decision variables are zero which implies the value of the
slack variable equals to the RHS value.
1(0) + 2(0) +s1+ 0S2 = 40
S1= 40 -------------------------------------------------- 1
4(0) + 3(0) + 0S1 + s2 = 120
S2 = 120------------------------------------------------ 2
N.B: at the origin all decision variables are non-basic whereas all
slack are basic.
11/29/2022
Yabsiel Gashaw
Pivot Pivot
column number
Pivot Row
11/29/2022
Yabsiel Gashaw
Cont…
11/29/2022
Yabsiel Gashaw
Cont …
11/29/2022
Yabsiel Gashaw
Cont…
11/29/2022
Yabsiel Gashaw
Cont…
The optimal solution has been reached because all
values of Cj-zj row are less than and equal to zero.
11/29/2022
Yabsiel Gashaw
E.
▪ Multiple optimal solutions on a simplex tableau can be
determined from Cj- Zj or Zi-Cj row value. An alternative
optimal solutions have the same z value but different
variable values.
▪ The answer for the question is yes because optimal simplex
tableau is said to be multiple if at least one non-basic
variable has zero value in the Cj-Zi or Zj-Cj row.
▪ Now you can see the above table, x2 is non-basic variable
but its value corresponds to Cj-zj row is zero.
▪ Alternative optimal solution is determined by selecting the
non-basic variable with Cj-zj = 0 as entering or incoming
variable.
11/29/2022
Yabsiel Gashaw
Cont…
11/29/2022
Yabsiel Gashaw
Example 3:
A farmer owns a 100-hectare farm and plans to
plant at most three crops. The seed for crops A,
B, and C costs $40, $20, and $30 per hectare,
respectively. A maximum of $3,200 can be
spent on seed. Crops A, B, and C require 1, 2,
and 1 work days per hectare, respectively, and
there is a maximum of 160 work days available.
If the farmer can make a profit of $100 per
hectare on crop A, $300 per hectare on crop B,
and $200 per hectare on crop C, how many
hectare of each crop should be planted to
40
maximize profit? What is the maximum profit?
Yabsiel Gashaw
Yabsiel Gashaw
Yabsiel Gashaw
Yabsiel Gashaw
Yabsiel Gashaw
solution
• Number of hectare of crop A = 0
• Number of hectares of crop B = 60
• Number of hectares of crop C = 40
• Maximum profit = $26,000
Yabsiel Gashaw
The Big M-method
/Charnes Penalty Method/
• The Big-M Method is a method which is used in removing artificial
variables from the basis .In this method; we assign coefficients to
artificial variables, undesirable from the objective function point of
view.
• If objective function Z is to be minimized, then a very large
positive price (called penalty) is assigned to each artificial
variable.
• Similarly, if Z is to be maximized, then a very large negative price
(also called penalty) is assigned to each of these variables.
• Following are the characteristics of Big-M Method:
• High penalty cost (or profit) is assumed as M
• M is assigned to artificial variable A in the objective function Z.
• Big-M method can be applied to minimization as well as
maximization problems with the following distinctions:
Yabsiel Gashaw
1. Minimization problems
• -Assign +M as coefficient of artificial variable A in the objective
function Z
• Maximization problems:
• -Here –M is assigned as coefficient of artificial variable A in the
objective function Z
• Coefficient of S (slack/surplus) takes zero values in the objective
function Z
• For minimization problem, the incoming variable corresponds to the
highest negative value of Cj-Zj.
• Solution is optimal when there is no negative value of Cj-Zj.(For
minimization case)
• Example:
• 1. Minimize Z=25x1 +30x2
• Subject to:
• 20x1+15x2 > 100
• 2x1+ 3x2 > 15
• x 1, x 2 > 0
Yabsiel Gashaw
• Solution
• Step 1
• Standardize the problem
• Minimize Z=25x1 +30x2 +0s1+0s2 +MA1+MA2
• Subject to:
• 20x1+15x2- s1+A1 = 100
• 2x1+ 3x2 –s2+A2 = 15
• x1, x2 , s1, s2 ,A1 ,A2 > 0
• Step 2
• Initial simplex tableau
• The initial basic feasible solution is obtained by setting x1= x2= s1=
s2=0
• No production, x1= x2= s1=0==>20(0) +15(0) - 0+A1 = 100 ==> A1 =
100
• x1= x2= s2=0==>0(0)+3(0) - 0+A2 =15==> A2 =
15
Yabsiel Gashaw
Contd…..
Yabsiel Gashaw
Contd…..
Yabsiel Gashaw
Contd….
Yabsiel Gashaw
Yabsiel Gashaw