0% found this document useful (0 votes)
19 views47 pages

Algebraic and Simplex Method

The document provides definitions and explanations related to linear programming, including basic solutions, basic feasible solutions, and the simplex method. It outlines the steps for solving linear programming problems using the simplex method, detailing the initialization, optimality tests, and iterations involved. Additionally, it includes examples to illustrate the application of these concepts in practice.

Uploaded by

bharathplkm1234
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)
19 views47 pages

Algebraic and Simplex Method

The document provides definitions and explanations related to linear programming, including basic solutions, basic feasible solutions, and the simplex method. It outlines the steps for solving linear programming problems using the simplex method, detailing the initialization, optimality tests, and iterations involved. Additionally, it includes examples to illustrate the application of these concepts in practice.

Uploaded by

bharathplkm1234
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/ 47

DEFINITIONS

Basic Solution :Given a system of m simultaneous linear


equations with n (>m) variables:

B be any mXm non singular submatrix of A obtained by


reordering m linearly independent columns of A. Then , a solution
obtained by setting (n-m) variables not associated with the columns
of B, equal to zero and solving the resulting system
is called a Basic solution to the given system of equations.
Remarks
A basic solution has the following properties:
1. Each variable is designated as either a non basic variable
or a basic variable.

2. The number of basic variables equals the number of


functional constraints. Therefore, the number of non
basic variables equals the total number of variables minus
the number of functional constraints.

3. The non basic variables are set equal to zero.


4. There are at most
Basic Feasible Solution(BFS) :A Basic solution to
the system of simultaneous equations is said to
be Basic Feasible Solution if all the values are non
negative.

A basic feasible solution is correspond to a


corner point of the Feasible Region of LPP.

The maximum number of Basic feasible solution


of m simultaneous linear equations with n(>m)
variables is less than or equal to
Degenerate Basic Feasible Solution :

A BFS to the system of equations is called degenerate if


one or more of the basic variables values equal to zero.

Non-Degenerate Basic Feasible Solution:

A BFS is called non-degenerate BFS if values of all basic


variables are positive.
Algebraic Method to solve LPP
1. Assume all the constraints are equations
in the given LPP
2. Find the Basic Solution
3. Determine the Basic Feasible
solution(BFS)
4. Determine the Optimum BFS of LPP by
using the objective function of the LPP
Example for obtaining Basic Solution
Consider the following system of equations:
++=4
+2 +=5 and ,,,≥0
The following Table provides all the Basic solutions:
Non Basic Basic Variables Basic Solution
Variables

(, ) (, ) (4, 5 )
(, ) (, ) (4,-3)
( , ) (, ) (2.5 , 1.5 )
(, ) (, ) (2, 3)
(, ) (, (5, -6)
(, ) (, ) (1,2)
Example for Solving LPP By
Algebraic Method
Consider the following LPP:
Maximize Z=+ 3+0+0
Subject to
++=4
+2 +=5 and ,,,≥0
The following Table provides all the Basic feasible solutions:

Non Basic Basic Basic Z value


Variables Variables Feasible
Solution
(, ) (, ) (4, 5 ) 0
( , ) (, ) (2.5 , 1.5 ) 7.5
(, ) (, ) (2, 3) 4
(, ) (, ) (1,2) 8
PRACTICE PROBLEMS
Find all the Basic feasible solution for
the system of equations:

3.
DEFINITIONS

Slack Variable: The non-negative variables which are


added to LHS of the constraints to convert them into
equalities are known as slack variables.
For constraints of the type ( ≤ ), the right hand side
normally represents the limit on the availability of a
resource and the left hand side represents the usage of
this limited resources by the different
activities(variables) of the model. A slack variable
represents the amount by which the available amount
of resources exceeds its usage by the activities.
Surplus Variable: The non-negative variables which
are subtracted from the LHS of the constraints to
convert them into equalities are known as surplus
variables.
For Constraints of the type (≥) normally set minimum
specification requirements. In this case, a surplus
variable represents the excess of the left hand side
over the minimum requirement

Remark: Slack and Surplus variables carry a


zero coefficient in the objective function.
Artificial Variables :
When we use surplus variables to convert inequalities into
equations then to obtain Initial basis matrix as identity
matrix, we used artificial variable in each constraint of the
type

Remark : The coefficient of artificial variables in


the objective function is

+M for Minimization
-M for Maximization, M>0
STANDARD FORM OF LPP

The standard form of the LP Problem should have the following characteristics:
1) All the constraints are equations with nonnegative
right hand side value

2) All the decision variables are non negative

3) The objective function is either maximization or minimization type


Examples :
Introduction of Simplex Method
• Simplex Method: It is a linear-programming
algorithm that can solve problems having any number
of decision variables.
• The simplex technique involves generating a series of
solutions in tabular form, called tableaus. By inspecting
the bottom row of each tableau, one can immediately
tell if it represents the optimal solution. Each tableau
corresponds to a corner point of the feasible solution
space. The first tableau corresponds to the origin.
Subsequent tableaus are developed by shifting to an
adjacent corner point in the direction that yields the
highest (smallest) rate of profit (cost). This process
continues as long as a positive (negative) rate of profit
(cost) exists.
The simplex method in tabular form
• Steps:
1. Initialization:
a. Transform all the constraints to equality by
introducing slack, surplus, and artificial variables as
follows:

