Вы находитесь на странице: 1из 68

Manufacturing Processes

Oscar E. Sotomayor
Introduction to Linear Programming
• OBJECTIVES
A good understanding of linear programming (LP) problems
Formulation of the two-variable LP problem
Understanding optimization in the contexts of minimization and
maximization objective functions
Representing a two-variable LP model graphically.
FORMULATION OF LP PROBLEMS
• LP is an optimization model in which the objective functions and
constraints are strictly linear
• It is used in a wide range of areas such as agriculture, transportation,
economics, and industry.
Formulation 1 .- Product Mix Problem
RM company produces two types of lubricants, Oil1 and Oil2, from two raw
materials, BASE an ADDITIVE . To make one ton of Oil1 they need 3 tons of
BASE and 1 ton of ADDITIVE. To make one ton of Oil2 they need 2 tons of
BASE and 2 tons of ADDITIVE. They have 12 tons of BASE and 6 tons of
ADDITIVE. These products are sold at 500 USD/ton and 400 USD/ton
respectively. Find the best product mixt to maximize the revenue.
Let x1 be the tons of Oil1 made
Let x2 be the tons of Oil2 made
Maximize 500x1 + 400x2
3x1 +2x2 ≤ 12
x1 +2x2 ≤ 6
x1 ,x2 ≥ 0
Notation
Let x1 be the tons of Oil1 made
Decision variables
Let x2 be the tons of Oil2 made

Maximize 500x1 + 400x2 Objective Function

3x1 +2x2 ≤ 12
x1 +2x2 ≤ 6 Constraints

x1 ,x2 ≥ 0 Non Negativity Restriction


Formulation 2 .- Manpower requirement
The daily requirement of workers on a factory is given in the following
table
Time of the day Requirement
8 am – 12 noon 12
12 noon – 4 pm 15
4 pm – 8 pm 10
8 pm – 12 midnight 8
12 midnight – 4 am 6
4 am – 8 am 10

The workers start work at the beginning of the shift (8am, 12 noon,
etc) and work for 8 continuous hours. What is the minimum number
of workers required to meet the daily demand?
Let X1 to X6 be the number of workers who start working at 8 am, 12noon,
4 pm, 8pm, 12 midnight an 4 am respectively

6
Minimize 𝑖=1 𝑥𝑖 = 𝑋1 + 𝑋2 + 𝑋3 + 𝑋4 + 𝑋5 + 𝑋6

x1+x2 ≥ 15
x2+x3 ≥ 10
x3+x4 ≥ 8
x4+x5 ≥ 6
x5+x6 ≥ 10
x6+x1 ≥ 12

x1,x2 x3,x4 x5,x6 ≥ 0


Formulation 3 – Production planning
The demands for 2 weeks for a product are 800 and 1000. In a week
the company can produce up to 700 units in regular time at 100
USD/product. It can employ overtime and product up to an extra 300
units in a week at 120 USD/product. The cost of carrying a product
from one week to the next is 15USD/product/week. How should they
produce to meet the demand at minimum cost
Let X1 be the number of products made using regular time in week 1.
Let X2 be the number of products made using regular time in week 2.
Let Y1 be the number of products made using overtime in week 1.
Let Y2 be the number of products made using overtime in week 2.
Let Z1 be the number of products carried from week 1 to week 2.
Formulation 3 – Production planning
Cost= 100X1+120Y1+100X2+120Y2+15Z1
Formulation 3 – Production planning
Cost= 100X1+120Y1+100X2+120Y2+15Z1

X1 + Y1=800 +Z1
Formulation 3 – Production planning
Cost= 100X1+120Y1+100X2+120Y2+15Z1

X1 + Y1=800 +Z1
X1 + Y1 –Z1=800
Formulation 3 – Production planning
Cost= 100X1+120Y1+100X2+120Y2+15Z1

X1 + Y1 –Z1=800
Formulation 3 – Production planning
Cost= 100X1+120Y1+100X2+120Y2+15Z1

