www.egwald.com Egwald Web Services

Egwald Web Services
Domain Names
Web Site Design

Egwald Website Search JOIN US AS A FACEBOOK FAN Twitter - Follow Elmer WiensRadio Podcasts - Geraldos Hour

 

Statistics Programs - Econometrics and Probability Economics - Microeconomics & Macroeconomics Operations Research - Linear Programming and Game Theory Egwald's Mathematics Egwald's Optimal Control
Egwald Home Operations Research Home Game Theory Home Page Linear Programming Home  Page Graphical Solution Simplex Algorithm Linear Programming Algorithm Two Person Game Your LP Problem Try Problems
 

Operations Research - Linear Programming - Dual Simplex Tableaux Generator

by

Elmer G. Wiens

Egwald's popular web pages are provided without cost to users.
Please show your support by joining Egwald Web Services as a Facebook Fan: JOIN US AS A FACEBOOK FAN
Follow Elmer Wiens on Twitter: Twitter - Follow Elmer Wiens

Graphical Solution | Simplex Algorithm | Primal Simplex Tableaux Generator | Dual Simplex Algorithm | Dual Simplex Tableaux Generator
Economics Application - Profit Maximization | Economics Application - Least Cost Formula

example problem | your l.p. problem | simplex algorithm | references

The dual simplex method transforms an initial tableau into a final tableau containing the solutions to the primal and dual problems. Each stage of the algorithm generates an intermediate tableau as the algorithm gropes towards a solution.

This web page permits you to enter your own linear programming problem and generate these tableaux with a user friendly interface. You can specify up to 6 variables and 10 constraints in the primal problem, with any mixture of <=, >=, and = constraints.

To illustrate the procedure you need to follow, consider the problem:

Primal Linear Program
Maximize the Objective Function (P)
P = 15 x1 + 10 x2 + 17 x3 subject to
L1: 1.0 x1 + 1.0 x2 + 1.0 x3 <= 85
L2: 1.25 x1 + 0.5 x2 + 1.0 x3 >= 90
L3: 0.6 x1 + 1.0 x2 + 0.5 x3 = 55
      x1 >= 0; x2 >= 0; x3 >= 0

with diagram:

Primal  Linear Programming Problem




To generate the form used to enter the l.p. data you must set the parameters that specify your l.p. problem as I have done below for the problem above.

L.P. Problem Name:    
Number of variables:
n =
Number of constraints:
m =
Number of <= constraints:
m1 =
Number of >= constraints:
m2 =
Number of = constraints:
m3 =
 
               

Certain restrictions apply to to the parameters:
m = m1 + m2 + m3;   n <= 6;   m <= 10;   n > 0;
m > 0;   m1 >= 0;   m2 >= 0;   m3 >= 0.

Your L.P. Parameter Form.

Your Linear Programming Problem's Parameters
L.P. Problem Name:    
Number of variables:
n =
Number of constraints:
m =
Number of <= constraints:
m1 =
Number of >= constraints:
m2 =
Number of = constraints:
m3 =
 
               

After you fill in your form and click submit paramters, a web page will pop with a table, like the one below, where you can enter the data of your l.p. problem. Notice that you need neither multiply = constrainst by -1, nor convert >= constraints to <= constraints.

FormTable =
My L.P. Problem
P = x1 + x2 + x3 subject to
L1 x1 + x2 + x3 <=
L2 x1 + x2 + x3 >=
L3 x1 + x2 + x3 =

After you fill in your data and click submit, the program will automatically calculate a sequence of tableaux that solves the primal and dual l.p. problems. Examine the tableaux that follow to see how the dual simplex method proceeds to find the solution.


To perform a sensitivity analysis on your linear programming problem, change the data in the table above, and click Submit L.P. again.


Dual Simplex Algorithm.

The standard form for the initial dual simplex tableau is:

Initial Tableau
bAI3
0-cTO3T

The dual simplex algorithm calculates a sequence of tableaux. Tableauk has the form:

Tableauk
ßUB
µtTyT
=
Tableauk
ßÛ
µØ

after consolidating the center 2 by 2 block of matrices.

