0% found this document useful (0 votes)
124 views39 pages

EM 602 - Lecture 01 Introduction To LP PDF

This document provides an introduction to operations research and linear programming. It defines operations research as a scientific approach to decision-making that analyzes organizational systems. The document then discusses the history and development of operations research. It also introduces the basic methodology of defining a problem, collecting data, formulating and solving a model, and analyzing outputs. Finally, it provides an overview of common elements in optimization models, such as decision variables, objectives, and constraints.

Uploaded by

vamshi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
124 views39 pages

EM 602 - Lecture 01 Introduction To LP PDF

This document provides an introduction to operations research and linear programming. It defines operations research as a scientific approach to decision-making that analyzes organizational systems. The document then discusses the history and development of operations research. It also introduces the basic methodology of defining a problem, collecting data, formulating and solving a model, and analyzing outputs. Finally, it provides an overview of common elements in optimization models, such as decision variables, objectives, and constraints.

Uploaded by

vamshi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 39

EM 602

MANAGEMENT SCIENCE

Lecture 1:
Introduction to Operations
Research and Liner Programming

Introduction
 Operations Research (OR) / Management Science
 A scientific approach to decision making that involves
operations of organizational systems.
 The art of giving bad answers to problems to which otherwise
worse answer are given.
 Quantitative Common Sense.
 An aid for the executive in making decisions by providing
him/her with the needed quantitative information based on the
scientific method of analysis.
 Simply, ways to effectively use information.
2

1
Introduction
 Today’s business problems tend to be very complex
 Businesses turn to algorithms to solve problems.
 Management science models become useful when common
sense and intuition fail to solve the problems.
 This class will present how quantitative methods can be used
to solve business problems.
 The methods in this class can apply to many problems and
environments.

History of OR
 1885: Optimal Shovel Load to maximize work (Frederick W. Taylor)
 1917: Telephone Call Switching – queuing theory (A.K. Erlang)
 World War II (WWII):
 Search procedures
 Optimal bomb patterns
 Missile trajectories
 Logistics
 Birth of the ENIAC (Electronic Numerical Integrator And
Computer) – the first mainframe, calculated artillery firing tables.

2
History of OR (continued)
 Post WWII all areas of study
 Business: OM, Finance, Strategic Planning
 Economics: Equilibriums, Econometrics
 Civil Engineering: Optimal Construction
 Chemical Engineering: Optimal Process Design
 Computer Science: Switching, etc.

OR Today
 IFORS
 INFORMS
 Mathematical Programming Society
 Transportation Science
 Interfaces

3
OR Today

The Methodology of OR

Problem Definition

Data Collection
Feedback
Model Formulation

Model Solution

Validation and Output Analysis

Implementation

4
Models and Purpose
 The purpose of a mathematical model is to represent the essence of a
problem in a concise form, providing several advantages:
 Enables managers to understand the problem better;
 Helps to define the scope of the problem, the possible solutions, and the data
requirements

 Allows analysts to employ a variety of the mathematical solution


procedures that have been developed over the last 50 years;
 The modeling process itself, if done correctly, often helps to “sell” the
solution to the people who must work with the system that is eventually
implemented.

Types of Models
 Descriptive models: models that simply describe a situation.
 Optimization models: models that suggest a desirable course
of action.
 Example
 Waiting line: Convenience store with a single cash register.
 The manager suspects that excessive waiting times in lines to the
register hurt the business.
 The manager builds a mathematical model to help understand the
problem, and suggest improvements to the current situation.

10

10

5
Descriptive Models
 A descriptive model can take at least two forms.
 One form is to show all of the elements of the problem in a diagram, as in
Figure below.
 Helps the company to visualize the problem and to better understand how
the elements of the problem are related.

11

11

Optimization model
 The company/manager uses methods or/and software
to quickly search through all potential sets of
decisions and find the one that maximizes total NPV
while staying within the budget.

12

12

6
OR Modeling Techniques
 Operation Research (OR) / Management Science is best
defined by the techniques rather than the problems (i.e., the
problem set is unbounded.)

 Mathematical Programming  Stochastic Processes


 Linear Programming (LP)  Markov Chain
 Nonlinear Programming (NLP)  Queuing Theory
 Network Programming  Simulation
 Integer Programming (IP)
 Dynamic Programming
 Calculation of Equilibrium 13

13

Models – Common Elements


 All optimization models have several common elements:
 Decision variables, the variable whose values the decision maker is
allowed to choose. The values of these variables determine such outputs
as total cost, revenue, and profit.
 An objective function (objective, for short) to be optimized – minimized
or maximized.
 Constraints that must be satisfied. They are usually physical, logical, or
economic restrictions, depending on the nature of the problem.
 In searching for the values of the decision variables that optimize the
