Professional Documents
Culture Documents
Examples and Solution
Examples and Solution
1- Ken and Larry, Inc., supplies its ice cream parlors with three flavors of ice
cream: chocolate, vanilla, and banana. Due to extremely hot weather and a
high demand for its products, the company has run short of its supply of
ingredients: milk, sugar, and cream. Hence, they will not be able to fill all the
orders received from their retail outlets, the ice cream parlors. Due to these
circumstances, the company has decided to choose the amount of each flavor
to produce that will maximize total profit, given the constraints on supply of
the basic ingredients.
The chocolate, vanilla, and banana flavors generate, respectively, $1.00, $0.90,
and $0.95 of profit per gallon sold. The company has only 200 gallons of milk,
150 pounds of sugar, and 60 gallons of cream left in its inventory.
Solution:
Let
C = gallons of chocolate ice cream produced,
V = gallons of vanilla ice cream produced,
B = gallons of banana ice cream produced.
Each full-time employee earns $13 per hour, while each part-time employee earns $10
per hour. Management wishes to know what mix of each of the three types of gloves
to produce per week, as well as how many full-time and how many part-time workers
to employ. They would like to maximize their net profit — their gross profit from
sales minus their labor costs.
Solution:
Letting
M = number of men’s gloves to produce per week,
W = number of women’s gloves to produce per week,
C = number of children’s gloves to produce per week,
F = number of full-time workers to employ, and
P = number of part-time workers to employ,
formulate a linear programming model for this problem, and put it into standard
form (with only constraints).
Choose x1 and x2 to
Min Z= 3x1 + 2x2
S.T
2x1 + x2 10
-3x1 + 2x2 6
x1 + x2 6
x1 , x2 0.
Solution:
[Flipping the constraint to ]
You must note that the right hand side of any constraint
MUST be positive not negative so to make it positive
multiply the constraint with -1 to change the sign and
change it to greater than (-3x1 + 2x2 6
Must become 3x1 - 2x2 6 after multiplying by -1)
(b) After putting the problem in (a) in standard form, construct its
dual.
Solution:
YOU MUST MAKE A MATRIX AND THE TRANSPOSE.
Solution:
X1 = number of cheese burgers produced.
X2 = number of turkey burgers produced.
X3 = number of double burgers produced.
The problem is then: find values for x1, x2, and x3 to solve:
Max 4X1+5.5X2+8X3
S.T.
X2/4 ≤500
X1+ X3 ≤ 2000
X1/4+X3/2 ≤ 800
X1+X2+X3 ≤ 2500
X3≥100
X1, X2, X3 ≥ 0
Tutorial solutions
1. Joe's Garage specializes in oil changes and tune-ups. Profit per oil change is $7 and
$15 per tune-up. Joe's has a fleet account customer, which guarantees at most 30 oil
changes per week. Each oil change requires 20 minutes labor and $8 in supplies. A
tune-up takes one hour and costs Joe's $15 in supplies. Mechanics are paid $10 per
hour and Joe's currently employs two mechanics working 40 hours each per week.
Every week Joe's orders $1,750 in supplies, and Joe's wishes to maximize profit.
The Solution
X1 = Oil changes
X2 = Tune-ups
:Subject to
X1 30 Fleet Account
20X1 + 60X2 4800 Labor time
8X1 + 15X2 1750 Materials
X1, X2 0
Standard form
Z-7X1-15X2=0
X1+S1=30
20X1+60X2+S2=4800
8X1+15X2+S3=1750
X1,X2,S1,S2,S3 0
BASIC X1 X2 S1 S2 S3 RHS
S1 1 0 0 0 0 30
S2 20 60 0 1 0 4800
S3 8 15 0 0 1 1750
Z -7 -15 0 0 0 0
S1 1 0 0 0 0 30
x2 1/3 1 0 1/60 0 80
S3 3 0 0 -1/4 1 550
Z -2 0 0 1/4 0 1200
Pivot row= 1 0 0 0 0 30
BASIC X1 X2 S1 S2 S3 RHS
X1 1 0 0 0 0 30
X2 0 1 0 1/60 0 70
S3 0 0 0 0 0 460
Z 0 0 0 1/4 0 1260
Solution:
X1: refinery 1
X2: refinery 2
BASIC Y1 Y2 Y3 S1 S2 RHS
BASIC Y1 Y2 Y3 S1 S2 RHS
Solution:
The standard form is
Z-2X1-X2+3X3-5X4=0
X1+2X2-2X3+4X4 +S1
2X1-X2+X3+2X4 +S2
4X1-2X2+X3-X4 +S3 10
X1,X2,X3,S1,S2,S3 ≥ 0
BASIC X1 X2 X3 X4 S1 S2 S3 RHS
S1 1 2 -2 4 1 0 0 40
S2 2 -1 1 2 0 1 0 8
S3 4 -2 1 -1 0 0 1 10
Z -2 -1 3 -5 0 0 0 0
S1 -3 4 -4 0 1 -2 0 24
BASIC X1 X2 X3 X4 S1 S2 S3 RHS
Z 0.4 0 2 0 14 0.75 0 41
Solution:
1 2 3
3 2 5
2 2 0
BASIC Y1 Y2 S1 S2 RHS
S1 1 3 1 0 2/3
S2 2 2 0 1 1
Z -3 -5 0 0 0
Pivot row= 1/3 1 1/3 0 2/3
BASIC Y1 Y2 S1 S2 RHS
BASIC Y1 Y2 S1 S2 RHS
Y2 0 1 1/2 -0.7/3 ½
Z 0 0 1 1 4
X1 X2