X1 + Y1 –Z1=800
X2 + Y2 + Z1 = 1000

X1 ≤ 700
Y1 ≤ 300
X2 ≤ 700
Y2 ≤ 300

X1, Y1, X2, Y2 , Z1 ≥ 0


Formulation 3 – Production planning
Cost= 100X1+120Y1+100X2+120Y2+15Z1 Cost= 100X1+120Y1+100X2+120Y2+15(X1 +
Y1 -800)

X1 + Y1 –Z1=800
X1 + Y1 ≥ 800
X2 + Y2 + Z1 = 1000
X2 + Y2 + (X1+Y1-800) ≥ 1000

X1 ≤ 700 X1 ≤ 700
Y1 ≤ 300 Y1 ≤ 300
X2 ≤ 700 X2 ≤ 700
Y2 ≤ 300 Y2 ≤ 300

X1, Y1, X2, Y2 , Z1 ≥ 0 X1, Y1, X2, Y2 ≥ 0


Formulation 4 – Napkins problem

The requirement of napkins on a five consecutive days of dinner is


100, 60, 80, 90, 70. New napkins cost 60 ctvs. Napkins sent to laundry
at the end of any day can be used from the second day onwards. The
laundry cost 20 ctvs./napkin. Find a solution to napkins problem that
minimizes total cost?

• Let X1 to X5 represent the number of new napkins bought that day.

• Let Y1 to Y3 represent the number of napkins sent to laundry at the


end of that day
Formulation 4 – Napkins problem

Day 1 demand 𝑿𝟏 ≥ 𝟏𝟎𝟎


Formulation 4 – Napkins problem

𝑿𝟏 ≥ 𝟏𝟎𝟎
Day 1 demand

Day 2 demand – We can buy more than 100 on day 𝑿𝟏 − 𝟏𝟎𝟎 + 𝑿𝟐 ≥ 𝟔𝟎


1 and use some of the extra napkins on day 2
Formulation 4 – Napkins problem

𝑿𝟏 ≥ 𝟏𝟎𝟎
Day 1 demand

Day 2 demand – We can buy more than 100 on day


1 and use some of the extra napkins on day 2 𝑿𝟏 + 𝑿𝟐 ≥ 𝟏𝟔𝟎
Formulation 4 – Napkins problem

𝑿𝟏 ≥ 𝟏𝟎𝟎
Day 1 demand

Day 2 demand – We can buy more than 100 on day


1 and use some of the extra napkins on day 2 𝑿𝟏 + 𝑿𝟐 ≥ 𝟏𝟔𝟎
Day 3 demand – extra napkins from day 2 + new
napkins bought on day 3 + napkins received from
laundry on day 3 (sent on day 1)
Formulation 4 – Napkins problem

𝑿𝟏 ≥ 𝟏𝟎𝟎
Day 1 demand

Day 2 demand – We can buy more than 100 on day


1 and use some of the extra napkins on day 2 𝑿𝟏 + 𝑿𝟐 ≥ 𝟏𝟔𝟎
Day 3 demand – extra napkins from day 2 + new
napkins bought on day 3 + napkins received from 𝑿𝟏 + 𝑿𝟐 − 𝟏𝟔𝟎 + 𝑿𝟑 + 𝒀𝟏 ≥ 𝟖𝟎
laundry on day 3 (sent on day 1)
Formulation 4 – Napkins problem

𝑿𝟏 ≥ 𝟏𝟎𝟎
Day 1 demand

Day 2 demand – We can buy more than 100 on day


1 and use some of the extra napkins on day 2 𝑿𝟏 + 𝑿𝟐 ≥ 𝟏𝟔𝟎
Day 3 demand – extra napkins from day 2 + new
napkins bought on day 3 + napkins received from 𝑿𝟏 + 𝑿𝟐 − 𝟏𝟔𝟎 + 𝑿𝟑 + 𝒀𝟏 ≥ 𝟖𝟎
laundry on day 3 (sent on day 1) 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 ≥ 𝟐𝟒𝟎
Formulation 4 – Napkins problem

