SlideShare a Scribd company logo
Linear Programming Problems



       Dr. Purnima Pandit
                Assistant Professor
        Department of Applied Mathematics
         Faculty of Technology and Engg.

  The Maharaja Sayajirao University of Baroda
Different Kinds of
Optimization
Elements

 Variables
 Objective function
 Constraints
        Obtain values of the variables
     that optimizes the objective function
          ( satisfying the constraints )
Linear Programming (LP)


LP is a mathematical modeling
technique used to achieve an objective,
subject to restrictions called constraints
Types of LP
LP Model Formulation

 Decision variables
      mathematical symbols representing levels of activity of an
       operation
 Objective function
      a linear relationship reflecting the objective of an operation
      most frequent objective of business firms is to maximize profit
      most frequent objective of individual operational units (such as
       a production or packaging department) is to minimize cost
 Constraint
      a linear relationship representing a restriction on decision
       making
LP Model Formulation (cont.)

Max/min          z = c1x1 + c2x2 + ... + cnxn

subject to:
                 a11x1 + a12x2 + ... + a1nxn (≤, =, ≥) b1
                 a21x1 + a22x2 + ... + a2nxn (≤, =, ≥) b2
                          :
                 am1x1 + am2x2 + ... + amnxn (≤, =, ≥) bm

   xj = decision variables
   bi = constraint levels
   cj = objective function coefficients
   aij = constraint coefficients
LP Model: Example

                   RESOURCE REQUIREMENTS
                    Labor        Clay      Revenue
PRODUCT            (hr/unit)   (lb/unit)    ($/unit)
Bowl                   1           4          40
Mug                    2           3          50

There are 40 hours of labor and 120 pounds of clay
available each day

Decision variables
            x1 = number of bowls to produce
            x2 = number of mugs to produce
LP Formulation: Example

Maximize Z = $40 x1 + 50 x2

Subject to
        x1 + 2x2 40 hr (labor constraint)
      4x1 + 3x2 120 lb (clay constraint)
            x1 , x2 0

Solution is x1 = 24 bowls     x2 = 8 mugs
Revenue = $1,360
Graphical Solution Method

1. Plot model constraint on a set of coordinates
   in a plane
2. Identify the feasible solution space on the
   graph where all constraints are satisfied
   simultaneously
3. Plot objective function to find the point on
   boundary of this space that maximizes (or
   minimizes) value of objective function
Convex Hull

 A set C is convex if
  every point on the line
  segment connecting x
  and y is in C.

 The convex hull for a
  set of points X is the
  minimal convex set
  containing X.
Graphical Solution: Example
x2
50 –

40 –
            4 x1 + 3 x2 120 lb
30 –

20 –              Area common to
                  both constraints
10 –
                             x1 + 2 x2 40 hr
 0–     |    |     |     |      |     |
       10   20    30    40     50    60    x1
Computing Optimal Values

x2                                         x1 + 2x2 = 40
40 –
                                          4x1 + 3x2 = 120
       4 x1 + 3 x2 120 lb
                                          4x1 + 8x2 = 160
30 –                                     -4x1 - 3x2 = -120
                                                 5x2 =    40
20 –
                x1 + 2 x2 40 hr                 x2 =     8
10 – 8
                                           x1 + 2(8) =    40
 0–         |     | 24 |       | x1
                                           x1        =    24
           10    20   30      40
                              Z = $50(24) + $50(8) = $1,360
Extreme Corner Points

         x1 = 0 bowls
x2       x2 =20 mugs
                         x1 = 224 bowls
         Z = $1,000
40 –                     x2 =8 mugs
                         Z = $1,360     x1 = 30 bowls
30 –                                    x2 =0 mugs
20 – A
                                        Z = $1,200

10 –
                 B
 0–     |    |    | C|
       10   20   30 40     x1
Objective Function
x2
  40 –
         4x1 + 3x2 120 lb

 30 –             Z = 70x1 + 20x2
                                            Optimal point:
                                            x1 = 30 bowls
 20 –A
                                            x2 =0 mugs
                                            Z = $2,100
 10 –                    B

                                     x1 + 2x2 40 hr
  0–         |       |         | C      |
            10      20        30       40     x1
Minimization Problem

                     CHEMICAL CONTRIBUTION
Brand          Nitrogen (lb/bag)    Phosphate (lb/bag)
Gro-plus               2                    4
Crop-fast              4                    3

        Minimize Z = $6x1 + $3x2

        subject to
               2x1 + 4x2  16 lb of nitrogen
               4x1 + 3x2  24 lb of phosphate
                    x 1, x 2  0
Graphical Solution
   x2

   14 –
        x1 = 0 bags of Gro-plus
   12 – x = 8 bags of Crop-fast
         2

   10 –
        Z = $24

    8–A
                              Z = 6x1 + 3x2
    6–

    4–
                  B
    2–
                          C
    0–    |   |   |   |        |    |    |
          2   4   6   8       10   12   14   x1
