Linear Programming Applications The Product Mix problem The product mix problem is always the first application that is learnt in Linear Programming. This problem is used to illustrate the LP problem in almost all text books. The problem is to find out how much to produce when there are resource constraints. Illustration 1.11______ Consider a manufacturing shop that can make four products (1 to 4). The products have to be processed on three machines (A to C). The unit processing time (in minutes) for product i on machine j is given in Table 1.11 Table 1.11 – Data for Illustration 1.11 A B C 1 15 15 10 2 12 12 10 3 10 9 12 4 5 6 10 The products A, B and C are sold for unit price of Rs 100, 86 and 75 and require raw material that cost Rs 60, 50 and 40 respectively. All the machines are available for 2400 minutes in a week. The market demand for the products is 50, 50 and 100 respectively. Find the optimum production quantities of the items. The given problem can be formulated as a Linear Programming problem. Let X1, X2 and X3 be the quantities of A, B and C produced. The unit gain (or profit) for the three products are 40, 30 and 35 respectively. The LP Maximize 40X1 + 36X2 + 35X3 Subject to 15X1 + 15X2 + 10X3 ≤ 2400 12X1 + 12X2 + 10X3 ≤ 2400 10X1 + 9X2 + 12X3 ≤ 2400 5X1 + 6X2 + 10X3 ≤ 2400 Xj ≥ 0 The objective function maximizes the total profit. The four constraints ensure that the time used on the machines is not more than the time available on the machines. The optimum solution to the LP is X1 = 60, X3 = 150 with profit = Rs 7650. We observe that the product with the maximum profit is A and if we choose to produce A only, we would have produced 160 of A with a profit of Rs 6400. The total profit of 7650 explains the role of the constraints in the LP problem. The above solution assumes that we can sell all the products made. This is not true and we have the market demands that have to be added as constraints to the LP. Three more constraints X1 ≤ 50, X2 ≤ 50 and X3 ≤ 100, representing the upper bounds or limits on the variables (quantities) are added to the LP resulting in seven constraints. The optimum solution now is given by X1 = 50, X2 = 43.33 and X3 = 100 with profit = Rs 7060. We also know that addition of constraints can only decrease the value of the objective function value in a maximization problem and we observe that the value has reduced. We have added the three constraints corresponding to the market demand. These are not actual constraints but are bounds on the values of the variables. We can use the Simplex algorithm for bounded variables to solve the LP with four constraints and three bounds. If we had sorted the products based on decreasing unit profit, we would have them chosen in the order A, B and C. Considering the demands, we would have produced 50 of A, 50 of B and 90 of C to get a total profit of Rs 6950. This once again shows the role of the constraints and the usefulness of the LP solution that provides the best or optimum solution. We also observe that the solution X1 = 50, X2 = 43.33 and X3 = 100 cannot be implemented because the variable X2 has a fractional value and we cannot make 43.33 units of a product. This has happened because we have solved an LP problem that assumes that variables can take continuous values. If we had wanted the production quantities to be integers, we should have defined the variables as integers. This would have resulted in an Integer Programming (IP) problem. The solution methods are different for IP problems compared to LP problems but if we are using an available solver, the difference lies only in the definition of the variable as continuous or integer. Assuming that we are still interested in using the LP solution to get integer values to the variables, the popular and easy way is to round off the continuous variables to integer values. Usually rounding off on the lower side gives a resultant feasible solution to the IP. In our example, we get the rounded solution X1 = 50, X2 = 43 and X3 = 100 with profit = 7048. If all constraints are ≤ type in a maximization problem and all RHS values are non negative, rounding off on the lower side results in a feasible solution to the IP with reduced cost. If we round off some variables to the upper integer value and some to the lower integer value, we can have some constraints violated by the rounded solution. We have to check for feasibility before we accept or evaluate a rounded solution. If we defined the production quantities as integers and solved an IP, the optimum solution is X1 = 50, X2 = 44 and X3 = 99 with profit = 7049. Rounded LP solutions that are feasible usually give answers very close to the IP optimum. Even though rounding off LP solutions to obtain integer feasible solutions is commonly practiced, it is not accepted in theory for multiple reasons. It is advisable to solve the IP optimally however difficult it could be. Of course, solving large IPs also takes considerable time and can become intractable. Production Planning problem The production planning problem is another commonly used problem to illustrate a minimization LP problem. Here the decisions are how much to produce using various ways of production such that the total cost is minimized. Illustration 1.1 2 Consider a company making a single product. The demand for the next four days is 60, 200, 160 and 100 units. The company employs 15 people and each person works for 8 hours daily. Each person makes one unit of the product/hour. The employees can work for 1 extra hour per day overtime. The costs of regular and over time production are Rs 80 and 120 per product. The company has to meet the daily demand but can produce more and store them for further use at Rs 4/unit/day. The company can get the product made outside and buy it at Rs 125/unit. If the company does not use an employee, it costs Rs 60/hour. Find the least cost production plan? The company uses a different kind of a costing system by which the cost of labour is separated from the cost of the products made. Cost of regular time labour is Rs 60/hour and cost of overtime labour is Rs 100/hour. The material cost is Rs 20/unit. The company starts with 15 people and can add or layoff people. The persons employed for the day have to be paid Rs 480/day whether they make products or not. Additional cost of hiring a person is Rs 200/person and cost of layoff is Rs 200/person. The cost of not utilizing the facility is Rs 40/hour. The company is also exploring the possibility of the staff working for a maximum of 2 hours overtime. Find the least cost plan under the new assumptions? Let X1 to X4 represent the quantities produced in regular working hours for the four days. Let Y1 to Y4 represent the quantities produced using overtime during the four days. Let P 1 to P4 be the quantities bought out and used for the four days. Let U1 to U4 be the regular time hours not utilized. Let I1 to I3 be the extra units made and stored for subsequent use at the end of the first three days. The formulation is to MInImIze 80X1+80X2+80X3+80X4+120Y1+120Y2+120Y3+120Y4+4I1+4I2+4I3+60U1+60U2+60U3+60 U4+125P1+125P2 +125P3+125P4 Subject to X1+Y1+P1-I1=60 I1+X2+Y2+P2-I2=200 I2+X3+Y3+P3-I3=160 I3+X4+Y4+P4=100 X1+U1=120 X2+U2=120 X3+U3=120 X4+U4=120 Y1≤15 Y2≤15 Y3≤15 Y4≤15 The objective function minimizes the total cost comprising of cost of regular time production, cost of overtime production, cost of holding the inventories, cost of underutilization and the cost of buying the products from outside. The first four constraints relate the variables to meeting the demand. Constraints 5 to 8 measure the quantities underutilized. Constraints 9 to 12 limit the overtime production. The optimum solution is given by X1 = X2 = X3 = 120, X4 = 100, Y1 = 5, Y2 = Y3 = 15, I1 = 65, U4 = 20, P3= 25 with Z = 45585. Considering the new costing system, we introduce additional variables W 1 to W4 represent the number of people working on the four days, H1 to H4 are the number of people hired and L1 to L4 are the number of people laid off. The new formulation is MInImIze 20X1+20X2+20X3+20X4+60Y1+60Y2+60Y3+60Y4+480W1 + 480W2 + 480W3 + 480W4 + 4I1 +4I2 +4I3 +40U1 +40U2+40U3+40U4+125P1+125P2+125P3+125P4 + 10S1 + 10S2 + 10S3 + 200H1 + 200H2 + 200H3 + 200H4 + 200L1 + 200L2 + 200L3 + 200L4 Subject to X1+Y1+P1-I1 + S1 =60 I1 –S1 +X2+Y2+P2-I2 +S2 =200 I2 – S2 +X3+Y3+P3-I3 +S3 =160 I3 – S3 +X4+Y4+P4 =100 X1+U1 -8W1 =0 X2+U2 -8W2 = 0 X3+U3 -8W3 =0 X4+U4 -8W4 =0 Y1≤2W1 Y2≤2W2 Y3≤2W3 Y4≤2W4 W1 –H1 +L1 = 15 W1+H2 –L2 –W2 = 0 W2+H3 –L3 –W3 = 0 W3+H4 –L4 –W4 = 0 The objective function minimizes the total cost comprising of cost of regular time production, cost of overtime production, cost of payroll to the employees, cost of holding the inventories, cost of underutilization, cost of buying the products from outside, cost of backorder (late deliveries), cost of hiring and cost of layoff . The first four constraints relate the variables (including the shortage) to meeting the demand. Constraints 5 to 8 measure the quantities underutilized and limits the regular time production to the workforce. Constraints 9 to 12 limit the overtime production to the workforce. We have assumed that the workforce can work for a maximum of 2 hours. Constraints 13 to 16 capture the changes in the workforce and relates the change to the number of people hired/laid off. The optimum solution is W1 = W2 = W3 = W4 = 13, X1 = X2 = X3 = X4 = 104, Y1= Y2 = Y3 = Y4 = 26, I1 = 70, S3 = 30 and L1 = 2 and Cost = 40500 The cost is less compared to the earlier solution. The solution recommends layoff of 2 people and utilizing them fully in regular and over time production. There is no outright purchase of the product to meet the demand. Building inventory and shortage is recommended. When the demands do not fluctuate very much, it is a good strategy to use regular time and over time production, build inventories and buy from outside only after the internal options are exhausted. The costs also increase as we consider regular time, overtime and outsourcing. If we consider that the overtime is restricted to one hour, the four constraints become Y1≤2W1, Y2≤2W2, Y3≤2W3, Y4≤2W4. Modifying these constraints and solving the LP problem, we get the optimum solution W1 = W2 = W3 = W4 = 14.44, X1 = X2 = X3 = X4 = 115.56, Y1= Y2 = Y3 = Y4 = 14.44, I1 = 70, S3 = 30 and L1 = 0.55 and Cost = 40500. The optimum solution is not integer valued as in the previous solution. This is because we have solved an LP problem that allows the variables to take continuous values. Either we can define all the variables as integers or choose to round off the LP optimum solution. One of the rounded solutions would be W1 = W2 = W3 = W4 = 14, X1 = X2 = X3 = X4 = 112, Y1= Y2 = Y3 = Y4 = 14, I1 = 66, S3 = 26, P2 = P3 = 8 and L1 = 1 and Cost = 41924. If we define all the variables as integers, we get the optimum solution W1 = W2 = 15, W3 = W4 = 14, X1 = X2 = 120, X3 = X4 = 112, Y1= Y2 = 15, Y3 = 14, Y4 = 12, I1 = 75, I2 = 10, S3 = 24 and L3 = 1 and Cost = 41260. We observe that the IP solution changes the workforce in the middle of the planning period because the demands reduce in periods 3 and 4. The above example shows the application of LP to production planning. Most of the times we get fractional solutions to the LP necessitating that the problem is solved as an IP. However, the LP solution provides a basis to make decisions that can be used in practice. Also the problem gets larger and open ended as we make more assumptions regarding the parameters influencing the decisions. Caterer Problem The Caterer problem or the “napkins” problem is well known and is a very fine example of LP formulation that can be covered in a classroom. It also tests the ability of the student to understand the various aspects of LP and formulate a problem for the given situation. Illustration 1.13 Consider a caterer who has to provide food for several dinners happening in the next 8 days. The demand for cloth napkins that are used in the dinners is 80, 120, 66, 75, 100, 120 135 and 150. New napkins cost Rs 20. Napkins can be put to laundry and washed napkins can be used on subsequent days. Two types of laundry are available. The fast laundry that charges Rs 6 per unit and will deliver for use on the second day and the slow laundry that costs Rs 4/unit and can deliver for use on the third day. Find the least cost purchase and use plan for the caterer? We can formulate the caterer problem as a LP problem. Before we attempt this, we show a solution based on commonsense. This solution is shown in Table 1.12 Table 1.12 – Feasible solution for the caterer problem Day Demand New From fast From slow laundry laundry 1 80 80 2 120 120 3 66 0 66 4 75 0 61 14 5 100 0 41 59 6 120 20 75 25 7 135 35 100 8 150 30 120 Total 846 285 463 98 Sent to fast laundry 66 61 41 75 100 120 Sent to slow laundry 14 59 25 463 98 The solution in Table x is based on the assumption that we minimize the purchase of new napkins. We have to meet the demand of the first two days using new napkins. We try to minimize the purchase of new napkins for use in days 3 to 8. We observe that this approach makes us buy 85 more napkins on the last three days because the demand increases towards the end. The rest of the values shown in the table are self explanatory. The total cost of this solution is TC = 285 x 20 + 463 x 6 + 98 x 4 = 8870. We formulate the problem as a LP problem by defining the following variables Xj = number of new napkins bought on day j Yj = number of napkins sent to fast laundry at the end of day i (can be used from day i+2 onwards) Zi = number of napkins sent to slow laundry at the end of day i (can be used from day i+3 onwards) We have to write constraints to meet the daily demand. Ordinarily the demand of day j can be met by using new napkins or by napkins that have arrived from fast laundry and from slow laundry. It is also possible to use some of the napkins that have arrived from the laundries on previous days. This leads us to the following eight constraints X1 ≥ 80 X1 + X2 ≥ 200 X1 + X2 +X3 + Y1 ≥ 266 X1 + X2 +X3 X4 + Y1 +Y2 + Z1 ≥ 341 X1 + X2 +X3 X4 + X5 + Y1 +Y2 + Y3 + Z1 +Z2 ≥ 441 X1 + X2 +X3 X4 + X5 + X6 + Y1 +Y2 + Y3 + Y4 + Z1 +Z2 +Z3 ≥ 561 X1 + X2 +X3 X4 + X5 + X6 +X7 + Y1 +Y2 + Y3 + Y4 + Y5 + Z1 +Z2 +Z3 +Z4 ≥ 696 X1 + X2 +X3 X4 + X5 + X6 +X7 + X8 + Y1 +Y2 + Y3 + Y4 + Y5 +Y6 + Z1 +Z2 +Z3 +Z4 +Z5 ≥ 846 The napkins sent to laundry at the end of day j cannot exceed the demand of day j. This gives us the following six constraints Y1 + Z1 ≤ 80 Y2 + Z2 ≤ 120 Y3 + Z3 ≤ 66 Y4 + Z4 ≤ 75 Y5 + Z5 ≤ 100 Y6 ≤ 120 We also have the non negativity constraint on the variables. The objective function is to minimize the total cost and is given by Minimize 20 (X1 + X2 +X3 X4 + X5 + X6 +X7 + X8) + 6 (Y1 +Y2 + Y3 + Y4 + Y5 +Y6) + 4 (Z1 +Z2 +Z3 +Z4 +Z5) We do not send any napkin to the fast laundry on days 7 and 8 because such napkins can be used from day 9 onwards. For the same reason we do not send napkins to slow laundry on days 6, 7 and 8. We do not have variables Y7 Y8 Z6 Z7 and Z8. The optimum solution to the LP problem is X1 = 285, Y4 = 10, Y5 = 70, Y6 = 120, Z1 = 80, Z2 = 120, Z3 = 66, Z4 = 65, Z5 = 30 with Z = 8344. The solution is to buy 285 new napkins and manage the demand by sending them to laundry. The slow laundry is used more than the fast laundry. The computations and usages are shown in Table 1.13 Table 1.13 – Solution for the caterer problem Day Demand New From fast laundry 1 80 80 2 120 120 3 66 66 From slow laundry Sent to fast laundry Sent to slow laundry 80 120 66 4 5 6 7 8 Total 75 100 120 135 150 846 0 0 19 285 10 70 120 200 75 100 66+20+5 65 30 361 10 70 120 65 30 200 361 The total cost is 285x20 + 361x4 + 200x6 = 8344 Since there is no cost of carrying the new or cleaned napkins if they are used on subsequent days, the solution has X1 = 285. The caterer purchases 285 and uses the new napkins to meet the entire demand of the first two days and 65 on the third day. We also observe that the commonsense solution also purchased 285 new napkins but did not distribute it to the laundries efficiently. LP allows us to obtain and use the correct purchase and distribution of the napkins. In the above formulation, we have to carry out some computations to find out how the returned napkins are used. We can have an alternate formulation where we define the daily usage of the returned napkins. Let Xj = number of new napkins used on day j Yj = number of fast laundry returned napkins used to meet the demand of day j. Zi = number of slow laundry returned napkins used to meet the demand of day j. The Yj and Zj could include napkins that may have arrived earlier and would have been stored for further use. The demand constraints are X1 = 80 X2 = 120 X3 + Y3 = 66 X4 + Y4 + Z4 = 75 X5 + Y5 + Z5 = 100 X6 + Y6 + Z6 = 120 X7 + Y7 + Z7 = 135 X8 + Y8 + Z8 = 150 A maximum of 80 napkins can be sent for laundry on day 1. The returned napkins depending on the mode of laundry can be used from day 3 onwards (fast) and day 4 onwards (slow). This aspect leads us to aggregating the supply and use of the washed napkins. The corresponding constraints are Y3 + Z4 ≤ 80 Y3 + Y4 + Z4 + Z5 ≤ 200 Y3 + Y4 + Y5 + Z4 + Z5 + Z6 ≤ 266 Y3 + Y4 + Y5 + Y6 + Z4 + Z5 + Z6 + Z7 ≤ 341 Y3 + Y4 + Y5 + Y6 + Y7 + Z4 + Z5 + Z6 + Z7 + Z8 ≤ 441 Y3 + Y4 + Y5 + Y6 + Y7 + Y8 + Z4 + Z5 + Z6 + Z7 + Z8 ≤ 561 Xj, Yj, Zj ≥ 0 The optimum solution to the LP problem is X1 = 80, X2 = 120, X3 = 66, X4 = 19, Z4 = 56, Z5 = 100, Z6 = 110, Y6 = 10, Z7 = 65, Y7 = 70, Z8 = 30 and Y8 = 120 with cost = 8344. The solution is to buy 285 new napkins and manage the demand by sending them to laundry. The slow laundry is used more than the fast laundry. This solution tells us directly the number of napkins from the various types (new, fast and slow) that have to be used each day. It is also observed that though we solved LPs to determine the quantities of napkins, we did not get fractional solutions as long as the demands were integers. This example also shows us that there is indeed a class of LP problems (called network problems) where we will get integer solutions as long as the Right hand side (RHS) values are integers. This is due to the unimodularity property of the coefficient matrix. We therefore have instances where the LP solves integer problems. (The problem can be modified if there is an inventory cost to store a usable napkin). One dimensional Cutting Stock problem The one dimensional cutting stock problem is another popular application of linear programming. Here sheets of known width are available. Sheets of specified width are required in certain known quantities. These are to be cut (in one dimension) using the larger available sheets such that the wastage is minimized. Illustration 1.14 Consider a one dimensional cutting stock problem where the demand is for 619 of 8” sheets, 423 of 7” sheets and 339 of 5” sheets. Two types of sheets of width 20 and 25 inches are available. Find the cutting patterns and quantities that minimize waste? The demand for the next day is for 707 sheets of 8”, 243 of 7” sheets and 277 of 5” sheets. Solve a one dimensional cutting stock problem to minimize waste? The cost of a 20” sheet is Rs 2000 and that of a 25” sheet is Rs 2400 We first start with 20” sheets and generate patterns that can cut 8”, 7” and 5” sheets out of 20” sheets. The six possible patterns are shown in Table 1.14 Table 1.14 – Possible patterns 8” 7” 5” waste 1 2 0 0 4 2 1 1 1 0 3 1 0 2 2 4 0 2 1 1 5 0 1 2 3 6 0 0 4 0 The patterns are generated under the assumption that the waste is less than 5” (the minimum width required). The decision variables are Xj = number of 20” sheets cut using pattern j. The problem would be to Minimize 4X1 + 2X3 + X4 + 3X5 Subject to 2X1 + X2 + X3 ≥ 619 X2 + 2X4 + X5 ≥ 423 X2 + 2X3 + X4 + 2X5 + 4X6 ≥ 339 Xj ≥ 0 The objective function minimizes the total waste in terms of lengths. The constraints ensure that the demand is met. The optimum solution to the problem that minimizes waste is X2 = 619 which results in a waste of zero (Z = 0). This is one among the many alternate solutions that can have zero waste. The solution is obvious because pattern 2 results in zero waste. We use 619 sheets and produce 619 of all the three widths. We cut 196 more 7” and 280 more of 5” widths. One view would be that these can be used to meet the demand of subsequent days. We would still like to use fewer sheets to realize the demand. Another view is that we could treat (for the purpose of modeling) that the extra sheets are to be treated as waste. We can add the excess sheets to the objective function which on simplification becomes Minimize 20 (X1 + X2 + X3 + X4 + X5 + X6) + K This reduces to Minimizing X1 + X2 + X3 + X4 + X5 + X6 which is to use minimum number of sheets and realize the demand. The optimum solution is X1 = 182, X2 = 255 and X4 = 84 with Z = 521 and the cost is Rs 1042000. We cut 182 sheets using the pattern [2 0 0] T giving us 364 sheets of 8”. We cut 255 sheets using the pattern [1 1 1] T giving us 255 sheets of 8”, 7” and 5” respectively. We cut 84 sheets using the pattern [0 2 1] T to get 168 sheets of 7” and 84 of 5”. We have a total of 619 of 8”, 423 of 7” and 339 of 5”. We do not overproduce any width. If we had produced more than the required quantities, we can now store them for subsequent use. It is therefore customary to solve this problem with an objective function that minimizes the number of sheets rather than to minimize waste. We consider 25” sheets and evaluate possible patterns. These are shown in Table 1.15 Minimizing only the waste would give us an objective function that Minimizes X1 + 2X2 + 4X3 + 3X4 + 2X6 + 4X7 + X8 +3X9 and a solution with X5 = 619 would be optimal with waste = 0. If we minimize the total number of sheets cut, we have a solution Y1 = [3 0 0]T = 206.333, Y7 = [0 3 0]T = 28, Y8 = [0 2 2]T = 169.5 with Z = 403.833 sheets. We have used variables Y1 to Y10 to represent the variables in this case. Table 1.15 – Patterns for 25” sheets 1 2 3 8” 3 2 2 4 1 5 1 6 1 7 0 8 0 9 0 10 0 7” 5” waste 0 0 1 1 0 2 0 1 4 2 0 3 1 2 0 0 3 2 3 0 4 2 2 1 1 3 3 0 5 0 The first observation is that we do not have an integer solution as in the previous case. This is because we have not defined the number of sheets as integers. Defining them as integers would have given us a solution with 404 sheets. We can alternately round off the solution suitably to get an integer feasible solution very close or within 3 sheets of optimum. The original problem is a minimization problem with integer variables. The LP optimum in this case would give us a lower bound indicating that ZIP would be 204 or more. We simply round off the solution to the lower integer values to have a solution Y1 = 206, Y7 = 28 and Y8 = 169 with 403 sheets. Using 403 sheets we can cut 618 sheets of 8”, 422 sheets of 7” and 338 of 5”. We are short of 1 sheet of all the three. With an extra sheet of 25” we can cut one of each. The optimum number is 404 sheets and the cost is Rs 9696000. It is customary to solve the LP and if we get a fractional solution, we use the downward rounding to get an infeasible, but close to required solution and to use additional sheets to meet the required demand. We also observe that as the thickness of the available sheets increases, we use lesser sheets. We also observe that if we solve a problem where we consider the patterns from 20” and 25” sheets together (and get 16 variables), the solution will only choose patterns from the largest available sheet. Our solution would be the same 403.833 sheets of 25” if we consider both 20” and 25” together. We now consider the second day demand of 707 of 8”, 243 of 7” and 277 of 5”. We can solve the problem optimally to minimize waste or to minimize the number of sheets used. Let us consider 20” sheets and minimize the total number of sheets. The optimal solution is X1 = 232, X2 = 243 and X4 = 8.5 with 483.5 cuts. We can get an integer optimal solution with 484 cuts using the procedure explained above. The total number of sheets of 20” used to meet the two day demand is 521 + 484 = 1005. The cost of 1005 20” sheets is Rs 2010000. We consider the solution X2 = 619 that minimized waste and met the demand of day 1 using 20” sheets. We produced 619 sheets of all three widths and therefore produced an excess of 196 of 7” and 280 of 5”. We now adjust the second day’s demand to 707, 47, 0 of the three widths (we can meet the entire demand of 277 sheets of 5” from the excess and still have an excess of three). Solving the problem of minimizing the total number of sheets used, we get a solution that uses 353.5 sheets of [2 0 0]T and 23.5 sheets of [0 2 1]T. We produce about 24 extra sheets of 5”. We can use the rounding off procedure to obtain an optimum solution that uses 377 sheets and meets the demand. The total number of 20” sheets used to meet the demand of two days is 619 + 377 = 996. If we aggregate the two days demand to 1326 of 8”, 666 of 7” and 616 of 5” and solve for 20” sheets to minimize the total number of sheets, we get the optimum solution with 996 sheets. The solution is X1 = [2 0 0]T = 380, X2 = [1 1 1] T = 566 and X4 = [0 0 4]T = 50. The cost of 996 20” sheets is Rs 1992000. We observe that if we solve the problem to minimize the number of sheets, the solution is better when we aggregate the demands. We had used 380 sheets for the pattern [2 0 0] T when we aggregated the demand while we used 182 + 232 = 414 sheets for the same pattern. This resulted in more waste and hence more sheets when the demand was met daily. When we solved for the first day to minimize waste, we over produced some quantities which helped in the aggregation when the second day demand was adjusted. Therefore using minimum waste criterion helps in aggregation as long as the same widths are required and as long as we do not build too much excess inventory by choosing the waste minimization objective. We can conclude that aggregating the demand certainly helps. If we use a combination of 20” and 25” sheets to meet the aggregate demand the optimum solution would use only 25” sheets. The solution is [3 0 0]T = 442 sheets, [0 3 0]T = 16.667 sheets and [0 2 2]T = 308 sheets with total = 766.66 sheets. We can get a solution with 767 sheets. The cost is Rs 1840800. If we restrict the number of available 25” sheets to 500 sheets, we have the optimum solution [3 0 0]T = 352, [0 2 2]T = 148 (both from 25” sheets), [1 1 1]T = 270 and [0 2 1]T = 50 (using 20” sheets) to get a total of 820 sheets. Manpower Planning problem Manpower Planning is another popular application of Linear Programming. This problem is important because like the caterer problem, we will get integer solutions to the basic manpower planning problem as long as the requirements are integers. This is due to the unimodularity of the coefficient matrix. Illustration 1.15 Consider an airline that has demand for baggage handlers in a domestic airport. The hourly requirements for 24 hours starting from 12 midnight are 4, 2, 4, 3, 4, 5, 6, 6, 7, 10, 12, 12, 10, 10, 12, 12, 14, 15, 16, 20, 16, 10, 8 and 4 respectively. The handlers start working at 12 midnight or 4 am or 8 am or 12 noon or 4 pm or 8 pm. They work for 8 consecutive hours. The demand is the same for all days. Find the minimum number of handlers required that meets the demand? If the people work on one of three consecutive shifts that can start at any hour, find the minimum people required. The airline is also considering flexi shifts where a person can start at any hour and work for 8 consecutive hours. The first case involves people starting work at 12, 4, 8, 12, 16, 20 hours respectively. Let X 1 to X6 represent the number of people starting work on the 6 slots. Since the people work for 8 consecutive hours, it is enough to consider the six slots and the maximum demand in each, which is 4, 6, 12, 12, 20 and 16. For example the last figure 16 is the demand for the period 20 hours to 24 hours which is the maximum of the four demands 16, 10, 8 and 4. The LP problem is formulated as follows Let Xj be the number of people starting work on the six slots (0, 4, 8, 12, 16, 20). The constraints are X6 + X1 ≥ 4 X1 + X2 ≥ 6 X2 + X3 ≥ 12 X3 + X4 ≥ 12 X4 + X5 ≥ 20 X5 + X6 ≥ 16 The objective is to minimize X1 + X2 + X3 + X4 + X5 + X6. The optimum solution is X1 = 4, X2 = 4, X3 = 8, X5 = 4, X5 =16 with Z = 36 people. If we assume that people start working at 1, 5, 9, 13, 17 and 21 hours, the maximum demand in the slots is 4, 7, 12, 14, 20 and 10. The number of variables is six and the RHS values alone change. The optimum number of workers is X1 = 4, X2 = 8, X3 = 4, X4 = 10, X5 = 10 with 36 people. If the slots are 2, 6, 10, 14, 18, 22, the demands are 5, 10, 12, 15, 20, 8. The optimum number of workers is X1 = 5, X2 = 9, X3 = 3, X4 = 12, X5 = 8 with 37 people. If the slots are 3, 7, 11, 15, 19, 23 the demands are 6, 12, 12, 16, 20, 4. The optimum number of workers is X1 = 6, X2 = 12, X4 = 16, X5 = 4 with 38 people. If a person can start at any hour and works for 8 consecutive hours, we can define 24 variables. Let Xj be the number of people starting work at hour j (j = 0,.., 23, where hour 0 is the first hour). The demand for the hour 0-1 will be met by people who start work at 17, 18, 19, 20, 21, 22, 23 and 0. The constraint will be X17 + X18 + X19 + X20 + X21 + X22 + X23 + X0 ≥ 4. The second constraint is X18 + X19 + X20 + X21 + X22 + X23 + X0 + X1 ≥ 2. There are 24 constraints one for each period where the demand for people is met. The 23 objective function Minimizes X j 0 j The optimum solution is given by X3 = 3, X4 = 6, X5 = 6, X12 = 4, X13 = 6, X14 = 2, X15 = 4, X19 = 4 with 35 people. Three people start work at 3 am; six people start work at 4 am and so on. Single constraint problems We revisit the product mix to explain how to solve single constrained LP problems. We also explain the popular “TOC rule” (Theory of Constraints Rule) that is used to solve some product mix problems. We also relate the single constrained LP to single constrained IP problems (called knapsack problems). Illustration 1.16 Consider the LP problem given in Example 1.1. Verify if the LP problem can be treated as a single constrained LP problem. If so, solve the LP to obtain the optimum solution. Maximize 40X1 + 36X2 + 35X3 Subject to 15X1 + 15X2 + 10X3 ≤ 2400 12X1 + 12X2 + 10X3 ≤ 2400 10X1 + 9X2 + 12X3 ≤ 2400 5X1 + 6X2 + 10X3 ≤ 2400 X1 ≤ 50, X2 ≤ 50 and X3 ≤ 100 and Xj ≥ 0 The LP has three variables that represent the production quantities of three products A, B and C. There is a given upper limit on the production quantities. The solution can have a maximum of 50 of A and B and a maximum of 100 of C. The requirement on the four resources to produce X1 = X2 = 50 and X3 = 100 are 2500, 2200, 2150 and 1550.Considering the maximum production quantities, we observe that the first resource alone is less than required while the other three resources are available more than required. The problem therefore reduces to Maximize 40X1 + 36X2 + 35X3 Subject to 15X1 + 15X2 + 10X3 ≤ 2400 X1 ≤ 50, X2 ≤ 50 and X3 ≤ 100 and Xj ≥ 0 If we ignore the bounds (or the upper limits), the problem is a single constrained LP. Since there is only one constraint, there is only one variable in the solution. It is the variable that has the maximum ratio of Cj/aj (objective function coefficient/constraint coefficient). In our example, it is variable 3 with the maximum ratio of 35/10 = 3.5. Variable X3 will take the value 2400/10 = 240 with profit = 8400. A single constrained LP has only one basic variable in the solution. The variable with the largest value of Cj/aj takes a value of b/aj. The objective function value is Cjb/aj. Our example also has the bounds on the variables. We sort the variables in the decreasing order of the value of Cj/aj. The order is X3 followed by X1 and then X2. Consider variable X3. We can make 240 of X3 if there was no upper bound. X3 = 100 (the bound). This consumes 1000 units of the resource. We hav*e 1400 units available for X1 and X2. Consider variable X1. We can produce 1400/15 = 93.33 of X2if there was no bound. We therefore set X1 = 50. This consumes 750 of the resource and we have 650 units available for variable X2. Without the bound, we could produce 650/15 = 43.33 of B, which is within the bound. The final solution is X1 = 50, X2 = 43.33 and X3 = 100 with profit = 7060. The above procedure is used to solve a single variable LP with bounds on the variables. This rule is called the TOC rule and is suggested to solve the product mix problem when there is only one scarce resource when bounds on the variables are applied. The TOC rule cannot be applied to get the optimum solution when more than one resource is scarce. Illustration 1.17 Consider a student preparing to go for trekking and has a backpack to carry items. The bag can carry a volume of 5000 cm3. The student can carry four types of food items each in packets. The volume occupied by a packet of each type is 3000, 800, 1200 and 500 cm 3. The usefulness of each type of food is 40, 8, 15 and 6 units. Find how many packets of each type that he carries. If he chooses to carry a maximum of only one packet per type, how which are the ones does she carry? Let Xj be the number of packets of type j that the student carries. The problem is to Maximize 40X1 + 8X2 + 15X3 + 6X4 Subject to 3000X1 + 800X2 + 1200X3 + 500X4 ≤ 5000 Xj ≥ 0. The above formulation is a LP formulation that does not restrict the quantities to be integers. The single constrained LP is solved as explained in example 1.6. The LP optimum is X1 = 1.666 with Z = 66.67. Since the LP optimum did not give an integer optimum solution, it is an upper bound to the IP optimum. We now define the variables to be integers. The IP optimum is X1 = 1, X4 = 3 with Z = 64. The above problem, which is a single constrained IP problem is called the knapsack problem and has wide uses and applications. If we sort the variables in the decreasing order of Cj/aj, the order is X1, X3, X4, X2. She can take only one unit of X1. This uses 3000 of the space and 2000 units are available. Only 1 unit of X3 can be taken. This leaves us with 800 units of space. The next variable is X4 and only one unit of X4 can be taken. The solution is X1 = X3 = X4 = 1 with Z = 61. This thumb rule based method (that also uses the algorithm to solve the single constrained LP) does not give the IP optimum always. If only one unit of each food item can be taken, the problem would be to Maximize 40X1 + 8X2 + 15X3 + 6X4 Subject to 3000X1 + 800X2 + 1200X3 + 500X4 ≤ 5000 Xj = 0, 1. The above problem is a single constrained binary IP and is called the binary knapsack problem. The IP optimum has the solution X1 = X3 = X2 = 1 with Z = 63. The thumb rule based solution using sorted list of the variables would have given us the solution X1 = X3 = X4 = 1 with Z = 61.
© Copyright 2025 Paperzz