𝑿𝟏 ≥ 𝟏𝟎𝟎
Day 1 demand

Day 2 demand – We can buy more than 100 on day


1 and use some of the extra napkins on day 2 𝑿𝟏 + 𝑿𝟐 ≥ 𝟏𝟔𝟎
Day 3 demand – extra napkins from day 2 + new
napkins bought on day 3 + napkins received from 𝑿𝟏 + 𝑿𝟐 − 𝟏𝟔𝟎 + 𝑿𝟑 + 𝒀𝟏 ≥ 𝟖𝟎
laundry on day 3 (sent on day 1) 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 ≥ 𝟐𝟒𝟎
Day 4 demand – extra napkins from day 3 + new
napkins bought on day 4 + napkins received from
laundry on day 4 (sent on day 2)
Formulation 4 – Napkins problem

𝑿𝟏 ≥ 𝟏𝟎𝟎
Day 1 demand

Day 2 demand – We can buy more than 100 on day


1 and use some of the extra napkins on day 2 𝑿𝟏 + 𝑿𝟐 ≥ 𝟏𝟔𝟎
Day 3 demand – extra napkins from day 2 + new
napkins bought on day 3 + napkins received from 𝑿𝟏 + 𝑿𝟐 − 𝟏𝟔𝟎 + 𝑿𝟑 + 𝒀𝟏 ≥ 𝟖𝟎
laundry on day 3 (sent on day 1) 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 ≥ 𝟐𝟒𝟎
Day 4 demand – extra napkins
from day 3 + new napkins bought 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 − 𝟐𝟒𝟎 + 𝑿𝟒 + 𝒀𝟐 ≥ 𝟖𝟎
on day 4 + napkins received from
laundry on day 4 (sent on day 2)
Formulation 4 – Napkins problem

𝑿𝟏 ≥ 𝟏𝟎𝟎
Day 1 demand

Day 2 demand – We can buy more than 100 on day


1 and use some of the extra napkins on day 2 𝑿𝟏 + 𝑿𝟐 ≥ 𝟏𝟔𝟎
Day 3 demand – extra napkins from day 2 + new
napkins bought on day 3 + napkins received from 𝑿𝟏 + 𝑿𝟐 − 𝟏𝟔𝟎 + 𝑿𝟑 + 𝒀𝟏 ≥ 𝟖𝟎
laundry on day 3 (sent on day 1) 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 ≥ 𝟐𝟒𝟎
Day 4 demand – extra napkins from day
3 + new napkins bought on day 4 + 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 + 𝟐𝟒𝟎 + 𝑿𝟒 + 𝒀𝟐 ≥ 𝟗𝟎
napkins received from laundry on day 4
(sent on day 2) 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝑿𝟒 + 𝒀𝟏 + 𝒀𝟐 ≥ 𝟑𝟑𝟎
Formulation 4 – Napkins problem
Day 5 demand –
extra napkins
from day 4 + new
napkins bought
on day 5 +
napkins received
from laundry on
day 5 (sent on
day 3)
Formulation 4 – Napkins problem
Day 5 demand – 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 + 𝑿𝟒 + 𝒀𝟐 − 𝟑𝟑𝟎 + 𝑿𝟓 + 𝒀𝟑 ≥ 𝟕𝟎
extra napkins
from day 4 + new
napkins bought
on day 5 +
napkins received
from laundry on
day 5 (sent on
day 3)
Formulation 4 – Napkins problem
Day 5 demand – 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 + 𝑿𝟒 + 𝒀𝟐 − 𝟑𝟑𝟎 + 𝑿𝟓 + 𝒀𝟑 ≥ 𝟕𝟎
extra napkins
from day 4 + new 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝑿𝟒 + 𝑿𝟓 + 𝒀𝟏 + 𝒀𝟐 + 𝒀𝟑 ≥ 𝟒𝟎𝟎
napkins bought
on day 5 +
napkins received
from laundry on
day 5 (sent on
day 3)
Formulation 4 – Napkins problem
Day 5 demand – 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 + 𝑿𝟒 + 𝒀𝟐 − 𝟑𝟑𝟎 + 𝑿𝟓 + 𝒀𝟑 ≥ 𝟕𝟎
extra napkins
from day 4 + new 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝑿𝟒 + 𝑿𝟓 + 𝒀𝟏 + 𝒀𝟐 + 𝒀𝟑 ≥ 𝟒𝟎𝟎
napkins bought
on day 5 +
napkins received
from laundry on
day 5 (sent on
day 3)
Limit on napkins
sent to laundry
Formulation 4 – Napkins problem
Day 5 demand – 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 + 𝑿𝟒 + 𝒀𝟐 − 𝟑𝟑𝟎 + 𝑿𝟓 + 𝒀𝟑 ≥ 𝟕𝟎
extra napkins
from day 4 + new 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝑿𝟒 + 𝑿𝟓 + 𝒀𝟏 + 𝒀𝟐 + 𝒀𝟑 ≥ 𝟒𝟎𝟎
napkins bought
on day 5 +
napkins received
from laundry on
day 5 (sent on
day 3)
Limit on napkins
sent to laundry
Formulation 4 – Napkins problem
Day 5 demand – extra 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 + 𝑿𝟒 + 𝒀𝟐 − 𝟑𝟑𝟎 + 𝑿𝟓 + 𝒀𝟑 ≥ 𝟕𝟎
napkins from day 4 +
new napkins bought on
day 5 + napkins received 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝑿𝟒 + 𝑿𝟓 + 𝒀𝟏 + 𝒀𝟐 + 𝒀𝟑 ≥ 𝟒𝟎𝟎
from laundry on day 5
(sent on day 3)

