Sensitivity Analysis 2 - PowerPoint PPT Presentation

1 / 47
About This Presentation
Title:

Sensitivity Analysis 2

Description:

To make your life easier, this is changed to the book's definition on p. 237. ... G) .000000 .333333 binding. W) .000000 .500000 binding. NO. ITERATIONS= 2. 10 ... – PowerPoint PPT presentation

Number of Views:40
Avg rating:3.0/5.0
Slides: 48
Provided by: fuqu71
Category:

less

Transcript and Presenter's Notes

Title: Sensitivity Analysis 2


1
Sensitivity Analysis 2
  • More on pricing out
  • Effects on final tableaus

2
Partial summary of last lecture
  • To make your life easier, this is changed to the
    books definition on p. 237.
  • The shadow price is the improvement in the
    optimal objective value per unit increase in the
    RHS.
  • The shadow price for a ? 0 constraint (i.e., a
    sign condition) is called the reduced cost.
  • Shadow prices usually but not always have
    economic interpretations that are managerially
    useful.
  • Shadow prices are valid in an interval, which is
    provided by the Sensitivity Analysis Report.
  • Reduced costs can be determined by pricing out

3
Running Example
  • Sarah can sell bags consisting of 3 gadgets and 2
    widgets for 2 each.
  • She currently has 6 gadgets and 2 widgets.
  • She can purchase bags with 3 gadgets and 4
    widgets for 3.
  • Formulate Sarahs problem as an LP and solve it.

4
Model
  • maximize z -3x1 2x2
  • subject to g) 3x2 x3
    6 3x1
  • w) 2x2
    x4 2 4x1
  • x1, x2,
    x3, x4 ? 0
  • where x1 is the number of bags she buys for 3 a
    piece
  • x2
    sells for 2 a piece
  • The constraints say that she cannot sell more
    gadgets (or widgets) than she has.
  • The o.f. is her net profit.

5
Shadow Prices can be found by examining the
initial and final tableaus!
maximize z -3x1 2x2 subject to
-3x1 3x2 x3
6
-4x1 2x2 x4 2
x1, x2, x3,
x4 ? 0
x1
x2
x4
x3
-z
-3
2
0
0
1
0

-3
3
1
6
0
0

2
-4
2
0
1
0
6
The Initial Basic Feasible Solution
x1
x2
x4
x3
-z
Apply the min ratio rule
-3
2
0
0
1
0

-3
3
1
0
0
6
x3

min (6/3, 2/2).
-4
2
0
1
0
2
2
x4
The basic feasible solution is x1 0, x2 0,
x3 6, x4 2
x2
What is the entering variable?
x4
What is the leaving variable?
7
The 2nd Tableau
x1
x2
x4
x3
-z
-3
2
0
0
1
0
1
0
-1
0
-2

-3
3
1
0
0
6
0
1
-3/2
3
3
x3

-4
2
0
1
0
2
-2
1
0
1/2
1
x2
The basic feasible solution is x1 0, x2 1,
x3 3, x4 0, z 2
x1
What is the next entering variable?
x3
What is the next leaving variable?
8
The 3rd Tableau
x1
x2
x4
x3
-z
1
0
-1
0
-2
0
0
-1/2
-1/3
1
-3

3
0
1
-3/2
3
1
0
1/3
-1/2
0
1
x1

-2
1
0
1/2
1
0
1
2/3
-1/2
0
3
x2
The optimal basic feasible solution is x1 1,
x2 3, x3 0, x4 0, z 3
9
LINDO output
  • MAX - 3 X1 2 X2
  • SUBJECT TO
  • G) - 3 X1 3 X2 lt 6
  • W) - 4 X1 2 X2 lt 2
  • END
  • LP OPTIMUM FOUND AT STEP 2
  • OBJECTIVE FUNCTION VALUE
  • 1) 3.0000000
  • VARIABLE VALUE REDUCED COST
  • X1 1.000000 .000000
    basic
  • X2 3.000000 .000000
    basic
  • ROW SLACK OR SURPLUS DUAL PRICES
  • G) .000000 .333333
    binding

