0% found this document useful (0 votes)
73 views31 pages

Simplex Methos (Chapter 3)

The document describes the simplex method for solving linear programming problems (LPPs). It notes that the simplex method is used when there are more than two decision variables or constraints, as the graphical method becomes lengthy in such cases. The summary explains that the simplex method works by selecting a pivot column and row at each step to replace a variable in the solution mix and iteratively arrive at an optimal solution. It provides an example problem of determining chair and table production and walks through the initial tableau setup and first two iterations of the simplex method steps.

Uploaded by

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

Simplex Methos (Chapter 3)

The document describes the simplex method for solving linear programming problems (LPPs). It notes that the simplex method is used when there are more than two decision variables or constraints, as the graphical method becomes lengthy in such cases. The summary explains that the simplex method works by selecting a pivot column and row at each step to replace a variable in the solution mix and iteratively arrive at an optimal solution. It provides an example problem of determining chair and table production and walks through the initial tableau setup and first two iterations of the simplex method steps.

Uploaded by

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

The Simplex Method

The graphical method is useful only for problems involving two decision
variables and relatively few problem constraints. We use simplex method
when we need more decision variables and more problem constraints

Simplex method help solve large real world LPPs

 When decision variables are more than 2, it is always advisable to use


Simplex Method to avoid lengthy graphical procedure.

 The simplex method is not used to examine all the feasible solutions.

 It deals only with a small and unique set of feasible solutions, the set of vertex
points (i.e., extreme points) of the convex feasible space that contains the
optimal solution.
Slack Variables
“A mathematical representation of surplus
resources.” In real life problems, it’s unlikely
that all resources will be used completely, so
there usually are unused resources.
Slack variables represent the unused resources
between the left-hand side and right-hand
side of each inequality.
To solve a linear programming problem in standard form, use the following steps.

1- Convert each inequality in the set of constraints to an equation by adding


slack variables.
2- Create the initial simplex tableau.
3- Select the pivot column. ( The column with the “most negative value” element
in the last row.)
4- Select the pivot row. (The row with the smallest non-negative result when the
last element in the row is divided by the corresponding in the pivot
column.)
5-Use elementary row operations calculate new values for the pivot row so that
the pivot is 1 (Divide every number in the row by the pivot number.)
6- Use elementary row operations to make all numbers in the pivot column
equal to 0 except for the pivot number. If all entries in the bottom row are
zero or positive, this the final tableau. If not, go back to step 3.
7- If you obtain a final tableau, then the linear programming problem has a
maximum solution, which is given by the entry in the lower-right corner of
the tableau.
Pivot
Pivot Column: The column of the tableau
representing the variable to be entered into
the solution mix.
Pivot Row: The row of the tableau representing
the variable to be replaced in the solution mix.
Pivot Number: The element in both the pivot
column and the pivot row.
Simplex Tableau
Most real-world problems are too complex to
solve graphically. They have too many corners
to evaluate, and the algebraic solutions are
lengthy. A simplex tableau is a way to
systematically evaluate variable mixes in order
to find the best one.
Initial Simplex Tableau
All variables Solution

Basic variables coefficients

0
EXAMPLE 1

A furniture Company produces tables and chairs.


Each table takes four hours of labor from the
carpentry department and two hours of labor
from the finishing department. Each chair
requires three hours of carpentry and one hour
of finishing. During the current week, 240 hours
of carpentry time are available and 100 hours of
finishing time. Each table produced gives a profit
of $70 and each chair a profit of $50. How many
chairs and tables should be made?
STEP 1
All information about example
Resource Table s ( x1 ) Chairs ( x2 ) Constraints
Carpentry (hr) 4 3 240
Finishing (hr) 2 1 100
Unit Profit $70 $50

Objective Function P  70 x1  50 x2

Carpentry Constraint 4 x1  3 x2  240

Finishing Constraint 2 x1  1x2  100

Non-negativity conditions x1 , x2  0
The first step of the simplex method requires that each inequality
be converted into an equation. ”less than or equal to”
inequalities are converted to equations by including slack
variables.
Suppose s1 carpentry hours and s2 finishing hours remain
unused in a week. The constraints become;