Two type of Constraints


Binding and Nonbinding constraints:
 A constraint is binding if the left-hand and right-
 hand side of the constraint are equal when the
 optimal values of the decision variables are
 substituted into the constraint.
 A constraint is nonbinding if the left-hand side
 and the right-hand side of the constraint are
 unequal when the optimal values of the decision
 variables are substituted into the constraint. 18
Special Cases of Graphical Solution


• Some LPs have an infinite number of solutions
  (alternative or multiple optimal solutions).

• Some LPs have no feasible solution (infeasible
  LPs).

• Some LPs are unbounded: There are points in
  the feasible region with arbitrarily large (in a
  maximization problem) z-values.
                                              19
Alternative or Multiple Solutions

                           X2




                           60
                                B




                                D




                           50
Any point (solution)                                        Feasible Region

falling on line segment

                           40
AE will yield an optimal
solution with the same                                  E
                           30
objective value                          z = 100
                                                                    z = 120
                           20




                                    z = 60
                           10




                            F
                                                                               A    C
                                             10    20          30             40   50   20
                                                                                         X1
No feasible solution
                            X2




                            60
                                 No Feasible Region




                            50
                                                           x1 >= 0




                            40
 Some LPs have no
                                                                          x2 >=0
 solution. Consider
                            30



 the following
 formulation:
                            20
                            10




No feasible region exists
                                 10         20        30             40       50   21
                                                                                    X1
Unbounded LP

                           X2
                                               Feasible Region
                            6 D

The constraints are
                            5                                    B
satisfied by all points                   z=4
bounded by the x2 axis      4

and on or above AB and      3
CD.
                            2
There are points in the
feasible region which       1
                                                             z=6

will produce arbitrarily
                                  A        C
large z-values                    1   2    3       4     5       6 X1
(unbounded LP).                                                      22
Higher Dimensional Problems


Graphical Method is useful for two
 dimensional Problems.

Simplex method for 2 and higher
  dimensional problems
Cannonical form
 Standard form is a basic way of describing a LP
  problem.
 It consists of 3 parts:
     A linear function to be maximized
            maximize c1x1 + c2x2 + … + cnxn
    Problem constraints
           subject toa11x1 + a12x2 + … + a1nxn < b1
                     a21x1 + a22x2 + … + a2nxn < b2
                                    …
                    am1x1 + am2x2 + … + amnxn < bm
  Non-negative variables
                    x1, x2 ,…, xn > 0
Obtain Standard Form
     IMPORTANT: Simplex only deals with equalities

General Simplex LP model:
  min (or max) z =  ci xi
  s.t.
         Ax=b
         x0
In order to get and maintain this form, use
 slack, if x  b, then x + slack = b
 surplus, if x  b, then x - surplus = b
 artificial variables (sometimes need to be added to
   ensure all variables  0 )
Different "components" of a LP model

  LP model can always be split into a basic
   and a non-basic part.


  “Transformed” or “reduced” model is
   another good way to show this.


  This can be represented in mathematical
   terms as well as in a LP or simplex
   tableau.
Simplex
 A simplex or n-simplex is
  the convex hull of a set of
  (n +1) . A simplex is an n-
  dimensional analogue of a
  triangle.
 Example:
      a 1-simplex is a line segment
      a 2-simplex is a triangle
      a 3-simplex is a tetrahedron
      a 4-simplex is a pentatope
Movement to Adjacent
       Extreme Point
Given any basis we move to an adjacent extreme point
(another basic feasible solution) of the solution space by
exchanging one of the columns that is in the basis
for a column that is not in the basis.


Two things to determine:
1) which (nonbasic) column of A should be brought
   into the basis so that the solution improves?
2) which column can be removed from the basis
   such that the solution stays feasible?
Entering and Departing Vector
    (Variable) Rules

General rules:
 The one non-basic variable to come in is the one
  which provides the highest reduction in the objective
  function.
 The one basic variable to leave is the one which is
  expected to go infeasible first.


NOTE: THESE ARE HEURISTICS!!
Variations on these rules exist, but are rare.
Example Problem

 Maximize Z = 5x1 + 2x2 + x3

subject to

             x1 + 3x2 - x3 ≤ 6,

                     x2 + x3 ≤ 4,

             3x1 + x2          ≤ 7,

             x1, x2, x3 ≥ 0.
Simplex and Example Problem
          Step 1. Convert to Standard Form

a11 x1 + a12 x2 + ••• + a1n xn ≤ b1,   a11 x1 + a12 x2 + ••• + a1n xn + xn+1 = b1,

a21 x1 + a22 x2 + ••• + a2n xn ≥ b2,    a21 x1 + a22 x2 + ••• + a2n xn - xn+2 = b2,
                       
