Chapter 1 Example 1.1 The Apex Television Company has to decide on the number of 27- and 20-inch sets to be produced at one of its factories. Market research indicates that at most 40 of the 27-inch sets and 10 of the 20-inch sets can be sold per month. The maximum number of work-hours available is 500 per month. A 27-inch set requires 20 work-hours and a 20-inch set requires 10 work-hours. Each 27-inch set sold produces a profit of $120 and each 20-inch set produces a profit of $80. A wholesaler has agreed to purchase all the television sets produced if the numbers do not exceed the maxima indicated by the market research. (a) Formulate a linear programming model for this problem. The decisions that need to be made are the number of 27-inch and 20-inch TV sets to be produced per month by the Apex Television Company. Therefore, the decision variables for the model are x1 = number of 27-inch TV sets to be produced per month, x2 = number of 20-inch TV sets to be produced per month. Also let Z = total profit per month. The model now can be formulated in terms of these variables as follows. The total profit per month is Z = 120 x1 + 80 x2. The resource constraints are: (1) Number of 27-inch sets sold per month: x1 40 (2) Number of 20-inch sets sold per month: x2 10 (3) Work-hours availability: 20 x1 + 10 x2 500. Nonnegativity constraints on TV sets produced: x1 0, x2 0 With the objective of maximizing the total profit per month, the LP model for this problem is Maximize Z = 120 x1 + 80 x2 subject to x1 40 x2 10 20 x1 + 10 x2 500 and x1 0, x2 0 (b) Use the graphical method to solve this model. Example 1.2 Dwight is an elementary school teacher who also raises pigs for supplemental income. He is trying to decide what to feed his pigs. He is considering using a combination of pig feeds available from local suppliers. He would like to feed the pigs at minimum cost while also making sure each pig receives an adequate supply of calories and vitamins. The cost, calorie content, and vitamin content of each feed are given in the table below. Contents Calories (per pound) Vitamins (per pound) Cost (per pound) Feed Type A 800 140 units $0.40 Feed Type B 1,000 70 units $0.80 Each pig requires at least 8,000 calories per day and at least 700 units of vitamins. A further constraint is that no more than one-third of the diet (by weight) can consist of Feed Type A, since it contains an ingredient which is toxic if consumed in too large a quantity. (a) Formulate a linear programming model for this problem. Let A and B be the quantity (pounds) of Feed Type A and Feed Type B, respectively, used per day. Also let Z be the total daily cost of the feed per pig. Then, the daily cost is Z = $0.4 A + $0.8 B. The constraints on the minimum daily requirements of calories and vitamins are (1) Calories requirement: 800 A + 1000 B 8,000. (2) Vitamins requirement: 140 A + 70 B 700. Also, Dwight needs to avoid using too much of Feed Type A because of the toxic ingredient in it. The toxic constraint is A 1/3 (A+B), which reduces to 2/3 A - 1/ 3B≤0. Nonnegativity constraints: A 0, B 0. The resulting linear programming model for this problem is Minimize Z = 0.4 A + $0.8 B, subject to 800 A + 1000 B 8000 140 A + 70 B 700 2/3 A - 1/3 B 0 and A 0, B 0. (b) Use the graphical method to solve this model. What is the resulting daily cost per pig? As shown below, the optimal solution is (A, B) = (20/7, 40/7). The resulting daily cost per pig is Z = 40/7 = $5.71. Example 1.3 A furniture store has set aside 800 square feet to display its sofas and chairs. Each sofa utilizes 50 sq. ft. and each chair utilizes 30 sq. ft. At least five sofas and at least five chairs are to be displayed. a. Write a mathematical model representing the store's constraints. b. Suppose the profit on sofas is $200 and on chairs is $100. On a given day, the probability that a displayed sofa will be sold is .03 and that a displayed chair will be sold is .05. Mathematically model each of the following objectives: 1. Maximize the total pieces of furniture displayed. 2. Maximize the total expected number of daily sales. 3. Maximize the total expected daily profit. Solution: Let s and c be the number of sofa and chair respectively. a. 50s + 30c < 800 s> 5 c> 5 b. (1) Max s + c (2) Max 0.03s + 0.05c (3) Max 6s + 5c Example 1.4 Maxwell Manufacturing makes two models of felt tip marking pens. Requirements for each lot of pens are given below. Plastic Ink Assembly Molding Time Fliptop Model Tiptop Model 3 4 5 4 5 2 Available 36 40 30 The profit for either model is $1000 per lot. a. What is the linear programming model for this problem? b. Find the optimal solution. c. Will there be excess capacity in any resource? Solution: a. Let F = the number of lots of Fliptip pens to produce Let T = the number of lots of Tiptop pens to produce Max 1000F + 1000T s.t. 3F + 4T < 36 5F + 4T < 40 5F + 2T < 30 F,T > 0 b. T 15 10 5 F 0 0 5 10 15 The complete optimal solution is:F = 2, T = 7.5, Z = 9500 c.There is an excess of 5 units of molding time available. Chapter 2 Example 2.1 Consider the following linear programming model. Maximize Z = 3x1 + 2 x2, subject to x1 ≤4 x1 + 3x2 ≤15 2x1 + x2 ≤10 and x1 ≥0,x2 ≥0. (a) Use graphical analysis to identify all the corner-point solutions for this model. Label each as either feasible or infeasible. The graph showing all the constraint boundary lines and the corner-point solutions at their intersections is shown below. The exact value of (x1, x2) for each of these corner-point solutions (A, B, ..., I) can be identified by obtaining the simultaneous solution of the corresponding two constraint boundary equations. The results are summarized as... Corner-point solutions A B C D E F G H I (x1, x2) (0, 5) (0,10) (3, 4) (4, 11/3) (4, 2) (4, 0) (5, 0) (15, 0) (0, 0) Feasibility Feasible Infeasible Feasible Infeasible Feasible Feasible Infeasible Infeasible Feasible (b) Calculate the value of the objective function for each of the CPF solutions. Use this information to identify an optimal solution. The objective value of each corner-point feasible solution is calculated in the following table: Corner-point feasible solutions A C E F I (x1, x2) Objective Value Z (0, 5) (3, 4) (4, 2) (4, 0) (0, 0) 3*0+2*5 = 10 3*3+2*4 = 17 3*4+2*2 = 16 3*4+2*0 = 12 3*0+0*0 = 0 Since point C has the largest value of Z, (x1, x2) = (3, 4) must be an optimal solution. (c) Use the simplex method to get the solution and to identify which sequence of CPF solutions would be examined by the simplex method to reach an optimal solution. Therefore, the sequence of CPF solutions examined by the simplex method would be I → F→ E→ C. Example 2.2 Consider the following linear programming model. Maximize Z = x1 + 2x2, subject to 6x1 - 2x2 ≤ 3 2x1 + 3x2 ≤ 6 x1 + x2 ≤ 3 and x1 ≥0,x2 ≥0. (a) Use graphical analysis to identify all the corner-point solutions for this model. Label each as either feasible or infeasible. (b) Calculate the value of the objective function for each of the CPF solutions. Use this information to identify an optimal solution. (c) Use the simplex method to get the solution and to identify which sequence of CPF solutions would be examined by the simplex method to reach an optimal solution. Solution: (a) x1 + x2 = 3 3 6x1- 2x2 = 3 2 x1 + 2x2 =0 Feasible Region 1 2x1 + 3x2 = 6 0 x1 0 1 2 (a) corner-point feasibility (0, 0) feasible (0.5, 0) feasible (21/22, 15/11) feasible (0, 2) feasible (c) 1st tableau (b) obj. value 0 0.5 3.68 4 1 x1 6 2 1 0 1 2 x2 -2 3 1 0 2 0 0 0 sl1 sl2 sl3 bi i - 1 0 0 3 0 1 0 6 2 0 0 1 3 3 0 0 0 ∑icBibi= 0 0 0 0 1 x1 2 x2 0 0 0 sl1 sl2 sl3 bi 1 cB1= 0 xB1= sl1 22/3 0 1 2/3 0 7 2 cB2= 2 xB2= x2 3 cB3= 0 xB3= sl3 fj 2/3 1/3 4/3 1 0 2 -1/3 0 0 1/3 0 2 0 -1/3 1 1 0 2/3 0 ∑icBibi= 4 0 -2/3 0 i 1 2 3 Max Cj cB xB cB1= 0 xB1= sl1 cB2= 0 xB2= sl2 cB3= 0 xB3= sl3 fj Cj-fj 3 2nd tableau (final) i Max cB Cj xB Cj-fj Corner point (0, 0) → Corner point (0, 2) i Chapter 3 Example 3.1 The Fagersta Steelworks currently is working two mines to obtain its iron ore. This iron ore is shipped to either of two storage facilities. When needed, it then is shipped ont ot h ec ompa ny ’ ss t e e lp l a nt .Thedi a gr a m be l owde p i c t st h i sdi s t r i bu t i o nne t wor k, where M1 and M2 are the two mines, S1 and S2 are the two storage facilities, and P is the steel plant. The diagram also shows the monthly amounts produced at the mines and needed at the plant, as well as the shipping cost and the maximum amount that can be shipped per month through each shipping lane. $2,000/ton 30 tons max. 40 tons produced M1 S1 $400/ton 70 tons max. $1,700/ton 30 tons max. P $1,600/ton 50 tons max. 60 tons M2 produced $1,100/ton 50 tons max. S2 100 tons needed $800/ton 70 tons max. Management now wants to determine the most economic plan for shipping the iron ore from the mines through the distribution network to the steel plant. (a) Formulate a linear programming model for this problem. The decision variables are defined as follows: xm1-s1 : number of units (tons) shipped from Mine 1 to Storage Facility 1, xm1-s2 : number of units (tons) shipped from Mine 1 to Storage Facility 2, xm2-s1 : number of units (tons) shipped from Mine 2 to Storage Facility 1, xm2-s2 : number of units (tons) shipped from Mine 2 to Storage Facility 2, xs1 -p : number of units (tons) shipped from Storage Facility 1 to the Plant, xs2 -p : number of units (tons) shipped from Storage Facility 2 to the Plant. The total shipping cost is: Z = 2000 xm1-s1 + 1700 xm1-s2 + 1600 xm2-s1 + 1100 xm2-s2 + 400 xs1-p + 800 xs2-p The constraints we need to consider are: (1) Supply constraint on M1 and M2: xm1-s1 + xm1-s2 = 40 xm2-s1 + xm2-s2 = 60 (2) Conservation-of-flow constraint on S1 and S2: xm1-s1 + xm2-s1 - xs1-p = 0 xm1-s2 + xm2-s2 - xs2-p = 0 (3) Demand constraint on P: xs1-p + xs2-p = 100 (4) Capacity constraints: xm1-s1 30, xm1-s2 30 xm2-s1 50, xm2-s2 50 xs1-p 70, xs2-p 70 (5) Nonnegativity constraints: xm1-s1 0, xm1-s2 0 xm2-s1 0, xm2-s2 0 xs1-p 0, xs2-p 0 The resulting linear programming model for this problem is: Maximize Z = 2000 xm1-s1 + 1700 xm1-s2 + 1600 xm2-s1 + 1100 xm2-s2 + 400 xs1-p + 800 xs2-p, subject to xm1-s1 + xm1-s2 = 40 xm2-s1 + xm2-s2 = 60 xm1-s1 + xm2-s1 - xs1-p = 0 xm1-s2 + xm2-s2 - xs2-p = 0 xs1-p + xs2-p = 100 xm1-s1 30, xm1-s2 30 xm2-s1 50, xm2-s2 50 xs1-p 70, xs2-p 70 and xm1-s1 0, xm1-s2 0, xm2-s1 0, xm2-s2 0, xs1-p 0, xs2-p 0 Example 3.2 Minimize f = -1x1 + 2x2 - 3x3 subject to x1 + x2 + x3 = 6 -1x1 + x2 + 2x3 = 4 2x2 + 3x3 = 10 x3 2 and x1, x2, x3 0 Find the optimal solution by big M and two phase methods. Solution: The first tableau of big M method: Min i 1 2 3 Cj -1 cB xB x1 cB1= M xB1=a1 1 cB2= M xB2=a2 -1 cB3= M xB3=a3 0 4 cB4= 0 xB3=s1 fj Cj-fj 2 x2 1 1 2 -3 x3 1 2 3 M a1 1 0 0 M M a2 a3 0 0 1 0 0 1 0 s1 0 0 0 bi 6 4 10 0 0 1 0 0 0 1 2 0 4M 6M M M M 0 0 0 0 -1 2-4M -3-6M 0 i ∑icBibi= 20M+2 The first tableau of Phase I in two phase method: Min C’ j 0 0 0 1 1 1 0 xB x1 x2 x3 a1 a2 a3 s1 bi i 1 1 1 1 0 0 0 6 6 2 cB2= 1 xB2=a2 -1 1 2 0 1 0 0 4 2 3 cB3= 1 xB3=a3 0 2 3 0 0 1 0 10 10/3 4 cB4= 0 xB3=s1 0 0 1 0 0 0 1 2 2 f ’ j 0 4 6 1 1 1 0 ∑icBibi= 20 C’ ’ j-f j 0 -4 -6 0 0 0 0 i cB 1 cB1= 1 xB1=a1 The final tableau of Phase I in two phase method: Min C’ j 0 0 0 1 1 1 0 xB x1 x2 x3 a1 a2 a3 s1 bi 1 cB1= 0 xB1=x1 1 0 0 1/2 -1/2 0 1/2 2 2 cB2= 0 xB2=x2 0 1 0 1/2 1/2 0 -3/2 2 3 cB3= 1 xB3=a3 0 0 0 -1 -1 1 0 0 4 cB4= 0 xB3=x3 0 0 1 0 0 0 1 2 f ’ j 0 0 0 -1 -1 1 0 ∑icBibi= 0 C’ ’ j-f j 0 0 0 2 2 0 0 i cB **extra constraint The first & also final tableau of Phase II in two phase method: Min Cj -1 2 -3 0 xB x1 x2 x3 s1 bi 1 cB1= -1 xB1=x1 1 0 0 1/2 2 2 cB2= 2 xB2=x2 0 1 0 -3/2 2 4 cB4= -3 xB3=x3 0 0 1 1 2 fj -1 2 -3 -7/2 Cj-fj 0 0 0 7/2 i cB i ∑icBibi= -4 i Example 3.3 A&C Distributors is a company that represents many outdoor products companies and schedules deliveries to discount stores, garden centers, and hardware stores. Currently, scheduling needs to be done for two lawn sprinklers, the Water Wave and Spring Shower models. Requirements for shipment to a warehouse for a national chain of garden centers are shown below. Month Shipping Capacity March 8000 April 7000 May 6000 Product Water Wave Spring Shower Water Wave Spring Shower Water Wave Spring Shower Requirement 3000 1800 4000 4000 5000 2000 Unit Cost to Ship .30 .25 .40 .30 .50 .35 Per Unit Inventory Cost .06 .05 .09 .06 .12 .07 Let Sij be the number of units of sprinkler i shipped in month j, where i = 1 or 2, and j = 1, 2, or 3. Let Wij be the number of sprinklers that are at the warehouse at the end of a month, in excess of the requirement. (a.) Write the portion of the objective function that minimizes shipping costs. (b.) An inventory cost is assessed against this ending inventory. Give the portion of the objective function that represents inventory cost. (c.) There will be three constraints that guarantee, for each month, that the total number of sprinklers shipped will not exceed the shipping capacity. Write these three constraints. (d.) There are six constraints that work with inventory and the number of units shipped, making sure that enough sprinklers are shipped to meet the requirements. Write these six constraints. Solutions (a.) Min 0.3S11 + 0.25S21 + 0.40S12 + 0.30S22 + 0.50S13 + 0.35S23 (b.) Min 0.06W11 +0.05W21 +0.09W12 +0.06W22 +0.12W13 +0.07W23 (c.) S11 + S21 8000 S12 + S22 7000 S13 + S23 6000 (d.) S11 - W11 = 3000 S21 - W21 = 1800 W11 + S12 - W12 = 4000 W21 + S22 - W22 = 4000 W12 + S13 - W13 = 5000 W22 + S23 - W23 = 2000 Example 3.4 (a.) Find the optimal solution of (a.) in Example 3.3 by the big-M method. (b.) Find the optimal solution of (b.) in Example 3.3 by the two phases method. (寫到 Phase II 的 1st tableau 就可以。) Solution for (a.) Min 0.3S11 + 0.25S21 + 0.40S12 + 0.30S22 + 0.50S13 + 0.35S23 S11 + S21 8000 S12 + S22 7000 S13 + S23 6000 S11 - W11 = 3000 S21 - W21 = 1800 W11 + S12 - W12 = 4000 W21 + S22 - W22 = 4000 W12 + S13 - W13 = 5000 W22 + S23 - W23 = 2000 S11,~, S23, W11,~, W23 0 S11 + S21 +s1 = 8000 S12 + S22 + s2 = 7000 S13 + S23 + s3 = 6000 S11 - W11 + a1 = 3000 S21 - W21 + a2= 1800 W11 + S12 - W12 + a3= 4000 W21 + S22 - W22 + a4 = 4000 W12 + S13 - W13 + a5 = 5000 W22 + S23 - W23 + a6 = 2000 S11,~, S23, W11,~, W23, s1,~, s3, a1,~, a6 0 (a) Simplex 1st tableau i Min Cj 0.3 0.4 0.5 0.25 0.3 0.35 0 0 0 0 0 0 0 0 0 M M M M M M cB xB S11 S12 S13 S21 S22 S23 W11 W12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0 0 0 0 1 2000 -0.25 fj M M M 0.25 0.25 0.25 0 0 -M 0 0 0 0 0 M 0.25 M 0.25 M 0.25 Cj-fj 0.3 0.4 0.5 0 0.05 0.05 0 -M -M -M 0 0 0.25 0 0 0 0 +M 0 +M 0 +M M 0 -0.25 -0.25 -0.25 Simplex 5th tableau i Min Cj 0.3 0.4 0.5 0.25 0.3 0.35 0 0 0 0 0 0 0 0 0 M M M M M M cB xB S11 S12 S13 S21 S22 S23 W11 W12 W13 W21 W22 W23 s1 s2 s3 a1 a2 a3 a4 a5 a6 bi i 1 cB1=0.3 xB1=S11 1 0 0 0 -1 -1 0 0 0 0 0 1 1 0 0 0 -1 0 -1 0 -1 200 2 cB2=0 xB2=s2 0 1 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 7000 7000 3 cB3=0 xB3=s3 0 0 1 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 6000 4 cB4=M xB3=a1 0 0 0 0 1 1 -1 0 0 0 0 -1 -1 0 0 1 1 0 1 0 1 2800 2800 5 cB5=0.25 xB3=S21 0 0 0 1 1 1 0 0 0 0 0 -1 0 0 0 0 1 0 1 0 1 7800 7800 6 cB6=M xB3=a3 0 1 0 0 0 0 1 -1 0 0 0 0 0 0 0 0 0 1 0 0 0 4000 7 cB7=0 xB3=W21 0 0 0 0 1 1 0 0 0 1 0 -1 0 0 0 0 0 0 1 0 1 6000 6000 8 cB8=M xB3=a5 0 0 1 0 0 0 0 1 -1 0 0 0 0 0 0 0 0 0 0 1 0 5000 - 9 cB9=0 xB3=W22 0 0 0 0 0 1 0 0 0 0 1 -1 0 0 0 0 0 0 0 0 1 2000 - 0 M +M M +M M +M 0 0 0.05 0 0.05 0 0.05 fj Cj-fj -0.05 -0.05 0.3 M M 0.25 +M +M 0 0.35 0.4 0.4 0.5 0 0 0 -M -M -M -M 0 -M 0 0 M 0 -0.05 0.3 0 -M 0 -M 0.05 -0.3 0 0 +M +M -0.05 -0.05 -0.05 - - - Simplex 6th tableau i Min Cj 0.3 0.4 0.5 0.25 0.3 0.35 0 0 0 0 0 0 0 0 0 M M M M M M cB xB S11 S12 S13 S21 S22 S23 W11 W12 W13 W21 W22 W23 s1 s2 s3 a1 a2 a3 a4 a5 a6 bi i 1 cB1=0.3 xB1=S11 1 0 0 0 0 0 -1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 3000 2 cB2=0 xB2=s2 0 1 0 0 0 -1 1 0 0 0 0 1 1 1 0 -1 -1 0 0 0 -1 4200 4200 3 cB3=0 xB3=s3 0 0 1 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 6000 - 4 cB4=0.3 xB3=S22 0 0 0 0 1 1 -1 0 0 0 0 -1 -1 0 0 1 1 0 1 0 1 2800 - 5 cB5=0.25 xB3=S21 0 0 0 1 0 0 1 0 0 0 0 0 1 0 0 -1 0 0 0 0 0 5000 5000 6 cB6=M xB3=a3 0 1 0 0 0 0 1 -1 0 0 0 0 0 0 0 0 0 1 0 0 0 4000 4000 7 cB7=0 xB3=W21 0 0 0 0 0 0 1 0 0 1 0 0 1 0 0 -1 -1 0 0 0 0 3200 3200 8 cB8=M xB3=a5 0 0 1 0 0 0 0 1 -1 0 0 0 0 0 0 0 0 0 0 1 0 5000 - 9 cB9=0 xB3=W22 0 0 0 0 0 1 0 0 0 0 1 -1 0 0 0 0 0 0 0 0 1 2000 - fj Cj-fj -0.35 0.3 M M 0.25 0.3 0.3 +M 0 -M 0 0.35 0.4 0.5 0 0 0 0.05 0 M 0 -M -M -M 0 -0.3 -0.05 0 0 0.35 0.3 M 0.3 M 0.3 0 0.3 0.05 0 0 0 -0.3 +M 0 -0.3 +M 0 -0.3 +M - Simplex 7th tableau i Min Cj 0.3 0.4 0.5 0.25 0.3 0.35 0 0 0 0 0 0 0 0 0 M M M M M M cB xB S11 S12 S13 S21 S22 S23 W11 W12 W13 W21 W22 W23 s1 s2 s3 a1 a2 a3 a4 a5 a6 bi i 1 cB1=0.3 xB1=S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Cj-fj 0.3 0.4 0.5 0.25 0.3 0.35 0 0 0 0 0 0 0 0 0 -M 0 -0.05 0.45 -M -0.45 -0.35 0 0.3 0.4 0 -M -M -0.3 -0.4 M 0.05 +M 0.35 0 +M +M -1 bi -0.05 M +M M 0.3 M 0.35 0 0.05 0 -0.3 +M -0.35 0 +M Optimal cost: 0.3*6200 + 0.25*1800 + 0.40*3000 + 0.30*4000 + 0.50*2800 + 0.35*2000 = 6810 Solution for (b) Phase I : 1st tableau (由於考慮 Wij 所以 pivoting 以 Wij 優先) i Min Cj cB xB 0 0 0 0 0 0 0 0 1 S11 S12 S13 S21 S22 S23 W11 W12 W13 W21 W22 W23 s1 s2 s3 0 0 0 0 0 0 0 1 1 1 1 1 a1 a2 a3 a4 a5 a6 bi i 1 cB1=0 xB1=s1 1 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 8000 8000 2 cB2=0 xB2=s2 0 1 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 7000 - 3 cB3=0 xB3=s3 0 0 1 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 6000 - 4 cB4=1 xB3=a1 1 0 0 0 0 0 -1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 3000 3000 5 cB5=1 xB3=a2 0 0 0 1 0 0 0 0 0 -1 0 0 0 0 0 0 1 0 0 0 0 1800 - 6 cB6=1 xB3=a3 0 1 0 0 0 0 1 -1 0 0 0 0 0 0 0 0 0 1 0 0 0 4000 - 7 cB7=1 xB3=a4 0 0 0 0 1 0 0 0 0 1 -1 0 0 0 0 0 0 0 1 0 0 4000 - 8 cB8=1 xB3=a5 0 0 1 0 0 0 0 1 -1 0 0 0 0 0 0 0 0 0 0 1 0 5000 - 9 cB9=1 xB3=a6 0 0 0 0 0 1 0 0 0 0 1 -1 0 0 0 0 0 0 0 0 1 2000 - 1 1 1 1 1 1 0 0 -1 0 0 -1 0 0 0 1 1 1 1 1 1 -1 -1 -1 -1 -1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 0 0 0 0 0 0 1 2000 - fj 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 Cj-fj 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 (b.) Min 0.06W11 +0.05W21 +0.09W12 +0.06W22 +0.12W13 +0.07W23 Phase II : 1st tableau i Min Cj cB xB 0 0 0 0 0 0.06 0.09 0.12 0.05 0.06 0.07 0 0 0 S11 S12 S13 S21 S22 S23 W11 W12 W13 W21 W22 W23 s1 s2 s3 bi 0 1 cB1=0.09 xB1=W12 0 0 0 0 0 0 0 1 0 0 1 0 1 1 0 2200 2 cB2=0.05 xB2=W21 0 0 0 0 0 0 1 0 0 1 0 0 1 0 0 3200 3 cB3=0 xB3=s3 0 0 0 0 0 0 0 0 1 0 0 1 -1 1 1 2800 4 cB4=0 xB3=S11 1 0 0 0 0 0 -1 0 0 0 0 0 0 0 0 3000 5 cB5=0 xB3=S21 0 0 0 1 0 0 1 0 0 0 0 0 1 0 0 5000 6 cB6=0 xB3=S13 0 0 1 0 0 0 0 0 -1 0 -1 0 -1 -1 0 2800 7 cB7=0 xB3=S22 0 0 0 0 1 0 -1 0 0 0 -1 0 -1 0 0 800 8 cB8=0 xB3=S12 0 1 0 0 0 0 1 0 0 0 1 0 1 1 0 6200 9 cB9=0 xB3=S23 0 0 0 0 0 1 0 0 0 0 1 -1 0 0 0 2000 fj 0 0 0 0 0 0 0.05 0.09 Cj-fj 0 0 0 0 0 0 0.01 0 0 0.12 0.05 0.09 0 0 0.14 0.09 0 -0.03 0.07 -0.14 -0.09 0 i Chapter 4 Example 4.1 Consider the following primal linear programming model. Minimize f = 6x1 + 8x2 subject to 3x1 + x2 ≤ 4 5x1 + 2x2 ≤10 x1 + 2x2 = 3 and x1, x2 ≥0 Find its dual linear programming model. Solution: Change into canonical form: -3x1 - x2 -4 -5x1 - 2x2 -10 x1 + 2x2 3 -x1 - 2x2 -3 and x1, x2 ≥0 Thus, 4 10 6 , c , and A = b 3 8 3 3 1 5 2 , i.e., AT = 1 2 1 2 So, the dual form is: Maximize g = -4y1-10y2+3y3-3y4 -3y1-5y2+ y3- y4 ≤6 - y1-2y2+2y3-2y4 ≤8 y1, y2, y3, y4 ≥0 3 5 1 1 1 2 2 2 Example 4.2 Consider the the following linear programming model: Min f = 2x1 + 4x2 Subject to x1 + 5x2 80 4x1 + 2x2 6 x1 + x2 = 3 x1, x2 0 (a) Rewrite the linear programming model into its canonical form. (b) Change into its dual form. Solution for (a) Min f = 2x1 + 4x2 Subject to - x1 - 5x2 -80 4x1 + 2x2 6 -x1 - x2 -3 x1 + x2 3 x1, x2 0 Solution for (b) Max f ’= 80y1 -6y2+ 3y3 -3y4 y1 -4y2 + y3 -y4 2 5y1 -2y2 + y3 -y4 4 y1, y2, y3, y4 0 Chapter 5 Example 5.1 Consider the following primal linear programming model. Maximize f = 4x1 - x2 + x3 subject to 2x1 + x2 + x3 ≤6 -2x1 + 2x2 ≤4 and x1, x2, x3 ≥0 The following is its simplex final tableau. Cj 4 i cB xB x1 1 cB1=4 xB1=x1 1 2 cB2=0 xB2=s2 0 fj 4 Cj-fj 0 -1 1 0 0 x2 x3 s1 s2 bi 0.5 0.5 0.5 0 3 3 1 1 1 10 2 2 2 0 ∑icBibi=12 -3 -1 -2 0 Find the adjustable range of the follows such that the basic variables in the optimal solution can keep invariant. (1) The coefficient’ s range of non-basic variable x2 in objective function. (2) The coefficient’ s range of basic variable x1 in objective function. (3) The range of b1. Solutions: 1 0 0 (1) Cj 4 c2 i cB xB x1 x2 x3 s1 s2 bi 1 cB1=4 xB1=x1 1 0.5 0.5 0.5 0 3 2 cB2=0 xB2=s2 0 3 1 1 1 10 fj 4 2 2 2 0 ∑icBibi=12 Cj-fj 0 c2 - 2 -1 -2 0 Let c2 be the coefficient of x2 in the objective function, then the following inequality c2 –2 ≤0 c2 ≤2 must be hold to keep x2 staying outside of the basic variables. This also implies that if the unit profit of x2 is greater than $2, the optimality should be changed. (2) Cj i cB xB 1 cB1=c1 xB1=x1 2 cB2=0 xB2=s2 fj Cj-fj -1 1 0 x1 x2 x3 s1 1 0.5 0.5 0.5 0 3 1 1 c1 0.5c1 0.5c1 0.5c1 0 -1-0.5c1 1-0.5c1 -0.5c1 c1 0 s2 bi 0 3 1 10 0 ∑icBibi=12 0 Let c1 be the coefficient of x1 in the objective function, then the following inequalities must be hold to keep the basic variables unchanged. -1-0.5c1 ≤0 1+0.5c1 0 c1 -2 1-0.5c1 ≤0 c1 2 -0.5c1 ≤0 c1 0 The concluding result is c1 2. If the unit profit of x1 is smaller than $2, x1 should leave from basic variables, and x3 will get into as a basic variable. (3) i cB Cj xB 4 x1 -1 x2 1 x3 0 s1 0 s2 bi 1 cB1=4 xB1=x1 1 0.5 0.5 0.5 0 3 2 cB2=0 xB2=s2 0 3 1 1 1 fj 4 2 2 2 0 ∑icBibi=12 Cj-fj 0 -3 -1 -2 0 10 Observe that NxN + BxB = b B-1NxN + B-1BxB = B-1b xB = B-1b - B-1NxN -1 Since xN = 0 and xB 0, so we conclude that xB = B b 0, thus the range of b1 is, 0.5 0 b1 0 1 14 0.5b10 and b1 + 4 0 b1 -4, the result is: b10. 0 Example 5.2 Maximize f = 9 x1+12 x2 subject to 3x1+2x2 40 2x1+3x2 30 2x1+ x2 250 and x1, x2 0 The following table is the final table of the above model. Max Cj 9 12 i cB x B x 1 x 2 0 s1 0 s2 0 s3 bi 1 9 x1 1 0 3/5 -2/5 0 12 2 12 x2 0 1 -2/5 3/5 0 2 3 0 s3 0 0 -4/5 5/9 1 224 fj 9 12 3/5 18/5 0 0 -3/5 -18/5 0 Cj-fj 0 132 i Under the concern of keeping the basic variables invariant, do the following exercises (a) Find the allowable range of coefficient’ s values (say, c1 and c2) for x1 and x2. (b) Find the allowable range of resource amount (say, b1 and b2) for 1st and 2nd resources. (c) Find the marginal values of 1st and 2nd resources. Solution: (a) -0.6c1+4.8 0;0.4c1-7.2 0 c1 8;c1 18 8 c1 18 -5.4+0.4c2 0;0.4-0.6c2 0 c2 1.35;c2 ⅔ ⅔ c2 1.35 (b) 0.6 0.4 0 b1 0.6b1 12 30 0.4b 18 0 0.4 0.6 0 1 5 0.8 0.8b1 266.67 1 250 9 0.6b1-12 0;-0.4b1+18 0;-0.8b1+266.67 0 b1 20;b1 45;b1 333.34 20 b1 45 0.6 0.4 0 24 0.4b2 40 b 16 0.6b 0 0 . 4 0 . 6 0 2 2 b 5 0.8 5 9 1 250 218 2 9 24-0.4b2 0;16+0.6b2 0;218+0.8b2 0 b2 60;b2 -26.67;b2 -272.5 -26.67 b2 60 (c) Let y1, y2 and y3 be the marginal values of 1st, 2nd and 3rd resources, then the dual form of the original model is as follows: Min Min g = 40 y1+30 y2+250 y3 g = 40 y1+30 y2+250 y3+Ma1+Ma2 subject to subject to 3y1+2y2+2y3-s1+a1 = 9 3y1+2y2+2y3 9 2y1+3y2+ y3 12 2y1+3y2+ y3-s2+a2 = 12 y1, y2, y2 0 y1, y2, y2 s1, s2, a1, a2 0 Min Cj i cB x B 40 y1 30 y2 250 y3 0 s1 0 s2 M a1 M a2 bi i 1 M a1 3 2 2 -1 0 1 0 9 3 2 M a2 2 3 1 0 -1 0 1 12 4 3M -M -M M M M M 0 0 fj Cj-fj 5M 5M 40-5M 30-5M 250-3M Min Cj i cB x B 40 y1 30 y2 250 y3 0 s1 0 s2 M a1 M a2 bi i 1 40 y1 1 2/3 2/3 -1/3 0 1/3 0 3 4.5 2 M a2 0 5/3 -1/3 2/3 -1 -2/3 1 6 3.6 fj 40 -40/3 +2M/3 40/32M/3 M 40/3 2M/3 -40/3 +2M/3 M 0 80/3 M/3 670/3 +M/3 -M Cj-fj 80/3+ 5M/3 10/35M/3 Min Cj i cB x B 40 y1 30 y2 250 y3 0 s1 0 s2 M a1 M a2 bi i 1 40 y1 1 0 0.4 -0.6 0.4 7/15 -0.4 0.6 2 30 y2 0 1 -0.2 0.4 -0.6 -0.2 0.6 3.6 fj 40 30 10 -12 -18 略 略 Cj-fj 0 0 240 12 略 略 Marginal value of Resource 1 is 0.6. Marginal value of Resource 2 is 3.6. 18 0 Chapter 6 Example 6.1 某電子公司,主要訂單來自 A、B、C 三市,而該公司在這三市都設有倉庫。公司 的三座工廠與倉庫不在同一地方,分別設於 I、J、K 三地。由於市場不景氣,業務 嚴重萎縮,如下表所示: 工廠 每年最大產能(千個) 倉庫 每倉庫預估來年之需求量(千個) I J K 210 140 290 A B C 80 200 200 各廠與倉庫間的運輸成本及其生產成本如下表: 倉庫 工廠 I J K A B C 生產成本 2 4 3 4 3 6 4 4 4 11 14 12 公司目前的流通策略如下:所有 A 市倉庫的需求由 I 廠供應,所有 J 廠的產品都運 到 B 市倉庫,而 B 市倉庫不足的需求量都由 I 廠供應,C 市的需求量則完全由 K 廠 供應。試評估針對來年需求,採用現行策略的成本。以 VAM 法改善公司此一策 略。 Solution: (1)、試評估針對來年需求,採用現行策略的成本。解釋公司為何採用此一策略? 令成本=運輸成本+生產成本 倉庫 工廠 I J K Request A B 13 80 18 15 80 15 60 17 140 18 200 C D(slack) Supply 15 0 70 18 0 16 200 0 200 90 160 Total cost=13×80+15×60+17×140+16×200=7420(千元)。 210 140 290 640 Apply company strategy: penalty 1 4 15 233 1 165 0 penalty 倉庫 工廠 A B C D(slack) 13 2 I 17 1 J 15 2 1 K Supply 13 10 18 15 200 17 15 0 18 15 70 18 16 200 0 140 0 20 290 270 70 200 140 20 640 Request 80 70 200 210 10 140 Total cost=13×10+15×200+15×70+16×200=7380(千元)。 Example 6.2 下表所示為三處倉庫與四位顧客間的供需關係表。陰影部份是各相關之運輸成本。 顧客 倉庫 戒 定 慧 需求量 阿 彌 陀 佛 7 10 6 8 12 10 11 5 11 10 4 9 20 28 17 33 庫存量 98 30 45 35 110 以 VAM 法求出其可行解,並計算該解之總運算成本。 Solution: penalty 顧客 penalty 倉庫 7 戒 4 定 6 慧 Request 1 2 6 5 阿 彌 陀 佛 D(slack) 庫存量 7 8 11 10 0 10 12 5 4 0 6 10 11 9 0 20 28 17 33 0 12 30 45 35 110 penalty 顧客 penalty 倉庫 17 戒 14 定 36 慧 Request penalty 顧客 penalty 倉庫 1 戒 61 定 3 慧 Request penalty 顧客 penalty 倉庫 1 戒 6 定 3 慧 Request 0 1 2 6 5 阿 彌 陀 佛 D(slack) 庫存量 12 7 8 11 10 0 10 12 5 4 0 6 10 11 9 0 30 18 45 35 20 28 17 33 12 0 1 2 6 5 0 阿 彌 陀 佛 D(slack) 庫存量 12 7 8 10 6 10 0 12 11 17 5 4 0 10 11 9 0 110 18 45 28 35 20 28 17 0 33 0 1 2 6 51 0 阿 彌 陀 佛 D(slack) 庫存量 110 12 7 8 10 6 20 10 28 4 0 12 11 17 5 10 11 9 0 28 0 33 5 0 0 18 28 0 35 110 1 2 6 1 阿 彌 陀 佛 D(slack) 庫存量 penalty 顧客 penalty 倉庫 12 戒 6 定 31 慧 12 7 8 10 20 6 Request 20 0 penalty 顧客 penalty 倉庫 2 戒 6 定 1 慧 Request penalty 顧客 penalty 倉庫 2 戒 6 定 1 慧 Request 0 10 28 4 0 12 11 17 5 10 11 9 0 28 0 5 18 0 0 35 15 0 110 1 2 6 1 0 阿 彌 陀 佛 D(slack) 庫存量 12 18 7 8 10 28 4 0 12 11 17 5 10 20 6 10 11 9 0 0 0 28 10 0 5 0 1 - 6 - 0 阿 彌 陀 10 20 6 12 10 10 0 10 0 11 17 5 11 0 15 110 12 8 0 佛 D(slack) 庫存量 18 7 18 0 10 28 4 5 9 50 0 0 0 0 0 0 15 0 110 Final penalty 顧客 penalty 倉庫 戒 定 慧 Request 阿 彌 陀 佛 D(slack) 庫存量 12 18 7 8 10 20 6 12 10 10 20 28 11 17 5 11 17 10 28 4 5 9 33 30 0 45 0 35 0 12 110 總運送成本: 20×6+18×8+10×10+17×5+28×4+5×9 = 606。