4 x1  3x2  s1  240 4 x1  3 x2  s1  0s2  240


or
2 x1  x2  s2  100 2 x1  x2  0 s1  s2  100

As unused hours result in no profit, the slack variables can be


included in the objective function with zero coefficients:
P  70 x1  50 x2  0 s1  0 s2
P  70 x1  50 x2  0s1  0s2  0
The problem can now be considered as solving a system of 3 linear
equations involving the 5 variables x1, x2 , s1 , s2 , P in such a way
that P has the maximum value;

4 x1  3x2  s1  0 s2  240
2 x1  x2  0s1  s2  100
P  70 x1  50 x2  0s1  0s2  0

Now, the system of linear equations can be written in matrix form


or as a 3x6 augmented matrix. The initial tableau is;
STEP 2
Right
Basic
x1 x2 S1 S2 P Hand
Variables
Side
S1 4 3 1 0 0 240
S2 2 1 0 1 0 100
P -70 -50 0 0 1 0

The tableau represents the initial solution;

x1  0, x2  0, s1  240, s2  100, P  0

The slack variables S1 and S2 form the initial solution mix. The initial
solution assumes that all avaliable hours are unused. i.e. The slack variables
take the largest possible values.
Variables in the solution mix are called basic variables. Each basic
variables has a column consisting of all 0’s except for a single
1. all variables not in the solution mix take the value 0.

The simplex process, a basic variable in the solution mix is


replaced by another variable previously not in the solution
mix. The value of the replaced variable is set to 0.
STEP 3
Select the pivot column (determine which variable to enter into the
solution mix). Choose the column with the “most negative”
element in the objective function row.

Right
Basic
x1 x2 S1 S2 P hand
Variables
side
S1 4 3 1 0 0 240
S2 2 1 0 1 0 100
P -70 -50 0 0 1 0
Pivot column
x1 should enter into the solution mix because each unit of x 1 (a table)
contributes a profit of $70 compared with only $50 for each unit of x 1 (a
chair)
Step 4
No, There aren’t any positive elements in the
pivot column above the dashed line.

We can go on step 5
STEP 5
Select the pivot row (determine which variable to replace in the solution mix).
Divide the last element in each row by the corresponding element in the
pivot column. The pivot row is the row with the smallest non-negative result.

Enter

Right
Basic
x1 x2 S1 S2 P hand
Variables
side
S1 4 3 1 0 0 240 240 / 4  60
Exit S2 2 1 0 1 0 100 100 / 2  50

P -70 -50 0 0 1 0
Pivot row
Pivot column

Pivot number
Should be replaced by x1 in the solution mix. 60 tables can be made with 240
unused carpentry hours but only 50 tables can be made with 100
finishing hours. Therefore we decide to make 50 tables.
Now calculate new values for the pivot row. Divide every number in the row
by the pivot number.

Right
Basic
x1 x2 S1 S2 P hand
Variables
side
S1 4 3 1 0 0 240
R2
x1 1 1/2 0 1/2 0 50 2
P -70 -50 0 0 1 0
Use row operations to make all numbers in the pivot column equal to 0 except
for the pivot number which remains as 1.

Right
Basic
x1 x2 S1 S2 P hand
Variables
side
S1 0 1 1 -2 0 40 4.R2  R1

x1 1 1/2 0 1/2 0 50
70.R2  R3
P 0 -15 0 35 1 3500

If 50 tables are made, then the unused carpentry hours are reduced by 200
hours (4 h/table multiplied by 50 tables); the value changes from 240 hours to 40
hours. Making 50 tables results in the profit being increased by $3500; the value
changes from $0 to $3500.
In this case, x1  50, x2  0, s1  40, s2  0, P  3500
Now repeat the steps until there are no negative numbers in the last row.

Select the new pivot column. x2 should enter into the solution mix.
Select the new pivot row. S1 should be replaced by x2 in the solution mix.
Enter

