Often, the ®rst part of a solution is to determine whether there is a valid LP model for your situation.. I would prefer to have the constraints in the form of a system of linear equatio
Trang 1Linear programming is a method for dealing with an
exceptionally diverse class of situations A situation is
usually presented in the form of a moderately
amor-phous mass of information by a group of one or more
people who wish to do something To deal with a
situa-tion effectively, you need to understand the situasitua-tion,
so you know what the group wants to do Then you
need to analyze the situation, so you can tell the group
how to do what it wants to do Typically the goal is to
make decisions to optimize an objective while
satisfy-ing constraints To understand a situation you need to
formulate an accurate conceptual model for the
situa-tion; generally this encompasses stating an appropriate
set of decisions that must be made, together with the
objective to be optimized and the constraints which
must be satis®ed The corresponding analysis is
typi-cally a process to determine which set of values for the
decisions will optimize the objective while satisfying
the constraints; it often involves formulating an
appro-priate mathematical model for the situation, solving
the model and interpreting the implications of the
model for the situation
Linear programming (LP), is an extremely effective
method for formulating both the conceptual and
math-ematical models Good LP software is available to
solve the problem if you can formulate a valid LP
model of reasonable size Linear programming passes several activities It includes recognizingwhether or not an LP model is appropriate for a spe-ci®c situation An LP model is both a conceptual and amathematical model for the situation If an LP model
encom-is appropriate, LP includes formulating an accurate LPmodel (also called simply an LP), solving the LP, andapplying the solution to the LP to the situation.Formulating an LP model for a situation involvesthree basic steps:
1 Specify the decision variables
2 Specify the constraints
3 Specify the objective function
Quantifying an appropriate set of decisions is thecrucial ®rst step to understanding a situation and toformulating a valid model for the situation; itaddresses the question: What decisions need to bemade in order to optimize the objective? The ®rststep in formulating an LP model for a situation helpsyou understand the situation by requiring you to spe-cify an appropriate set of decision variables for themodel After the decision variables are speci®ed, onetries to specify the constraints and objective function aslinear functions of the decision variables Either youget an LP model or you discover where essential non-linearities appear to be
Linear programming has its theoretical side too,with algebraic and geometrical components, and var-297
Trang 2ious algorithms for solving LP models However, the
common procedures are variations of the simplex
method discovered by George Dantzig The simplex
method uses elementary linear algebra to exploit the
geometrical and algebraic structure of an LP; it is
ele-gant and ef®cient Learning the rudiments of the
sim-plex method will enable you to utilize output from LP
software packages more effectively In addition to
giv-ing you a solution to your LP, or tellgiv-ing you that there
is no solution, the software may provide you with
addi-tional information that can be very helpful if you know
how to use it Theoretical concepts are useful in LP
modeling While theory will not be discussed in this
chapter, some theoretical concepts will appear during
our discussions of the examples which are presented in
the sequel
Sometimes you will discover that the problem has a
special structure which permits you to formulate a
dif-ferent type of model for the problem, one that exploits
the special structure more ef®ciently Transportation
problems have a special structure which has been
stu-died from several points of view Transportation
pro-blems provide a good bridge between LP and network
models Network models are associated with a diverse
class of methods After using examples to introduce
several types of situations to which LP can be applied,
we will apply dynamic programming to some
situa-tions to illustrate how special structure and condisitua-tions
can be exploited
Programming has artistic and technical aspects, and
like learning to paint or play a game, one learns to
program by doing it Reading can help you get started,
but you need to participate to become good at it As
you participate you will be able to model an increasing
diverse collection of situations effectively An effective
model is valid, it can be solved using software that is
available to you, and it will provide clear usable output
with which to make your decisions
Finding an optimal solution to a complicated
pro-blem may well depend on recognizing whether LP or
some other special structure can be used to model
your situation accurately Often, the ®rst part of a
solution is to determine whether there is a valid LP
model for your situation If you decide that a valid
LP model can be constructed, then either ®nd special
structure that will let you to use a signi®cantly faster
algorithm or construct an ef®cient LP model
Otherwise, look for special structure in the situation
which will permit you to use some known modeling
strategy
Examples of types of situations which can be
mod-eled using LP will be discussed below The examples
begin with some information being provided, followed
by an LP model and a brief discussion of the situation.Often there are several valid LP models for a situation
If you model the same situation on different days, evenyour decision variables may be quite different becauseyou may be emphasizing different aspects of the situa-tion A different focus may well result in a model withdifferent constraints and a different objective function.You may wish to formulate and solve your own mod-els for these situations; do not be surprised if what youget differs from what you see here
The basic ingredients of linear programming areintroduced in the ®rst three examples
2.1.2 Examples 1±3Example 1 A Production ProblemInformation Provided An organization has an abun-dance of two types of crude oil, called light crude anddark crude It also has a re®nery in which it can pro-cess light crude for 25 dollars per barrel and dark crudefor 17 dollars per barrel Processing yields fuel oil,gasoline, and jet fuel as indicated in the table below
Output
InputLight crude Dark crudeFuel oil
GasolineJet fuel
0.210.50.25
0.550.30.1
The organization requries 3 million barrels of fuel oil, 7million barrels of gasoline, and 5 million barrels of jetfuel
Understanding the Situation: Interpreting theInformation Provided Part of programming is inter-preting what people are trying to tell you and feedingback your impressions to those people until you believeyou understand what they are trying to tell you Forexample, the entry 0.21 in this table seems to implythat each unit of light crude oil which you processproduces 0.21 units of fuel oil If the objective is toprocess enough oil to meet the listed demands at mini-mum processing cost, then we wish to determine howmuch light and dark crude should be processed to meetthe requirements with minimal processing cost Tobegin recall the three steps in formulating an LPmodel:
1 Specify the decision variables
2 Specify the constraints
3 Specify the objective function
Trang 3Decision Variables We must decide how much light
crude oil to process and how much dark crude oil to
process A set of decision variables for Example 1
The values of decision variables are numbers I
can-not overemphasize the importance of doing Step 1
Specifying the decision variables as numerical valued
variables forces you to focus on exactly what decisions
you need to make
The next two steps are to specify a set of constraints
to model the requirements and to specify an appropriate
objective function to model the cost, which we wish to
minimize The form and order of these speci®cations
depend on our choice of decision variables and our
thought processes at the time when we are making
the model In this example we consider the constraints
®rst
Constraints I interpreted the table to imply that each
million barrels of light crude processed produces 0.21
million barrels of fuel oil, etc Thus, processing L
mil-lion barrels of light crude and D milmil-lion barrels of dark
crude produces 0:21L 0:55D barrels of fuel oil Since
3 million barrels are required, we have the constraint
0:21L 0:55D 3; this constraint is a linear equation
in L and D Similar equations for gasoline and jet fuel
apply Putting these equations together gives us the
linear system
0:21L 0:55D 3 (fuel oil)
0:50L 0:30D 7 (gasoline)
0:25L 0:10D 5 (jet fuel)
Necessity of Inequality Constraints Unfortunately,
because processing either type of crude oil produces
at least twice as much gasoline as jet fuel, there is no
way to produce 5 million barrels of jet fuel without
producing at least 10 million barrels of gasoline
Thus, there is no feasible solution to this linear system
Consequently, we are forced to formulate our
con-straints as a system of linear inequalities:
0:21L 0:55D 3
0:50L 0:30D 7
0:25L 0:10D 5
Standard Form for Constraints I would prefer to
have the constraints in the form of a system of linear
equations because I know how to solve systems oflinear equations, so we put them in that form by intro-ducing surplus variables F, G, and J to denote thenumber of millions of barrels of surplus fuel oil, gaso-line, and jet fuel produced The preceding system oflinear inequalities is replaced by the following system
of linear equations:
0:21L 0:55D 3 F0:50L 0:30D 7 G0:25L 0:10D 5 Jwhich can be rewritten in standard form:
0:21L 0:55D F 30:50L 0:30D G 70:25L 0:10D J 5Objective Function The cost of processing L millionbarrels of light crude and D million barrels of darkcrude is 25L 17D millions of dollars The objectivefunction for this problem is the linear function of Land D given by the formula
0:50L 0:30D G 70:25L 0:10D J 5
A standard form LP has the form: minimize a linearfunction of the decision variables subject to a system oflinear equations being satis®ed by the decision vari-ables, plus implicit constraints which require that thedecision variables be nonnegative This is the form that
is processed by the simplex method
Note: Unless it is speci®cally stated otherwise, thevalues of all decision variables are nonnegative num-bers
Canonical Form Some authors use the name cal LP, or canonical form LP, to denote an LP which
canoni-we have called a standard form LP Sometimes dard form or canonical form refers to a max LP withequality constraints, so be aware of these variations interminology when you read about or discuss LP.After a comment about vectors and matrices,elementary concepts from linear algebra, we will use
Trang 4stan-them to write the model for Example 1 in a very
com-pact form which displays its structure
Comments about Vectors and Matrices
A vector is simply a list of numbers This simple
concept is extremely useful both conceptually and
computationally Imagine a cash register drawer with
eight compartments, labelled 1 to 8, for pennies,
nick-els, dimes, quarters, dollar bills, 5 dollar bills, 10 dollar
bills, and 20 dollar bills, respectively Suppose that I
count the number of pieces of money in each
compart-ment and write those numbers in a list If that list is
3; 5; 2; 4; 11; 4; 1; 6, then how much money is in the
drawer? If you trust my counting and your answer is
$162.48, then you understand how vectors work
We can either write the list as a row of numbers: a
row vector, denoted [ ], or as a column of numbers: a
column vector Column vectors take more space on a
page, so we generally use a row format using
paren-theses ( ), to denote column vectors; for example,
the preceding vector, representing a list of the numbers
of the various items in the drawer, really looks like
A matrix is a rectangular array of numbers We can
think of a matrix as a row of column vectors or as a
column of row vectors when it is convenient to do so
We will illustrate how one can use vectors and
matrices to formulate LPs in a very compact form by
discussing Example 1 from a vector±matrix perspective
35
provide lists of the number of units of fuel oil, gasoline,
and jet fuel produced by processing one unit of light
and dark crude oil, respectively
Let A denote the 3 2 matrix whose columns are
the unit output vectors of light and dark crude oil, let b
denote the column vector of requirements, let c denote
the row vector of unit processing costs, and let x
denote the column vector of decision variables:
A
0:21 0:550:5 0:30:25 0:1
26
3
5
26
3
7 c 25; 17
x LD
Then the LP model for Example 1 can be written asfollows:
Minimize cxsubject to Ax b; x 0
Example 2 A Generic Diet ProblemInformation Provided A large institution wishes toformulate a diet to meet a given set of nutritionalrequirements at minimal cost Suppose that n foodsare available and m nutritional components of thefoods are to be considered (each of n and m denotes
an arbitrary but ®xed positive integer determined bythe individual situation) Label the foods f1; ; fnandlabel the nutrients N1; ; Nm The costs and nutri-tional characteristics of the foods, and the nutritionalrequirements of the diet, are provided in the followingformat A unit of fj costs cj money units and contains
aijunits of Ni; at least biunits of Niare required for thediet Use summation notation to formulate a compact
LP model for the diet problem
Summation Notation: a Compact Way to Write the Sum
of n Quantities Given n quantities Q1; Q2; ; Qi;
; Qnwhich can be added, their sum Q1 Q2 Qi
Qn is denoted by Pni1Qi The index i is asymbol which represents a generic integer between 1and n; instead of i, one can use j, or any other symbolexcept n, which represents the number of terms to beadded
Solution The n decisions are how many units of each
of the foods to put in the diet The constraints are the
m nutritional requirements that must be satis®ed, andthe objective is to ®nd a minimal cost combination ofavailable foods which meets the nutritional require-ments Let x denote the column vector
x1; ; xi; ; xn, let b denote the column vector
b1; ; bi; ; bm, let c denote the row vector
c1; ; ci; ; cn, and let A denote the m n matrixwhich has aij in its ith row and jth column Then the
LP model for Example 2 has the formMinimize cx
subject to Ax b; x 0
Trang 5A numerical example follows.
Example 2a ``What's for Lunch?'' Suppose seven
foods: green beans, soybeans, cottage cheese,
Twinkies, vegetable juice, spaghetti and veggie
supreme cheese pizza, are available Suppose that
units of these foods cost 0.35, 0.2, 0.28, 0.2, 0.15,
0.99, and 2.49 dollars, respectively Suppose that four
properties of each food: calories, protein,
carbohy-drates, and vitamins, are required to be considered,
and the following properties matrix A and
require-ments vector b are provided:
b
1681413
2
6
6
377
c 0:35; 0:2; 0:28; 0:2; 0:15; 0:99; 2:49
The four numbers listed in a column of the matrix
represent the numbers of units of the four properties
in one unit of the food corresponding to that column;
for instance, column three corresponds to cottage
cheese, so each unit of cottage cheese contains three
units of calories, four units of protein, three units of
carbohydrates, and two units of vitamins
A unit of pizza has been designed to meet the
diet-ary requirements exactly A meal composed of one unit
of green beans, two units of soybeans, 3/2 units of
cottage cheese, and 3/4 units of Twinkie also ®ts the
minimal requirements of the diet exactly; this meal
costs $1.32, while pizza costs $2.49 Notice that a
meal composed of one unit of spaghetti and two
units of vegetable juice will also meet the requirements,
at a cost of $1.29 (this meal provides two extra units of
vitamins) Which of these three meals would you
choose?
The transportation problem is another classical
example; a standard form LP model for it is developed
in Example 3
Example 3 A Transportation Problem
The goal of a transportation problem is to ship
quan-tities of a material from a set of supply points to a set
of demand points at minimal cost, A model for a
trans-portation problem consists of supplying ®ve lists: a list
of supply points, a list of demand points, a list of the
numbers of units available at each supply point, a list
of the numbers of units desired at each demand point,and a list of the costs of shipping a unit of materialfrom each supply point to each demand point, and an apriori constraint: total supply is equal to total demand.These ®ve lists will be displayed in a transportationtableau The tableau for an example which deals withshipping truckloads of blueberries from orchards towarehouses follows
Orchards
Warehouses
SuppliesCalifornia Arizona Colorado MexicoNew
WashingtonOregonMichigan
460350990
550450920
650560500
720620540
100170120
Total supply total demand 390 There are 12decisions to be made; we must decide how many truck-loads of blueberries to ship from each of the threesupply points to each of the four demand points Wereplace the unit shipping costs with a list of names forthe decision variables below
Orchards
Warehouses
SuppliesCalifornia Arizona Colorado MexicoNew
WashingtonOregonMichigan
X1X5X9
X2X6X10
X3X7X11
X4X8X12
100170120
There are three supply constraints and four demandconstraints:
X1 X2 X3 X4 100 (Washington)X5 X6 X7 X8 170 (Oregon)X9 X10 X11 X12 120 (Michigan)
Trang 6Then the blueberry example has the standard form LP
model displayed below
Minimize cx
Subject to Ax b; x 0
2.1.3 Duality
An LP has a speci®c algebraic form There is a
corre-sponding algebraic form, called the dual LP The
ori-ginal problem is called the primal problem, and the
primal together with the dual is called a primal±dual
pair; the primal is the ®rst LP in the pair and the dual
LP is the second LP in the pair When an LP is a model
of a ``real-world'' situation, very often there is a
differ-ent (dual) perspective of the situation which is modeled
by the dual LP Knowing the existence and form of the
dual LP provides a vantage point from which to look
for a dual interpretation of the situation; examples are
provided below by exhibiting dual linear programs for
Examples 1 and 3
2.1.3.1 Dual Problem for Example 1
A related problem, called the dual problem, will be
introduced by considering Example 1 from a different
perspective below
A group has ample supplies of fuel oil, gasoline, and
jet fuel which they would like to sell to the
organiza-tion The group wishes to maximize income from
sell-ing 3 million barrels of fuel oil, 7 million barrels of
gasoline and 5 million barrels of jet fuel to the
organi-zation The group's decisions are to determine the
numbers of millions of dollars (prices), pF, pG, and
pJ, to charge for a million barrels of fuel oil, gasoline,
and jet fuel, respectively For algebraic reasons we
write their decision variable vector in row form
y pF; pG; pJ Then the group's objective can beexpressed algebraically in the form: maximize yb,where A and b are de®ned in Example 1 For thegroup to be competitive, the price for the output ofprocessing a million barrels of light crude can be nomore than the processing cost; this constraint has thealgebraic form 0:21pF 0:5pG 0:25pJ 25 Thecorresponding constraint for dark crude is0:55pF 0:3pG 0:1pJ 17 These constraints can
be written in vector±matrix form as yA c; y 0.Thus, the dual can be written
Subject to yA c; y 0
2.1.3.2 Comment on Standard form
By introducing slack variables, surplus variables, andother appropriate modi®cations, any LP can be put instandard form For instance, Example 1 showed how
to write constraints in standard form by introducingsurplus variables The dual constraints introducedabove can be written in standard form by introducingnonnegative slack variables, sL and sD:
0:21pF 0:5pG 0:25pJ sL 250:55pF 0:3pG 0:1pJ sD 17The objective ``Maximize yb'' is equivalent to
``Minimize y b:''2.1.3.3 Dual Problem for Example 3
A wholesale produce corporation wishes to buy theblueberries at the orchards and deliver the requiredamounts at the demand points Their objective is tomaximize net income from this transaction Their deci-sions are prices to charge per truckload, but the pricesare not all 0 because buying blueberries at the orch-ards represents negative income Referring to Example
3, put y y1; y2; y3; y4; y5; y6; y7, where y1; y2; andy3 are 0 and the others are 0 The net income to bemaximized is yb The constraints are that the buyingprice at an orchard plus the selling price at a state is nomore than the cost of shipping a truckload from theorchard to the state; these 12 constraints are writtenalgebraically as yA c Thus, the dual problem can bewritten
Subject to yA c
Trang 7We do not have the constraints y 0 in the dual of a
standard form LP
2.1.4 Absolute Values and Integer Variables
Before presenting more examples to illustrate a variety
of situations which can be modeled using LP, we
men-tion two useful concepts, absolute values and integer
variables
2.1.4.1 Absolute Values
The absolute value of a number is the magnitude of the
difference between the number and zero The absolute
value, jXj, of a number X can be expressed as the
Realistic solutions to situations must often be integer
valued An LP model does not require integer values
for solutions; however, in many cases either the LP
solution turns out to be integer valued, or one can
use the LP solution to guess an integer valued solution
that is good enough The de®nition of ``good enough''
depends the tools, time, and creativity available to
apply to the problem Problems that were intractable
for a PC a few years ago can be solved easily now
Computer hardware and software that is available
for a reasonable price has been getting faster and better
at a rapid pace Some problems that had to be modeled
carefully in order to be solvable with available tools a
few years ago can be solved using a sloppy model now
However, good modeling habits are worth cultivating
because they enable you to deal effectively with a
larger set of situations at any point in time
There are two kinds of integer-value variables, INT
variables and GIN variables, which are often available
in LP software Each INT variable may essentially
double the computational complexity of a LP model
and each GIN variable may increase it at least that
much Consequently, they should be used carefully
Nevertheless, they can be very useful
INT variables (sometimes called 0±1-valued integer
variables) are variables whose values are either 0 or 1
An INT variable can be used as a switch to switchbetween two possible situations The INT variableinsures that at most one of the possibilities occurs inany one possible solution
For example, given a positive number M, the lute value of X in a range from M to M can also beexpressed using an INT variable, Z, as follows:jXj P N P MZ; N M 1 Z
abso-P 0 N 0The inequalities involving Z require that at least one of
P and N be equal to zero In some situations it is useful
to consider ``big M'' constants, denoted by M; ``bigM's'' are constants which are big enough to impose
no new constraint on a problem in which they areused We illustrate this with the following example.Constraints of the form
ajXj y ; ; or cwhere each of X and y is a linear term and each of aand c is a constant, can be put in LP format If a 0,
we have an LP constraint; otherwise, there are twocases to consider, a > 0 and a < 0 In both cases, wedivide the constraint by a If a > 0 we getjXj 1=ay , , or c=a Putting Y 1=ay and
C c=a, the constraint becomesjXj Y ; ; or C
If a < 0, the inequalities are reversed Consequently,
we have three possibilities to consider The case isthe easiest The constraint jXj Y C is equivalent tothe following two LP constraints
``big M'' in the following additional constraints:
Trang 8Example 4 A Primal-Dual Pair
Information Provided The Volkswagen Company
produces three products: the bug, the superbug, and
the van The pro®t from each bug, superbug, and van
is $1000, $1500, and $2000, respectively It takes 15,
18, and 20 labor-hours to produce an engine; 15, 19,
and 30 labor-hours to produce a body; and 10, 20, and
25 minutes to assemble a bug, superbug, and van The
engine works has 10,000 labor-hours available, the
body works has 15,000 labor-hours available, and the
assembly line has 168 hours available each week Plan
weekly production to maximize pro®t
Solution
Let B number of bugs produced per week
Let S number of superbugs produced per week
Let V number of vans produced per week
An LP model and solution for Example 4 follow
The solution says that all the engine works and
assem-bly time is used, but about 2074 labor-hours of body
works time is not used
The values of the decision variables in the LP
solu-tion are not all integers However, the feasible, integer
valued solution B 276, S 1, and V 292 has
objective function value equal to 861,500 Thus, this
solution is optimal because its value, 861,500, is the
largest multiple of 500 which is 861,714.3, the LP
optimum
Now we introduce a dual problem for Example 4:
demographics change with time and BMW Corp
dec-ides to increase production BMW decdec-ides to approach
Volkswagen about leasing their plant They want to
determine the smallest offer that Volkswagen might
accept A model for their situation follows
Let E no of dollars to offer per hour for engine
2) 15 E + 15 W + 10 A >= 1000 3) 18 E + 19W + 20 A >= 1500 4) 20 E + 30 W + 25 A >= 2000
The constraints for this dual problem say that thenumber of dollars offered to pay to rent must beenough to make Volkswagen's rental income at least
as much as the pro®t it would get by using its resources
to manufacture vehicles instead of renting them toBMW It turns out that the optimal objective functionvalues for the primal and its dual are always equal Asolution follows
at least 2 kg of protein, and at least 3 g of vitamins perday Three kinds of feed are available; the followingtable lists their relevant characteristics per kilogram
Feed Cost Calories Kg of protein Grams ofvitamins1
23
$0.8
$0.6
$0.2
360020001600
0.250.350.15
0.70.40.25
The farmer also requires that the mix of feeds contain
at least 20% (by weight) feed 1 and at most 50% (byweight) feed 3 The farmer wishes to formulate a dietwhich meets his requirements at minimum cost.Solution
Let A no of kilograms of feed 1 to put in the diet.Let B no of kilograms of feed 2 to put in the diet.Let C no of kilograms of feed 3 to put in the diet.The ®rst four constraints correspsond to the calorie,protein and vitamin requirements of the diet The lasttwo correspond to the percentage requirements: A 0:2
A B C and C 0:5 A B C A model appearsbelow, followed by a solution The constraints havebeen adjusted to make the coef®cients integers
Trang 9Example 6 A Processing Problem
Information Provided Fruit can be dried in a dryer
according to the following table The dryer can hold
0.460.440.340.31
0.530.510.470.42
Formulate an LP to estimate the minimum time in
which 20 m3 of grapes, 10 m3 of apricots, and 5 m3 of
plums can be dried to a volume of no more than 10 m3
Solution We begin by making some simplifying
assumptions The dryer will be ®lled with one kind of
fruit and operated for 1, 2, 3, or 4 hours, then the dried
fruit will be removed from the dryer and the dryer will
be re®lled In accord with these assumptions, we have
the following decision variables:
Let GI no of cubic meters of grapes to dry for I
Time spent ®lling the dryer and removing dried fruit is
assumed to be independent of the type of fruit being
dried and the number of hours the fruit is dried Then
these factors do not need to be explicitly incorporated
into the model
OBJECTIVE FUNCTION VALUE 82.4999900 VARIABLE VALUE
of 83 The objective function value of any integervalued solution will be an integer Since 83 is the smal-lest integer which is 82:5, we know that changing A1
to 6 and A3 to 4 provides use with an optimal integervalued solution
Example 7 A Packaging ProblemInformation Provided The Brite-Lite Companyreceives an order for 78 ¯oor lamps, 198 dresserlamps, and 214 table lamps from Condoski Corp.Brite-Lite ships orders in two types of containers.The ®rst costs $15 and can hold two ¯oor lamps andtwo table lamps or two ¯oor lamps and two tablelamps and four dresser lamps The second type costs
$25 and can hold three ¯oor lamps and eight tablelamps or eight table lamps and 12 dresser lamps.Minimize the cost of a set of containers to hold theorder
SolutionLet CIJ = no of containers of type I to pack with mixJ; I 1; 2; J 1; 2
Minimize 15 C11 + 15 C12 + 25 C21 + 25 C22 Subject to
2) 2 C11+ 2 C12 + 3 C21 78 3) 4 C11 + 2 C12 + 8 C21 + 8 C22 214 4) 4 C12 + 12 C22 198
OBJECTIVE FUNCTION VALUE 852.500000 VARIABLE VALUE
Trang 10This solution is not integer valued; however, it puts
six dresser lamps in the half carton of type 2 packed
with mix 2 and no other listed packing option will
allow six dresser lamps in one carton Consequently,
I could put C22 10, increase the cost to 865, and
claim that I now have the optimal solution But
claim-ing does not necessarily make it optimal Is there a
better solution? Using GIN variables, I found a better
solution The best integer-valued solution is C11 4,
C12 20, C21 10 and C22 10, with objective
function value 860; 5 may seem to be a trivial number
of dollars, but if we are shipping different products and
we are talking about hundreds of thousands of dollars,
the difference might be signi®cant to you
Example 8 LP Can Model Diminishing Return
ThresholdsInformation Provided The Model-Kit Company
makes two types of kits They have 215 engine
assem-blies, 525 axle assemassem-blies, 440 balsa blocks, and 560
color packets in stock Their earthmover kit contains
two engine assemblies, three axle assemblies, four balsa
blocks, and two color kits; its pro®t is $15 Their racing
kit contains one engine assembly, two axle assemblies,
two balsa blocks, and three color kits; its pro®t is
$9.50 Sales have been slow and Sears offers to buy
all that Model-Kit can supply using components in
stock if Model-Kit will sell all earthmover kits over
60 at a $5 discount and all racing kits over 50 at a $3
discount Determine which mix of model kits to sell to
Sears to maximize pro®t using components in stock
Solution The numbers 60 and 50 are thresholds for
earthmover and racing kits As production increases
across the threshold, the return per unit diminishes
Let E and R denote the number of earthmover and
racing kits to sell to Sears Let E1 denote the number
of earthmover kits to be sold at the regular price and
let E2 denote the number to be sold for $5 less:
E2 E E1 Let R1 and R2 play similar roles for
Because E1 contributes more pro®t per unit than E2,
the model will automatically increase E1 to 60 before
E2 becomes greater than zero A similar remarkapplies to racing kits
OBJECTIVE FUNCTION VALUE 1667.50000 VARIABLE VALUE
or annual basis The following tables provide lists ofspace required in thousands of square feet and cost ofspace in dollars per thousand square feet per leaseperiod Quarterly lease periods begin January 1,April 1, July 1, and October 1 Half-year lease periodsbegin February 1 and August 1 Formulate an appro-priate LP model to lease space at minimal cost for acalendar year
MonthSpacereqd
1
10 152 233 324 435 526 507 568 409 1025 1115 1210
Leasing period Dollars per 1000 ft2
MonthQuarterHalf-yearYear
3005007001000
SolutionLet MI no of thousands of square feet leased formonth I, 1 < I < 12:
Let QI no of thousands of square feet leased forquarter I, 1 < I < 4:
Let HI no of thousands of square feet leased forhalf year I, I 1; 2:
Let Y no of thousands of square feet leased forthe year
Minimize 10 Y + 7 H1 + 7 H2 + 5 Q1 + 5 Q2 +
5 Q3 + 5 Q4 + 3 M1 + 3 M2 + 3 M3 + 3 M4 +
3 M5 + 3 M6 + 3 M7 + 3 M8 + 3 M9 + 3 M10 +
3 M11 + 3 M12 Subject to 2) Y + Q1 + M1 10 3) Y + H1 + Q1 + M2 15 4) Y + H1 + Q1 + M3 23 5) Y + H1 + Q2 + M4 32 6) Y + H1 + Q2 + M5 43
Trang 11I have included a solution in the form of output
from a software package so we can discuss it
Reduced costs and dual prices are discussed in books
on linear programming If you are going to use LP
with some frequency it is worth learning about the
algebra and geometry of LP If you simply want to
know whether an LP may have multiple solutions, a
®rst clue is a decision variable with value equal to zero
and reduced cost equal to zero: that does not occur
below A second clue is a slack or surplus equal to
zero with corresponding dual price equal to zero:
that does occur below
OBJECTIVE FUNCTION VALUE 510.000000
There are many ways to look for multiple optimal
solutions I put the objective function equal to C (for
cost) and added this as a constraint I was going to add
the constraint C 510 and use a new objective
func-tion to search for another solufunc-tion, but look what the
®rst change caused to happen
Minimize 10 Y + 7 H1 + 7 H2 + 5 Q1 + 5 Q2 +
5 Q3 + 5 Q4 + 3 M1 + 3 M2 + 3 M3 + 3 M4 +
3 M5 + 3 M6 + 3 M7 + 3 M8 + 3 M9 + 3 M10 +
3 M11 + 3 M12 Subject to 2) Y + Q1 + M1 >= 10 3) Y + H1 + Q1 + M2 >= 15 4) Y + H1 + Q2 + M3 >= 23 5) Y + H1 + Q2 + M4 >= 32 6) Y + H1 + Q2 + M5 >= 43 7) Y + H1 + Q2 + M6 >= 52 8) Y + H1 + Q3 + M7 >= 50
9 ) Y + H2 + Q3 + M8 >= 56 10) Y + H2 + Q3 + M9>= 40 11) Y + H2 + Q4 + M10 >= 25 12) Y + H2 + Q4 + M11 >= 15 13) Y + H2 + Q4 + M12 >= 10 14) 10 Y + 7 H1 + 7 H2 + 5 Q1 + 5 Q2 +
5 Q3 + 5 Q4 + 3 M1 + 3 M2 + 3 M3 +
3 M4 + 3 M5 + 3 M6 + 3 M7 + 3 M8 +
3 M9+ 3 M10 + 3 M11 + 3 M12 - C = 0 OBJECTIVE FUNCTION VALUE 510.00000
C 510 The following solution appeared
OBJECTIVE FUNCTION VALUE 18.000000
Trang 12The point of this discussion is to make you aware of
the possibility of multiple optimal solutions and
indi-cate how you can begin to look for them
Example 10 A Loading Problem
Information Provided Quick Chemical Corporation
supplies three types of chemicals to Traction Tire
Company The chemicals are shipped on pallets loaded
with one type of chemical Type 1, 2, and 3 pallets
weigh 2000, 2500, and 3000 lb, respectively
Currently, Quick has 50 type 1 pallets, 100 type 2,
and 30 type 3 pallets in stock Quick ships pallets in
a truck which can hold 11,000 lb Quick requires that
its truck be fully loaded How many truckloads can
Quick deliver using its current stock?
Solution There are four ways to load the truck
Let L1 no of trucks loaded with one type 1 pallet
and three type 3 pallets
Let L2 no of trucks loaded with four type 1
pal-lets and one type 3 pallet
Let L3 no of trucks loaded with three type 1
pallets and two type 2 pallets
Let L4 no of trucks loaded with two type 2
pal-lets and 2 type 3 palpal-lets
This solution is not integer valued, so we change the
value of L3 to 16 to get an integer-valued solution and
claim that this solution is optimal: the value of the best
LP solution is less than 32, so the value of any integer
solution will be at most 31; we have an integer solution
with value equal to 31
Example 11 A Shipping ProblemInformation Provided A company has a large order
to ship There are four types of products to be shipped.The company transports the products from its factory
to a dock Then the orders are transported from thedock to customers by boat The boat leaves the dockeach Sunday and returns to the dock the followingFriday The company uses two trucks, say A and B,
to transport products to the dock The trucks can holdthe following quantities of the four types of products:
2, 7500 of type 3, and 8000 of type 4 products.Determine how to ship the order as quickly andcheaply as possible
SolutionLet AI no of truckloads of type I to transport tothe dock on truck A, I 4
Let BI no of truckloads of type I to transport tothe dock on truck B, I 4
Minimize T Subject to 2) 25 A1 + 42 B1 >= 7000 3) 20 A2 + 37 B2 >= 6500 4) 15 A3 + 34 B3 >= 7500 5) 10 A4 + 31 B4 >= 8000 6) A1 + A2 + A3 + A4 - T <= 0 7) B1 + B2 + B3 + B4 - T <= 0
Trang 13OBJECTIVE FUNCTION VALUE 522.985100
Since it takes 14 weeks to process the order, we add
the constraint T < 560 and change the objective
function to get an LP model which will ®nd the
mini-mal cost of transporting the order to the dock in 14
We cannot send parts of a truck to the dock; so we
don't have a solution Seven years ago my computer
was much slower and my software did not have a GIN
capability, so I wrote: ``But we do have some
informa-tion which we can use to get an approximate soluinforma-tion
The slack in constraint 6) tells me that we can increase
the number of loads which we send to the dock on
truck A Also, we can round one of the BIs up if we
round the other two down Rounding B3 down will
require sending truck A twice; but, we can decrease
B1 to 81 and increase A1 to 144, and we can decrease
B4 to 258 and increase A4 to 1 Consequently, I will
choose the approximate solution
solu-Exercise: Using Overtime to Fill a RushOrder Suppose that the trucks could be run a sixth8-hr day each week at a cost per hour $4 higher thanthose listed in the table How much would transporta-tion costs increase if the company were to use someovertime to transport the order to the dock in 12weeks?
Let CI no of overtime truckloads of type I totransport to the dock on truck A
Let DI no of overtime truckloads of type I totransport to the dock on truck B
Minimize 18 A1 + 16 A2 + 12 A3 + 10 A4 +
26 B1 + 26 B2 + 18 B3 + 16 B4 + 22 C1 +
20 C2 + 16 C3 + 14 C4 + 30 D1 + 30 D2 +
22 D3 + 20 D4 Subject to 2) 25 A1 + 42 B1 + 25 C1 + 42 D1 >= 7000 3) 20 A2 + 37 B2 + 20 C2 + 37 D2 >= 6500 4) 15 A3 + 34 B3 + 15 C3 + 34 D3 >= 7500 5) 10 A4 + 31 B4 + 10 C4 + 31 D4 >= 8000 6) A1 + A2 + A3 + A4 - T <= 0
7) B1 + B2 + B3 + B4 - T <= 0 8) T <= 480
9 ) C1 + C2 + C3 + C4 <= 9 6 10) D1 + D2 + D3 + D4 <= 96 OBJECTIVE VALUE
Trang 14the optimal LP solution What would be your
integer-valued solution?
Example 12 Using INT Variables to Model
Increasing Return ThresholdsInformation Provided Speedway Toy Company man-
ufactures tricycles and wagons, which require 17 and 8
min to shape and 14 and 6 min to ®nish Tricycles
require one large wheel and two small wheels; wagons
require four small wheels Speedway has decided to
allocate up to 520 hr of shaping time and up to 400 hr
of ®nishing time to these two products during the next
month Speedway buys wheels from Rollright
Corporation, which sells large wheels for $5 and small
wheels for $1 Speedways has been selling its entire
out-put of these products to Toy World, Inc at a pro®t of
$11 and $5 per unit The holidays approach; Rollright
offers to sell small wheels in excess of 6000 for $0.75
each, and Toy World is willing to pay a $2 bonus for
tricycles in excess of 1200 Speedway wants to plan
production of tricycles and wagons for the next month
Solution
Let T no of tricycles to produce
Let W no of wagons to produce
Let S1 no of small wheels to purchase at $1 each
Let S2 no of small wheels to purchase at $0.75
each
Let T2 no of tricycles to produce in excess of
1200
Let T1 T T2
We have thresholds of 6000 and 1200 for small
wheels and tricycles However, in contrast with
Example 8, as we cross these thresholds the return per
unit increases An LP model for this situation like the
one used for Example 8 would prefer to use S2 and T2
rather than S1 and T1, so we will use two INT
vari-ables, X and Y, to force S2 and T2 to have value equal
to zero until S1 and T1 reach 6000 and 1200
Since no more than 2000 tricycles can be produced and
no more than 4000 wagons can be produced, 14,000 is
an upper bound for S2 in constraint 7 and 800 is an
upper bound for T2 in constraint 9 If S1 is less than
6000, then constraint 6 requires that X be equal tozero, which forces S2 to be equal to zero according
to constraint 7 If S1 is equal to 6000, then X can beequal to 1, which permits S2 to be any nonnegativenumber no greater than 14000 Similarly, constraints
8 and 9 reqire that Y be zero and T2 be zero if T1 <
1200 and permit T2 to be any number between zeroand 800 if T1 1200:
Example 13 INT VariablesInformation Provided A paper-recycling machine canproduce toilet paper, writing pads, and paper towels,which sell for 18, 29, and 25 cents and consume 0.5,0.22, and 0.85 kg of newspaper and 0.2, 0.4, and0.22 min Each day 10 hr and 1500 kg of newspaperare available; at least 1000 rolls of toilet paper and
400 rolls of paper towels are required If any writingpads are manufactured, then at least 500 must bemade; moreover, the government will pay a bonus of
$20 if at least 1200 rolls of toilet paper are produced.The objective is to determine which mix of productswill maximize daily income
SolutionLet T no of rolls of toilet paper to produce in a
of toilet paper are produced
The model appears after some comments whichexplain how the INT variables work in the model.Constraints 6 and 7 take care of writing pads.Constraint 7 forces Y to be one if W > 0; I chose touse the number 3000 in constraint 7 because it is clearfrom constraint 3 that W 3000 whenever W is feas-ible; 1500 or any larger number would work equallywell Constraint 6 forces W to be 500 if Y > 0.Constraint 8, T 1200Z, permits Z to be one if
T 1200; the presence of the term 20Z in the objectivefunction causes the value of Z to pop up to 1 as soon
as the value of T reaches 1200
Maximize 20 Z + 18 T + 29W + 25 P Subject to
2) 5 T + 22 W + 85 P <= 1500 3) 2 T + 4 W + 22 P <= 600 4) T >= 1000
5) P >= 400 6) -500 Y + W >= 0
Trang 15Example 14 GIN Variables
Information Provided A product is assembled from
three parts that can be manufactured on two types of
machines, A and B Each assembly uses one part 1, two
part 2, and one part 3 There are three type A machines
and ®ve type B machines Each machine can run up to
16 hr per day A machine can process at most one type
of part during the day The number of parts
manufac-tured by each type of machine per hour is summarized
below
Part
No of parts per hourMachine A Machine B1
2
3
1215Ð
61225
Management wants a daily schedule for the machines
that will produce parts for the maximal number of
There are six 4 hr shifts for cooks each day Cookswork two consecutive shifts The minimum number ofcooks needed on a shift is tabulated below; the num-bers do not change from day to day Cooks are paidthe same hourly salary, independent of shifts worked
1: Midnight to 4 AM2: 4 AM to 8 AM3: 8 AM to noon4: Noon to 4 PM5: 4 PM to 8 PM6: 8 PM to midnight
6121612148
Waitresses are hired to work one 6 hr shift per day.They are paid for 6 hr per day for ®ve consecutive days,then they are off for two days They are all paid thesame amount per day of work The following schedule
of minimal waitress hours needed per day follows
SundayMondayTuesdayWednesdayThursdayFridaySaturday
400400400400400200None
Up to 50% of the waitresses who are off on a givenday can be hired as overtime employees that day Ifthey are hired for a day of overtime, they are expected
to be available to work up to 6 hr that day and they arepaid 150% of a regular day's pay
Solution Scheduling cooks and waitresses are tively separate problems Cooks will be scheduled ®rst.Since cooks are all paid the same it suf®ces to minimizethe total number of cooks needed each day
effec-Cooks Let NI number of cooks to begin ing at start of shift I, I < 6, and let N denote thetotal number of cooks needed each day
work-Minimize N Subject to 2) N - N1 - N2 - N3 - N4 - N5 - N6 =0 3) N1 + N6 >= 6
Trang 16The LP solution turned out to have integer values,
which was ®ne There are many alternate solutions to
the problem
Waitresses To determine the number of
regular-time waitresses needed, we will determine the number
of waitresses that will begin their work week on each
day of the week, and we will determine the number
of waitresses to work overtime on each day of the
week
Starting with Sunday corresponding to day 1, let
WI denote the number of waitresses to begin their
regular work week on day I, let DI denote the total
number of regular time waitresses working on day I,
and let OI denote the number of waitresses to work
to the numbers listed in the table for the correspondingday Because waitresses are available to work 6 hr perday, making these changes does not change the solu-tion, but does encourage the solution to be intergervalued, which we need Before making these changes,the solution was a mess After making them, it was stillnot integer valued, however the optimal value of the
LP was 386.1, which implies that an integer solutionwith objective function value 386.5 is optimal I addedthe constraint ``GIN W'' and got the following integersolution
NEW INTEGER SOLUTION OF 386.5
It would like to have 1000, 230, 430, and 1400 boxcarsper month at the power plants The suppliers can pro-vide 800, 600, and 1000 boxcars per month The follow-ing table lists costs (including shipping) for a boxcar ofcoal delivered from a supplier to a power plant
Trang 17Denver Fort Collins Pueblo Salt LakeColorado
Utah
Wyoming
403530360
441510340
458550380
430350410
Solution The total supply is 2400 boxcars and the
total demand is 3030 boxcars, so total demand cannot
be met Consequently, we split the demand for each
city into two demands, a minimal demand to keep the
power plant running and an optional demand which
represents the number of boxcars above minimal
demand that the city would like to receive The
total minimal demand is 1160 boxcars We will use
available supply to meet the minimal demands
Consequently, there are 1240 boxcars available to
meet some optimal demand There are 630 boxcars
of optimal demand that cannot be met We will
intro-duce a dummy supply of 630 boxcars to represent
unmet demand, and we will introduce a big M cost
of shipping from the dummy supply to the minimal
demands to insure that minimal demands are met
from real supplies The costs from the dummy supply
to the optimal demand will be put equal to zero, since
we are not really shipping anything A transportation
tableau follows
Denmin Denopt Fortmin Fortopt Peubmin Peubopt minSL opt SupplySLColorado
4035303600600
441510340M80
4415103400150
458550380M120
4585503800310
430350410M560
4303504100840
80060010006603060
Example 17 ``Everyone Wants More Money''
Information Provided Four research centers are
applying for grants from four government agencies
The centers need 20, 30, 40, and 50 million dollars
next year to keep operating They would each like an
in®nite amount of money The agencies have 40, 30,
30, and 80 million dollars available for research grants
to the four centers next year The government has
decided to keep the centers operating and has prepared
the following table of estimated bene®t per million
2685
5397
7364
66410
Solution This situation can also be modeled as atransportation problem It can be modeled as a ``max-imize'' (bene®t) transportation problem, or as a ``mini-mize'' transportation problem after changing thebene®ts to costs by multiplying them by 1, andthen adding 10 to each of these negative numbers toget nonnegative numbers We present a transportationtableau for the minimize formulation below The fourresearch centers require a total of 140 million dollars tokeep operating, this number is the sum of the minimalneeds; enough money to meet minimal needs will beshipped from the agencies to the research centers Inaddition to this 140 million, there are 40 million dollarsavailable to meet optional demand (wants) by theresearch centers Consequently, even though theresearch centers might prefer more, the most that anyone can get is 40 million dollars; thus, the optionaldemands are set at 40 and a dummy supply of 120 isincorporated to balance total supply with totaldemand We use 20 as a big M to keep from shippingarti®cial money to meet minimal demands The mini-mal and optional demands of research center I aredenoted by MI and OI
M1 O1 M2 O2 M3 O3 M4 O4 Supplies1
234DummyDemands
84252020
8425040
57132030
5713040
37462040
3746040
44602050
4460040
40303080120Ð
A solution in the form of an allocation table lows
fol-M1 O1 M2 O2 M3 O3 M4 O4 Supplies1
234Dummy
Ð20ÐÐÐ
Ð10ÐÐ30
ÐÐ30ÐÐ
ÐÐÐÐ40
40ÐÐÐÐ
ÐÐÐÐ40
ÐÐÐ50Ð
ÐÐÐ3010
40303080120
Trang 18Example 18 A Multiperiod Problem
Information Provided A company produces two
pro-ducts, which we denote by P and Q During the next
four months the company wishes to produce the
fol-lowing numbers of products P and Q
Product
No of productsMonth 1 Month 2 Month 3 Month 4P
Q 40006000 50006000 60007000 40006000
The company has decided to install new machines on
which to produce product Q These machines will
become available at the end of month 2 The company
wishes to plan production during a four-month
change-over period Maximum monthly production of product
Q is 6000 during months 1 and 2, and 7000 during
months 3 and 4; maximum total monthly production is
11,000 during months 1 and 2, and 12,000 during
months 3 and 4 Manufacturing costs of product Q are
$15 per unit less during months 3 and 4 Also, during the
changeover period, units of product Q can be delivered
late at a penalty of $10 per unit per month Monthly
inventory costs are $10 per unit per month for product
P and $8 per unit per month for product Q Formulate
an LP to minimize production, penalty, and inventory
costs during the four-month changeover period
Solution Let PI and QI denote the numbers of units
of products P and Q produced during month I,
1 I 4 Let XI denote the number of units of
pro-duct Q in inventory at the end of month I, and let YI
denote the number of units of product Q backlogged at
the end of month I (i.e., not able to be delivered by the
end of month I)
Constraints:
1) P1 >= 4 (Production for month 1)
2) P1 + P2 >= 9(Production for months 1 and 2)
3) P1 + P2 + P3 >= 15 (Production for months 1-3)
4) P1 + P2 + P3 + P4 = 19(Production for months 1-4)
Constraints 5±10 are production capacity constraints
Constraints 11±13 model the effects of production of Q
during months 1±3, and constraint 14 is the production
requirement on Q for months 1±4: backlogging is onlypermitted during the changeover period, and inventory
at the end of month 4 would incur an unnecessary cost.Constraints 12 and 13 can be written in a recursiveformulation which is useful to know about; we do thatnow Using constraint 11 we replace Q1 6 in con-straint 12 by X1 Y1 to get
typ-Objective function The objective (in thousands ofdollars) is to
Minimize f10 3P1 2P2 P3 4 9 15g f8 X1
X2 X3g f10 Y1 Y2 Y3gf15 Q3 Q4g
The ®rst block in the objective function representsinventory cost for product P; the number 28 can bedeleted because it is a constant Likewise, productioncost for product P is a constant which is ignored in theobjective function The next two blocks representinventory and backlogging costs for product Q Thelast block represents production savings due to manu-facturing product Q during periods 3 and 4 Becauseboth XI and YI incur a positive cost, at most one ofeach pair will be positive
Example 19 Another Multiperiod ProblemInformation Provided A cheese company is sailingalong smoothly when an opportunity to double itssales arises, and the company decides to ``go for it.''The company produces two types of cheese, Cheddarand Swiss Fifty experienced production workers havebeen producing 10,000 lb of Cheddar and 6000 lb ofSwiss per week It takes one worker-hour to produce
10 lb of Cheddar and one worker-hour to produce 6 lb
of Swiss A workweek is 40 hr Management hasdecided to double production by putting on a secondshift over an eight-week period The weekly demands(in thousands of pounds) during the eight-week periodare tabulated below
WeekCheddarSwiss
1106
2107.2
3128.4
41210.8
51610.8
61612
72012
82012
Trang 19An experienced worker can train up to three new
employees in a two-week training period during
which all involved contribute nothing to production;
nevertheless, each trainee receives full salary during the
training period One hundred experienced (trained)
workers are needed by the end of week 8 Trained
workers are willing to work overtime at time and a
half during the changeover period Experienced
work-ers earn $360 per week Ordwork-ers can be backlogged
dur-ing the transition period at a cost of $0.50 per pound
for Cheddar and $0.60 per pound for Swiss for each
week that shipment is delayed All back orders must be
®lled by the end of week 8
Solution We will start by setting up an LP model
Let CI no of workers to make Cheddar during
Let TI no of workers to begin training new
workers during week I
Let NI no of new workers to begin training
dur-ing week I
Let AI no of thousands of pounds of Cheddar to
backlog at end of week I
Let BI no of thousands of pounds of Swiss to
backlog at end of week I
(also see Page 316)
This solution is not satisfactory because we cannot use
parts of experienced workers to train parts of new
employees What would you do next?
Example 20 Sometimes It Pays to Permit Idle
TimeInformation Provided ATV corporation has pre-
dicted delivery requirements of 3000, 6000, 5000, and
2000 units in the next four months Current regular
time workforce is at the 4000 units per month level
At the moment there are 500 units in inventory At the
end of the four months the company would like its
inventory to be 500 units and its regular time
work-force to be at the 3000 units per month level Regular
time workforce has a variable cost of $100 per unit
Overtime can be hired in any period at a cost of $140
per unit Regular time workforce size can be increased
from one month to the next at a cost of $300 per unit
of change in capacity, it can be decreased at a cost of
$80 per unit There is a charge of $5 per unit for
inven-tory at the end of each month
SolutionLet RK no of units of regular time workforce inperiod K
Let OK no of units of overtime workforce inperiod K
Let IK no of units of inventory at end of periodK
Let HK no of units of regular time workforcehired at beginning of period K
Let FK no of units of regular time workforce
®red at beginning of period K
Two models are presented below; the ®rst requiresthat all production capacity be utilized to produceunits of the product, while the second model permitssome of the workforce to be idle Seepage 317.Example 21 An Assignment Problem
This is the last example in the linear programmingsection of this chapter The variables are actuallyINT variables; however, the LP solution to themodel turns out to be integer valued, so the LP solu-tion solves the INT-variable problem We will alsopresent a dynamic-programming model for this situa-tion in Example 25, the concluding example in the nextsection
Information Provided A corporation has decided tointroduce three new products; they intend to produce
2000, 1200 and 1600 units of products 1, 2, and 3weekly The corporation has ®ve locations where theproducts could be produced at the following costs perunit
Product
Unit production costs
123
906276
825870
926480
8456Ð
8658Ð
Each location has ample production capacity; ever, they have decided to produce each product atonly one location, and to produce no more than oneproduct at any location: three locations get a productand two locations get no product Product 3 can only
how-be produced at locations 1, 2, or 3
Solution We will formulate an LP model to assignproducts to plants In actuality, the variables are INTvariables, but we will run the LP model without requir-
Trang 20Minimize 540 O1 + 540 O2 + 540 O3 + 540 O4 + 540 O5 + 540 O6 + 540 O7 + 540 O8 + 500 A1 + 500 A2 + 500 A3 + 500 A4 + 500 A5 + 500 A6 + 500 A7 + 600 B1 + 600 B2 + 600 B3 + 600 B4 + 600 B5 + 600 B6 + 600 B7 + 2880 N1 + 2520 N2 + 2160 N3 + 1800 N4 + 1440 N5 + 1080 N6 + 720 N7
OBJECTIVE FUNCTION VALUE 131118.800
Trang 21ing that the variables be INT variables and see what
happens
Let
AIJ 1
denote that product I is assigned to plant J
The cost of assigning production of a product to a
plant is determined because the numbers of items to be
produced are given parameters of the problem
Minimize 1800 A11 + 1640 A12 + 1840 A13 +
1680 A14 + 1720 A15 + 744 A21 + 696 A22 +
768 A23 + 672 A24 + 696 A25 + 1216 A31 +
1120 A32 + 1280 A33
Subject to
2) A11 + A12 + A13 + A14 + A15 = 1
3) A21 + A22 + A23 + A24 + A25 = 1
4) A31 + A32 + A33 = 1
5) A11 + A21 + A31 <= 1
6) A12 + A22 + A32 <= 1
7) A13 + A23 + A33 <= 1
Since the solution to the LP is an INT variable
solu-tion, we know that it is an optimal solution to the
assignment problem that we wished to solve
2.2 DYNAMIC PROGRAMMING
2.2.1 Introduction
Like linear programming, dynamic programming (DP)
can be an effective way to model situations which have
an appropriate structure This section begins by
intro-ducing three characteristics of problems which ®t into
a (backward) dynamic programming format and
out-lining the steps involved in formulating a DP model
Next an example is used to explain the terminology
(stages, states, etc.) of DP Then three more examples
are used to illustrate some types of situations which ®t
into a dynamic programming format, and show you
how to use DP to model these situations
2.2.2 Three Characteristics Necessary for a(Backward) DP Model
1 The problem can be organized into a ®nitesequence of stages, with a decision to be made
at each stage A set of initial states enters astage A decision transforms each initial state
to a terminal state; the terminal state leavesthe stage and becomes an initial state for thenext stage Suppose there are n stages for a pro-blem Then a solution to the problem amounts
to making a sequence of n decisions, one foreach stage This sequence of decisions is called
an optimal policy or strategy for the problem
2 A key characteristic of problems which can bemodeled effectively by dynamic programming isthe Markov property or principle of optimality:given any initial state at any stage, an optimalpolicy for the successive stages does not depend
on the previous stages (i.e., an optimal policyfor the future does not depend on the past)
3 The optimal decisions for the ®nal stage aredetermined (known in advance)
When these three properties are satis®ed, the blem can be solved (dynamically) by moving backwardstage by stage, making an optimal decision at eachstage
pro-2.2.3 Formulating a DP ModelThis includes four steps:
1 Specifying a sequence of stages
2 Noting that the ®nal stage policies are mined
deter-3 Checking that the Markov property is satis®ed
4 Formatting each stage; this involves
a Specifying initial states
b Specifying how initial states are formed
trans-c Specifying terminal states
d Specifying a decision rule that determinesthe optimal terminal state (or states) corre-sponding to each initial state at each stage.2.2.4 Examples 22±25
Example 22 Travel Plans
We are back in the 1800s and wish to travel by coach for the least possible cost from San Francisco toNew York There are four time zones to cross and wehave several alternative possible stagecoach rides