10
LINDO Sensitivity Analysis
  • RANGES IN WHICH THE BASIS IS UNCHANGED
  • OBJ COEFFICIENT RANGES
  • VARIABLE CURRENT ALLOWABLE
    ALLOWABLE
  • COEF INCREASE
    DECREASE
  • X1 -3.000000 1.000000
    1.000000
  • X2 2.000000 1.000000
    .500000
  • RIGHTHAND SIDE RANGES
  • ROW CURRENT ALLOWABLE
    ALLOWABLE
  • RHS INCREASE
    DECREASE
  • G 6.000000 INFINITY
    3.000000
  • W 2.000000 2.000000
    INFINITY

11
Final tableau
  • tab
  • THE TABLEAU
  • ROW (BASIS) X1 X2 SLK2
    SLK3
  • 1 ART .000 .000
    .333 .500 3.000
  • G X1 1.000 .000
    .333 -.500 1.000
  • W X2 .000 1.000
    .667 -.500 3.000

12
Shadow Price
  • The shadow price of a constraint is the
    improvement in the optimum objective value per
    unit increase in the RHS coefficient, all other
    data remaining equal.
  • What is the shadow price for constraint 1,
    gadgets on hand?
  • This is the value of an extra gadget on hand.

13
x1
x2
x4
x3
-z
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
14
Reduced Costs
  • The reduced cost of a variable x is the shadow
    price of the x ? 0 constraint. It is also the
    cost coefficient for x in the final tableau.
  • Suppose in the previous example that we required
    that x3 ? 1? What is the impact on the optimal
    objective value? What is the resulting solution?
  • By the previous slide, the impact is 1/3.

Sarahs Problem
15
More on reduced costs
  • In a pivot, multiples of constraints are added to
    the cost row.
  • We will use this fact to determine explicitly how
    the cost row in the final tableau is obtained.

16
x1
x2
x4
x3
-z
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
The cost row in the final tableau is obtained by
adding multiples of original constraints to the
original cost row.
x1
x2
x4
x3
-z
0
0
-1/2
-1/3
-3
1

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
17
x1
x2
x4
x3
-z
How are the reduced costs in the 2nd tableau
below obtained?
-3
2
0
0
1
0
1

-3
3
1
0
0
6

-1/3
-4
2
0
1
0
2
x1
x2
x4
x3
-z
Take the initial cost coefficients.
0
0
-1/2
-1/3
-3
1
-1/3

Then subtract 1/3 of constraint 1.
1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
18
x1
x2
x4
x3
-z
-3
2
0
0
1
0
1

-3
3
1
0
0
6

-1/3
-4
2
0
1
0
2
-1/2
x1
x2
x4
x3
-z
Next subtract ½ of constraint 2 from these
costs.
0
0
-1/2
-1/3
-3
1
-1/2

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
19
Implications of Reduced Costs
  • Implication 1 increasing the cost coefficient
    of a non-basic variable by D leads to an increase
    of its reduced cost by D.

20
x1
x2
x4
x3
-z
What is the effect of adding D to the cost
coefficient for x3?
-3
2
0
0
1
0
D

-3
3
1
0
0
6

-4
2
0
1
0
2
FACT Adding D to the cost coefficient in an
initial tableau also adds D to the same
coefficient in subsequent tableaus
x1
x2
x4
x3
-z
0
0
-1/2
-1/3
-3
1
D-1/3

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
21
x1
x4
-z
What is the effect of adding D to the cost
coefficient for x2?
x3
x2
RHS
2
-3
0
1
0
0
2D

3
-3
0
0
6
1

2
-4
1
0
2
0
x1
x2
-z
x4
x3
RHS
Sarahs Problem
0
0
0
0
1
0D
-1/2
-3
-1/3

1
0
0
-1/2
1
1/3

0
1
0
-1/2
3
2/3
22
x1
x4
-z
x3
x2
RHS
Subtract D times row 3 from row 1 to get it back
in canonical form.
2
-3
0
1
0
0
2D

3
-3
0
0
6
1