objective, only those values that satisfy all of the constraints are
allowed.

14

14

7
General LP Model
 Suppose we have n-activities : x1, x2,……., xn and m resources
 Let bi, i ={1, 2,....., m} = total amount of i-th resource available

 aij  i 1,2 ,...,m


j 1,2 ,..,n = number of units of resource i consumed per one unit of activity j

 cj , j ={1, 2,...,n} = profit per unit of activity j


Then, the Standard Form is: Terminology:
1. Maximize Z = c1x1 + c2x2 + …+cnxn 1. Objective Function
2. Subject to (s.t.) 2. Structural Constraints
3. Non-negativity Constraints
a11x1 + a12x2 +…+ a1nxn  b1
a21x1 + a22x2 +…+ a2nxn  b2 a ij , bi , c j are called the problem parameters
xj's are the decision variables
………………………
am1x1 + am2x2 +…+ amnxn  bm a ij  Contribution coefficient
cj  Cost coefficient
3. x1, x2, …., xn  0 bi  Right-Hand-Side (RHS) 15

15

General LP Model (cont’d)


OR
n
1. Max Z=  cjxj
j 1
s.t.
n
2.  aij x j  bi i = 1, 2,........,m
j 1

3. xj  0 j = 1,2,.........,n

16

16

8
General LP Model – Matrix Notation

Max Z = cx where : c  c1 c2  cn 

s.t. Ax  b  x1 
x 
x 
2
x0   a11 a12 ... a1n 
  a a22 ... a1n 
 xn  A  21

     
 b1   
b   am1 am 2 ... amn 
b 2

 
bm 

17

17

LP Model Solution(s)
 x1 
x 
x 
2
 A solution: Any realization of vector

 
 xn 
 Feasible Solution : Any solution that satisfies all
constraints

 Optimal Solution : A feasible solution with the largest Z


value

18

18