Constraint type Variable to be added

≤ + slack (s)

≥ - Surplus (s) + artificial (A)

= + Artificial (A)
Simplex method in tabular form
b. Construct the initial simplex tableau

Basic X1 … Xn S1 …... Sn A1 …. An RHS


variable
S b1
Coefficient of the constraints

A bm
Z Objective function coefficient Z
In different signs value
Simplex method in tabular form
2. Test for optimality:
Case 1: Maximization problem
The current BF Solution is optimal if every
coefficient in the objective function row is non
negative
Case 2: Minimization problem
The current BF Solution is optimal if every
coefficient in the objective function row is non
positive
Simplex method in tabular form
3. Iteration
Step 1: Determine the entering variable by
selecting the variable (automatically a non basic
variable) with the most negative value (in case
of maximization) or with the most positive (in
case of minimization) in the last row (Z-row).
Put a box around the column below this
variable, and call it the “pivot column”
Simplex method in tabular form
• Step 2: Determine the leaving basic variable by
applying the minimum ratio test as following:
1. Pick out each coefficient in the pivot column that is
strictly positive (>0)
2. Divide each of these coefficients into the right hand
side entry for the same row
3. Identify the row that has the smallest of these ratios
4. The basic variable for that row is the leaving variable,
so replace that variable by the entering variable in the
basic variable column of the next simplex tableau. Put
a box around this row and call it the “pivot row”
Step 3: Update the Simplex table

Find the new BF solution by using elementary row operations


(multiply or divide a row by a nonzero constant; add or subtract a
multiple of one row to another row) to construct a new simplex
tableau, and then go to the Step 2.
The specific elementary row operations(Gauss-Jordan) are:

1. New pivot row = old pivot row  Pivot Element


2. Other New row = old row – [(the coefficient of this row
in the pivot column) x (new pivot row)]

24
Example 1 to solve LP using SIMPLEX METHOD

Consider the previously discussed Fruit-Seller’s Problem.

LP Model 1
𝑴𝒂𝒙𝒊𝒎𝒊𝒛𝒆 𝒁=𝟔 𝒙 𝟏 +𝟏𝟎 𝒙 𝟐

Subject to
𝟐𝟓 𝒙 𝟏+𝟓𝟎 𝒙𝟐 ≤𝟓𝟎𝟎
𝒙 𝟏+ 𝒙 𝟐 ≤𝟏𝟐
𝒙 𝟏 ≥ 𝟎 , 𝒙𝟐 ≥ 𝟎
25
SOLUTION TO LP MODEL 1
Standard Form: In this case all constraints are type
constraints. and are slack variables
𝑴𝒂𝒙𝒊𝒎𝒊𝒛𝒆 𝒁=𝟔 𝒙 𝟏 +𝟏𝟎 𝒙 𝟐+ 𝟎 𝑺𝟏+ 𝟎 𝑺𝟐

Subject to
𝟐𝟓 𝒙 𝟏+𝟓𝟎 𝒙𝟐 + 𝑺𝟏=𝟓𝟎𝟎
𝒙 𝟏+ 𝒙 𝟐 + 𝑺 𝟐=𝟏𝟐
𝒙 𝟏 ≥ 𝟎 , 𝒙𝟐 ≥ 𝟎

26
ITERATION 1
𝑴𝒂𝒙𝒊𝒎𝒊𝒛𝒆 𝒁=𝟔 𝒙 𝟏 +𝟏𝟎 𝒙 𝟐+ 𝟎 𝑺𝟏+ 𝟎 𝑺𝟐
Subject to
𝟐𝟓 𝒙 𝟏+𝟓𝟎 𝒙𝟐 + 𝑺𝟏=𝟓𝟎𝟎
𝒙 𝟏+ 𝒙 𝟐 + 𝑺 𝟐=𝟏𝟐
𝒙 𝟏 ≥ 𝟎 , 𝒙𝟐 ≥ 𝟎
Basic Variables:
Non-Basic variables:
Solution:

Z 27
ITERATION 1
Entering
variable

Basic X1 X2 S1 S2 RHS Ratio


variable
Least Positive
S1 25 50 1 0 500 10 Ratio

S2 1 1 0 1 12 12
Z -6 -10 0 0 0

Leaving
variable
Pivot
Pivot column
Pivot row
Element
Optimality test
• By investigating the last row of the initial
tableau, we find that there are some negative
numbers. Therefore, the current solution is
not optimal
Finding the new Basic Feasible solution by using the eliminatory row
operations (Gauss-Jordan ) as following.
1. New pivot row = old pivot row  Pivot Element
= Old Pivot Row  50
2. New row = old row – [the coefficient of this row in the pivot column
*(new pivot row)]
Basic X1 X2 S1 S2 RHS
variable
x2 0.50 1 0.02 0 10
S2
Z