am1 x1 + am2 x2 + ••• + amn xn ≤ bm,   am1 x1 + am2 x2 + ••• + amn xn + xn+k = bm,

             In our example problem:

      x1 + 3x2 - x3 ≤ 6,                        x1 + 3x2 - x3 + x4            = 6,

            x2 + x3 ≤ 4,                               x2 + x3     + x5       = 4,

     3x1 + x2          ≤ 7,                     3x1 + x2                  + x6 = 7,

     x1, x2, x3 ≥ 0.                            x1, x2, x3, x4, x5, x6 ≥ 0.
Simplex: Step 2

      Step 2. Start with an initial basic feasible solution (b.f.s.) and set up the
      initial tableau.
    In our example
Maximize Z = 5x1 + 2x2 + x3

x1 + 3x2 - x3 + x4            = 6,

       x2 + x3     + x5       = 4,

3x1 + x2                  + x6 = 7,          cB      Basis           cj          Constants
                                                             5 2 1 0 0 0
x1, x2, x3, x4, x5, x6 ≥ 0.                                  x1 x2 x3 x4 x5 x6
                                             0        x4     1 3 -1 1 0 0              6
                                             0        x5     0 1 1 0 1 0               4
                                             0        x6     3 1 0 0 0 1               7
                                                 c row       5 2 1 0 0 0              Z=0
Step 2: Explanation
Adjacent Basic Feasible Solution
If we bring a nonbasic variable xs into the basis, our system changes from the
basis, xb, to the following :
   x1            + ā1sxs= b1               x = b a          for i =1, …, m
                                                                i        i   is
        xr     + ārsxr= b                                       xs = 1
                         r
                                        xj = 0   for j=m+1, ..., n and js
           xm + āmsxs= b
                        s
      The new value of the objective function becomes:
                                        m
                        Z          c (b  a
                                     i 1
                                                   i   i        is )  c s

      Thus the change in the value of Z per unit increase in xs is
              cs = new value of Z - old m
                    m
                                         value of Z
                  =    c (b  a
                      i 1
                             i
                                 m
                                        i      is )  c s      c b
                                                                i 1
                                                                       i i
                                                                             This is the Inner Product rule
                  =   c  c a
                       s                    i is
                                 i 1
Simplex: Step 3
Use the inner product rule to find the relative profit coefficients


              cB       Basis              cj            Constants
                               5 2 1 0 0 0
                               x1 x2 x3 x4 x5 x6
               0        x4     1 3 -1 1 0 0                6
               0        x5     0 1 1 0 1 0                 4
               0        x6     3 1 0 0 0 1                 7
                   c row       5 2 1 0 0 0                Z=0

                               c j  c j  cB Pj
                               c1 = 5 - 0(1) - 0(0) - 0(3) = 5 -> largest positive
                               c2 = ….
                               c3 = ….

Step 4: Is this an optimal basic feasible solution?
Simplex: Step 5

Apply the minimum ratio rule to determine the basic variable to leave the basis.

   The new values of the basis variables:

                      xi = bi    a is x s                      for i = 1, ..., m

                                                  bi 
                                max xs  min 
                                         a is  0 a is
                                                  
 In our example:
  cB     Basis                  cj                  Constants
                 5    2    1         0    0    0                     Row        Basic Variable   Ratio
                 x1   x2   x3        x4   x5   x6                     1            x4             6
  0        x4    1    3    -1        1    0    0       6              2            x5             -
  0        x5    0    1    1         0    1    0       4              3            x6             7/3
  0        x6    3    1    0         0    0    1       7
      c row      5    2    1         0    0    0      Z=0
Simplex: Step 6
    Perform the pivot operation to get the new tableau and the b.f.s.
      cB      Basis            cj               Constants
                      5 2 1 0 0 0
                      x1 x2 x3 x4 x5 x6
      0        x4     1 3 -1 1 0 0                 6
      0        x5     0 1 1 0 1 0                  4
      0        x6     3 1 0 0 0 1                  7
          c row       5 2 1 0 0 0                 Z=0

New iteration:
find entering                              cB      Basis               cj                    Constants
variable:                                                   5  2 1          0    0      0
 c j  c j  c B Pj                                         x1 x2 x3        x4   x5    x6
                                           0        x4      0 8/3 -1        1    0      0     11/3
 cB = (0 0 5)                              0        x5      0  1 1          0    1      0      4
                                           5        x1      1 1/3 0         0    0     1/3    7/3
c2 = 2 - (0) 8/3 - (0) 1 - (5) 1/3 = 1/3       c row        0 1/3 1         0    0    -5/3   Z=35/3
c3 = 1 - (0) (-1) - (0) 1 - (5) 0 = 1
c6 = 0 - (0) 0 - (0) 0 - (5) 1/3 = -5/3
Final Tableau

