20111iln250v1 gaining insight in linear programming

Upload: ricardo-mery

Post on 02-Apr-2018

218 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    1/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    4

    Gaining Insight in Linear Programming

    from Patterns in Optimal Solutions

    Kenneth BakerTuck School of Business

    Dartmouth College

    Hanover, New Hampshire 03755, USA

    [email protected]

    Abstract

    This paper advocates the practice of interpretingthe qualitative pattern in a linear programmingsolution. This practice should be part of theinstruction we offer on LP, because it helpsstudents gain insight that enhances decision-making. In linear programs, the optimal solutiontells a story about the pattern of economicpriorities, and the recognition of these prioritiescan provide useful insight. The pattern also helpsus anticipate some of the answers to "what if"questions. The discussion covers severalexamples of patterns, shows how to describe apattern without using numbers, and provides twotests to confirm that the pattern has beenarticulated.________________________________________

    The purpose of modeling is insight, not

    numbers.

    Many of us have made a statement like this in theclassroom when we teach basic linearprogramming. Some of us may even attribute theprinciple to Art Geoffrion (1976), in which heactually referred specifically to mathematicalprogramming. But he probably had predecessors.Geoffrion quotes Richard Hammings statementto the effect that the purpose of computing isinsight. And Ive been told that Albert Einsteinsaid that the purpose of mathematics is insight. Itall makes me think that perhaps Euclid mightonce have said that the purpose of geometry isinsight. So, I doubt that the talk about insight isvery new. Still, I find myself wondering: where isthe insight, anyway? Specifically, when we teachlinear programming, and we say that the real take-away from solving an LP model is insight, whereexactly do we find it?

    In this paper, I shall describe one form of insight,which comes from interpreting the qualitative

    pattern in an LP solution. Stated another way, theoptimal solution tells a story about a pattern ofeconomic priorities, and its the recognition ofthese priorities that provides insight. When weknow the pattern, we can explain the solutionmore convincingly than when we simply read the

    algorithms output. When we know the pattern,we can also anticipate some of the answers towhat if questions. In short, the pattern providesa level of understanding that enhances decision-making. Therefore, when we ask students tosolve LP problems, we should also ask them todescribe the qualitative pattern in the optimalsolution.

    Spotting a pattern involves observations aboutboth variables and constraints. In the optimalsolution we should ask ourselves, whichconstraints are binding and which are not? Which

    variables are positive and which are zero?Grasping the pattern of binding constraints andpositive variables allows us to reconstruct thesolution in a sequential fashion. To the untrainedobserver, we seem to be solving the problem withless effort than the simplex algorithm wouldrequire; but, in fact, we are only providing aretrospective interpretation of the solution, andwe need to know that solution as a starting point.Nevertheless, theres more here than justidentifying the optimal basis: there is anopportunity to discern an economic imperative at

    the heart of the situation depicted in the model.When students can see that, then they haveinsight.

    The next sections give some examples of patterns,show how to describe a pattern without usingnumbers, and provide two tests to determinewhether the pattern has been identified. We'll seehow ranges for shadow prices and reduced costscan be computed based on patterns. (Theseranges help interpret the quantitative informationin sensitivity analysis and reinforce theunderlying economics in a solution.) Finally,

    keep in mind that, although the examples arerelatively small, the process of identifyingpatterns is fairly general and also applies in muchlarger models.

    The examples discussed here have been used in arequired introductory-level MBA course inmathematical modeling, where linearprogramming is one of several management

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    2/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    5

    science topics covered. (The course does notalways include all of the examples, but eachexample has been used at one time or another.)However, identifying patterns is an interpretiveskill rather than an advanced mathematical skill;it can be covered in undergraduate courses or

    management development classeswhereverlinear programming is taught.

    Because my own teaching has emphasizedspreadsheet-based modeling approaches, I willrefer specifically to the use of Solver and thereport it provides for sensitivity analysis (calledthe Sensitivity Report). Solver is one of manylinear programming packages, but it is the mostpopular among end-users and one that is nowemphasized in the top MBA programs (Fylstra etal., 1998). Comments about Solver apply to mostcommon linear optimization software packages

    and to the reports they generate for optimalsolutions and for sensitivity analysis.

    A Transportation Example

    In the classical transportation model, we are givensupply quantities at several sources, demandrequirements at several destinations, and we seeka least cost shipment schedule. In the example ofExhibit 1, there are three sources (A, B, and C)with supply quantities 70, 50, and 30,respectively, and there are five destinations (Dthrough H), with requirements of 30, 24, 12, 42and 6. These parameters, along with unittransportation costs for each route, are given inthe upper table. The lower table gives the optimalshipment schedule, with a minimum total cost of$1018.

    Exhibit 1. Spreadsheet format for the transportation example.

    The first thing to notice is that we dont need touse all of the available routes in order to optimizecosts. (This comes as no surprise to anyone whohas studied linear programming from theperspective of linear algebra, but it is worthpointing out explicitly to the novice problem-solver, for whom it may be counterintuitive.) Asthe optimal solution reveals, the best routes to useare AE, AG, BD, BG, BH, CD, and CF.

    The model contains excess supply. Since unitcosts are positive on all routes, we should expectthat the optimal solution ships only enough tomeet demands exactly; there is no incentive toship more than demand to any destination.Another consequence of meeting all demandsexactly is that at least one of the supply capacitieswill be underutilized in the optimal solution. (Inour example, A is underutilized; the other sources

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    3/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    6

    send out their full capacities.) In general, there isno way to anticipate how many sources will befully utilized and how many will be underutilized,so one useful feature of the optimal pattern is theidentification of critical sourcesthose that arefully utilized. The critical sources correspond to

    binding (supply) constraints in the model. (In ourexample, B and C are critical.)

    A noteworthy feature of the optimal schedule isthat some demands are met from a unique source:demand at E is all met from A, demand at F is allmet from C, and demand at H is all met from B.In some sense, these are high priority allocations;we can think of them as if they are made first. Inother problems there can be a symmetric feature:supply may be shipped to a unique destination.This feature also marks a high priority allocation.

    If we remove the high priority shipments and theirdemands from consideration, we are left with areduced problem containing three sources and twodestinations. Now, the list of best routes tells usthat the remaining supply at C must go to D, sinceCD is a high priority allocation in the reducedproblem. Thus, we know exactly whichshipments leave C and where they go.

    Having accounted for the allocation of the entiresupply at C, we are left with a net demand at D,with only B still available (among the best routes)as a source. Given that we have removed C from

    consideration after allocating its entire supply, theremaining demand at D is all met from B. Nowwe can remove D from consideration.

    We are left with just the demand at G. Since B iscritical and BG is one of the best routes, theremaining supply at B must all go to G. Thisleaves a portion of demand at G unsatisfied; thisportion must come from A.

    Looking back, note that this descriptioncharacterizes the optimal solution withoutexplicitly using a number. By describing the

    optimal solution without using the parameters inthe problem, we are portraying a qualitativepattern in the solution and articulating it as if itresulted from a list of economic priorities.

    To review the steps in priority order, we have thefollowing.

    List the best routes and critical sources.

    Identify a high priority demandone thatis met from a unique sourceandallocate the demand to this route. Thenremove this destination fromconsideration. Repeat if possible.

    Identify a critical source with only onebest route unallocated and allocate theremaining supply to this route. Thenremove this source from consideration.

    Repeat the previous two steps usingremaining demands and remainingsupplies each time, until all shipments areaccounted for.

    This retrospective description of the solution hastwo important features: it is complete (that is, wecan specify the entire shipment schedule) and it is

    unambiguous (that is, the description leads to justone schedule.) Anyone who constructs thesolution using these steps should reach the sameresult.

    The significance of this pattern is that it holds notjust for the specific problem that we solved, butalso for other problems that are very similar butwith some of the parameters slightly altered. Forexample, suppose that demand at F were raised to13. We could verify that the same pattern applies.Thus we know that the unit added to the demandat F will optimally be met from C, and therefore

    the direct cost due to the demand change is $6.However, when we allocate the marginal unit tothe route CF, there is one less unit available toallocate to route CD. To compensate, we need toadd a unit to route BD, remove one from BG, andadd one to AG. Tracing down the indirectchange in cost, we find that it comes to (10+910+14) or $3. Thus, the change in the optimaltotal cost due to the unit increase in demand at Fis $9. (This marginal cost is, of course, theshadow price on the demand constraint for F, butthere is no mystery about where this value comes

    from if we understand the pattern in the optimalsolution.)

    As we trace the steps in this modified solution, wecan also anticipate the range over which theshadow price holds. As we add units to thedemand at F, the pattern induces us to make thesame incremental adjustments in shipmentquantities we traced above. The pattern ofshipments will be preserved, and none of the best

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    4/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    7

    routes will be altered, as long as we add no morethan 18 units to the demand at F. At that level,the shipment on CD disappears and we can nolonger subtract from it. For an increase beyond18 units, the set of best routes will change andtherefore the pattern will shift to a different one.

    More generally, we can perturb the originalproblem in several ways at once. Supposedemands at D, E, and F are each raised by oneunit. What will the optimal schedule look like?In qualitative terms, we already know. Thequalitative pattern of economic priorities allowsus to write down the optimal solution to therevised problem without re-invoking Solver.Tracing the cost implications, we will find thatthe one-unit increases in the three demands willincrease the optimal total cost by $29. This figurecan be obtained by adding the three corresponding

    shadow prices, but the pattern allows us to takeone additional step. We can also determine thatthe $29 figure holds for a change (in the threedemand levels) of 16, which is the stage at whichthe allocation to BG runs out. Thus, we can findthe range for a shadow price corresponding tosimultaneous changes in several constraintconstants. This is more complete informationthan we can obtain from the 100% rule, or fromthe typical sensitivity report. (In this case the100% rule would tell us only that the $29marginal value holds for at least 8.7 units at the

    margin. For background on the 100% Rule, seeRagsdale, 1998.)

    A Product Portfolio Example

    The product portfolio problem asks whichproducts a firm ought to be making. If there arecontractual constraints that force the firm to entercertain markets, then the question is whichproducts we ought to be making in quantitiesbeyond the required minimum. Consider FrostyDistributors, a company that distributes fifteendifferent vegetables to grocery stores. Frostysvegetables come in standard cardboard cartonsthat each take up 1.25 cubic feet in thewarehouse. The company replenishes its supplyof frozen foods at the start of each week andrarely has any inventory remaining at the weeksend. An entire weeks supply of frozenvegetables arrives each Monday morning at thewarehouse, which can hold up to 18,000 cubicfeet of product. In addition, Frostys supplier

    extends a line of credit amounting to $30,000.That is, Frosty is permitted to purchase up to$30,000 worth of product each Monday.

    Frosty can predict sales for each of the fifteenproducts for the coming week. This forecast isexpressed in terms of a minimum and maximumanticipated sales quantity. The minimum quantityis based on a contractual agreement that Frostyhas made with a small number of retail grocerychains; the maximum quantity represents aconservative estimate of the sales potential in theupcoming week. The cost and selling price percarton of each of the products are known. Thegiven data are tabulated in Exhibit 2.

    Exhibit 2. Spreadsheet format for the product portfolio example.

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    5/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    8

    Frosty solves the linear programming modelshown in the exhibit, with an objective ofmaximizing profit for the coming week. Sales foreach product are constrained by a minimumquantity and a maximum quantity. In addition,aggregate constraints on warehouse space and

    purchase expenditures make up the model.

    When we look at the variables in the solution, wenotice that all but one of the purchase quantitiesmatch either the maximum or the minimum.(Lima beans are the only exception.) Clearly, anyproduct that has a nonzero minimum must appearin the solution at a positive amount, but someproducts are purchased at higher levels. Theseare high priority products.

    When we look at the constraints in the solution,we see that the credit limit is binding, but the

    space constraint is not. In effect, the credit limitserves as a bottleneck on purchases. In otherwords, we are solving a knapsack problem:produce the highest possible value from thefifteen products under a tight credit limit. Tosolve this problem, we can use a common-senseheuristic: pursue the products in the order ofhighest to lowest value-to-cost ratio. (Thisheuristic is known to find the optimal value forthe knapsack problem in the case of continuousvariables.) The only proviso is that we must meetthe given minimum quantities. Therefore, we caninterpret the solution as follows.

    = Purchase enough of each product to satisfyits minimum.

    = Rank the products from highest to lowestratio of profit to cost.

    = For the highest ranking product, raise thepurchase quantity toward its maximumquantity. Two things can happen: eitherwe increase the purchase quantity so thatthe maximum is reached (in which case wego to the next product), or else we use up

    the credit limit (in which case we stop.)The ranking mechanism prioritizes the products.Using these priorities, we essentially partition theset of products into three groups: a set of high-priority products, produced at their maximumlevels; a set of low-priority products, produced attheir minimum levels; and a single medium-priority product, produced at a level in betweenits min and max. (The medium-priority product is

    defined as the one we are adding to the purchaseplan when we hit the credit limit.) This procedureis complete and unambiguous, and this patterndescribes the optimal solution without explicitlyusing a number.

    Again, we can perturb the base case modelslightly and follow the consequences for theoptimal purchase plan. For example, if we raisethe credit limit, the only change at the margin willbe the purchase of additional cartons of themedium-priority product. Thus, it should not behard to see that the marginal value of raising thecredit limit ($0.1179) is equivalent to theincremental profit per dollar of purchase cost forthe medium-priority product. Furthermore, wecan easily compute the range over which thisshadow price continues to hold. At the margin,we are adding to the 2150 cartons of lima beans,

    where each carton adds $0.1179 of profit perdollar of cost. As we expand the credit limit, theoptimal solution will call for an increasingquantity of lima beans, until we hit the maximumof 3300 cartons. That extra 1150 cartons willconsume an extra $2.80 each of an expandedcredit limit, thus hitting the maximum demand atan additional $3220 of expansion. This is exactlythe allowable increase for the credit limitconstraint.

    Suppose we increase the amount of a low-priorityproduct in the purchase plan. Then, following theoptimal pattern (see the bullet points above), wewould have to purchase less of the medium-priority product. Consider the purchase of moresquash than the 100-carton minimum. Eachadditional carton will cost $2.50, substituting forabout 0.892 cartons of lima beans. The net effecton profit is as follows.

    = add a carton of squash (increase profit by$0.20)

    = remove 0.892 cartons of lima beans(decrease profit by $0.2946)

    = net cost = $0.0946Thus, each carton of squash we force into thepurchase plan (above the minimum of 100) willreduce profits by 9.46 cents, which corresponds tothe reduced cost for squash. Over what range willthis figure hold? From the optimal pattern, wesee that we can continue to swap squash for limabeans only until the squash reaches its maximumdemand of 500 cartons or until lima beans reach

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    6/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    9

    their minimum demand of 500, whichever occursfirst. Thus, the reduced cost holds for 400additional cartons of squash above its minimumdemand, a figure that is not directly accessible onthe sensitivity report.

    Comparing the analysis of Frostys problem withthe transportation problem considered earlier, wesee that the optimal pattern in both cases iscomplete and unambiguous. We can also use thepattern to determine shadow prices on bindingconstraints and the ranges over which thesevalues continue to hold; and, similarly, we canuse the pattern to derive reduced costs and theirranges as well.

    Red Brand Canners

    One of the most popular teaching cases in ourfield over the last generation has been Red BrandCanners (Stanford Business Cases, 1965). In

    brief, the company is interested in planningproduction for three products: whole tomatoes(WT), tomato juice (TJ) and tomato paste (TP),with variable profit margins per case of $1.48,1.32, and $1.85, respectively. A case contains 18pounds of WT, 20 pounds of TJ, and 25 pounds of

    TP. In addition, the market potential is 800,000cases of WT, 50,000 cases of TJ and 80,000 casesof TP.

    Red Brands supplier will furnish 3 millionpounds of fruit, 20% of which is Grade A, withthe remainder Grade B. Grade A tomatoesaverage 9 points on Red Brands quality scale;Grade B tomatoes average 5 points. WT productmust average at least 8 points, while TJ mustaverage at least 6 points. There is no minimumpoint requirement for TP. Equivalently, WTproduct must contain at least 13.5 pounds per case

    of Grade A tomatoes, while TJ must contain atleast 5 pounds per case of Grade A tomatoes.

    Exhibit 3. Spreadsheet format for the Red Brand example.

    Red Brand wishes to allocate its supply oftomatoes to its three products. Exhibit 3 providesa linear programming model for Red Brandsproblem, with the optimal allocation shown. Thevariables are cases of product to produce, inthousands, and the objective function is total

    profit contribution, in thousands of dollars. Thefirst three constraints provide market capacities,and the next constraint reflects the limited supplyof fruit. The last constraint is actually a qualityconstraint; when it is binding, products are made

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    7/14

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    8/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    11

    = TJ from 15.000 to 13.000 (decreasingcontribution by $2640)

    = TP unchangedThe net change in total contribution would be anincrease of $7227, or about 9.03 cents per pound.This figure (equal to the sum of the shadow priceson the last two constraints) tells us that additionalA-tomatoes can raise total contribution if they canbe purchased for less than nine cents per pound.Taking the analysis a little further, we cancalculate that the marginal value of 9.03 centsholds for an increment of 600 pounds; at thatlevel, TJ drops to zero, and beyond that level theoptimal pattern changes.

    A Production Planning Example

    The production planning problem comes inseveral forms. In one version, a company hascontracted to meet a certain demand schedule andfaces constraints on production capacity. Theproblem is to find a least-cost production plan. Inour example, a company produces two products(A and B) using two types of machines (X and Y)over a planning period of three months. The

    products can be produced on either machine, andthe following table describes the machine hoursrequired to make a single unit of each product:

    Product A Product B

    Hrs. on Machine X 2.0 1.5

    Hrs. on Machine Y 2.5 2.0

    Machine capacities on X and Y are given for eachof the three months. In addition, the quantities tobe delivered each month, according to thecontract, are also given. The relevant costs arelabor on each machine ($30/hr.) and inventoryheld ($10/unit/month, for either product). Exhibit4 provides a linear programming model for thisproblem, with the optimal solution shown.

    The variables in this model are of two types. Onetype is the number of units of each productscheduled for production, broken down bymachine and by month. The other type is theinventory of each product held from one month tothe next. The inventory variables allow us toexpress demand constraints using the basic

    Exhibit 4. Spreadsheet format for the production planning example.

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    9/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    12

    accounting definition of inventory: final inventorymust be equal to starting inventory plusproduction minus shipments. One such equationapplies to each product in each month.

    To find the pattern in the optimal solution, weagain start by noticing which variables arepositive and which are zero. If we focus onproduct-month combinations, we may not see adistinct pattern, although it becomes clear that theoptimal schedule calls for overproduction in thefirst month, creating inventory that gets consumedin the second month. In the third month,production matches demand exactly. When wefocus on product-machine combinations, a patterndoes emerge. We see that product B is neverproduced on machine Y, whereas product A issometimes produced on X and sometimes on Y.Apparently, its desirable to produce B on X, but

    not so desirable to produce A on X. Already a setof priorities is emerging. In fact, we also see thatits preferable to produce B on X in an earlierperiod, and to hold it in inventory, as compared toproducing B on Y in the period when demandoccurs. This observation suggests that thesolution can be constructed by the followingprocedure.

    = First, assign X capacity in each month tomake the number of units of B demandedin that period.

    = If X capacity is inadequate to meet alldemand, then assign X capacity in theprevious month, and hold the items ininventory.

    = If X capacity is more than adequate, thenassign X capacity to make the number ofunits of A demanded in that period.

    = If X capacity is fully consumed by theassignment in the previous step, thenassign Y capacity to make the remainingnumber of units of A demanded in that

    period.= If Y capacity is inadequate in the previous

    step, then assign Y capacity in theprevious month, and hold the items ininventory.

    Here, again, we have interpreted the optimalsolution without explicitly using a number; yet wehave provided a complete and unambiguous

    description of the solution. We drew onobservations about which variables turned outpositive in the optimal solution and which turnedout zero. The description can be viewed as asystem of priorities, with each assignmentconsidered in priority order and implemented

    before going on to the next priority. (A diagramof this process is available as a Powerpoint file,Production Schedule Diagram.)

    Again, we can test our understanding of theoptimal pattern by examining the shadow prices.For example, suppose that the capacity of X wereincreased by one hour in month 1. Given theoptimal pattern, wed want to transfer someproduction of A at the margin from machine Y tomachine X. The extra hour of X wouldaccommodate 1/2 unit of A. This would reduceproduction of A by 5/4 of an hour on Y. In cost

    terms, the extra hour of X incurs a cost of $30,while 5/4 of an hour on Y will be saved, at abenefit of $37.50. The net benefit is $7.50, whichis the shadow price on the capacity constraint formachine X in month 1.)

    As another example of perturbing the problem,suppose that we increase the quantity of productA to be delivered in month 1 by one unit. Themarginal cost of meeting this shipment is just thecost of producing one more unit of A on Y. Thisamount is $75, which will match the shadow pricefor the corresponding constraint in the sensitivityreport. Suppose instead that we increase thequantity of product A to be delivered in month 2by one unit. This time the marginal cost is $85,since the marginal unit must be produced inmonth 1 (at a cost of $75) and held in inventoryone month (at a cost of $10), because no capacityremains in month 2 under the optimal plan.Suppose instead that we increase the quantity ofproduct B to be delivered in month 2 by one unit.The pattern of priorities tells us that wed like tomake this unit on machine X, but machine X isfully committed to B during month 2. Following

    the pattern, we will want to make B on X duringmonth 1 and hold it in inventory, but to do so, wewill have to transfer some production of A frommachine X to machine Y. To find the marginalcost of this adjustment, we have to follow theeconomic implications of each element of themarginal change:

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    10/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    13

    = make one unit of B on X (time = 1.5 hrs.;cost = $45)

    = hold one unit of B one month (cost = $10)= remove 1.5 hrs. of A production from X

    (cost saved = $45; 3/4 unit)= add 3/4 unit of A production to Y (time =

    15/8 hrs.; cost = $56.25)= net cost = $66.25

    Once again, the qualitative pattern of economicpriorities allows us to anticipate how the optimalsolution will change. Moreover, we can back upour qualitative appreciation for that change andunravel the shadow price to see where it comesfrom.

    A Cash Flow Matching Example

    In his recent book Wayne Winston (1998) poses amodel for funding a pension liability. In essence,the fund is committed to a set of annual paymentsstretching over 14 years, starting at the end ofyear 1.

    Year 00 01 02 03 04 05 06 07

    $000 0 12 14 15 16 18 20 21

    Year 08 09 10 11 12 13 14

    $000 22 24 25 30 31 31 31

    These obligations are to be funded by thepurchase of three bonds that are available at timezero.

    CurrentPrice

    AnnualCoupon

    Years toMaturity

    FaceValue

    Bond 1 $980 $60 5 $1000

    Bond 2 $970 $65 11 $1000

    Bond 3 $1050 $75 14 $1000

    The fund will be kept in an interest bearing bankaccount that will pay 4% on fund balances at theend of any year. The problem is to minimize thetotal cost of the investment at time zero such thatthe funds obligations can be met.

    There are alternative ways to model this problemas a linear program. A network formulation isshown in Exhibit 5, based on the network diagramin Figure 1. In this approach, each nodecorresponds to a point in time (say, the end ofeach year.) Flows into the node come fromsources of cash (coupon payments, bondredemptions, and last years ending fund balanceplus interest.) Flows out of the node come fromuses of cash (purchases of bonds, investment inthe bank account, or payments of the pensionobligations.) The essential constraint for eachyear is a requirement that total flow into the nodematch total flow out of the node.

    Exhibit 5. Spreadsheet format for the cash flow matching example.

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    11/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    14

    60

    60

    60

    60

    1060

    65

    65

    65

    65

    65

    65

    65

    65

    65

    65

    1065

    75

    75

    75

    75

    75

    75

    75

    75

    75

    75

    75

    75

    75

    1075

    980 970 1050

    Figure 1. Network diagram for the cash flow matching example.

    The optimal solution calls for the purchase ofsome amount of each of the bonds, along with aninitial investment in the bank account. Thus far,it is not easy to see a distinctive pattern.Anticipating that all of the constraints areequalities in a network model, we know that there

    will not be a pattern emerging from the bindingconstraints. However, we can begin to see apattern when we look at the larger set ofvariables. Here, the zero variables in the optimalsolution are revealing.

    The Savings variables represent the amountcarried from one period to the next (beforeinterest) in the bank account. In the optimal

    solution three of these are zero: the bank accountdrops to empty at the end of periods 4, 10, and 13.Immediately, we note that this means the bankaccount is never a source of funds for periods inwhich bonds mature. Thus, for Year 14, the onlysources of funds are the face value of Bond 3 and

    its last coupon payment. Since we know that thisamount is $1075 per bond purchased, and weknow that we are obligated to make a pensionpayment of $31,000, it follows that we should buy28.837 units of Bond 3.

    The purchase of Bond 3 in this quantity fixes notonly the funds flow for Year 14, but it determinesthe size of the coupon flows from Bond 3 in all

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    12/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    15

    previous years. In Years 12 and 13 there is noother coupon payment (since Bond 2 maturesearlier), so net pension obligations in those twoyears must be met from the bank account, which,in turn dictates how large the bank account mustbe at the end of Year 11. For Year 11, the only

    sources of funds are the coupon payments fromBond 3 (already fixed at $2163), the face value ofBond 2, and its last coupon payment. Bond 2provides $1065 per bond purchased, and we cancalculate that we need a pension payment of$30,000 in Year 11, along with a balance of$52,227 in the bank account. It follows that weshould buy 77.208 units of Bond 2 in order toprovide the $82,227 needed.

    Now that the purchases of Bonds 2 and 3 arefixed, we can use the same type of logic tocompute the size of Bond 1. Since we will finish

    Year 10 with no funds in the bank account, thesize of the account at the end of Year 5 must besufficient to meet the pension obligations in Years6-10, net of the coupon payments alreadydetermined by purchases of Bonds 2 and 3. Wealso need to cover the payment obligation in Year5. Toward this funds requirement, Bond 1provides $1060 per bond purchased. We cancompute that well need $78,116 in Year 5, whichwill dictate the need to purchase 73.695 units ofBond 1.

    Finally, the initial amount to place in the bankaccount is determined by the obligations in thefirst four years, net of the coupon payments fromall three bonds, which by now are determined. Inshort, the pattern is as follows:

    = Purchase enough of Bond 3 to meet thelast (14th) pension obligation precisely.

    = Apply the coupon payments for Bond 3against outstanding obligations in allearlier years, producing a set of netobligations.

    = Purchase enough of Bond 2 to meet the netpension obligations in years 11-14precisely, via redemption in Year 11.

    = Apply the coupon payments for Bond 2against outstanding obligations in Years 1-10, producing a new set of net obligations.

    = Purchase enough of Bond 1 to meet the netpension obligations in years 5-10precisely, via redemption in Year 5.

    = Apply the coupon payments for Bond 1against outstanding obligations in Years 1-

    4, producing a new set of net obligations.

    = Invest sufficient funds in the bank accountinitially to meet the net pensionobligations in years 1-4 precisely. (Adiagram of this process is available as aseries of Excel worksheets, IterativeSolution.)

    Once again, the first test is whether wecompletely and unambiguously construct theoptimal allocation with a sequence of allocations,and the steps enumerated above do just that. The

    next test is whether we can explain the shadowprices. Suppose, for example that the pensionobligation in Year 4 is increased by $1000. Whatwill change? To answer this question, note fromthe pattern (see the bullet points above) that theobligation in Year 4 has no effect on any of thebond purchases. Thus, if we increase theobligation in Year 4, the optimal pattern tells usthat we will have to cover the increment byinvesting more in the bank account initially. Inparticular, we need to invest just enough money,so that when it draws interest of 4% per year, it

    will grow to $1000 in four years. A simplepresent value calculation reveals that the preciseamount is $854.80. Equivalently, the shadowprice for the constraint corresponding to Year 4 is0.8548.

    Now suppose instead that the pension obligationin Year 5 is increased by $1000. Here, theoptimal pattern takes us in a different direction.In this case, the pattern tells us that theincremental obligation will be paid out of theredemption of Bond 1. (Recall from the patternthat Bonds 2 and 3 are not affected by obligations

    in Year 5.) To cover the $1000 increment, wellneed to purchase an additional 0.9434 bonds,since each bond pays $1060 in Year 5. However,the additional bonds will also provide couponpayments in Years 1-4, reducing the netobligations that must be covered by the initialinvestment in the bank account. This reduction innet obligations has a present value of $205.47,which is the amount by which we can reduce the

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    13/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    16

    initial investment. In sum, we pay an extra$924.53 for Bond 1 but save $205.47 for a netcost of $719.06. In essence, we have derived theshadow price for the constraint corresponding toYear 5, which is 0.7191. Similar arguments applyto the years following Year 5, where Bond 2

    becomes involved if we examine the incrementaleffects for Years 10-13, and Bond 3 becomesinvolved at Year 14. Furthermore, the range overwhich such marginal values hold can bedetermined by the same approach we illustratedearlier.

    Summary

    The five examples illustrate the process ofextracting insight from linear programmingsolutions. The first step, of course, is to

    understand the situation leading to the model.This allows us to examine the optimal decisionvariables for positive or zero quantities andperhaps notice a pattern (or part of one). We canalso examine the constraints and determinewhether or not they are binding in the optimalsolution. The purpose of these observations is toappreciate how the solution procedure appears toconstruct the optimal solution from the givenparameters. This construction can usually beinterpreted as a list of priorities, and thosepriorities reveal the economic forces at work.

    The pattern that emerges from the economicpriorities is essentially a qualitative one, in thatwe can describe it without using specific data.Nevertheless, the pattern leads us to the optimalsolution when we supply the data. In a sense, itsalmost as if Solver first spots the optimal patternand then says, Give me the numericalinformation in your problem. For anyspecification of the numbers (within certainlimits), Solver can then compute the optimalsolution by simply following the sequential stepsin the pattern. In reality, of course, Solver cannot

    know the pattern until the solution is revealed.

    There are two diagnostic questions that helpdetermine whether a pattern has been extractedfrom a solution. First, is the pattern complete andunambiguous? That is, the pattern must lead us toa full solution, not just to a partial solution of theproblem, and it must not leave any room forchoice in the list of priorities. Second, where do

    the shadow prices come from? In each case, theshadow price comes from perturbing the originalproblem one constraint constant at a time. Weshould be able to trace the incremental changes inthe variables, through the various steps in thepattern, and ultimately derive the shadow price

    for the corresponding constraint. We can, ofcourse, determine marginal values for changingseveral parameters at a time in much the sameway, and, as we saw, we can also compute therange over which these marginal values continueto hold.

    Patterns have certain limits, as suggested above.If we think of testing our specification of a patternby deriving shadow prices, we have to recognizethat shadow prices have ranges of validity. As wechange a right-hand side constant, there willeventually be a change in the shadow price. The

    same is true of the pattern: beyond the range inwhich the shadow price holds, the pattern maychange. In technical terms, it is as if the storyin the pattern simply reflects the choice ofvariables in the optimal basis. However, this isnot always the case. In the production planningexample, the pattern was described in a fairlygeneral way: it will hold even when the shadowprice changes (i.e., even when the basis changes.)In that example, we were able to articulate apattern at a high enough level that the storycontinues to hold even for substantial changes in

    the given data.

    The advent of accessible solution procedures forlinear programming, most particularly ExcelsSolver, currently makes optimization available toeven the novice problem-solver. Various writersin our field have observed (and sometimeslamented) that Solver now brings linearprogramming to the masses. This makes it evenmore important to focus the novice on somethingother than just obtaining the numbers. Theexamples given in this paper show the insight wegain by focusing on the pattern. If, as teachers,

    we can orient our students to the pattern, thenwell at least be able to say that while Solverprovides LP to the masses, we can provide theinsight.

  • 7/27/2019 20111ILN250V1 Gaining Insight in Linear Programming

    14/14

    BAKERGaining Insight in Linear Programming from Patterns in Optimal Solutions

    ____________________________________________________________________________________________

    ______________________________________________________________________________

    INFORMS Transactions in Education1:1 (4-17) INFORMS

    17

    References

    Fylstra, D., L. Lasdon, J. Watson, and A. Waren(1998), Design and Use of the Microsoft ExcelSolver,Interfaces, Vol. 28, No. 5, pp. 29-55.

    Geoffrion, A. (1976), The purpose ofmathematical programming is insight, notnumbers, Interfaces, Vol. 7, No. 1, 81-92.

    Ragsdale, C. (1998), SpreadsheetModeling andDecision Analysis (Second Edition), South-Western, Cincinnati, OH, p. 142.

    Red Brand Canners (1965), Stanford BusinessCases, Stanford University, Palo Alto, CA;distributed by Harvard Business SchoolPublishing as Case number 9-110-060.

    Winston, W. (1998), Financial models using

    simulation and optimization (Chapter 14),Palisade Corporation, Newfield, NY.