Limit on napkins 𝒀𝟏 ≤ 𝟏𝟎𝟎, 𝒀𝟐 ≤ 𝟔𝟎, 𝒀𝟑 ≤ 𝟖𝟎


sent to laundry
Formulation 4 – Napkins problem
Day 5 demand – extra 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 + 𝑿𝟒 + 𝒀𝟐 − 𝟑𝟑𝟎 + 𝑿𝟓 + 𝒀𝟑 ≥ 𝟕𝟎
napkins from day 4 +
new napkins bought on
day 5 + napkins received 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝑿𝟒 + 𝑿𝟓 + 𝒀𝟏 + 𝒀𝟐 + 𝒀𝟑 ≥ 𝟒𝟎𝟎
from laundry on day 5
(sent on day 3)

Limit on napkins 𝒀𝟏 ≤ 𝟏𝟎𝟎, 𝒀𝟐 ≤ 𝟔𝟎, 𝒀𝟑 ≤ 𝟖𝟎


sent to laundry Minimize
Objective Function 60(𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝑿𝟒 + 𝑿𝟓 ) + 𝟐𝟎(𝒀𝟏 + 𝒀𝟐 + 𝒀𝟑 )
Formulation 4 – Napkins problem
Day 5 demand – extra 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝒀𝟏 + 𝑿𝟒 + 𝒀𝟐 − 𝟑𝟑𝟎 + 𝑿𝟓 + 𝒀𝟑 ≥ 𝟕𝟎
napkins from day 4 +
new napkins bought on
day 5 + napkins received 𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝑿𝟒 + 𝑿𝟓 + 𝒀𝟏 + 𝒀𝟐 + 𝒀𝟑 ≥ 𝟒𝟎𝟎
from laundry on day 5
(sent on day 3)

Limit on napkins 𝒀𝟏 ≤ 𝟏𝟎𝟎, 𝒀𝟐 ≤ 𝟔𝟎, 𝒀𝟑 ≤ 𝟖𝟎