2
-4
1
0
2
0
D ? 1 for the tableau to remain optimal. Bound on
changes in cost coefficients.
How large can D be?
x1
x2
-z
x4
x3
RHS
0
0
0
0
1
0D
-1/2
-3
-1/3
-1/2 D/2
-3-3D
-1/3-2D/3
0
0

1
0
0
-1/2
1
1/3

Sarahs Problem
0
1
0
-1/2
3
2/3
23
Implications of Reduced Costs
  • Implication 2 We can compute the reduced cost
    of any variable if we know the original column
    and if we know the prices for each constraint.

24
x1
x2
x5
x3
-z
x4
RHS
-3
2
0
1
0
0

-3
3
1
0
6
0

-4
2
0
0
2
1
Suppose that we add another variable, say x5.
Should we produce x5? What is ?c5?
x1
x2
x3
-z
x4
0
0
-1/3
-3
1
-1/2

1
0
1/3
1
0
-1/2

0
1
2/3
3
0
-1/2
25
x1
x2
x5
x3
-z
x4
RHS
-3
2
0
1
0
0

-3
3
1
0
6
0

-4
2
0
0
2
1
?c5 3/2 - 21/3 11/2 1/3
FACT We can compute the reduced cost of a new
variable. If the reduced cost is positive, it
should be entered into the basis.
x1
x2
x3
-z
x4
0
0
1/3
-1/3
-3
1
-1/2

1
0
1/3
1
0
-1/2

0
1
2/3
3
0
-1/2
26
More on Pricing Out
  • Every tableau has prices. These are usually
    called simplex multipliers.
  • The prices for the optimal tableau are the shadow
    prices.

27
Simplex Multipliers
x1
x2
x5
x3
-z
x4
-3
2
0
1
0
0

-3
3
1
0
6
0
p11/3

-4
2
0
0
2
1
p2 1/2
FACT x2 is a basic variable and so?c2 0.
x5
x1
x2
x3
-z
x4
1/5
0
0
-1/3
-3
1
-1/2

1/2
1
0
1/3
1
0
-1/2

1.5
0
1
2/3
3
0
-1/2
28
A useful fact from linear algebra
  • If column j in the initial tableau is a linear
    combination of the other columns, then it is the
    same linear combination of the other columns in
    the final tableau.
  • e.g., if A.3 A.2 2 A.1 , then
    ?A.3 ?A.2 2?A.1

We will use this fact to derive information about
the final tableau. But first. some practice.
29
x1
x2
x4
x3
-z
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
30
x1
x2
x4
x3
-z
Let Aj column j
-3
2
0
0
1
0

A2 column for x2
-3
3
1
0
0
6

A0 column for z
-4
2
0
1
0
2
x1
x2
x4
x3
-z
Let ?Aj column j
?A2 column 2
0
0
-1/2
-1/3
-3
1

?A0 column for z
1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
31
x1
x2
x4
x3
-z
A1 -3 A0 - 3 A3 - 4 A4
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
x1
x2
x4
x3
-z
?A1 -3?A0 - 3?A3 - 4?A4
0
0
-1/2
-1/3
-3
1

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
32
x1
x2
x4
x3
-z
A2 2 A0 3 A3 2 A4
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
x1
x2
x4
x3
-z
?A2 2?A0 3?A3 2?A4
0
0
-1/2
-1/3
-3
1

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
33
x1
x2
x4
x3
-z
b
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
x1
x2
x4
x3
-z
?b
?b?
0
0
-1/2
-1/3
-3
1

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
34
x1
x2
x4
x3
-z
b
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
b b A3
What is?b ?
x1
x2
x4
x3
-z
?b
?b
0
0
-1/2
-1/3
-3
1

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
35
x1
x2
x4
x3
-z
b
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
b b A3
?b ?b ?A3
x1
x2
x4
x3
-z
?b
?b
0
0
-1/2
-1/3
-3
1

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
36
x1
x2
x4
x3
-z
b
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
The reduced cost of the slack is the negative of
the shadow price.
x1
x2
x4
x3
-z
?b
?b
0
0
-1/2
-1/3
-3
1
-3 - 1/3
-1/3