9
Assumptions in a General LP Model
1. Proportionality: Activity levels are directly proportional to their contributions to
the objective function and each constraint
 One unit increase in xj increases Z by cj.
 One unit increase in xj consumes aij units of the i-th resource (i.e. (reduces
bj by aij).
2. Additivity: Activities are independent.
3. Divisibility: Activity units can be divided into fractional levels (does not, and
usually is not, have to be strictly integer).
4. Deterministic Model: Problem parameters are known and constant.
Note that when parameters are not fixed in value (constant) but can assume values
with associated probability, we say that the model is probabilistic or stochastic.

19

19

Canonical Form of an LP
Min / Max OR
c1 x1  c2 x2 cn xn
Min / Max
s.t. Z  cx
a11 x1  a12 x2 a1n xn  b1  0 s.t.
a21 x1  a22 x2 a2 n xn  b2  0 Ax  b
 x0
am1 x1  am 2 x2 amn xn  bm  0
x1  0, x2  0, , xn  0

20

20

10
Canonical Form of an LP
xn1
n
1.  aij x j  bi add SLACK
j 1
n
 aij x j  xn1  bi ; xn1  0
j 1
n
2.  aij x j  bi subtract SURPLUS xn1
j 1

xn1  0
n
 aij x j
j 1
 xn 1  bi ;

3. x j unrestricted in sign (unsigned) replace x j by two variables:

x j  0, x j  0
x j  x j  x j

4. bi  0 multiply by ( -1 ) on both sides of equality


21

21

Canonical Form of an LP (cont’d)


Min / Max Z  cx
s.t.
Ax  b m equations
x0 n unknowns

If m = n, and if all equations are independent it


may have one solution.

m  n, overdetermined - can not meet all constraints.

m  n, need to pick one of many solutions.

22

22

11
Example 1 – Diet Problem
Diet Problem
- 1945 George Stigler

Minimize The Cost of a Dietary Plan


s.t. Meeting Required Daily Allowance (RDA) for each Nutrient (e.g., vitamin)

Data
Nutrient Gal. Milk Lb. Tuna Lb. Bread Lb. Spinach RDA
Vitamin A 6,400 237 0 34,000 5,000 IU
Vitamin C 40 0 0 71 75 mg
Vitamin D 540 0 0 0 400 IU
Iron 28 7 13 8 12 mg

Cost $7.50 $6.50 $2.69 $7.99


Define x1 x2 x3 x4
23

23

Example 1 – Diet Problem


Minimize 7.50 x1 + 6.50 x2 + 2.69 x3 + 7.99 x4
s.t.

6,400 x1 + 237 x2 + 0. x3 + 34,000 x4  5,000

40 x1 + 0 x2 + 0. x3 + 71 x4  75

540 x1 + 0 x2 + 0. x3 + 0. x4  400

28 x1 + 7 x2 + 13 x3 + 8 x4  12

x1  0 , x2  0 , x3  0 , x4  0

24

24

12
Example 2 – Portfolio Selection
$500,000 available for investment

Maximize Yield
s.t. Budget limit
Risk acceptable level

xj = amount of money invested in security j

Investment E ROR  Variance (in ROR) $


Municipal Bonds 7.5 0.2 x1
Govt. Bonds 6.5 0.0 x2
Midland Oil Stock 11.9 6.0 x3
Western Coal Stock 8.8 4.5 x4
N. Auto Stock 10.0 5.0 x5

25

25

Example 2 – Portfolio Selection


Further Demands (Constraints)
Must invest  20 % in bonds
 30 % of bond investment must be in Government Bonds
 half in Western Coal Stock

Weighted risk (average )  3.0

Maximize 7.5 x1 + 6.5 x2 + 11.9 x3 + 8.8 x4 + 10.0 x5 ( Yield )

s.t. x1 + x2 + x3 + x4 + x5 = 500,000 (Budget)

0.2 x1 + 0. x2 + 6.0 x3 + 4.5 x4 + 5.0 x5  3.0*( 500,000 ) ( Risk )

x2  0.3 ( x1 + x2 ) or

-0.3 x1 + 0.7 x2  0 ( Government Bonds )

x1 + x2  0.2 ( 500,000 ) = 100,000 ( Total Bonds )

x4  250,000 (Coal Stock limit)

x1 , x2 , x3 , x4 , x5  0
26

26

13
Example 3 – Air Pollution
Controlling Air Pollution -- NORI & LEETS CO.

Given

Clean Air Standards for the Next Nori & Leets Co.
Pollutant Required Reduction in Annual Emission Rate
(Million Pounds)
Particulates 60
Sulfur oxides 150
Hydrocarbons 125

Reduction in Emission Rate (in Millions of Pounds per year) from the Maximum Feasible
Use of an Abatement Method for Nori & Leets Co.

Taller Smokestacks Filters Better Fuels


Pollutant
Blast Open- Blast Open- Blast Open-
Furnace Hearth Furnace Hearth Furnace Hearth
Furnace Furnace Furnace
Particulates 12 9 25 20 17 13
Sulfur 35 42 18 31 56 49
oxides
Hydrocarbo 37 53 28 24 29 20
ns
Note: each method needn’t be fully used and the fraction rate of use could be
different for blast and open-hearth furnace. 27

27

Example 3 – Air Pollution


Total Annual Cost from the Maximum Feasible Use of an Abatement Method for Nori &
Leets Co. ($ Millions)
Abatement Method Blast Furnaces Open-Hearth Furnaces
Taller smokestacks 8 10
Filters 7 6
Better fuels 11 9
Note: The annual cost is the annualized total cost, which accounts for almost any
additional cost induced by the use of method.

Objective:
Minimize the total annual cost

Constraints:
Annual emission reduction rate must be met.
No method could be overused, i.e., the fraction of the maximum feasible use
of an abatement method couldn’t exceed 100%.

28

28

14
Example 3 – Air Pollution

Decision variables:

Xj = the fraction of the abatement capacity , j=1,2…6,

Decision Variables (Fraction of the Maximum Feasible Use of an Abatement


Method) for Nori & Leets Co.

Abatement Method Blast Furnace Open-Hearth Furnace


Taller smokestacks X1 X2
Filters X3 X4
Better fuels X5 X6

Z = Total annual cost.

29

29

Example 3 – Air Pollution


Formulation as a Linear Programming Problem:

Minimize Z=8X1 + 10X2 + 7X3 + 6X4 + 11X5 + 9X6 (objective function)

s.t.
1. Emission reduction:
12X1 + 9X2 + 25X3 + 20X4 + 17X5 + 13X6 >=60
35X1 + 42X2 + 18X3 + 31X4 + 56X5 + 49X6 >=150
37X1 + 53X2 + 28X3 + 24X4 + 29X5 + 20X6 >=125

2. Technological limit:
Xj<=1, for j=1,2,…,6

3. Nonnegativity:
Xj>=0, for j=1,2,…,6

30

30

15
Example 3 – Air Pollution

Optimal Solution for this problem:

The minimum-cost plan:

( X1, X2, X3, X4, X5, X6 ) =( 1, 0.623, 0.343, 1, 0.048, 1) ; Z=32.16

31

31

Example 4 – Personnel Scheduling


Given the following shift and personnel information for Union Airways:

Time Period Time Periods Covered Minimum Number


of Agents Needed
Shift
1 2 3 4 5
6:00 A.M. to 8:00 A.M.  48
8:00 A.M. to 10:00 A.M.   79
10:00 A.M. to 12:00 A.M.   65
12:00 A.M. to 2:00 P.M.    87
2:00 P.M. to 4:00 P.M.   64
4:00 P.M. to 6:00 P.M.   73
6:00 P.M. to 8:00 P.M.   82
8:00 P.M. to 10:00 P.M.  43
10:00 P.M. to 12:00 P.M.   52
12:00 P.M. to 6:00 A.M.  15
Daily cost per agent $170 $160 $175 $180 $195

32

32

16
Example 4 – Personnel Scheduling
Each agent work an 8-hour shift 5 days per week, and the authorized shifts are shown in
the above table, for example: shift 1 is from 6:00 A.M. to 2:00 P.M. This problem is mix
of activity level kind of problem, where activities correspond to shifts and number of
agents for each shift corresponds to level of activity. For the mix of activity levels problem,
the decision variables are always the levels of activities.

Objective:
Minimize the personnel cost

Constraint:
For each time period, the number of total agents from each possible shift meets the
minimum number requirement -- the number of agents for each time period.

Define the decision variables: Let


Xj = the number of agents assigned to shift j for j=1,2…5
Z = the total personnel cost

33

33

Example 4 – Personnel Scheduling


Formulation as a linear programming problem:

Minimize Z = 170X 1 + 160X 2 + 175X 3+180X4+195X 5 (objective function)

s.t.
X 1 >= 48 (6 -8 A.M.)
X 1 + X 2 >= 79 (8 -10 A.M.)
X 1 + X 2 >= 65 (10 -12 A.M.)
X 1 + X 2 + X 3 >= 87 (12 -2 P.M.)
X 2 + X 3 >= 64 (2 -4 P.M.)
X 3 +X4 >= 73 (4 -6 P.M)
X 3 +X4 >= 82 (6 -8 P.M.)
X 4 >= 43 (8 -10 P.M.)
X 4 +X5 >= 52 (10 -12 P.M.)
X 5 >=15 (12 P.M –6 A.M.)

and
Xj >= 0, for j = 1, 2, 3, 4, 5.
nd
Here, the 2 , 6th constrains and three nonnegative constraints -X1 >= 0, X 4 >= 0, X 5 >= 0
are redundant constraints and can be deleted.

34

34

17
Example 4 – Personnel Scheduling
 Optimal solution for this model: (X1, X2, X3, X4, X5 ) = ( 48, 31, 39, 43, 15 )

 Accordingly Z = 30,610.

 Note: In the above problem, the decision variables should be integer. Note that
there are no constraints specifying that in the problem statement. Fortunately, the
above solution happens to be integer. Otherwise, we will have to add the integer
constraints and turn the problem into an integer programming model.

35

35

Example 5 – Distribution Network


The OR study for DISTRIBUTION UNLIMITED CO concerns with
deciding the optimum shipment through each shipping lane available
between factories and warehouses as to minimize the total shipping cost.
The information about the units available for shipping, the units needed
at each warehouse and the capacity of shipping lane are provided in the
following figure.

36

36

18
Example 5 – minimum cost flow problem
$900/unit
50 units 30 units
F1 W1
produced needed
Notation:
$400/unit F1: F2: 2 factories
W1: W2: 2 warehouse
DC $200/unit $300/unit
DC: a distribution center
$200/unit 10 units max.

$100/unit

80 units max
$300/unit

40 units F2 W2 60 units
produced needed

Feasible shipping lane -- e.g. shipment from F1 to W1 has 3 alternative


routes:
1. from F1 to W1 directly
2. from F1 to DC, then to W2, finally to W1
3. from F1 to F2, then to DC, then to W2, finally to W1
37

37

Example 5 – minimum cost flow problem


Formulation as a Linear Programming problem:

Based on the above information, the mathematical model is as follows:


Choose XF1-F2, XF1-DC, XF1-W1, XF2-DC, XDC-W2, XW1-W2, XW2-W1 as decision variables,
which denote the shipments on feasible lanes. And, Let Z be the total shipping cost,
which is to be minimized.

Objective Function:
Minimize:
Z = 2XF1-F2 + 4XF1-DC + 9XF1-W1 + 3XF2-DC + XDC-W2 + 3XW1-W2 + 2XW2-W1

S.T.

1. Net flow constraints:


XF1-F2 + XF1-DC + XF1-W1 = 50 (factory 1)
-XF1-F2 + XF2-DC = 40 (factory 2)
-XF1-DC - XF2-DC + XDC-W2 = 0 (distribution center)
-XF1-W1 + XW1-W2 - XW2-W1 = -30 (warehouse 1)
- XDC-W2 - XW1-W2 + XW2-W1 = -60 (warehouse 2)
38

38

19
Example 5 – minimum cost flow problem

2. Upper-bound constraints:
XF1-F2 <= 10, XDC-W2 <= 80

3. Nonnegativity constraints:
XF1-F2 >= 0, XF1-DC >= 0, XF1-W1 >= 0, XF2-DC >= 0, XDC-W2 >= 0,
XW1-W2 >= 0, XW2-W1 >= 0.

Optimal solution for this model:

(XF1-F2, XF1-DC, XF1-W1, XF2-DC, XDC-W2, XW1-W2, XW2-W1)


=(0, 40, 10, 40, 80, 0, 20)

Z = $49,000

39

39

Example 6 – Post Office Problem


A post office requires different numbers of
full-time employees on different days of Day Number of Full-Time
the week. The number of full-time Employees Required

employees required on each day is given. 1=Monday 17

Union rules state that each full-time 2=Tuesday 13


employee must work five consecutive days
3=Wednesday 15
and then receive two days off. For
example, an employee who works Monday 4=Thursday 19
to Friday must be off on Saturday and
5=Friday 14
Sunday. The post office wants to meet its
daily requirements using only full-time 6=Saturday 16
employees. Formulate an LP that the post
7=Sunday 11
office can use to minimize the number of
full-time employees who must be hired.
40

40

20
Example 6 – Post Office Problem
 Solution:
xj Number of employees beginning work on day j
The objective function is
min z  x1  x2  x3  x4  x5  x6  x7

The post office must insure that enough employees are working on
each day of the week. For example, at least 17 employees must work
on Monday. Who is working on Monday? Everybody except the
employees who begin work on Tuesday or on Wednesday. This means
that the number of employees working on Monday is x1+x4+x5+x6+x7.
To ensure that at least 17 employees are working on Monday, we
require that the constraint x1+x4+x5+x6+x7≥17 be satisfied.

41

41

Example 6 – Post Office Problem


 The formulation of the post office’s problem is :
min z  x1  x2  x3  x4  x5  x6  x7
s.t. x1  x4  x5  x6  x7  17 (Monday constraint )
x1  x2  x5  x6  x7  13 (Tuesday constraint )
x1  x2  x3  x6  x7  15 ( Wednesday constraint )
x1  x2  x3  x4  x7  19 (Thursday constraint )
x1  x2  x3  x4  x5  14 (Friday Constraint )
x2  x3  x4  x5  x6  16 (Saturday Constraint )
x3  x4  x5  x6  x7  11 (Sunday Constraint )
xi  0 (i  1,2,  ,7) Sign restrictions 
67 4 10 22
The optimal solution is z  , x1  , x2  , x4 
3 3 3 3
10
x5  0, x6  , x7  5
3 42

42

21
Example 7 – An inventory model
 Sailco Corporation must determine how many sailboats should be produced
during each of the next four quarters (one quarter= three months). The
demand during each of the next four quarters is as follows: first quarter, 40
sailboats; second quarter, 60 sailboats; third quarter,75 sailboats; fourth
quarter, 25 sailboats. Sailco must meet demands on time. At the beginning
of the first quarter, Sailco has inventory of 10 sailboats. At the beginning of
each quarter Sailco must decide how many sailboats should be produced
during each quarter. For simplicity we assume that sailboats manufactured
during a quarter can be used to meet demand for that quarter. During each
quarter, Sailco can produce up to 40 sailboats with regular-time labor at a
total cost of $400 per sailboat. By having employees work overtime during
a quarter, Sailco can produce additional sailboats with overtime labor at a
total cost of $450 per sailboat.
At the end of each quarter (after production has occurred and the current
quarter’s demand has been satisfied), a carrying or holding cost of $20 per
sailboat is incurred. Use linear programming to determine a production
schedule to minimize the sum of production and inventory cost during the
next four quarters.
43

43

Example 7 – An inventory model


 Solution
For each quarter, Sailco must determine the number of sailboats that should be produced by
regular-time and by overtime labor. This, we define the following decision variables:

xt  number of sailboats produced by regular  time labor at 400/boat 


during quarter t t  1,2,3,4 
yt  number of sailboats produced by overtime labor at 500/boat 
during quarter t t  1,2,3,4 
it  number of sailboats on hand at end of quarter t t  1,2,3,4 

Total Cost  cost of producing regulartime boats 


cost of producing overtime boats  inventory costs

Objective function is
min z  400 x1  400 x 2  400 x3  400 x 4  450 y1  450 y 2
 450 y3  40 y 4  20i1  20i 2  20i3  20i4
For quarter t,
Inventort at the end of quarter t  inventory at the end of quartert  1
 quarter t production  quarter t demand 44

44

22
Example 7 – An inventory model
Quarter t demand will be met on time if and only if it  0 (t  1,2,3,4)
The formulation of the problem is

min z  400 x1  400 x 2  400 x3  400 x 4  450 y1  450 y 2


 450 y 3  40 y 4  20i1  20i2  20i3  20i4
s.t. x1  40, x 2  40, x3  40, x 4  40,
i1  10  x1  y1  40
i2  i1  x 2  y 2  60
i3  i2  x3  y 3  75
i4  i3  x 4  y 4  25
ii  0, y t  0, xt  0 (t  1,2,3,4)

The optimal solution to this problem is z  78,540 ; x1  x 2  x3  40 ;


x 4  25 ; y1  0 ; y 2  10 ; y 3  35 ; y 4  0 ; i1  10 ; i2  i3  i4  0

45

45

Example 8 – Advertising Models

Objective To develop an LP model that relates the numbers of ads on various


television shows to the exposures to various viewer groups, and to find the
minimum-cost advertising strategy that meets minimum exposure constraints.

46

46

23
Solving LPs
 Methods  Software
 Graphical  LINDO/LINGO

 Enumeration  GAMS (General Algebraic


 Enumeration (Partial) Modeling System)
 MS Excel - Solver
 Simplex Algorithm
 IBM ILOG CPELX
 Karmakar’s Algorithm
 AMPL

47

47

Example Problem
A new company Wyndor Glass Company has:

3 plants
making 2 products.
 8' glass door : product 1 
Products =  
4  6' window : product 2 
Resources : Production Capacities in 3 plants are as follows:

Production Time, hrs/product Total Available Capacity


Plant Production Time per week, hrs
1 2

1 1 0 4
2 0 2 12
3 3 2 18

Unit Profit 3 5
($)
48

48

24
Example Problem (continued)
 Note :

Plant 1 : makes aluminum frames & hardware


Plant 2 : makes wooden frames
Plant 3 : makes glass products & performs assembly

 Question : What is the Optimal Product Mix, a combination of products 1


and 2, that maximizes the profit of the company?

49

49

Example Problem (continued)


Problem Formulation

1. Define Decision ( Choice ) Variables : Let


x1  number of units of product 1
x2  number of units of product 2

z Total Profit

2. Profit ( or Cost ) Function


Z  3 x1  5 x2
The Company wants to maximize profit!

50

50

25
Example Problem (continued)
3. Restrictions (Constraints) on Production Process

Capacity Constraints:

plant 1 : 1 x1  0 x2  4
plant 2 : 0 x1  2 x2  12

plant 3 : 3 x1  2 x2  18

Non-negativity Constraint :

x1  0; x2  0 There are no negative quantities of products produced.

51

51

Graphical Solution
Consider the region formed by the constraints in form of
inequalities
x2
x1 = 4
(2,6)
(0,6) 2x2 = 12

(4,3)

3x1 + 2x2 = 18

x1
(4,0)

The shaded area is the permissible region of values of (x1, x2).

It is called the FEASIBLE solution set or FEASIBLE REGION.

52

52

26
Graphical Solution (continued)
Now, in order to maximize the objective function Z  3 x1  5 x 2
plot the line 0  3x1  5x2

Next, draw an array of parallel lines (until the next line would leave the feasible region).
x2
Note that the extreme x1 = 4
For Z=36
point with coordinates
(2,6)
(0,6) 2x2 = 12
x1  2 and x2  6
For Z=20
gives the largest possible (4,3)

value to the profit


function. For Z=10
3x1 + 2x2 = 18
Z = 3(2) + 5(6) = 36 For Z=0
x1
(4,0)

53

53

Properties of a Linear Program


 Adding more constraints can never enlarge the feasible region, only shrink
or leave as is.
 The feasible region set takes the form of a convex polytope (created by lines
- planes - hyper planes)
2-D 3-D n-D
 Constraints can be redundant ( e.g. do not affect the feasible region)
 If there is a solution to an LP, then it is always at a corner point solution or
more precisely, the solution always contains a vertex.
 Multiple optima can exist.
 A solution does not always exist.
 Slack and Surplus variable tell which constraints make up a particular vertex
(i.e., a zero slack or surplus says that the constraint is binding.)
54

54

27
Properties of a Linear Program
 If there is exactly one optimal solution, then it must be a corner (point) -
feasible solution.

 If there are multiple optimal solutions, then at least two must be adjacent corner-
feasible solutions.

 There exist only a finite number of corner feasible solutions if there are a finite
number of constraints and variables.

 If a corner-feasible solution is better than all its adjacent corner-feasible, then it is


better than all other corner-feasible solutions; i.e., it is optimal.

 Infeasibility

 Unboundedness
55

55

A Linear Programming Example


(from Winston)

 Given : Giapetto’s Woodcarving, inc.


 Manufactures two types of toys (products) : Soldiers and Trains.

Price ($ / toy) Raw Material ($ / toy) Labor + O/H ($ / toy)


Soldiers 27 10 14
Trains 21 9 10

Required Resources
Labor ( hrs / toy )
Finishing Carpentry
Soldiers 2 1
Trains 1 1

56

56

28
Example: Giapetto’s Woodcarving, Inc.

Available Resources

100 hrs / week for finishing


80 hrs / week for carpentry

Demand for toys

40 soldiers per week


Unlimited weekly demand for trains.

The problem: Find the optimal product mix that maximizes weekly profit!

57

57

Example: Giapetto’s Woodcarving, Inc.

Decision Variables

x1 = number of soldiers produced each week


x2 = number of trains produced each week

Objective Function

Z = Maximize Weekly Profit

Weekly Profit = Weekly Revenue - Weekly Cost


Weekly Revenue = Weekly revenues from soldiers + Weekly revenues
from trains

58

58

29
Example: Giapetto’s Woodcarving, Inc.
 $   soldiers   $   trains 
Weekly Revenue =     
 soldiers   week   train   week 
Weekly Revenue = 27 x1  21x2

Weekly Cost = Weekly raw material cost + Weekly variable labor + O / H cost

Weekly Cost = 10 x1  9 x2  14 x1  10 x2

Maximize Profit

(27 x1  21x2 )  (10 x1  9 x2 )  (14 x1  10 x 2 )  3x1  2 x2

Maximize Z  3x1  2 x2

59

59

Example: Giapetto’s Woodcarving, Inc.


Constraints

Limit on finishing time

Total finishing hrs finishing hrs. soldiers made finishing hrs. trains made
 
Week soldier Week train Week
= 2 x1  x2

Constraint 1
2 x1  x2  100

Constraint 2
x1  x2  80
Constraint 3
x1  40
60

60

30
Example: Giapetto’s Woodcarving, Inc.

Problem Statement

Maximize Z  3x1  2 x2 ( Objective Function )

s.t.
2 x1  x2  100 ( Finishing )

x1  x2  80 ( Carpentry )

x1  40 ( Demand )

x1  0 ( non-negativity)

x2  0 ( non-negativity)

61

61

Example: Giapetto’s Woodcarving, Inc.


 Graphical Solution

X2

2X1 + X2 = 100

(0, 80)
X1 = 40

(20, 60)
Z= 3X1 + 2X2
(40, 20)
For Z = 60
X1 + X2 = 80
For Z = 30

X1
(40, 0) (80, 0)

62

62

31
Review of Linear Algebra
3x  2 y  5 z  3  3 2 5 
 2 x  y  4 z  2 Coefficient matrix A    2 1 4 
 1 4  7 
x  4 y  7z  1
 3 2 5 3 
Augmented matrix A    2 1 4  2 
 1 4 7 1 

1 # # #
0 1 # # 

 0 0 1 # 
63

63

Review of Linear Algebra


• The Gauss - Jordan Method
The Gauss-Jordan Method transforms a given matrix A into a new matrix A’ via
elementary row operation(s).
There are 3 types of Elementary Row Operation (ERO)!
 Type 1: Replacement
 Type 2: Interchanging
 Type 3: Scaling
Type 1 ERO
obtain A’ by multiplying
1 2 3 4 1 2 3 4 
  row 2 of A by 3.  
Given A = 1 3 5 6 A’ = 3 9 15 18
0 1 2 3 0 1 2 3 
64

64

32
The Gauss - Jordan Method
Type 2 ERO
Multiply row i of A by a non-zero scalar C. For some row j other than i (j≠i), let row j
of A’ = C ( row i ) + row j
1 2 3 4
 
Let the other rows of A’ be the same as A. A = 1 3 5 6
0 1 2 3

Example : Multiply “row 2” of A by 4 and replace “row 3” of A by 4 (row 2) + row 3.


The “row 3” of A’ becomes

4 1 3 5 6   0 1 2 3   4 13 22 27 

1 2 3 4 
 
A’ = 1 3 5 6 
4 13 22 27
65

65

The Gauss - Jordan Method (continued)


Type 3 ERO

Interchange any two rows of A.

Example : interchange rows 1 and 3 of A to obtain A’.

1 2 3 4 0 1 2 3
𝐴 1 3 5 6 𝐴′ 1 3 5 6
0 1 2 3 1 2 3 4

How do we apply these EROs to solve a system of linear equations?

66

66

33
The Gauss - Jordan Method (continued)
Problem : Solve x1  x2  2
2 x1  4 x 2  7

First, replace the second equation by


-2 (first equation ) + ( second equation ) to obtain :

x1  x 2  2

2 x2  3
1
Multiply the second equation by yielding :
2
x1  x 2  2
3
x2 
2
67

67

The Gauss - Jordan Method (continued)

Replace the first equation by

-1 ( second equation ) + ( first equation ), yielding :

1
x1 
2
and from here
3
x2 
2

This is a unique solution!

68

68

34
The Gauss - Jordan Method (continued)
Finding a solution by the Gauss - Jordan Method

Use EROs in a systematic fashion to yield a solution.


Given a system of linear equations :

2 x1  2 x 2  x3  9 x1 =?

2 x1  x2  2 x3  6 we wish to reduce it to: x2 =?

x1  x 2  2 x 3  5 x3 =?

x1 =1
in this case: x2 =2
x3 =3
2 2 1 9 
 
The augmented matrix representation is given as : A | b = 2  1 2 6 
1  1 2 5 

69

69

The Gauss - Jordan Method (continued)


 By performing a sequence of EROs (to be shown later), we could transform
A | b into:

2 2 19 
A | b = 2  1 2 6 
 
 1  1 2 5 

1 0 01 
A|b= 0 1 02 
 
 0 0 13 

70

70

35
The Gauss - Jordan Method (continued)
The Plan
We begin by using type 1 - 3 EROs to transform the first column of the
initial matrix (i.e. A | b ) into :
1
0
 
0
Then, we use EROs to transform the second column of the resulting matrix into :
0
1
 
0
Finally, we use EROs to transform the third column of the resulting matrix into :

0
0
 
1

71

71

The Gauss - Jordan Method (continued)


2 2 19 
1  
Step 1. Multiply row 1 of A | b by . A | b = 2  1 2 6 
2
1  1 2 5 
1 1 1 / 2 9 / 2 
A1 | b1  2  1 2 6 

1  1 2 5 

Step 2. Replace row 2 of A1 | b1 by

-2 ( row 1 of A1 | b1 ) + row 2 of A1 | b1

1 1 1/ 2 9 / 2 
A2 | b2 = 0  3 1 3 

1  1 2 5 

72

72

36
The Gauss - Jordan Method (continued)
Step 3. Replace row 3 of A2 | b2 by :

-1 ( row 1 of A2 | b2 ) + row 3 of A2 | b2

1 1 1/ 2 9 / 2 
A3 | b3 = 0  3 1 3 
 
0  2 3 / 2 1 / 2 

The first column of A | b has now been transformed into :

1
0
 
0

73

73

The Gauss - Jordan Method (continued)


1 1 1/ 2 9 / 2 
1
Step 4. Multiply row 2 of A3 | b3 by - A3 | b3 = 0  3 1 3 
3  
0  2 3 / 2 1 / 2 
1 1 1/ 2 9 / 2 
A4 | b4 = 0 1  1 / 3 1 
 
0  2 3 / 2 1 / 2 

Step 5. Replace row 1 of A4 | b4 by :

-1 ( row 2 of A4 |b4 ) + row 1 of A4 | b4

1 0 5/ 6 7 / 2 
0 1  1 / 3 1 
A5 | b5 =  
0  2 3 / 2 1 / 2 

74

74

37
The Gauss - Jordan Method (continued)
1 0 5/ 6 7 / 2 
0 1  1 / 3 1 
Step 6. Replace row 3 of A5 | b5 by : A5 | b5 =  
0  2 3 / 2 1 / 2 

2 ( row 2 of A5 | b5 ) + row 3 of A5 | b5

1 0 5/ 6 7 / 2 
A6 | b6 = 0 1  1 / 3 1 
 
0 0 5 / 6 5 / 2 

The second column of A | b has now been transformed into :

0
1
 
0

75

75

The Gauss - Jordan Method (continued)


6 1 0 5/ 6 7 / 2 
Step 7. Multiply row 3 of A6 | b6 by A6 | b6 = 0 1  1 / 3 1 
5  
0 0 5 / 6 5 / 2 

1 0 5/ 6 7 / 2 

A7 | b7 = 0 1 1/ 3 1 
 
0 0 1 3 

5
Step 8. Replace row 1 of A7 | b7 by : - (row 3 of A7 | b7 ) + row 1 of A7 | b7
6

1 0 0 1

A8 | b8 = 0 1  1 / 3 1

 
0 0 1 3 

76

76

38
The Gauss - Jordan Method (continued)
Step 9. Replace row 2 of A8 | b8 by :
1 0 0 1
1 A8 | b8 = 0 1 1/ 3 1
( row 3 of A8 | b8 ) + row 2 of A8 | b8  
3 0 0 1 3

1 0 0 1 

A9 | b9 = 0 1 0 2

 
0 0 1 3 

This represents the system of equations :


x1 =1

x2 =2

x3 = 3
Since A9 | b9 was obtained from A | b via EROs, the unique solution to A | b must also

be: x1 = 1, x2 = 2, x3 = 3
77

77

39

You might also like