Professional Documents
Culture Documents
Sample Problems Linear Prog
Sample Problems Linear Prog
In this case the question is how many acres of wheat and how many acres of rye should be planted.
First, the objective. The object is to maximize profits. Each acre of wheat brings in $500 and each
acre of rye brings in $300.
After getting the unknowns defined and the objective expressed, everything else is a constraint.
The first constraint is the acreage constraint. The farmer has only 10 acres to plant. So the total
number of acres has to be less than or equal to 10. There is another acreage constraint. The farmer
has to plant at least 7 acres.
The next constraint is the cost constraint. The farmer has only $1200 to spend on the planting.
Finally there is the time constraint. The planting has to be done in 12 hours. So the constraints are expressed as
The implied constraints tell us that the feasible solutions will all lie in the upper right quadrant of the plane.
Let us first graph the acreage constraints. The first acreage constraint has 10 for both the x and y intercepts.
Plot 10 on both the x and y axes, and connect the points with a straight line. Next decide which side of the line is the side
that contains solutions to the inequality. Pick a point which is not on the line. In this case the origin is the simplest such
point with which to work. Does the origin satisfy this constraint?
At the origin, no acres are planted. Does the farmer have enough acres for this? The answer is yes. So the origin is on the
right side of this line. Shade in all of the points in the upper right quadrant which are on the same side of the line as the
origin.
The lower acreage constraint has x and y intercepts which are both equal to 7.
In this case, the origin is not a solution to this constraint. At the origin, the farmer is not planting any acres of anything, but
this constraint says that the farmer needs to plant at least 7 acres. If the origin is not on the right side, the other side is the
right side. The region of feasible solutions has been cut down to the shaded area above.
In general, if both unknowns are on the same side and all the coefficients are positive, the line will have positive x and y
intercepts, and the side toward the origin will be the less than side and the side away from the origin will be the greater
than side.
Next graph the cost constraint. It has an x intercept of 6 and a y intercept of 12.
Since this is a "less than" constraint the side on the same side as the origin is shaded.
The feasible corner points are the ones at the corners of the shaded region. To find them we identify the
equations which are associated with the lines that intersect at the points.
x=5
y=2
so
A = (5, 2)
x=4
and
y=4
so
B = (4, 4)
y=5
x=2
so
C = (2, 5)
We see that none of the feasible corner points is on the upper acreage constraint, the fact that the farmer had
only 10 acres. It turns out to be what is called a superfluous constraint. The most number of acres that can be
planted is 8 by planting 4 acres of each crop. If all of the other constraints are satisfied, the farmer will
automatically be planting less than 10 acres.
A = (5, 2)
B = (4, 4)
C = (2, 5)
The winner is B:
The maximize the profit of $3200 is obtained by planting 4 acres of each crop.
If we think about it, this makes sense. C can be seen to be the least profitable corner point. You are planting the
fewest number of acres and you are planting more of the less profitable rye and less of the more profitable
wheat. The real question is whether A or B will be more profitable. At B you are planting more acres than at A,
but at A you are planting more of the more profitable wheat and less of the less profitable rye. One way to
decide is to actually compute the profit at both points and see which one would be best.
2. Agold processor has two sources of gold ore, source A and source B.
In order to keep his plant running, at least three tons of ore must be
processed each day. Ore from source A costs $20 per ton to process,
and ore from source B costs $10 per ton to process. Costs must be
kept to less than $80 per day. Moreover, Federal Regulations require
that the amount of ore from source B cannot exceed twice the amount
of ore from source A. If ore from source A yields 2 oz. of gold per ton,
and ore from source B yields 3 oz. of gold per ton, how many tons of
ore from both sources must be processed each day to maximize the
amount of gold extracted subject to the above constraints?
Steps
In this case they are looking for the number of tons of ore from the two sources which should be processed each
day to maximize the amount of gold extracted.
The objective is to maximize the amount of the gold yield. Since each ton of ore from source A yields 2oz. of
gold and each ton of ore from source B yields 3oz. of gold, the amount of gold recovered will be
2x + 3y
After getting the unknowns and the objective out of the way, everything else in the problem is a constraint. The
constraints are the
processing
cost
federal regulations
Of course there are also the implied constraints
The implied constraints tell us that the graph will be in the upper right quadrant of the plane.
Since this is a "greater than" constraint the side of the line where the x's and y's get bigger will be the correct
side. This region goes on forever.
the x intercept is 80/20 = 4, and the y intercept is 80/10 = 8. There is enough money to process 4 tons of ore
from source A if we don't process any ore from source B, whereas, if we just use ore from source B, there will
be enough money to process 8 tons.
Since this is a "less than" constraint, the points on the side where x and y get small should be shaded. The set of
points which satisfy both of theses constraints are shaded above.
To tell which side of this line is which, notice that the x's are on the large side of the inequality and the y's are
on the small side. So we shade the side of the line where the x's are big and the y's are small.
We label the lines with the equations from which they come so that we can
x + 2x = 3
3x = 3
x=1
A = (1, 2)
Again, where we see a y we substitute 2x, and the first equation becomes
20x + 10(2x) = 80
20x + 20x = 80
40x = 80
x=2
B = (2, 4)
C is the x intercept for x + y = 3, so
C = (3, 0)
D = (4, 0)
The maximum yield of gold is 16oz. by processing 2 tons of ore from source A and 4 tons from source B.
When you test the corner points at (100, 170), (200, 170), (200, 80), (120,
80), and (100, 100), you should obtain the maximum value of R = 650 at
(x, y) = (100, 170). That is, the solution is "100 scientific calculators and
170 graphing calculators".
You need to buy some filing cabinets. You know that Cabinet
X costs $10 per unit, requires six square feet of floor space,
and holds eight cubic feet of files. Cabinet Y costs $20 per
unit, requires eight square feet of floor space, and holds
twelve cubic feet of files. You have been given $140 for this
purchase, though you don't have to spend that much. The
office has room for no more than 72 square feet of cabinets.
How many of which model should you buy, in order to
maximize storage volume?
Naturally, x > 0 and y > 0. I have to consider costs and floor space
(the "footprint" of each unit), while maximizing the storage volume,
so costs and floor space will be my constraints, while volume will
be my optimization equation.
This system (along with the first two constraints) graphs as:
When you test the corner points at (8, 3), (0, 7), and (12, 0), you should
obtain a maximal volume of 100 cubic feet by buying eight of model X
and three of model Y.
A school is preparing a trip for 400 students. The company who is providing the transportation has 10 buses of
50 seats each and 8 buses of 40 seats, but only has 9 drivers available. The rental cost for a large bus is $800
and $600 for the small bus. Calculate how many buses of each type should be used for the trip for the least
possible cost.
x = small buses
y = big buses
x+y≤9
x≥0
y≥0
4 Find the set of feasible solutions that graphically represent the constraints.
5 Calculate the coordinates of the vertices from the compound of feasible solutions.
6 Calculate the value of the objective function at each of the vertices to determine which of them has the
maximum or minimum values.
The minimum cost is $6,200. This is acheived with 4 large and 5 small buses.
A B Minimal
Shirts 1 3 200
Pants 1 1 100
A transport company has two types of trucks, Type A and Type B. Type A has a refrigerated capacity of 20 m3
and a non-refrigerated capacity of 40 m3 while Type B has the same overall volume with equal sections for
refrigerated and non-refrigerated stock. A grocer needs to hire trucks for the transport of 3,000 m3 of
refrigerated stock and 4,000 m3 of non-refrigerated stock. The cost per kilometer of a Type A is $30, and $40
for Type B. How many trucks of each type should the grocer rent to achieve the minimum total cost?
x = Type A trucks
y = Type B trucks
A B Total
Refrigerated 20 30 3 000
Non-
40 30 4 000
refrigerated
x≥0
y≥0
4 Find the set of feasible solutions that graphically represent the constraints.
5 Calculate the coordinates of the vertices from the compound of feasible solutions.
6 Calculate the value of the objective function at each of the vertices to determine which of them has the
maximum or minimum values.
The minimum cost is $4,180. To achieve this 50 trucks of Type A and 67 trucks of Type B are needed.
A B Minimal
Shirts 1 3 200
Pants 1 1 100
x = Type A trucks
y = Type B trucks
A B Total
3
Refrigerated 20 30
000
Non- 4
40 30
refrigerated 000
x≥0
y≥0
4 Find the set of feasible solutions that graphically represent the constraints.
5 Calculate the coordinates of the vertices from the compound of feasible solutions.
6 Calculate the value of the objective function at each of the vertices to determine which of them has the
maximum or minimum values.
The minimum cost is $4,180. To achieve this 50 trucks of Type A and 67 trucks of Type B are needed.
A B Minimal
Shirts 1 3 200
Pants 1 1 100
A store wants to liquidate 200 of its shirts and 100 pairs of pants from last season. They have decided to put
together two offers, A and B. Offer A is a package of one shirt and a pair of pants which will sell for $30. Offer
B is a package of three shirts and a pair of pants, which will sell for $50. The store does not want to sell less
than 20 packages of Offer A and less than 10 of Offer B. How many packages of each do they have to sell to
maximize the money generated from the promotion?
A B Minimal
Shirts 1 3 200
Pants 1 1 100
x + 3y ≤ 200
x + y ≤ 100
x ≥ 20
y ≥ 10
4 Find the set of feasible solutions that graphically represent the constraints.
5 Calculate the coordinates of the vertices from the compound of feasible solutions.
6 Calculate the value of the objective function at each of the vertices to determine which of them has the
maximum or minimum values.
f(x, y) = 30 · 20 + 50 · 10 = $1,100
f(x, y) = 30 · 90 + 50 · 10 = $3,200
f(x, y) = 30 · 20 + 50 · 60 = $3,600