Note that X2 becomes in the


basic variables list instead of S1
ITERATION 2 Entering
variable

Basic X1 X2 S1 S2 RHS
variable Ratio

x2 0.50 1 0.02 0 10 20
Least Positive
S2 0.50 0 -0.02 1 2 4 Ratio
Z -1 0 0.20 0 100

Leaving
variable
Pivot
Pivot column
Pivot row
Element
Optimality test
• By investigating the last row of the tableau,
we find that there are some negative
numbers. Therefore, the current solution is
not optimal
ITERATION 2

Basic Variables:
Non-Basic variables:
Solution:

33
ITERATION 3

Basic X1 X2 S1 S2 RHS
variable
x2 0 1 0.04 -1 8
x1 1 0 -0.04 2 4
Z 0 0 0.16 2 104

Since Optimality condition is satisfied,


Iteration 3 is Optimal.
ITERATION 3
Basic Variables:
Non-Basic variables:
Solution:

35
Simplex method
• Example 2
• Solve the following problem using the simplex method
• Maximize Z = 3X1+ 5X2
Subject to
X1  4
2 X2  12
3X1 +2X2  18
X1 , X2  0
Simplex method
• Solution
• Initialization
1. Standard form
Maximize Z,
Subject to Sometimes it is called the
Z - 3X1- 5X2 = 0 augmented form of the
problem because the
X1 + S 1 = 4 original form has been
2 X2+ S2 =12 augmented by some
supplementary variables
3X1 +2X2+ S3=18 needed to apply the
X1 , X2, S1, S2, S3  0 simplex method
Initial tableau
Entering
2. Initial tableau variable

Basic X1 X2 S1 S2 S3 RHS
variable
S1 1 0 1 0 0 4
S2 0 2 0 1 0 12
S3 3 2 0 0 1 18
Z -3 -5 0 0 0 0

Leaving Pivot row


Pivot column
variable Pivot
number
Simplex tableau
Notes:
• The basic feasible solution at the initial tableau
is (0, 0, 4, 12, 18) where:
X1 = 0, X2 = 0, S1 = 4, S2 = 12, S3 = 18, and Z = 0
Where S1, S2, and S3 are basic variables
X1 and X2 are nonbasic variables
• The solution at the initial tableau is associated
to the origin point at which all the decision
variables are zero.
Optimality test
• By investigating the last row of the initial
tableau, we find that there are some negative
numbers. Therefore, the current solution is
not optimal
Iteration
• Step 1: Determine the entering variable by
selecting the variable with the most negative in
the last row.
• From the initial tableau, in the last row (Z row),
the coefficient of X1 is -3 and the coefficient of X2
is -5; therefore, the most negative is -5.
consequently, X2 is the entering variable.
• X2 is surrounded by a box and it is called the pivot
column
Iteration
• Step 3: solving for the new BF solution by using the
eliminatory row operations as following:
1. New pivot row = old pivot row  pivot number
Basic X1 X2 S1 S2 S3 RHS
variable
S1
X2 0 1 0 1/2 0 6
S3
Z

Note that X2 becomes in the basic variables


list instead of S2
Iteration
2.For the other row apply this rule:
New row = old row – (the coefficient of this row in the pivot column) X
(new pivot row).
For S1

1 0 1 0 0 4
-
0 (0 1 0 1/2 0 6)
1 0 1 0 0 4
For S3

3 2 0 0 1 18
-
2 (0 1 0 1/2 0 6)
Substitute this
3 0 0 -1 1 6
for Z values in the table
-3 -5 0 0 0 0
-
-5(0 1 0 1/2 0 6)
-3 0 0 5/2 0 30
Iteration
This solution is not optimal, since there is a negative
numbers in the last row
Basic X1 X2 S1 S2 S3 RHS
variable
S1 1 0 1 0 0 4
X2 0 1 0 1/2 0 6
S3 3 0 0 -1 1 6
Z -3 0 0 5/2 0 30

The smallest ratio is


The most negative
6/3 =2; therefore, S3 is
value; therefore, X1 is
the leaving variable
the entering variable
Iteration
This solution is not optimal, since there is a negative numbers in the
last row
Basic X1 X2 S1 S2 S3 RHS
variable
S1 1 0 1 0 0 4
X2 0 1 0 1/2 0 6
S3 3 0 0 -1 1 6
Z -3 0 0 5/2 0 30

The smallest ratio is


The most negative
6/3 =2; therefore, S3 is
value; therefore, X1 is
the leaving variable
the entering variable
Iteration

Basic X1 X2 S1 S2 S3 RHS
variable
S1 0 0 1 2
X2 0 1 0 1/2 0 6
1 0 0 2

Z 0 0 0 3/2 1 36

This solution is optimal, since there is a no negative numbers in the


last row. Optimal BFS : =2, =6 with Maximum value Z=36
PRACTICE PROBLEMS

1. Maximize
subject to

and

2. Minimize
subject to

You might also like