7 lp sensitivity analysis
TRANSCRIPT
-
7/29/2019 7 LP Sensitivity Analysis
1/9
1
Linear Programming: Sensitivity Analysis
Learning Outcomes
Students should be able to:
Investigate the effect of changing the objective function coefficient on theoptimal solution.
Investigate the effect of changing a right-hand-side (RHS) value anddetermine shadow prices from an optimal tableau.
using both graphical and computer analysis.
Sensitivity Analysis
In LP, the parameters (input data) of the model can be changed within certain limitswithout causing the optimum solution to change. Making changes in the parameters
to see the effect on optimal solution is known as sensitivity analysis, or post-optimality analysis.
The general idea of sensitivity analysis will be performed on 2 cases.I. Sensitivity of the optimum solution to changes in the availability of resources
(the right-hand-side of the constraint)
II. Sensitivity of the optimum solution to changes in unit profits or unit cost(coefficients of the objective function)
I. Changes in the Right-Hand-Side
Example: Consider the Wyndor Glass problem
Maximize Z = 3X1 + 5X2subject to:
X1 4 (Plant 1 hours)2X2 12 (Plant 2 hours)
3X1 + 2X2 18 (Plant 3 hours)X1, X2 0
where` X1 = batches of doors to produce per week,
X2 = batches of windows to produce per week.
The graphical solution will be used to explain the basis for sensitivity analysis.
ECS716 OPERATIONAL RESEARCH
PN PAEZAH HAMZAH
-
7/29/2019 7 LP Sensitivity Analysis
2/9
2
The graphical solution is as follows:
If Plant 3 capacity is increased by 1 hour, then the RHS of the thirdconstraint changes from 18 to 19 hours. Accordingly, the feasible region becomesslightly bigger and the optimal solution will change accordingly.
Maximize Z = 3X1 + 5X2 (profit, $000)subject to:
X1 4 (Plant 1 hours)2X2 12 (Plant 2 hours)
3X1 + 2X2 19 (Plant 3 hours)
X1, X2 0
.
Corner Point Feasible (CPF) solution
CPF solution Z=3X1+5X2
(0,0) 0(0,6) 30(2,6) 36
(4,3) 27(4,0) 12
Optimal solution: X1=2, X2=6Produce 2 batches of doors and 6batches of windows per week
Maximum Profit=3(2)+5(6)=$36 thousand
6
4 6X1
X2
9
2X212
X14
3X1 +2X218
Feasible
region
(2, 6)
4 3
0
Zmax
6
4 6X1
X2
9
2X212
X14
3X1 +2X218
Feasible
region
(2.33, 6)
4 3
0
Zmax
Increase theRHS of Plant3 constraint
by 1 hour
Corner Point Feasible (CPF) solution
CPF solution Z=3X1+5X2(0,0) 0(0,6) 30
(2.33,6) 37
(4,3) 27(4,0) 12
Optimal solution: X1=2.33, X2=6
Maximum Profit=3(2.33)+5(6)=$37 thousand
3X1 +2X219
-
7/29/2019 7 LP Sensitivity Analysis
3/9
3
Effect of Changing RHS on the Objective Function Value
Increasing the RHS value of the second constraint by 1 unit, or equivalently, making1 additional production hour in Plant 3 available (at no additional cost), causes thetotal profit to increase by $1,000 from $36,000 to $37,000. The $1,000 increase isalso known as the shadow price or the dual price for Plant 3 production capacity.The shadow price can be used as a guideline for Wyndor Glass Inc. in determining
the amount of money to spend to increase its capacity. If the production time atPlant 3 were to be increased, the maximum amount of money to spend is $1,000 perhour.
In general, a shadow price is
the worth of 1 additional unit of a scarce resource.
the marginal value of 1 additional unit of a scarce resource.
the maximum amount to pay for 1 additional unit of a scarce resource.
How to determine the shadow price from a simplex solution?
The shadow prices for all the resources can be obtained from the optimal simplextableau. These are the numbers in the Zj row or the absolute value of the Cj-Zj of
the slack variable columns.
CjBasic
X1 X2 S1 S2 S3RHS3 5 0 0 0
0 S1 0 0 1 1/3 -1/3 25 X2 0 1 0 0.5 0 63 X1 1 0 0 -1/3 1/3 2
Zj 3 5 0 1.5 1 36Cj-Zj 0 0 0 -1.5 -1
The shadow price of Plant 1 production time =$0/hrThe shadow price of Plant 2 production time =$1,500 /hrThe shadow price of Plant 3 production time =$1,000 /hr
Question 1: What is meant by $0 shadow price? Why does Plant 1 have $0/hrshadow price?
The shadow price of $0 means that it is worth nothing to pay money foradditional resource.
The shadow price of Plant 1 production is $0/hr because the hours in thisplant are still available
Question 2: If Wyndor Glass can increase the capacity of the plants, which plantshould receive higher priority?
Plant 2, since the dual price is the highest.(Each additional hour of Plant 1 production time will not increase theweekly profit, each additional hour of Plant 2 and Plant 3 productiontime will increase the weekly profit by $1,500 and $1,000,respectively.)
The
shadow
price isthe valueof 1additiona
l unit of ascarce
resource
-
7/29/2019 7 LP Sensitivity Analysis
4/9
4
Question 3: Is it worthwhile to increase the capacities of Plant 2 and 3 at theadditional cost of $1,200/hr in each plant?
Plant 2: Yes, since the shadow price for production time is worth$1,500.
Plant 3: No, since the shadow price for production time in Plant 3 isworth $1,000.
Determination of Range of FeasibilityThere is a limit on the RHS change in order for the dual values to remain valid. Thevalid range is termed the range of feasibility.
Example:
Consider the optimal simpex tableau for Wyndor Glass Co.
Cj BasicX
1X
2S
1S
2S
3
RHS3 5 0 0 00 S1 0 0 1 1/3 -1/3 25 X2 0 1 0 0.5 0 63 X1 1 0 0 -1/3 1/3 2
Zj 3 5 0 1.5 1 36Cj-Zj 0 0 0 -1.5 -1
Determine the range of feasibility for Plant 2.
-
7/29/2019 7 LP Sensitivity Analysis
5/9
5
II. Changes in the Objective Function Coefficients
Making a change in the coefficient of the objective function (unit profit or unitcost ) will change the slope of Z.
Use QM for Windows software to investigate the effect of changing objective
coefficients.
Example: Change the unit profit of doors to $4,000 per batch.
qs
Maximize Z = 4X1 + 5X2 (profit, $000)subject to:
X1 4 (Plant 1 hours)2X2 12 (Plant 2 hours)3X1 + 2X2 18 (Plant 3 hours)
X1, X2 0
Corner Point Feasible (CPF) solution
X1 X2 Z=4X1+5X2
0 0 0
0 6 30
2 6 38
4 3 31
4 0 16
Optimal solution: X1=2, X2=6Produce 2 batches of doors and 6batches of windows per week
Maximum Profit=4 2 +5 6 = 38 thousand
Change theunit profit of
each batch ofdoor to$4 000
6
4 6X1
X2
9
2X212
X14
3X1 +2X218
Feasible
region
(2, 6)
4 3
0
Zmax
6
4 6X1
X2
9
2X212
X14
3X1 +2X218
Feasibleregion
(2, 6)
4 3
0
Zmax
-
7/29/2019 7 LP Sensitivity Analysis
6/9
6
Range of Optimality
If the change in an objective function coefficient is within a specific range of values,called the range of optimality, the current basic feasible solution will remainoptimal. However, current optimal solution will remain optimal for certain changes inthe values only.
a) The range of optimality for a basic variable: determines the values of objective function coefficient for which the basic
variables will remain in the current basic feasible solution.Note: the value of the variables may change.
b) The range of optimality for a non-basic variable: determines the objective function coefficient values for which variables will
remain non-basic
Example:
Consider the optimal simpex tableau for Wyndor Glass Co.
Cj Basic X1 X2 S1 S2 S3 RHSC1 5 0 0 0
0 S1 0 0 1 1/3 -1/3 25 X2 0 1 0 0.5 0 6C1 X1 1 0 0 -1/3 1/3 2
Zj 36Cj-Zj
i) Determine the range of optimality for X1ii) Determine the range of optimality for S2
-
7/29/2019 7 LP Sensitivity Analysis
7/9
7
QM for Windows Output for Wyndor Glass Co
Ranging----------
Variable Value Reduced Original Lower UpperCost Val Bound Bound
X1 1. 0 3. 0. 7.5X2 6. 0 5. 2. Infinity
Dual Slack/ Original Lower UpperConstraint Value Surplus Val Bound BoundConstraint 1 0 3 4 2. InfinityConstraint 2 1.5 0 12 6. 18.Constraint 3 1 0 18 12. 24.
Supplementary Exercises
1. a) Explain the meaning of shadow price. Describe how a firm would use theshadow price associated with a given constraint.
b) The operations department of a large company makes three products (A, B,and C). The department is preparing for its final run next week, which is justbefore the annual two-week vacation during which the entire departmentshuts down. The manager wants to use up existing stocks of the three rawmaterials used to fabricate products A, B, and C. She has formulated thelinear programming model and obtained an optimal solution given below.
A= quantity of product AB= quantity of product BC= quantity of product C
Max Z = 12A + 15B + 14C (Profit, RM)subject to
Material 1 3A +5B + 8C 720 kilogramsMaterial 2 2A + 3C 600 kilogramsMaterial 3 4A +6B + 4C 640 kilograms
A, B, and C 0
-
7/29/2019 7 LP Sensitivity Analysis
8/9
8
The optimal simplex tableau and ranging are as follows:
Based on the solution given, answer the following questions:
i) If Bs profit per unit could be increased to RM18, how much would B beproduced?
ii) What is the range of optimality of C?
iii) What is the range of feasibility for Material 3?
iv) By how much would profit increase if an additional 100 kilograms of Material 3could be obtained?
v) If the manager can obtain additional 20 kilograms of Material1 and Material3,what would be the effect to the optimal solution and the total profit?
A B C s1 s2 s3RHSBasis CB 12 15 14 0 0 0
C 14 0 0.1 1 0.2 0 -0.15 48S2 0 0 -3.1 0 -0.2 1 -0.35 232A 12 1 1.4 0 -0.2 0 0.4 112
Zj 12 18.2 14 0.4 0 2.7 2016
Cj - Zj 0 -3.2 0 -0.4 0 -2.7
Variable Value Reduced Cost OriginalValue
LowerBound
Upper Bound
A 112 0 12 9.71 14B 0 3.2 15 -infinity 18.2C 48 0 14 --- ---
Constraint Dual Value Slack/Surplus OriginalValue
LowerBound
Upper Bound
Constraint 1 0.4 0 720 480 1280Constraint 2 1.25 232 600 368 InfinityConstraint 3 2.7 0 640 360 960
-
7/29/2019 7 LP Sensitivity Analysis
9/9
9
2.Consider the following profit maximization linear programming problem. X1, X2,and X3 are the units of easy cupcakes, chocolate cupcakes, and vanilla cupcakesto be produced by Diana Bakery.
Maximize Z= 1.0X1 +1.2X2 + 1.4X3 (Ringgit)
Subject to
Multipurpose flour: 2.25X1 + 2X2 + 2.5X3 1,000 cupsSugar : 1.5X1 + 2X2 + 2X3 900 cupsMilk : X1 + 0.75X2 + X3 800 cups
X1, X2, X3 0
The incomplete final simplex tableau for the above problem is shown below. S1, S2,and S3 are the slack variables for multipurpose flour, sugar, and milk, respectively.
Cj 1.0 1.2 1.4 0 0 0
Basis X1 X2 X3 S1 S2 S3 RHS
X3 1.5 0 1 2 -2 0 200
X2 -0.75 1 0 -2 2.5 0 250
S3 0.0625 0 0 -0.5 0.125 1 412.5
Zj
Cj-Zj
a) Complete the above simplex tableau.
b) What are the optimal production quantities? What is the maximum total profit?
c) Which ingredient is not fully utilized? How much is used in the optimalproduction?
d) If the objective function coefficient for X2 is changed to 1.5, will the optimalsolution change? Justify your answer.
e) State the dual price for the multipurpose flour. For what values is this dualprice valid?
g) Diana just realized that there were 120 more cups of multipurpose flouravailable on hand to be used in making the cupcakes. What would be effect onthe total profit if these were used in the production?