The "three-phase method" of the dual simplex algorithm:

Phase 0 - drive all artificial variables (associated with = constraints) to zero, i.e. eliminate them from the basis;

Phase I - find a tableau with Ø >= 0, i.e. a feasible dual program;

Phase II - generate tableaux that decrease the value of µ turning ß >= 0, without dropping back into Phase 0 or I, i.e. find a feasible basic dual program that minimizes the objective function D.




Phase 0: Drive the artificial variables from the basis.

Tableau0
  b0 x01 x02 x03 s01 s02 s*03 row
sum
L018511110089
L02-90-1.25-0.5-1010-91.75
L03550.610.500158.1
P00-15-10-17000-42
 00000000

Basis for Tableau0: [s1, s2, s3, ]. Value of Objective Function = 0.

Proceed to the next tableau as follows:

Phase 0: Drive the artificial variables from the basis.

A. In Tableau0:

1. Select an artificial variable in the basis: s*3. The pivot row = 3.

2. Select a nonzero element in row L3 as pivot: Û3,2 = 1. The pivot column = 2.

B. To create Tableau1:

3. Compute row L13 = L03 / (1).

4. Subtract multiples of row L13 from all other rows of Tableau0 so that x12 = e3 in Tableau1.

Phase I: Goal: get Ø >= 0.

Tableau1
  b1 x11 x12 x13 s11 s12 s*13 row
sum
L11 = L01 - (1) * L13300.400.510-130.9
L12 = L02 - (-0.5) * L13-62.5-0.950-0.75010.5-62.7
L13 = L03 / (1)550.610.500158.1
P1 = P0 - (-10) * L13550-90-120010539
-P1 / L130150240000

Basis for Tableau1: [s1, s2, x2, ]. Value of Objective Function = 550.

Proceed to the next tableau as follows:

Phase 0: Complete.

Phase I: Goal: get Ø >= 0.

A. In Tableau1:

1. Select a target column, tcol, with Øtcol < 0: Ø11 = -9, tcol = 1.

2. Select any row, r, with a positive entry in tcol = 1 as the pivot row: row = 3 associated with Û3,1 = 0.6 and constraint L3.

3. Compute the ratios -Ø / L3 as per the last row. Discard ratios which are not positive and ratios associated with artificial variables. Select the column with the least positive ratio as the pivot column: col = 1 associated with 15. Thus Û3,1 = 0.6 is the pivot; variable x2 will leave the basis; variable x1 will enter the basis.

B. To create Tableau2:

4. Compute row L23 = L13 / (0.6).

5. Subtract multiples of row L23 from all other rows of Tableau1 so that x1 = e3 in Tableau2.

Tableau2
  b2 x21 x22 x23 s21 s22 s*23 row
sum
L21 = L11 - (0.4) * L23-6.6670-0.6670.16710-1.667-7.833
L22 = L12 - (-0.95) * L2324.58301.5830.042012.08329.292
L23 = L13 / (0.6)91.66711.6670.833001.66796.833
P2 = P1 - (-9) * L231375015-4.500251410.5
-P2 / L230005.40000

Basis for Tableau2: [s1, s2, x1, ]. Value of Objective Function = 1375.

Proceed to the next tableau as follows:

Phase 0: Complete.

Phase I: Goal: get Ø >= 0.

A. In Tableau2:

1. Select a target column, tcol, with Øtcol < 0: Ø23 = -4.5, tcol = 3.

2. Select any row, r, with a positive entry in tcol = 3 as the pivot row: row = 3 associated with Û3,3 = 0.833 and constraint L3.

3. Compute the ratios -Ø / L3 as per the last row. Discard ratios which are not positive and ratios associated with artificial variables. Select the column with the least positive ratio as the pivot column: col = 3 associated with 5.4. Thus Û3,3 = 0.833 is the pivot; variable x1 will leave the basis; variable x3 will enter the basis.

B. To create Tableau3:

4. Compute row L33 = L23 / (0.833).

5. Subtract multiples of row L33 from all other rows of Tableau2 so that x3 = e3 in Tableau3.