sent to laundry Minimize
Objective Function 60(𝑿𝟏 + 𝑿𝟐 + 𝑿𝟑 + 𝑿𝟒 + 𝑿𝟓 ) + 𝟐𝟎(𝒀𝟏 + 𝒀𝟐 + 𝒀𝟑 )

Non – Negativity 𝑿𝒊 ≥ 𝟎, 𝒀𝒊 ≥ 𝟎
restrictions
Formulation 5 – Maximum flow problem
Formulation 5 – Maximum flow problem
Formulation 5 – Maximum flow problem
Formulation 5 – Maximum flow problem
Formulation 5 – Maximum flow problem
Formulation 6 – Bin Packing
Formulation 6 – Bin Packing
Formulation 6 – Bin Packing
Formulation 6 – Bin Packing
Formulation 6 – Bin Packing
Solution to LP formulation – Graphical Method
Maximize Z=5X1+12X2

Subject to 10X1 + 20X2 ≤ 100


8X1+7X2 ≤ 56
X1, X2 ≥ 0
Solution to LP formulation – Graphical Method
Maximize Z=5X1+12X2

Subject to 10X1 + 20X2 ≤ 100


8X1+7X2 ≤ 56
X1, X2 ≥ 0

(0,0)
Solution to LP formulation – Graphical Method
Maximize Z=5X1+12X2

Subject to 10X1 + 20X2 ≤ 100


8X1+7X2 ≤ 56 (0,5)
X1, X2 ≥ 0

(0,0) (10,0)
Solution to LP formulation – Graphical Method
Maximize Z=5X1+12X2

Subject to 10X1 + 20X2 ≤ 100


8X1+7X2 ≤ 56 (0,5)
X1, X2 ≥ 0

10X1 + 20X2 = 100

(0,0) (10,0)
Solution to LP formulation – Graphical Method
Maximize Z=5X1+12X2

(0,8)
Subject to 10X1 + 20X2 ≤ 100
8X1+7X2 ≤ 56 (0,5)
X1, X2 ≥ 0

10X1 + 20X2 = 100

(0,0) (7,0) (10,0)


Solution to LP formulation – Graphical Method
Maximize Z=5X1+12X2

(0,8)
Subject to 10X1 + 20X2 ≤ 100 8X1+7X2 = 56

8X1+7X2 ≤ 56 (0,5)
X1, X2 ≥ 0

10X1 + 20X2 = 100

(0,0) (7,0) (10,0)


Solution to LP formulation – Graphical Method
Maximize Z=5X1+12X2

Subject to 10X1 + 20X2 ≤ 100


8X1+7X2 ≤ 56
X1, X2 ≥ 0
Solution to LP formulation – Graphical Method
Maximize Z=5X1+12X2

Subject to 10X1 + 20X2 ≤ 100


8X1+7X2 ≤ 56
X1, X2 ≥ 0
Feasible region
Every point inside the feasible region is dominated by a boundary point
It is enough to evaluate points boundary points
Solution to LP formulation – Graphical Method
Maximize Z=5X1+12X2

Subject to 10X1 + 20X2 ≤ 100


8X1+7X2 ≤ 56
X1, X2 ≥ 0

Evary boundary point is dominated by a corner point


Solution to LP formulation – Graphical Method
Maximize Z=5X1+12X2

Subject to 10X1 + 20X2 ≤ 100


8X1+7X2 ≤ 56
X1, X2 ≥ 0

Every boundary point is dominated by a corner point


Enough to evaluate at corner points
Minimization Problem
Minimization Problem
Minimization Problem

(0,6)

(0,6)
Minimization Problem

(0,6)

X1 + X 2 = 6

(0,6)
Minimization Problem
(0,14)

7X1 + X2 = 14

(0,6)

X1 + X 2 = 6

(2,0) (6,0)
Minimization Problem
Minimization Problem

Feasible region

(1.3,4.6)
Minimization Problem
C

Feasible region

(1.3,4.6)
B

A
Minimization Problem
C

Feasible region

(1.3,4.6)
B

Вам также может понравиться