cB      Basis              cj                       Constants          x3 enters basis,
                5  2 1          0     0        0                       x5 leaves basis
                x1 x2 x3        x4    x5      x6
0        x4     0 8/3 -1        1     0        0     11/3
0        x5     0  1 1          0     1        0      4
5        x1     1 1/3 0         0     0       1/3    7/3
    c row       0 1/3 1         0     0      -5/3   Z=35/3



                       cB            Basis                   cj                  Constants
                                              5  2 1              0    0   0
                                              x1 x2 x3            x4   x5 x6
                       0        x4            0 11/3 0            1    1   0      23/3
                       1        x3            0  1 1              0    1   0       4
                       5        x1            1 1/3 0             0    0 1/3      7/3
                           c row              0 -2/3 0            0    -1 -5/3   Z=47/3
Computational Considerations


 Unrestricted variables (unboundedness)
 Redundancy (linear dependency, modeling
  errors)
 Degeneracy (some basic variables = 0)
 Round-off errors
Simplex Variations

Various variations on the simplex method exist:
 "regular" simplex
 two-phase method: Phase I for feasibility
  and Phase II for optimality
 Condensed / reduced / revised method: only
  use the non-basic columns to work with
 (revised) dual simplex, etc.
Limitations of Simplex

1. Inability to deal with multiple objectives
2. Inability to handle problems with integer variables

Problem 1 is solved using Multiplex
Problem 2 has resulted in:
 Cutting plane algorithms (Gomory, 1958)
 Branch and Bound (Land and Doig, 1960)
However,
  solution methods to LP problems with integer or
  Boolean variables are still far less efficient than those
  which include continuous variables only
Primal and Dual LP Problems

•Economic theory indicates that scarce (limited) resources
have value. In LP models, limited resources are allocated, so
they should be, valued.

•Whenever we solve an LP problem, we implicitly solve two
problems: the primal resource allocation problem, and the
dual resource valuation problem.

•Here we cover the resource valuation, or as it is commonly
called, the Dual LP.
Max    c X         j     j
Primal   s.t.   a X
                    j

                             ij    j            bi       for all i
                    j
                                  Xj             0       for all j



         Min    b Y     i i

Dual     s.t.
                i

                a Y
                i
                         ji i                 c j for all j
                        Yi              0            for all i

More Related Content

PPTX
LINEAR PROGRAMMING
PPT
Simplex Method
PDF
Chapter 4 Simplex Method ppt
PPT
simplex method
PPTX
Simplex method concept,
PPTX
Duality in Linear Programming
PPTX
Linear programming ppt
PPTX
Linear programming
LINEAR PROGRAMMING
Simplex Method
Chapter 4 Simplex Method ppt
simplex method
Simplex method concept,
Duality in Linear Programming
Linear programming ppt
Linear programming

What's hot (20)

PPTX
Linear Programming Application
PPTX
graphical method
PPT
Simplex Method
PPSX
Graphical method
PDF
Integer programming
PPTX
Goal Programming
PPSX
Linear programing
PPTX
Sensitivity analysis linear programming copy
PDF
Unbalanced Transportation Problem
PPTX
LP special cases and Duality.pptx
PPTX
Special Cases in Simplex Method
PPTX
Linear Programming
PPTX
Big m method
PPT
4-The Simplex Method.ppt
PPTX
PRIMAL & DUAL PROBLEMS
PPTX
Integer Linear Programming
PPT
Formulation Lpp
PPTX
Linear programming - Model formulation, Graphical Method
PPTX
LEAST COST METHOD
PPTX
Decision theory
Linear Programming Application
graphical method
Simplex Method
Graphical method
Integer programming
Goal Programming
Linear programing
Sensitivity analysis linear programming copy
Unbalanced Transportation Problem
LP special cases and Duality.pptx
Special Cases in Simplex Method
Linear Programming
Big m method
4-The Simplex Method.ppt
PRIMAL & DUAL PROBLEMS
Integer Linear Programming
Formulation Lpp
Linear programming - Model formulation, Graphical Method
LEAST COST METHOD
Decision theory
Ad

Viewers also liked (17)

