PowerPoint

advertisement
456/556 Introduction to
Operations Research
Chapter 3: Introduction to Linear
Programming
Linear Programming





In order to solve OR problems, we need to turn a
real-world problem into a mathematical model.
One of the most important models (due to its
usefulness in solving a variety of problems) is the
linear programming model.
This type of model is used to address the general
problem of allocating limited resources among
competing activities in a best possible (optimal) way.
All mathematical functions in linear programming
models are linear.
We now look at some simple examples of linear
programming models that can be solved graphically.
2
456/556 Introduction to
Operations Research
3.1: Prototype Examples
Example 1 (File Cabinets)

An office manager needs to purchase new filing
cabinets. She knows that Ace cabinets cost $40
each, require 6 square feet of floor space, and hold
24 cubic feet of files. On the other hand, each
Excello cabinet costs $80, requires 8 square feet of
file space, and holds 36 cubic feet. Her budget
permits her to spend no more than $560 on files,
while the office has space for no more than 72
square feet of cabinets. The manager desires the
greatest storage capacity within the limitations
imposed by funds and space. How many of each
cabinet should she buy?
4
Example 1 (cont.)





We can formulate this situation as a linear
programming problem.
Let x1= the number of Ace cabinets to be
bought.
Let x2 = the number of Excello cabinets to be
bought.
Let Z = the total storage capacity of cabinets
purchased.
Summarize the given information in a table:
5
Example 1 (cont.)
Resource usage per cabinet
Cabinet type
Amount of
Resource
Available
Resource
Ace
Excello
Cost
$40
$80
$560
Floor space
6 sq ft
8 sq ft
72 sq ft
Storage
space
24 cu ft
36 cu ft
6
Example 1 (cont.)





We call x1 and x2 decision variables for this
model.
From the bottom row of the table, we get the
objective function:
Z = 24 x1 + 36 x2
(1)
The objective function gives the amount of
storage space in cubic feet for a choice of x1
and x2.
In this case, the objective is to maximize Z.
7
Example 1 (cont.)








From rows 1 and 2 of the table, we get restrictions
on our choices of x1 and x2 due to a limit on what we
can spend and the size of the office.
40 x1 + 80 x2 ≤ 560
(2)
6 x1 + 8 x2 ≤ 72
(3)
We also want
x1 ≥ 0
(4)
x2 ≥ 0
(5)
The last two restrictions on x1 and x2 make sense
physically.
We call equations (2) - (5) constraint equations.
8
Example 1 (cont.)







Our model for deciding how to allocate file
cabinets is as follows:
Maximize: Z = 24 x1 + 36 x2
Subject to the restrictions:
40 x1 + 80 x2 ≤ 560 (cost)
6 x1 + 8 x2 ≤ 72
(space)
and
x1 ≥ 0; x2 ≥ 0.
9
Example 2 (Feeding
Laboratory Animals)

Certain laboratory animals must have at least 30
grams of protein and at least 20 grams of fat per
feeding period. These nutrients come from food A,
which costs 18 cents per unit and supplies 2 grams of
protein and 4 of fat; and food B, which costs 12
cents per unit and has 6 grams of protein and 2 of
fat. Food B is bought under a long-term contract
requiring that at least 2 units of B be used per
serving. How much of each food should included in a
serving to produce the minimum cost per serving?
10
Example 2 (cont.)





Again, we can formulate this situation
as a linear programming problem.
Let x1= units of food A per serving.
Let x2 = units of food B per serving.
Let Z = the cost per serving of food.
As before, summarize the given
information in a table:
11
Example 2 (cont.)
Nutrient per serving
Food type
Amount of
Nutrient
Required
Nutrient
A
B
Protein
2 gm
6 gm
30 gm
Fat
4 gm
2 gm
20 gm
Cost
18 cents
12 cents
12
Example 2 (cont.)







The linear programming model for this case is
as follows:
Minimize: Z = 18 x1 + 12 x2
Subject to the restrictions:
2 x1 + 6 x2 ≥ 30
(protein)
4 x1 + 2 x2 ≥ 20
(fat)
and
x1 ≥ 0; x2 ≥ 2.
13
The Graphical Method


For linear programming problems
involving two decision variables, we can
solve by graphing linear inequalities!
For more than two variables, we will
have to resort to other methods, such
as the Simplex Method, which we will
see in Chapter 4.
14
The Graphical Method (cont.)



The basic idea of this method is to sketch a
graph of all ordered pairs of decision
variables (x1, x2) that satisfy all given
constraint equations.
The set of all valid pairs of decision variables
(x1, x2) is called the feasible region.
Once the feasible region is found, we look for
the pair(s) (x1, x2) that maximize (or
minimize) the objective function.
15
Example 1 (cont.)







Let’s apply the graphical method to this linear
programming problem for filing cabinet
choices:
Maximize: Z = 24 x1 + 36 x2
Subject to the restrictions:
40 x1 + 80 x2 ≤ 560 (cost)
6 x1 + 8 x2 ≤ 72
(space)
and
X1 ≥ 0; x2 ≥ 0.
16
Download