1
0
1/3
-1/2
1
0
1 1/3

0
1
2/3
-1/2
3
0
3 2/3
37
x1
x2
x4
x3
-z
b
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
b b D A3
What is?b ?
x1
x2
x4
x3
-z
?b
?b
0
0
-1/2
-1/3
-3
1

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
38
x1
x2
x4
x3
-z
b
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
b b D A3
?b ?b D?A3
x1
x2
x4
x3
-z
?b
?b
0
0
-1/2
-1/3
-3
1

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
39
x1
x2
x4
x3
-z
b
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
What are upper and lower bounds on D?
x1
x2
x4
x3
-z
?b
?b
0
0
-1/2
-1/3
-3
1

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
40
On varying the RHS
  • Suppose one adds D to b1.
  • This is equivalent to adding D times the column
    corresponding to the first slack variable
  • One can compute the shadow price and also the
    effect on ?b
  • This transformation also provides upper and lower
    bounds on the interval for which the shadow price
    is valid.

Sarahs Problem
41
x1
x2
x4
x3
-z
b
-3
2
0
0
1
0

-3
3
1
0
0
6

-4
2
0
1
0
2
What is?b? What are upper and lower bounds on D
?
x1
x2
x4
x3
-z
?b
?b
0
0
-1/2
-1/3
-3
1

1
0
1/3
-1/2
1
0

0
1
2/3
-1/2
3
0
42
Summary of Lecture
  • Using tableaus to determine information
  • Shadow prices and simplex multipliers
  • Changes in cost coefficients
  • Linear relationships between columns in the
    original tableau are preserved in the final
    tableau.
  • Determining upper and lower bounds on D so that
    the shadow price remains valid.
  • The simplex algorithm can determine all shadow
    prices and reduced costs VERY quickly

43
Some Extra Insight
  • The following four slides are additional material
    not covered in the lecture, but covered in AMP.

44
Shadow price vs slack variable
  • maximize z -3x1 2x2
  • subject to -3x1 3x2 x3
    6
  • -4x1 2x2
    x4 2
  • x1,
    x2, x3, x4 ? 0

Claim increasing the 6 to a 7 is mathematically
equivalent to replacing x3 ? 0 with x3 ?
-1. This is also the reduced cost for variable
x3.
Reason 1. Permitting Sarah to have 7 gadgets
is equivalent to giving her 6 and letting her use
1 more than she has (at no cost).
45
Shadow price vs slack variable
  • maximize z -3x1 2x2
  • subject to -3x1 3x2 x3
    6
  • -4x1 2x2
    x4 2
  • x1,
    x2, x3, x4 ? 0

Claim increasing the 6 to a 7 is mathematically
equivalent to replacing x3 ? 0 with x3 ?
-1. This is also the reduced cost for variable
x3.
Reason 2. Any solution to the original problem
can be transformed to a solution with RHS 7 by
subtracting 1 from x3. x1 0, x2 1, x3 3,
x4 0 ? x1 0, x2 1, x3 2, x4 0
46
Shadow price vs slack variable
Looking at the slack variable in the final
tableau reveals shadow prices.
x1 1x2 3x3 0x4 0 z 3
x1
x2
x4
x3
-z
1
0
-1
0
-2
0
0
-1/2
-1/3
1
-3

x1 4/3x2 11/3x3 -1x4 0 z 10/3
3
0
1
-3/2
3
1
0
1/3
-1/2
0
1

-2
1
0
1/2
1
0
1
2/3
-1/2
0
3
What is the optimal solution if x3 ? 0?
What is the optimal solution if x3 ? -1?
1/3
What is the shadow price for constraint 1?
47
Quick Summary
  • Connection between shadow prices and reduced
    cost. If xj is the slack variable for a
    constraint, then its reduced cost is the negative
    of the shadow price for the constraint.
  • The reduced cost for a variable is its cost
    coefficient in the final tableau
  • To do with your partner what is the shadow
    price for the 2nd constraint (widgets on hand)?
Write a Comment
User Comments (0)
About PowerShow.com