Right
Basic
x1 x2 S1 S2 P hand
Variables
side
Exit S1 0 1 1 -2 0 40 40 /1  40
50 / 0,5  100
x1 1 1/2 0 1/2 0 50
P 0 -15 0 35 1 3500
New pivot row
New pivot
column
Calculate new values for the pivot row. As the pivot number is already 1,
there is no need to calculate new values for the pivot row.

Use row operations to make all numbers in the pivot column equal to
except for the pivot number.

Right
Basic
x1 x2 S1 S2 P hand
Variables
side
x2 0 1 1 -2 0 40
1
 .R1  R2
x1 1 0 -1/2 3/2 0 30 2
P 0 0 15 5 1 4100 15.R1  R3
If 40 chairs are made, then the number of tables are reduced by
20 tables (1/2 table/chair multiplied by 40 chairs); the value
changes from 50 tables to 30 tables. The replacement of 20
tables by 40 chairs results in the profit being increased by
$600; the value changes from $3500 to $4100.

As the last row contains no negative numbers, this solution gives


the maximum value of P.
Result
This simplex tableau represents the optimal
solution to the LP problem and is interpreted
as:
x1  30, x2  40, s1  0, s2  0

and profit or P=$4100


The optimal solution (maximum profit to be
made) is to company 30 tables and 40 chairs
for a profit of $4100.
Example 2: Product Mix Problem

A Company produces two products: I and II. The raw material requirements,
space needed for storage, production rates, and selling prices for these products
are given below:

The total amount of raw material available per day for both products is 15751b.
The total storage space for all products is 1500 ft2, and a maximum of 7 hours per
day can be used for production. The company wants to determine how many
units of each product to produce per day to maximize its total income.
Solution

The LP model is:

 Step 1: Convert all the inequality constraints into equalities by the use o
slack variables. Let:
 Step II: . Identify the variable that will be assigned a nonzero value in the next
iteration so as to increase the value of the objective function. This variable is
called the entering variable.
 It is that nonbasic variable which is associated with the smallest negative
coefficient in the objective function.
 If two or more nonbasic variables are tied with the smallest coefficients,
select one of these arbitrarily and continue.

 Step III: Identify the variable, called the leaving variable, which will be
changed from a nonzero to a zero value in the next solution.
 Step IV: . Enter the basic variables for the second tableau. The row sequence
of the previous tableau should be maintained, with the leaving variable being
replaced by the entering variable.
 Step V: Compute the coefficients for the second tableau. A sequence of
operations will be performed so that at the end the x1 column in the second
tableau will have the following coefficients:

The second tableau yields the following feasible solution:


x1 = 315, x2 = 0, SI = 240, S2 = 0, S3 = 105, and Z = 4095
 The row operations proceed as fo1lows:
 The coefficients in row C2 are obtained by dividing the corresponding
coefficients in row C1 by 5.
 The coefficients in row A2 are obtained by multiplying the coefficients of
row C2 by 13 and adding the products to the corresponding coefficients
in row Al.
 The coefficients in row B2 are obtained by multiplying the coefficients of
row C2 by -4 and adding the products to the corresponding coefficients in
row Bl.
 The coefficients in row D2 are obtained by multiplying the coefficients of
row C2 by -1 and adding the products to the corresponding coefficients in
row Dl.
 Step VI: Check for optimality. The second feasible solution is also not
optimal, because the objective function (row A2) contains a negative
coefficient. Another iteration beginning with step 2 is necessary.
 In the third tableau (next slide), all the coefficients in the objective function
(row A3) are positive. Thus an optimal solution has been reached and it is as
follows:

x1 = 270, x2 = 75, SI = 45, S2 = 0, S3 = 0, and Z = 4335


Exercise

A farmer owns a 100 acre farm and plans to plant at most three crops. The
seed for crops A,B, and C costs $40, $20, and $30 per acre, respectively. A
maximum of $3200 can be spent on seed. Crops A,B, and C require 1,2,
and 1 workdays per acre, respectively, and there are maximum of 160
workdays available. If the farmer can make a profit of $100 per acre on
crop A, $300 per acre on crop B, and $200 per acre on crop C, how many
acres of each crop should be planted to maximize profit?

You might also like