You are on page 1of 5

Oreoluwa Adediwura – K00495516

Question 2
1a) Please formulate as a linear program.

Solution;

Decision Variables
 x1 = gallons of orange juice
 x2 = gallons of banana juice
 x3 = gallons of pineapple juice

Objective Function
Z = (22P1 +25P2 + 23P3 ) - (15J +17B + 20C)-(10M)

Constraints
1. Sugar Content: The minimum sugar content is 17% and the maximum is 21%.
0.10x1 + 0.15x2 + 0.20x3 ≥ 0.17(x1+x2+x3)
0.10x1 + 0.15x2+ 0.20x3 ≥ 0.17(x1+x2+x3)
2. Fiber Content: The fiber content should be at least 3%.
0.13x1+0.20x2+0.27x3 ≥ 0.03(x1+x2+x3)
3. Banana Inventory: Banana content should be greater than 200 gallons.
x2 ≥ 200
4. Pineapple Usage: Pineapple usage should be less than 500 gallons.
x3≤500
5. Total Juice Production: To satisfy the requirement of producing 12,000 juice packages, with
each package containing 8 fl oz or 0.0625 gallons:
x1+x2+x3=12,000×0.0625
x1+x2+x3=750
6. Non-negativity Constraints: x1,x2,x3≥0

L.P. Model

min 0.5x1 + 0.8x2 + 0.9x3

s.t.
-0.07x1 + 0.02x2 + 0.03x3 >= 0
-0.11x1 -0.06x2 - 0.01x3 <= 0
0.1x1 + 0.17x2 + 0.24x3 >= 0

x2 >= 200
x3 <= 500
x1 + x2 + x3 = 750
x1 >= 0
x2 >= 0
x3 >= 0End
LP MODEL SOLUTION

Global optimal solution found.


Objective value: 550.0000
Infeasibilities: 0.000000
Total solver iterations: 2
Elapsed runtime seconds: 0.14

Model Class: LP

Total variables: 3
Nonlinear variables: 0
Integer variables: 0

Total constraints: 10
Nonlinear constraints: 0

Total nonzeros: 20
Nonlinear nonzeros: 0

Variable Value Reduced Cost


X1 166.6667 0.000000
X2 583.3333 0.000000
X3 0.000000 0.6666667E-
01

Row Slack or Surplus Dual Price


1 550.0000 -1.000000
2 0.000000 -3.333333
3 53.33333 0.000000
4 115.8333 0.000000
5 383.3333 0.000000
6 500.0000 0.000000
7 0.000000 -0.7333333
8 166.6667 0.000000
9 583.3333 0.000000
10 0.000000 0.000000
Lindo Result Summary
Production Plan for Juice Production:
Orange Juice (x1):
Use 166.6667 gallons.
Banana Juice (x2):
Use 583.3333 gallons. This meets the company's requirement to have more than 200 gallons due to the
recent banana inventory.
Pineapple Juice (x3):
Use 0 gallons. This is in line with the desire to minimize costs as pineapple juice is the most expensive,
and there's also a constraint to use less than 500 gallons.

Total Cost Calculation: Using the costs provided:


Orange juice costs 50 cents per gallon.
Banana juice costs 80 cents per gallon.
Pineapple juice costs 90 cents per gallon.
Total Cost = (166.6667 gallons * $0.50) + (583.3333 gallons * $0.80) + (0 gallons * $0.90) = $83.33335
+ $466.66664 = $550.0000.

In conclusion, to achieve the objective of a minimum cost while satisfying all given constraints, the
company should produce a juice mix consisting of approximately 166.7 gallons of orange juice, 583.3
gallons of banana juice, and no pineapple juice, resulting in a total cost of $550.00.
b) If at least one employee needs to work for overtime, all other employee should work for same time.
How do you make additional constraint(s) for this restriction? How this restriction changes the decision?

Solution;

 To enforce the restriction that if at least one employee works overtime, all other employees must
work for the same amount of time, you can add the following additional constraint:
J=B=C
Where J - B = 0; B - C = 0; C - J = 0

 This constraint ensures that if John (J) works overtime, then Bill (B) and Cindy (C) must also
work the same amount of overtime, and vice versa.

 This restriction changes the decision by potentially limiting the flexibility in the allocation of
overtime hours. Specifically, if one employee works overtime, the constraint enforces that the
others must do the same. This could impact the overall production plan and, consequently, the
total profit. It may also lead to a different mix of products being produced or a different allocation
of overtime hours. The model will seek an optimal solution while adhering to this new constraint.

L.P. Model(revised)

max 22P1 + 25P2 + 23P3 - 15J - 17B - 20C - 10M

s.t.
Labor_time) 2P1 + P2 + 2P3 - J - B - C <= 80
Machine_time) P1 + P2 + 2P3 - M <= 65
Demand_P1) P1 >= 10
Demand_P2) P2 >= 50
Demand_P3) P3 >= 10
Labor_Overtime_B)B <= 10
Labor_Overtime_J)J <= 10
Labor_Overtime_C)C <= 10
Machine_Overtime)M <= 30
J - B = 0
B - C = 0
C - J = 0

End
L.P MODEL SOLUTION

Global optimal solution found.


Objective value: 1376.667
Infeasibilities: 0.000000
Total solver iterations: 0
Elapsed runtime seconds: 0.13

Model Class: LP

Total variables: 7
Nonlinear variables: 0
Integer variables: 0

Total constraints: 13
Nonlinear constraints: 0

Total nonzeros: 30
Nonlinear nonzeros: 0

Variable Value Reduced Cost


P1 10.00000 0.000000
P2 50.00000 0.000000
P3 10.00000 0.000000
J 3.333333 0.000000
B 3.333333 0.000000
C 3.333333 0.000000
M 15.00000 0.000000

Row Slack or Surplus Dual Price


1 1376.667 1.000000
LABOR_TIME 0.000000 17.33333
MACHINE_TIME 0.000000 10.00000
DEMAND_P1 0.000000 -22.66667
DEMAND_P2 0.000000 -2.333333
DEMAND_P3 0.000000 -31.66667
LABOR_OVERTIME_B 6.666667 0.000000
LABOR_OVERTIME_J 6.666667 0.000000
LABOR_OVERTIME_C 6.666667 0.000000
MACHINE_OVERTIME 15.00000 0.000000
11 0.000000 2.333333
12 0.000000 2.666667
13 0.000000 0.000000

The company will experience a decrease in the objective function as they opt to pay higher labor costs
instead of utilizing the most economical labor overtime for the tasks, all in pursuit of maximizing profit.

You might also like