Phase II: Goal: get ß >= 0.

Tableau3
  b3 x31 x32 x33 s31 s32 s*33 row
sum
L31 = L21 - (0.167) * L33-25-0.2-1010-2-27.2
L32 = L22 - (0.042) * L3320-0.051.5001224.45
L33 = L23 / (0.833)1101.221002116.2
P3 = P2 - (-4.5) * L3318705.424000341933.4
-P3 / L310272400000

Basis for Tableau3: [s1, s2, x3, ]. Value of Objective Function = 1870.

Proceed to the next tableau as follows:

Phase 0: Complete.

Phase I: Complete.

Phase II: Goal: get ß >= 0.

A. In Tableau3:

1. Select a pivot row, row, with b3row < 0: row = 1 associated with b31 = -25.

2. Compute the ratios -Ø / L1 as per the last row. Discard ratios which are not positive and ratios associated with artificial variables. Select the column with the least positive ratio as the pivot column: col = 2 associated with 24. Thus Û1,2 = -1 is the pivot; variable s1 will leave the basis; variable x2 will enter the basis.

B. To create Tableau4:

3. Compute row L41 = L31 / (-1).

4. Subtract multiples of row L41 from all other rows of Tableau3 so that x2 = e1 in Tableau4.

Tableau4
  b4 x41 x42 x43 s41 s42 s*43 row
sum
L41 = L31 / (-1)250.21-0-1-0227.2
L42 = L32 - (1.5) * L41-17.5-0.35001.51-1-16.35
L43 = L33 - (2) * L41600.80120-261.8
P4 = P3 - (24) * L4112700.600240-141280.6
-P4 / L4201.714000000

Basis for Tableau4: [x2, s2, x3, ]. Value of Objective Function = 1270.

Proceed to the next tableau as follows:

Phase 0: Complete.

Phase I: Complete.

Phase II: Goal: get ß >= 0.

A. In Tableau4:

1. Select a pivot row, row, with b4row < 0: row = 2 associated with b42 = -17.5.

2. Compute the ratios -Ø / L2 as per the last row. Discard ratios which are not positive and ratios associated with artificial variables. Select the column with the least positive ratio as the pivot column: col = 1 associated with 1.714. Thus Û2,1 = -0.35 is the pivot; variable s2 will leave the basis; variable x1 will enter the basis.

B. To create Tableau5:

3. Compute row L52 = L42 / (-0.35).

4. Subtract multiples of row L52 from all other rows of Tableau4 so that x1 = e2 in Tableau5.

Tableau5
  b5 x51 x52 x53 s51 s52 s*53 row
sum
L51 = L41 - (0.2) * L5215010-0.1430.5711.42917.857
L52 = L42 / (-0.35)501-0-0-4.286-2.8572.85746.714
L53 = L43 - (0.8) * L52200015.4292.286-4.28624.429
P5 = P4 - (0.6) * L52124000026.5711.714-15.7141252.571
-P5 / L5-100000000

Basis for Tableau5: [x2, x1, x3, ]. Value of Objective Function = 1240.

Phase 0: Complete.

Phase I: Complete.

Phase II: Complete.

Primal Solution: [x2, x1, x3, ] = [15, 50, 20, ];   P = 1240.

(Primal x variables not in the basis have a value of 0).

Dual Solution: [y1, y2, y3, ] = [26.571, 1.714, -15.714, ];   D = 1240.

End of the Linear Programming Dual Simplex Method



Linear Programming References.

  • Restrepo, Rodrigo A. Theory of Games and Programming: Mathematics Lecture Notes. Vancouver: University of B.C., 1967.
  • Restrepo, Rodrigo A. Linear Programming and Complementarity. Vancouver: University of B.C., 1994.
  • Taha, Hamdy A. Operations Research: An Introduction. 2nd Edition. New York: MacMillan, 1976.
  • Wu, Nesa, and Richard Coppins. Linear Programming and Extensions. New York: McGraw-Hill, 1981.

 
   

      Copyright © Elmer G. Wiens:   Egwald Web Services       All Rights Reserved.    Inquiries