PPTX
Determinant
PPTX
Controllability of Linear Dynamical System
PPTX
Bca i-fundamental of computer-u-3-functions operating systems
PDF
Basic mathematics code 303102 bca 1st semester exam. 2014
DOCX
sanjeev resume
PDF
BCA_MATHEMATICS-I_Unit-IV
PDF
Matrix Inverse, IMT
PPTX
Introduction to mathematical control theory - Dr. Purnima Pandit
PDF
BCA_Semester-II-Discrete Mathematics_unit-iii_Lattices and boolean algebra
PPTX
Soft computing (ANN and Fuzzy Logic) : Dr. Purnima Pandit
PDF
Matrices and determinants
PPTX
Inverse Matrix & Determinants
PPTX
Determinants
PPT
Matrices And Determinants
PPT
Application of Mathematics in Business : F 107 - Group K
PDF
Matrices and determinants
PPTX
BCA , BBA MATHEMATICS CLASSES
Determinant
Controllability of Linear Dynamical System
Bca i-fundamental of computer-u-3-functions operating systems
Basic mathematics code 303102 bca 1st semester exam. 2014
sanjeev resume
BCA_MATHEMATICS-I_Unit-IV
Matrix Inverse, IMT
Introduction to mathematical control theory - Dr. Purnima Pandit
BCA_Semester-II-Discrete Mathematics_unit-iii_Lattices and boolean algebra
Soft computing (ANN and Fuzzy Logic) : Dr. Purnima Pandit
Matrices and determinants
Inverse Matrix & Determinants
Determinants
Matrices And Determinants
Application of Mathematics in Business : F 107 - Group K
Matrices and determinants
BCA , BBA MATHEMATICS CLASSES
Ad

Similar to Linear Programming Problems : Dr. Purnima Pandit (20)

DOC
Simplex3
PDF
PPTX
Linear programming graphical method (feasibility)
PPT
LP Graphical Solution
PPT
Graphical Method
PPTX
Linear Programming Feasible Region
PDF
Problems in Linear Programming 2
PPT
Simplex method
PDF
Or lpp
PDF
Logistics. Example
PDF
23 industrial engineering
PDF
Review for final exam
PPTX
Or graphical method, simplex method
PPTX
Operations Research
PPTX
Linear programming simplex method
PPT
Linear Programming
PPT
Linear Programming
PPT
Linear Programming
PDF
Logistics. Terminology
PPTX
MFCS2-Module1.pptx
Simplex3
Linear programming graphical method (feasibility)
LP Graphical Solution
Graphical Method
Linear Programming Feasible Region
Problems in Linear Programming 2
Simplex method
Or lpp
Logistics. Example
23 industrial engineering
Review for final exam
Or graphical method, simplex method
Operations Research
Linear programming simplex method
Linear Programming
Linear Programming
Linear Programming
Logistics. Terminology
MFCS2-Module1.pptx

Recently uploaded (20)

PPTX
BOWEL ELIMINATION FACTORS AFFECTING AND TYPES
PPTX
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PDF
Physiotherapy_for_Respiratory_and_Cardiac_Problems WEBBER.pdf
PDF
VCE English Exam - Section C Student Revision Booklet
PDF
Saundersa Comprehensive Review for the NCLEX-RN Examination.pdf
PDF
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
PDF
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
PDF
Anesthesia in Laparoscopic Surgery in India
PDF
Business Ethics Teaching Materials for college
PPTX
Microbial diseases, their pathogenesis and prophylaxis
PDF
RMMM.pdf make it easy to upload and study
PPTX
Pharmacology of Heart Failure /Pharmacotherapy of CHF
PDF
Module 4: Burden of Disease Tutorial Slides S2 2025
PDF
102 student loan defaulters named and shamed – Is someone you know on the list?
PDF
Mark Klimek Lecture Notes_240423 revision books _173037.pdf
PDF
Complications of Minimal Access Surgery at WLH
PDF
2.FourierTransform-ShortQuestionswithAnswers.pdf
PDF
Microbial disease of the cardiovascular and lymphatic systems
PDF
grade 11-chemistry_fetena_net_5883.pdf teacher guide for all student
PPTX
human mycosis Human fungal infections are called human mycosis..pptx
BOWEL ELIMINATION FACTORS AFFECTING AND TYPES
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
Physiotherapy_for_Respiratory_and_Cardiac_Problems WEBBER.pdf
VCE English Exam - Section C Student Revision Booklet
Saundersa Comprehensive Review for the NCLEX-RN Examination.pdf
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
Anesthesia in Laparoscopic Surgery in India
Business Ethics Teaching Materials for college
Microbial diseases, their pathogenesis and prophylaxis
RMMM.pdf make it easy to upload and study
Pharmacology of Heart Failure /Pharmacotherapy of CHF
Module 4: Burden of Disease Tutorial Slides S2 2025
102 student loan defaulters named and shamed – Is someone you know on the list?
Mark Klimek Lecture Notes_240423 revision books _173037.pdf
Complications of Minimal Access Surgery at WLH
2.FourierTransform-ShortQuestionswithAnswers.pdf
Microbial disease of the cardiovascular and lymphatic systems
grade 11-chemistry_fetena_net_5883.pdf teacher guide for all student
human mycosis Human fungal infections are called human mycosis..pptx

