Download presentation
Presentation is loading. Please wait.
1
4.7 Alternate Optimal Solutions
If an LP has more than one optimal solution, it has multiple optimal solutions (多重最佳解) or alternative optimal solutions(擇一最佳解). If there is no NBV with a zero coefficient in row 0 of the optimal tableau, the LP has a unique optimal solution. Even if there is a NBV with a zero coefficient in row 0 of the optimal tableau, it is possible that the LP may not have alternative optimal solutions.
2
Example: p.152 Dakota Furniture Company (p.140)
max z = 60x1 + 35x2 + 20x3 s.t. 8x1+ 6x x3 ≤ (lumber constraint) 4x1+ 2x x3 ≤ (finishing constraint) 2x1+1.5x x3 ≤ (carpentry constraint) x ≤ (table demand constraint) x1, x2, x3 ≥ 0
3
max z = 60x1 + 35x2 + 20x3 s.t. 8x1+ 6x x3 ≤ 48 4x1+ 2x x3 ≤ 20 2x1+1.5x x3 ≤ 8 x ≤ 5 x1, x2, x3 ≥ 0 z - 60x1 - 35x2 - 20x3 = 0 8x1+ 6x x3 + s1 = 48 4x1+ 2x x3 + s2 = 20 2x1+1.5x x3 + s3 = 8 x s4 = 5 x1, x2, x3 , s1, s2, s3, s4 ≥ 0 Table 13 BV z x1 x2 x3 s1 s2 s3 s4 RHS Ratio 1 -60 -35 -20 8 6 48 4 2 1.5 20 0.5 5
4
Table 13 BV z x1 x2 x3 s1 s2 s3 s4 RHS Ratio 1 -60 -35 -20 8 6 48 4 2 1.5 20 5 0.5 LV - EV Table 14 BV z x1 x2 x3 s1 s2 s3 s4 RHS Ratio 1 10 -5 30 240 -1 -4 16 - 0.5 -2 4 8 LV 0.75 0.25 5 EV
5
Table 15 BV z x1 x2 x3 s1 s2 s3 s4 RHS 1 10 280 z=280 -2 2 -8 24 s1=24 -4 8 x3=8 1.25 -0.5 1.5 x1=2 5 s4=5 Table 16 BV z x1 x2 x3 s1 s2 s3 s4 RHS 1 10 280 z=280 1.6 1.2 -5.6 27.2 s1=27.2 -1.6 11.2 x3=11.2 0.8 -0.4 x2=1.6 -0.8 0.4 -1.2 3.4 s4=3.4
6
Any point on the line segment joining two optimal extreme points will also be optimal.
7
Exercise:p.154 #1~#4 Show that if a toy soldier sold for $28, then the Giapetto problem would have alternative optimal solutions. 2. Show that the following LP has alternative optimal solutions; find three of them. max z = -3x1 + 6x2 s.t. 5x1 + 7x2 ≤ 35 -x1 + 2x2 ≤ 2 x1, x2 ≥ 0 3. Find alternative optimal solutions to the following LP: max z = x1 + x2 s.t. x1 + x2 + x3 ≤ 1 x1 +2x3 ≤ 1 x1, x2, x3 ≥ 0 4. Find all optimal solutions to the following LP: max z = 3x1 + 3x2 s.t. x1 + x2 ≤ 1
8
p.154 4.8 Unbounded LPs For some LPs, there exist points in the feasible region for which z assumes arbitrarily large (in max problems) or arbitrarily small (in min problems) values. The LP is unbounded solution(無限解). An unbounded LP occurs in a max problem if there is a NBV with a negative coefficient in row 0 and there is no constraint that limits how large we can make this NBV. Specifically, an unbounded LP for a max problem occurs when a variable with a negative coefficient in row 0 has a non positive coefficient in each constraint.
9
Example 3. Breadco Bakeries
x1=number of loaves of French bread baked x2=number of loaves of sourdough bread baked x3=number of yeast packets purchased x4=number of ounces of flour purchased Objective function: Revenue = 36x1+30x2, Costs = 3x3 + 4x4 z = Revenue – Costs = 36x1 + 30x2 -3x3 - 4x4 Constraints: x1 +x2 ≤ 5 + x x1 +x2 - x3 ≤ 5 6x1 + 5x2 ≤ 10 + x 6x1 + 5x2 -x4 ≤ 10 Max z = 36x1 + 30x2 -3x3 - 4x4 s.t. x1 + x2 - x3 ≤ x1 + 5x2 -x4 ≤ 10 x1, x2 , x3 , x4 ≥0
10
max z = 36x1 + 30x2 – 3x3 – 4x4 s.t x x2 – x ≤ 5 6x x –x4 ≤ 10 x1, x2, x3, x4 ≥ 0 max z = 36x1 + 30x2 – 3x3 – 4x4 s.t x1 + x2 – x s1 =5 6x1 + 5x –x4 + s2 =10 x1, x2, x3, x4 , s1, s2 ≥ 0 Table 19 BV z x1 x2 x3 x4 s1 s2 RHS Ratio 1 -36 -30 3 4 z=0 -1 5 s1=5 6 10 s2=10 5/3
11
Table 19 BV z x1 x2 x3 x4 s1 s2 RHS Ratio 1 -36 -30 3 4 -1 5 6 10 10/6 LV EV Table 20 BV z x1 x2 x3 x4 s1 s2 RHS Ratio 1 3 -2 6 60 1/6 -1 -1/6 10/3 20 LV 5/6 5/3 - EV Table 21 BV z x1 x2 x3 x4 s1 s2 RHS Ratio 1 2 -9 12 4 100 -6 6 -1 20 - -3 5
12
Exercise:p.158 #1~#5 1. Show that the following LP is unbounded:
max z = 2x2 s.t. x1 - x2 ≤ 4 -x1 + x2 ≤ 1 x1,x2 ≥ 0 Find a point in the feasible region with z ≥ 10,000. 2. State a rule that can be used to determine if a min problem has an unbounded optimal solution (that is, z can be made arbitrarily small). Use the rule to show that max z = -2x1 - 3x2 s.t. x1 - x2 ≤ 1 x1 - 2x2 ≤ 2 is an unbounded LP.
13
3. Suppose that in solving an LP, we obtain the tableau in Table 22
3. Suppose that in solving an LP, we obtain the tableau in Table 22. Although x1 can enter the basis, this LP is unbounded. Why? 4. Show that the following LP is unbounded max z = x1 + 2x2 s.t. -x1 + x2 ≤ 2 -2x1 + x2 ≤ 1 x1,x2 ≥ 0 5. Show that the following LP is unbounded max z = -x1 - 3x2 s.t. x1 - 2x2 ≤ 4 -x1 + x2 ≤ 3 z x1 x2 x3 x4 RHS 1 -3 -2 -1 3 2 4
14
4.11 Degeneracy and Convergence of the Simplex Algorithm
Theoretically, the simplex algorithm can fail to find an optimal solution to an LP. The following are facts: If (value of entering variable in new bfs) > 0, then (z-value for new bfs) > (z-value for current bfs) If (value of entering variable in new bfs) = 0, then (z-value for new bfs) = (z-value for current bfs)
15
p.169 Assume that in each of the LP’s bfs all BV are positive. An LP is a nondegenerate (非退化) LP. An LP is degenerate(退化) if it has at least one bfs where a BV is equal 0. Any bfs that has at least one BV equal to zero is a degenerate bfs(退化基本可行解). When the same bfs is encountered twice it is called cycling(循環). If cycling occurs, then we will loop, or cycle, forever among a set of basic feasible solutions and never get to an optimal solution.
16
Example:Degenerate LP
max z = 5x1 + 2x2 s.t x1 + x2 ≤ 6 x1 – x2 ≤ 0 x1, x2 ≥ 0 max z = 5x1 + 2x2 s.t x1 + x2 + s1 = 6 x1 – x2 + s2 = 0 x1, x2 , s1, s2 ≥ 0 Table 29 BV z x1 x2 s1 s2 RHS 1 -5 -2 6 -1
17
Table 29 BV z x1 x2 s1 s2 RHS Ratio 1 -5 -2 6 -1 LV EV Table 30 BV z x1 x2 s1 s2 RHS Ratio 1 -7 5 2 -1 6 6/2 LV - EV Table 31 BV z x1 x2 s1 s2 RHS Ratio 1 3.5 1.5 21 0.5 -0.5 3
18
There are 3 sets of BVs that correspond to 1 extreme pt.
Fig. 12 (p.171) There are 3 sets of BVs that correspond to 1 extreme pt. Table 32 BV BFS Extreme point x1 , x2 x1 = 3, x2 = 3, s1 = s2 = 0 D x1 , s1 x1 = 0, s1 = 6, x2 = s2 = 0 C x1 , s2 x1 = 6, s2 =-6, x2 = s1 = 0 Infeasible x2 , s1 x2 = 0, s1 = 6, x1 = s2 = 0 x2 , s2 x2 = 6, s2 = 6, x1 = s1 = 0 B s1 , s2 s1 = 6, s2 = 0, x1 = x2 = 0
19
If an LP has many degenerate BFS (or many BV equal zero), then the simplex algorithm is often inefficient. Some degenerate LPs have a special structure that enables us to solve them by methods other than the simplex. (chapter 7)
20
Exercise:Degenerate LP
max z = 7x1 + 8x2 s.t x1 + 2x2 ≤ 10 3x1 + 2 x2 ≤ 18 x2 ≤ 5 x1, x2 ≥ 0 max z = 7x1 + 8x2 s.t x1 + 2x2 + s1 = 10 3x1 + 2x2 + s2 = 18 2x2 + s3 = 5 x1, x2 , s1, s2 ,s3≥ 0 BV z x1 x2 s1 s2 s3 RHS Ratio 1 -7 -8 2 10 5 3 18 9
21
BV z x1 x2 s1 s2 s3 RHS Ratio 1 -7 -8 2 10 5 3 18 9 BV z x1 x2 s1 s2 s3 RHS Ratio 1 -7 8 40 -2 3 8/3 5 - BV z x1 x2 s1 s2 s3 RHS Ratio 1 7 -6 40 -2 - -3 4 8 2 5
22
BV z x1 x2 s1 s2 s3 RHS Ratio 1 7 -6 40 -2 - -3 4 8 2 5 BV z x1 x2 s1 s2 s3 RHS Ratio 1 5/2 3/2 52 -1/2 1/2 4 -3/4 1/4 8 3/4 -1/4 3
23
Exercise:p.170 #1~#2 1. Even if an LP’s initial tableau is nondegenerate, later tableaus may exhibit degeneracy. Degenerate tableaus often occur in the tableau following a tie in the ration test. To illustrate this, solve the following LP: max z = 5x1 + 3x2 s.t. 4x1 + 2x2≤ 12 4x1 + x2≤ 10 x1 + x2≤ 4 x1, x2 ≥ 0 Also graph the feasible region and show which extreme points correspond to more than one set of basic variables. 2. Find the optimal solution to the following LP: max z = –x1 – x2 s.t. x1 + x2 ≤ 1 –x1 + x2 ≤ 0 x1, x2 ≥ 0
24
Summery (1) 1.進入變數平手 指2個NBV具有相同且最負的z列係數。 任意選一個為進入變數(無有效方法) 。
2.離開變數平手---退化解 有2個以上相同之最小比率。 未被選擇離開之BV,其值為0,該BV 即degenerate BV,含degenerate BV之bfs即是degenerate bfs。 理論上,退化bfs易產生cycle,使得z值不變,即 bfs1bfs2bfs3 bfs1 而無法求得最佳解。(有書專門討論此類問題)
25
實務上,遇到此情況,代表該LP之模式有誤。 (若z代表利潤,則z不可能∞) 4.最佳單形表含z列係數為0之NBV ---多重最佳解
3.無離開變數---無窮解 進入變數之欄無正值,使得無離開變數。 實務上,遇到此情況,代表該LP之模式有誤。 (若z代表利潤,則z不可能∞) 4.最佳單形表含z列係數為0之NBV ---多重最佳解 有任何NBV之z列係數為0 若讓為0之NBV為進入變數,則下一個z值不會改變,但BFS將由不同之BV組成。 亦即不同之解,卻有相同之目標函數值。
26
LP的各種變形與解法 Standard Form Min: Method 1 (Z=-Z) or Method 2 變形1 變形2
AX ≥ B (1)Big –M Method (2)Two Phase Method 變形3 Unrestricted-in-sign (urs) variable: Let xi=xi’-xi” xi’, xi” ≥ 0
27
Artificial Variables (人工變數)
為使simplex method 得以繼續沿用,以人工變數 對「≥」之「 =」之限制式進行轉換。 處裡人工變數之方法有二: Big M method (大M法) Two-phase Simplex method (雙階法) 目的在盡量使人工變數為0, 使得到之人工問題最佳解即為原問題之最佳解。
28
p.172 4.12 The Big M Method(大M法) The simplex method requires a starting bfs. Previous problems have found starting bfs by using the slack variables as BV. If an LP have ≥ or = constraints, however, a starting bfs may not be readily apparent. In such a case, the Big M method may be used to solve the problem.
29
Description of the Big M Method
Modify the constraints so that the rhs of each constraint is nonnegative. Identify each constraint that is now an = or ≥ constraint. Convert each inequality constraint to standard form (add a slack variable for ≤ constraints, add an excess variable for ≥ constraints). For each ≥ or = constraint, add artificial variables. Add sign restriction ai ≥ 0. Let M denote a very large positive number. Add (for each artificial variable) Mai to min problem objective functions or -Mai to max problem objective functions Since each artificial variable will be in the starting basis, all artificial variables must be eliminated from row 0 before beginning the simplex. Remembering M represents a very large number, solve the transformed problem by the simplex.
30
p.172 Example 4: Bevco Bevco manufactures an orange-flavored soft drink called Oranj by combining orange soda and orange juice. Each orange soda contains 0.5 oz of sugar and 1 mg of vitamin C. Each ounce of orange juice contains 0.25 oz of sugar and 3 mg of vitamin C. It costs Bevco 2¢ to produce an ounce of orange soda and 3¢ to produce an ounce of orange juice. Bevco’s marketing department has decided that each 10-oz bottle of Oranj must contain at least 30 mg of vitamin C and at most 4 oz of sugar. Use LP to determine how Bevco can meet the marketing department’s requirements at min cost.
31
Example 4: Solution Step 1
x1 = number of ounces of orange soda in a bottle of Oranj x2 = number of ounces of orange juice in a bottle of Oranj The LP is: min z = 2x1 + 3x2 s.t. 0.5x x2 ≤ 4 (sugar constraint) x x2 ≥ 20 (Vitamin C constraint) x x2 = 10 (10 oz in 1 bottle of Oranj) x1, x2 ≥ 0
32
Step 2 The LP in standard form has z and s1 which could be used for BVs but row 2 would violate sign restrictions and row 3 no readily apparent BV. In order to use the simplex method, a bfs is needed. Artificial variables (人工變數) are created. Row 0: z - 2x x = 0 Row 1: x x2 + s = 4 Row 2: x x e2 = 20 Row 3: x x = 10
33
Step 3 Row 0: z - 2x1 - 3x2 = 0 Row 1: 0.5x1 + 0.25x2 + s1 = 4
Row 2: x x e2 + a2 = 20 Row 3: x x a3 = 10 In the optimal solution, all artificial variables must be set equal to zero. For a min LP, a term Mai is added to the objective function for each artificial variable ai. For a max LP, the term –Mai is added to the objective function for each ai. M represents some very large number.
34
Step 4 The modified Bevco LP in standard form then becomes:
Modifying the objective function this way makes it extremely costly for an artificial variable to be positive. The optimal solution should force a2 = a3 =0. Row 0: z - 2x x Ma2 - Ma3 = 0 Row 1: x x2 + s = 4 Row 2: x x e a = 20 Row 3: x x a3 = 10
35
Step 5 Because a2 and a3 are in starting BFS, they must be eliminated from row 0. Replace row0 by row0 +M(row2)+M(row3) Row 0: z - 2x x Ma2 - Ma3 = 0 Row 1: x x2 + s = 4 Row 2: x x e a = 20 Row 3: x x a3 = 10 Row 0’: z + (2M - 2)x1 + (4M - 3)x2 - Me2 = 30M
36
Table 33 BV z x1 x2 s1 e2 a2 a3 RHS Ratio 1 2M-2 4M-3 -M 30M 1/2 1/4 4 16 3 -1 20 20/3 LV 10 EV Table 34 BV z x1 x2 s1 e2 a2 a3 RHS Ratio 1 5/12 1/12 -1/12 7/3 28/5 1/3 -1/3 20/3 20 2/3 10/3 5 LV EV
37
The optimal solution for Bevco is z=25, x1 = x2 = 5, s1 = 1/4, e2 = 0.
Table 35 BV z x1 x2 s1 e2 a2 a3 RHS Ratio 1 -1/2 25 -1/8 1/8 -5/8 1/4 1/2 5 3/2 The optimal solution for Bevco is z=25, x1 = x2 = 5, s1 = 1/4, e2 = 0. This means that Bevco can hold the cost of producing a 10-oz. bottle of Oranj to $.25 by mixing 5 oz of orange soda and 5 oz of orange juice.
38
p.177 Example 4’: min z = 2x1 + 3x2 s.t. 0.5x x2 ≤ 4 (sugar constraint) x x2 ≥ 36 (Vitamin C constraint) x x2 = 10 (10 oz in 1 bottle of Oranj) x1, x2 ≥ 0 Row 0: z - 2x x Ma2 - Ma3 = 0 Row 1: x x2 + s = 4 Row 2: x x e a = 36 Row 3: x x a3 = 10 Row 0’: z + (2M - 2)x1 + (4M - 3)x2 - Me2 = 46M
39
Table 36 BV z x1 x2 s1 e2 a2 a3 RHS Ratio 1 2M-2 4M-3 -M 46M 1/2 1/4 4 16 3 -1 36 12 10 LV EV Table 37 BV z x1 x2 s1 e2 a2 a3 RHS 1 1-2M -M 3-4M 30+6M 1/4 -1/4 3/2 -2 -1 -3 6 -0 10
40
If all artificial variables equal zero in the optimal solution, the solution is optimal. (exercise 4) If any artificial variables are positive in the optimal solution, the solution is infeasible. Then the original LP has no feasible solution. (exercise 5) 由於M為一相當大的值,對電腦而言,易產生數值上的問題(極大數與極小數相加,後果?),因此商業軟體少用此法,而多使用Two-Phase method.
41
Exercise:p.178 #1~#6 1. min z = 4x1 + 4x2 + x3 s.t. x1 + x2 + x3 ≤ 2
min z = 4x1 + 4x2 + x3 + Ma3 s.t. x1 + x2 + x3 + s1 = 2 2x1 + x s2 = 3 2x1 + x2 + 3x3 ‑ e3 + a3 = 3 x1, x2, x3, s1, s2, e3, a3≥ 0
42
Eliminating the BV a3 from z ‑ 4x1 ‑ 4x2 ‑ x3 ‑ Ma3 = 0
min z = 4x1 + 4x2 + x3 + Ma3 s.t. x1 + x2 + x3 + s1 = 2 2x1 + x s2 = 3 2x1 + x2 + 3x3 ‑ e3 + a3 = ×(-M) x1 , x2 , x3 , s1, s2, e3, a3 ≥ 0 Eliminating the BV a3 from z ‑ 4x1 ‑ 4x2 ‑ x3 ‑ Ma3 = 0 z + (2M ‑ 4)x1 + (M ‑ 4)x2 + (3M ‑ 1)x3 ‑ Me3 = 3M. z x1 x2 x3 s1 s2 e3 a3 rhs 1 2M‑4 M‑4 3M‑ 1 ‑M 3M 2 3 -1
43
The optimal solution is
z x1 x2 x3 s1 s2 e3 a3 rhs r 1 2M‑4 M‑4 3M‑ 1 ‑M 3M 2 3 none -1 z x1 x2 x3 s1 s2 e3 a3 rhs 1 -10/3 -11/3 ‑1/3 1/3-M 1/3 2/3 2 3 -1/3 The optimal solution is z = 1, s1 = 1, s2 = 3, x3 = 1, x2 = x1 = e3 = 0.
44
2. min z = 2x1 + 3x2 s.t. 2x1 + x2 ≥ 4 x1 – x2 ≥ -1 x1,x2 ≥ 0 3. max z = 3x1 + x2 s.t. x1 + x2 ≥ x1 + x2 ≤ x1 + x2 = x1,x2 ≥ 0 4. min z = 3x1 s.t. 2x1 + x2 ≥ x1 + 2x2 = 4 x1,x2 ≥ 0 5. min z = x1 + x2 s.t. 2x1 + x2 + x3 = x1 + x2 + 2x3 = x1,x2,x3 ≥ 0 6. min z = x1 + x2 s.t. x1 + x2 = x1 + 2x2 = x1,x2 ≥ 0
45
4.13 Two-Phase Simplex Method
Phase I 之目標函數僅考慮人工變數。 (p.178) 無論Min or Max問題,最好之z值為0,故不可能為無窮解 讓所有原始變數為0即為一可行解,故不可能為無可行解 所以必有最佳解。 當得到最佳解時,若所有人工變數均為0,則至phase II; 若有任何人工變數不為0,則原問題無可行解。 Phase II中: 刪除全部人工變數,若人工變數仍為BV,則保留。 以phase I 之最佳解做為phase II之起始bfs,並回復原問題之目標函數係數
46
Phase I LP In this method, artificial variables are added to the same constraints, then a bfs to the original LP is found by solving Phase I LP. The objective function is to minimize the sum of all artificial variables. At completion, reintroduce the original LP’s objective function and determine the optimal solution to the original LP.
47
Phase II LP Because each ai ≥ 0, solving the Phase I LP will result in one of the following three cases: Case 1. The optimal value of w’ is greater than zero. The original LP has no feasible solution. Case 2. The optimal value of w’ is equal to zero, and no AVs are in the optimal Phase I basis. Drop all columns in the optimal Phase I tableau that correspond to the artificial variables. Now combine the original objective function with the constraints from the optimal Phase I tableau. Case 3. The optimal value of w’ is equal to zero and at least one AV is in the optimal Phase I basis.
48
Example 5:case 2 p.179 min z = 2x1 + 3x2 s.t. 0.5x1 + 0.25x2 ≤ 4
min w’ = a2 + a (w’ - a2- a3=0) ---- (1) s.t. 0.5x x2 + s1 = 4 x x2 – e2 + a2 = (2) x x2 + a3 = (3) x1, x2, s1, e2, a2, a3 > 0 (1) + (2) + (3) min w’ + 2x1 + 4x2 - e2 = 30
49
Table 38 BV w’ x1 x2 s1 e2 a2 a3 RHS Ratio 1 2 4 -1 30 1/2 1/4 16 3 20 20/3 LV 10 EV Table 39 BV w’ x1 x2 s1 e2 a2 a3 RHS Ratio 1 2/3 1/3 -4/3 3/10 5/12 1/12 - /12 7/3 28/5 -1/3 20/3 20 10/3 5 LV EV
50
The optimal solution is z=25, x1=5, x2=5, s1=1/4, e2=0
Table 40 BV w’ x1 x2 s1 e2 a2 a3 RHS 1 -1 -1/8 1/8 -5/8 1/4 -1/2 1/2 5 3/2 Drop all AVs. The optimal solution is z=25, x1=5, x2=5, s1=1/4, e2=0
51
Example 6:case 1 p.181 min z = 2x1 + 3x2 s.t. 0.5x1 + 0.25x2 ≤ 4
min w’ = a2 + a (w’ - a2- a3=0) ---- (1) s.t. 0.5x x2 + s1 = 4 x x2 – e2 + a2 = (2) x x2 + a3 = (3) x1, x2, s1, e2, a2, a3 > 0 (1) + (2) + (3) min w’ + 2x1 + 4x2 - e2 = 46
52
w’ =6 > 0, so the original LP has no feasible solution.
Table 41 BV w’ x1 x2 s1 e2 a2 a3 RHS Ratio 1 2 4 -1 46 1/2 1/4 16 3 36 12 10 LV EV Table 42 BV w’ x1 x2 s1 e2 a2 a3 RHS Ratio 1 -2 -1 -4 6 1/4 -1/4 3/2 -3 -0 10 w’ =6 > 0, so the original LP has no feasible solution.
53
Example 7:case 3 p.183 max z = 40x1 + 10x2 + 7x5 + 14x6
s.t. x1 - x2 +2x5 = 0 -2x1 + x2 - 2x5 = 0 x1 + x3 + x5 - x6 = 3 2x2 + x3 + x4 + 2x5 + x6 = 4 x1, x2, x3, x4, x5, x6 > 0 min w’-a1-a2-a3 = (1) s.t. x1 - x2 + 2x5 + a1 = (2) -2x1 + x2 - 2x5 + a2 = (3) x1 + x3 + x5 - x6 + a3 = (4) 2x2 + x3 + x4 + 2x5 + x6 = 4 x1, x2, x3, x4, x5, x6, a1, a2, a3 > 0 (1) + (2) + (3) + (4) min w’ +x3 + x5 - x6 = 3
54
Table 43 BV w’ x1 x2 x3 x4 x5 x6 a1 a2 a3 RHS R 1 -1 3 2 -2 LV 4 EV Table 44 BV w’ x1 x2 x3 x4 x5 x6 a1 a2 a3 RHS R 1 -1 2 -2 3
55
Table 44 BV w’ x1 x2 x3 x4 x5 x6 a1 a2 a3 RHS Ratio 1 -1 2 -2 3 Table 44’ drop x1 and a3 BV w’ x1 x2 x3 x4 x5 x6 a1 a2 a3 RHS Ratio 1 -1 2 -2 3
56
Table 44’ BV w’ x2 x3 x4 x5 x6 a1 a2 RHS 1 -1 2 -2 3 Table 45 BV z x2 x3 x4 x5 x6 a1 a2 RHS Ratio 1 -10 -7 -14 -1 2 -2 3
57
Table 45 BV z x2 x3 x4 x5 x6 a1 a2 RHS Ratio 1 -10 -7 -14 -1 2 -2 3 1/2 LV EV Table 46 BV z x2 x3 x4 x5 x6 a1 a2 RHS Ratio 1 4 7 2 1/2 3/2 7/2 The optimal solution is z=7, x3 =7/2, x6 =1/2, x2 = x4 = x5 =0
58
Exercise:p.184 #1~#2 Use the two-phase simplex method to solve the Section 4.12 problems. 2. Explain why the Phase I LP will usually have alternative optimal solutions.
59
4.14 Unrestricted-in-Sign Variables
p.184 4.14 Unrestricted-in-Sign Variables An LP with an unrestricted-in-sign (urs) variable can be transformed to non-negative. For each urs variable, define two new variables x’i and xni. Then substitute x’i - xni for xi in each constraint and in the objective function. Also add the sign restrictions. The effect of this substitution is to express xi as the difference of the two nonnegative variables x’i and xni. No basic feasible solution can have both x’i ≥ 0 and xni ≥ 0.
60
For any basic feasible solution, each URS variable xi must fall into one of the following three cases. x’i > 0 and xni = 0 x’i = 0 and xni > 0 x’i = xni = 0
61
Example 8: Using urs vars
x1 = number of loaves of bread baked x2 = number of ounces by which flour supply is increased by Let x2 = x’2 – x”2 Max z = 30x1 - 4x2 s.t. 5x1 ≤ 30 + x2 (Flour constraint) x1 ≤ (Yeast constraint) x1 ≥ 0 , x2 urs Max z = 30x1 - 4 x’2 – 4x”2 s.t. 5x1 ≤ 30 + x’2 – x”2 (Flour constraint) x1 ≤ (Yeast constraint) x1 ≥ 0 , x’2 , x”2 ≥ 0
62
Max z = 30x1 - 4 x’2 + 4x”2 s.t. 5x1 –x’2 + x”2 + s1 = 30 x1 + s1 = 5
x1 ≥ 0 , x’2 , x”2 ≥ 0 ,s1, s2 ≥ 0 Table 47 BV z x1 x ’2 x”2 s1 s2 RHS Ratio 1 -30 4 -4 5 -1 30 6 LV EV Table 48 BV z x1 x ’2 x”2 s1 s2 RHS Ratio 1 4 -4 30 150 -1 -5 5 LV none EV
63
The optimal solution is z= 170, x1= 5, x”2= 5, x2’= 0, s1= s2= 0.
Table 49 BV z x1 x ’2 x”2 s1 s2 RHS Ratio 1 4 10 170 -1 -5 5 The optimal solution is z= 170, x1= 5, x”2= 5, x2’= 0, s1= s2= 0. x2= x’- x”2 = -5 Because x2 = -5, the baker should sell 5 oz of flour.
64
其它形式 x ≧ 3 x’ = x – 3 x’ ≧0 x ≦ 6 x’ = 6 – x x’ ≧0 2 ≦ x ≦ 5
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.