Linear Programming Problems : Dr. Purnima Pandit

  • 1. Linear Programming Problems Dr. Purnima Pandit Assistant Professor Department of Applied Mathematics Faculty of Technology and Engg. The Maharaja Sayajirao University of Baroda
  • 3. Elements  Variables  Objective function  Constraints Obtain values of the variables that optimizes the objective function ( satisfying the constraints )
  • 4. Linear Programming (LP) LP is a mathematical modeling technique used to achieve an objective, subject to restrictions called constraints
  • 6. LP Model Formulation  Decision variables  mathematical symbols representing levels of activity of an operation  Objective function  a linear relationship reflecting the objective of an operation  most frequent objective of business firms is to maximize profit  most frequent objective of individual operational units (such as a production or packaging department) is to minimize cost  Constraint  a linear relationship representing a restriction on decision making
  • 7. LP Model Formulation (cont.) Max/min z = c1x1 + c2x2 + ... + cnxn subject to: a11x1 + a12x2 + ... + a1nxn (≤, =, ≥) b1 a21x1 + a22x2 + ... + a2nxn (≤, =, ≥) b2 : am1x1 + am2x2 + ... + amnxn (≤, =, ≥) bm xj = decision variables bi = constraint levels cj = objective function coefficients aij = constraint coefficients
  • 8. LP Model: Example RESOURCE REQUIREMENTS Labor Clay Revenue PRODUCT (hr/unit) (lb/unit) ($/unit) Bowl 1 4 40 Mug 2 3 50 There are 40 hours of labor and 120 pounds of clay available each day Decision variables x1 = number of bowls to produce x2 = number of mugs to produce
  • 9. LP Formulation: Example Maximize Z = $40 x1 + 50 x2 Subject to x1 + 2x2 40 hr (labor constraint) 4x1 + 3x2 120 lb (clay constraint) x1 , x2 0 Solution is x1 = 24 bowls x2 = 8 mugs Revenue = $1,360
  • 10. Graphical Solution Method 1. Plot model constraint on a set of coordinates in a plane 2. Identify the feasible solution space on the graph where all constraints are satisfied simultaneously 3. Plot objective function to find the point on boundary of this space that maximizes (or minimizes) value of objective function
  • 11. Convex Hull  A set C is convex if every point on the line segment connecting x and y is in C.  The convex hull for a set of points X is the minimal convex set containing X.
  • 12. Graphical Solution: Example x2 50 – 40 – 4 x1 + 3 x2 120 lb 30 – 20 – Area common to both constraints 10 – x1 + 2 x2 40 hr 0– | | | | | | 10 20 30 40 50 60 x1
  • 13. Computing Optimal Values x2 x1 + 2x2 = 40 40 – 4x1 + 3x2 = 120 4 x1 + 3 x2 120 lb 4x1 + 8x2 = 160 30 – -4x1 - 3x2 = -120 5x2 = 40 20 – x1 + 2 x2 40 hr x2 = 8 10 – 8 x1 + 2(8) = 40 0– | | 24 | | x1 x1 = 24 10 20 30 40 Z = $50(24) + $50(8) = $1,360
  • 14. Extreme Corner Points x1 = 0 bowls x2 x2 =20 mugs x1 = 224 bowls Z = $1,000 40 – x2 =8 mugs Z = $1,360 x1 = 30 bowls 30 – x2 =0 mugs 20 – A Z = $1,200 10 – B 0– | | | C| 10 20 30 40 x1
  • 15. Objective Function x2 40 – 4x1 + 3x2 120 lb 30 – Z = 70x1 + 20x2 Optimal point: x1 = 30 bowls 20 –A x2 =0 mugs Z = $2,100 10 – B x1 + 2x2 40 hr 0– | | | C | 10 20 30 40 x1
  • 16. Minimization Problem CHEMICAL CONTRIBUTION Brand Nitrogen (lb/bag) Phosphate (lb/bag) Gro-plus 2 4 Crop-fast 4 3 Minimize Z = $6x1 + $3x2 subject to 2x1 + 4x2  16 lb of nitrogen 4x1 + 3x2  24 lb of phosphate x 1, x 2  0
  • 17. Graphical Solution x2 14 – x1 = 0 bags of Gro-plus 12 – x = 8 bags of Crop-fast 2 10 – Z = $24 8–A Z = 6x1 + 3x2 6– 4– B 2– C 0– | | | | | | | 2 4 6 8 10 12 14 x1
  • 18. Two type of Constraints Binding and Nonbinding constraints: A constraint is binding if the left-hand and right- hand side of the constraint are equal when the optimal values of the decision variables are substituted into the constraint. A constraint is nonbinding if the left-hand side and the right-hand side of the constraint are unequal when the optimal values of the decision variables are substituted into the constraint. 18
  • 19. Special Cases of Graphical Solution • Some LPs have an infinite number of solutions (alternative or multiple optimal solutions). • Some LPs have no feasible solution (infeasible LPs). • Some LPs are unbounded: There are points in the feasible region with arbitrarily large (in a maximization problem) z-values. 19
  • 20. Alternative or Multiple Solutions X2 60 B D 50 Any point (solution) Feasible Region falling on line segment 40 AE will yield an optimal solution with the same E 30 objective value z = 100 z = 120 20 z = 60 10 F A C 10 20 30 40 50 20 X1
  • 21. No feasible solution X2 60 No Feasible Region 50 x1 >= 0 40 Some LPs have no x2 >=0 solution. Consider 30 the following formulation: 20 10 No feasible region exists 10 20 30 40 50 21 X1
  • 22. Unbounded LP X2 Feasible Region 6 D The constraints are 5 B satisfied by all points z=4 bounded by the x2 axis 4 and on or above AB and 3 CD. 2 There are points in the feasible region which 1 z=6 will produce arbitrarily A C large z-values 1 2 3 4 5 6 X1 (unbounded LP). 22
  • 23. Higher Dimensional Problems Graphical Method is useful for two dimensional Problems. Simplex method for 2 and higher dimensional problems
  • 24. Cannonical form  Standard form is a basic way of describing a LP problem.  It consists of 3 parts: A linear function to be maximized maximize c1x1 + c2x2 + … + cnxn Problem constraints subject toa11x1 + a12x2 + … + a1nxn < b1 a21x1 + a22x2 + … + a2nxn < b2 … am1x1 + am2x2 + … + amnxn < bm Non-negative variables x1, x2 ,…, xn > 0
  • 25. Obtain Standard Form IMPORTANT: Simplex only deals with equalities General Simplex LP model: min (or max) z =  ci xi s.t. Ax=b x0 In order to get and maintain this form, use  slack, if x  b, then x + slack = b  surplus, if x  b, then x - surplus = b  artificial variables (sometimes need to be added to ensure all variables  0 )
  • 26. Different "components" of a LP model  LP model can always be split into a basic and a non-basic part.  “Transformed” or “reduced” model is another good way to show this.  This can be represented in mathematical terms as well as in a LP or simplex tableau.
  • 27. Simplex  A simplex or n-simplex is the convex hull of a set of (n +1) . A simplex is an n- dimensional analogue of a triangle.  Example:  a 1-simplex is a line segment  a 2-simplex is a triangle  a 3-simplex is a tetrahedron  a 4-simplex is a pentatope
  • 28. Movement to Adjacent Extreme Point Given any basis we move to an adjacent extreme point (another basic feasible solution) of the solution space by exchanging one of the columns that is in the basis for a column that is not in the basis. Two things to determine: 1) which (nonbasic) column of A should be brought into the basis so that the solution improves? 2) which column can be removed from the basis such that the solution stays feasible?
  • 29. Entering and Departing Vector (Variable) Rules General rules:  The one non-basic variable to come in is the one which provides the highest reduction in the objective function.  The one basic variable to leave is the one which is expected to go infeasible first. NOTE: THESE ARE HEURISTICS!! Variations on these rules exist, but are rare.
  • 30. Example Problem Maximize Z = 5x1 + 2x2 + x3 subject to x1 + 3x2 - x3 ≤ 6, x2 + x3 ≤ 4, 3x1 + x2 ≤ 7, x1, x2, x3 ≥ 0.
  • 31. Simplex and Example Problem Step 1. Convert to Standard Form a11 x1 + a12 x2 + ••• + a1n xn ≤ b1, a11 x1 + a12 x2 + ••• + a1n xn + xn+1 = b1, a21 x1 + a22 x2 + ••• + a2n xn ≥ b2, a21 x1 + a22 x2 + ••• + a2n xn - xn+2 = b2,  am1 x1 + am2 x2 + ••• + amn xn ≤ bm, am1 x1 + am2 x2 + ••• + amn xn + xn+k = bm, In our example problem: x1 + 3x2 - x3 ≤ 6, x1 + 3x2 - x3 + x4 = 6, x2 + x3 ≤ 4, x2 + x3 + x5 = 4, 3x1 + x2 ≤ 7, 3x1 + x2 + x6 = 7, x1, x2, x3 ≥ 0. x1, x2, x3, x4, x5, x6 ≥ 0.
  • 32. Simplex: Step 2 Step 2. Start with an initial basic feasible solution (b.f.s.) and set up the initial tableau. In our example Maximize Z = 5x1 + 2x2 + x3 x1 + 3x2 - x3 + x4 = 6, x2 + x3 + x5 = 4, 3x1 + x2 + x6 = 7, cB Basis cj Constants 5 2 1 0 0 0 x1, x2, x3, x4, x5, x6 ≥ 0. x1 x2 x3 x4 x5 x6 0 x4 1 3 -1 1 0 0 6 0 x5 0 1 1 0 1 0 4 0 x6 3 1 0 0 0 1 7 c row 5 2 1 0 0 0 Z=0
  • 33. Step 2: Explanation Adjacent Basic Feasible Solution If we bring a nonbasic variable xs into the basis, our system changes from the basis, xb, to the following : x1 + ā1sxs= b1 x = b a for i =1, …, m i i is xr + ārsxr= b xs = 1  r xj = 0 for j=m+1, ..., n and js xm + āmsxs= b  s The new value of the objective function becomes: m Z  c (b  a i 1 i i is )  c s Thus the change in the value of Z per unit increase in xs is cs = new value of Z - old m m value of Z =  c (b  a i 1 i m i is )  c s  c b i 1 i i This is the Inner Product rule = c  c a s i is i 1
  • 34. Simplex: Step 3 Use the inner product rule to find the relative profit coefficients cB Basis cj Constants 5 2 1 0 0 0 x1 x2 x3 x4 x5 x6 0 x4 1 3 -1 1 0 0 6 0 x5 0 1 1 0 1 0 4 0 x6 3 1 0 0 0 1 7 c row 5 2 1 0 0 0 Z=0 c j  c j  cB Pj c1 = 5 - 0(1) - 0(0) - 0(3) = 5 -> largest positive c2 = …. c3 = …. Step 4: Is this an optimal basic feasible solution?
  • 35. Simplex: Step 5 Apply the minimum ratio rule to determine the basic variable to leave the basis. The new values of the basis variables: xi = bi  a is x s for i = 1, ..., m  bi  max xs  min  a is  0 a is   In our example: cB Basis cj Constants 5 2 1 0 0 0 Row Basic Variable Ratio x1 x2 x3 x4 x5 x6 1 x4 6 0 x4 1 3 -1 1 0 0 6 2 x5 - 0 x5 0 1 1 0 1 0 4 3 x6 7/3 0 x6 3 1 0 0 0 1 7 c row 5 2 1 0 0 0 Z=0
  • 36. Simplex: Step 6 Perform the pivot operation to get the new tableau and the b.f.s. cB Basis cj Constants 5 2 1 0 0 0 x1 x2 x3 x4 x5 x6 0 x4 1 3 -1 1 0 0 6 0 x5 0 1 1 0 1 0 4 0 x6 3 1 0 0 0 1 7 c row 5 2 1 0 0 0 Z=0 New iteration: find entering cB Basis cj Constants variable: 5 2 1 0 0 0 c j  c j  c B Pj x1 x2 x3 x4 x5 x6 0 x4 0 8/3 -1 1 0 0 11/3 cB = (0 0 5) 0 x5 0 1 1 0 1 0 4 5 x1 1 1/3 0 0 0 1/3 7/3 c2 = 2 - (0) 8/3 - (0) 1 - (5) 1/3 = 1/3 c row 0 1/3 1 0 0 -5/3 Z=35/3 c3 = 1 - (0) (-1) - (0) 1 - (5) 0 = 1 c6 = 0 - (0) 0 - (0) 0 - (5) 1/3 = -5/3
  • 37. Final Tableau cB Basis cj Constants x3 enters basis, 5 2 1 0 0 0 x5 leaves basis x1 x2 x3 x4 x5 x6 0 x4 0 8/3 -1 1 0 0 11/3 0 x5 0 1 1 0 1 0 4 5 x1 1 1/3 0 0 0 1/3 7/3 c row 0 1/3 1 0 0 -5/3 Z=35/3 cB Basis cj Constants 5 2 1 0 0 0 x1 x2 x3 x4 x5 x6 0 x4 0 11/3 0 1 1 0 23/3 1 x3 0 1 1 0 1 0 4 5 x1 1 1/3 0 0 0 1/3 7/3 c row 0 -2/3 0 0 -1 -5/3 Z=47/3
  • 38. Computational Considerations  Unrestricted variables (unboundedness)  Redundancy (linear dependency, modeling errors)  Degeneracy (some basic variables = 0)  Round-off errors
  • 39. Simplex Variations Various variations on the simplex method exist:  "regular" simplex  two-phase method: Phase I for feasibility and Phase II for optimality  Condensed / reduced / revised method: only use the non-basic columns to work with  (revised) dual simplex, etc.
  • 40. Limitations of Simplex 1. Inability to deal with multiple objectives 2. Inability to handle problems with integer variables Problem 1 is solved using Multiplex Problem 2 has resulted in:  Cutting plane algorithms (Gomory, 1958)  Branch and Bound (Land and Doig, 1960) However, solution methods to LP problems with integer or Boolean variables are still far less efficient than those which include continuous variables only
  • 41. Primal and Dual LP Problems •Economic theory indicates that scarce (limited) resources have value. In LP models, limited resources are allocated, so they should be, valued. •Whenever we solve an LP problem, we implicitly solve two problems: the primal resource allocation problem, and the dual resource valuation problem. •Here we cover the resource valuation, or as it is commonly called, the Dual LP.
  • 42. Max c X j j Primal s.t. a X j ij j  bi for all i j Xj  0 for all j Min b Y i i Dual s.t. i a Y i ji i  c j for all j Yi  0 for all i