You are on page 1of 211

1

Introduction
Session 1
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Body of Knowledge
Problem Solving and
Decision Making
Quantitative Analysis
and Decision Making
Quantitative Analysis
Models of Cost,
Revenue, and Profit
Management Science
Techniques

Body of Knowledge
The body of knowledge involving quantitative
approaches to decision making is referred to as
Management Science
Operations Research
Decision Science
It had its early roots in World War II and is flourishing
in business and industry due, in part, to:
numerous methodological developments (e.g.
simplex method for solving linear programming
problems)
a virtual explosion in computing power
7 Steps of Problem Solving
(First 5 steps are the process of decision making)
1. Identify and define the problem.
2. Determine the set of alternative solutions.
3. Determine the criteria for evaluating alternatives.
4. Evaluate the alternatives.
5. Choose an alternative (make a decision).
6. Implement the selected alternative.
7. Evaluate the results.
Problem Solving and Decision
Making
Quantitative Analysis and Decision Making
Define
the
Problem
Identify
the
Alternatives
Determine
the
Criteria
Identify
the
Alternatives
Choose
an
Alternative
Structuring the Problem Analyzing the Problem
Decision-Making Process
Qualitative Analysis
based largely on the managers judgment and experience
includes the managers intuitive feel for the problem
is more of an art than a science


Analysis Phase of Decision-Making Process
Quantitative Analysis and Decision Making
Potential Reasons for a Quantitative
Analysis Approach to Decision Making
The problem is complex.
The problem is very important.
The problem is new.
The problem is repetitive.
Quantitative Analysis Process
Model Development
Data Preparation
Model Solution
Report Generation

Quantitative Analysis
Model Development
Models are representations of real objects or situations
Three forms of models are:
Iconic models - physical replicas (scalar
representations) of real objects
Analog models - physical in form, but do not
physically resemble the object being modeled
Mathematical models - represent real world
problems through a system of mathematical
formulas and expressions based on key
assumptions, estimates, or statistical analyses
Advantages of Models
Generally, experimenting with models
(compared to experimenting with the real
situation):
requires less time
is less expensive
involves less risk
The more closely the model represents the
real situation, the accurate the conclusions
and predictions will be.
Mathematical Models
Objective Function a mathematical expression
that describes the problems objective, such as
maximizing profit or minimizing cost
Constraints a set of restrictions or limitations,
such as production capacities
Uncontrollable Inputs environmental factors
that are not under the control of the decision
maker
Decision Variables controllable inputs; decision
alternatives specified by the decision maker,
such as the number of units of Product X to
produce
Data Preparation
Data preparation is not a trivial step, due
to the time required and the possibility of
data collection errors.
A model with 50 decision variables and 25
constraints could have over 1300 data
elements!
Often, a fairly large data base is needed.
Information systems specialists might be
needed.

Model Solution
The analyst attempts to identify the alternative (the set
of decision variable values) that provides the best
output for the model.
The best output is the optimal solution.
If the alternative does not satisfy all of the model
constraints, it is rejected as being infeasible,
regardless of the objective function value.
If the alternative satisfies all of the model constraints,
it is feasible and a candidate for the best solution.
A variety of software packages are available for
solving mathematical models.
Microsoft Excel
The Management Scientist
LINGO
Model Testing and Validation
Often, goodness/accuracy of a model cannot be
assessed until solutions are generated.
Small test problems having known, or at least
expected, solutions can be used for model testing and
validation.
If the model generates expected solutions, use the
model on the full-scale problem.
If inaccuracies or potential shortcomings inherent in
the model are identified, take corrective action such
as:
Collection of more-accurate input data
Modification of the model
End of Session 1
An Introduction to Linear
Programming
Session 2
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Linear Programming
Problem
Problem Formulation
A Simple
Maximization
Problem
Graphical Solution
Procedure
Linear Programming
Linear programming has nothing to do
with computer programming.
The use of the word programming here
means choosing a course of action.
Linear programming involves choosing a
course of action when the mathematical
model of the problem contains only linear
functions.
Linear Programming (LP)
Problem
The maximization or minimization of some quantity
is the objective in all linear programming problems.
All LP problems have constraints that limit the
degree to which the objective can be pursued.
A feasible solution satisfies all the problem's
constraints.
An optimal solution is a feasible solution that results
in the largest possible objective function value
when maximizing (or smallest when minimizing).
A graphical solution method can be used to solve a
linear program with two variables.
Linear Programming (LP)
Problem
If both the objective function and the constraints
are linear, the problem is referred to as a linear
programming problem.
Linear functions are functions in which each
variable appears in a separate term raised to the
first power and is multiplied by a constant (which
could be 0).
Linear constraints are linear functions that are
restricted to be "less than or equal to", "equal
to", or "greater than or equal to" a constant.
Problem Formulation
Problem formulation or modeling is the process
of translating a verbal statement of a problem
into a mathematical statement.
Formulating models is an art that can only be
mastered with practice and experience.
Every LP problems has some unique features,
but most problems also have common features.
General guidelines for LP model formulation are
illustrated on the slides that follow.
Guidelines for Model
Formulation
Understand the problem thoroughly.
Describe the objective.
Describe each constraint.
Define the decision variables.
Write the objective in terms of the decision
variables.
Write the constraints in terms of the
decision variables.
Summary of the Graphical Solution
Procedure
for Maximization Problems
Prepare a graph of the feasible solutions for
each of the constraints.
Determine the feasible region that satisfies all
the constraints simultaneously.
Draw an objective function line.
Move parallel objective function lines toward
larger objective function values without entirely
leaving the feasible region.
Any feasible solution on the objective function
line with the largest value is an optimal
solution.
Max 5x
1
+ 7x
2
+ 0s
1
+ 0s
2
+
0s
3


s.t. x
1
+ s
1

= 6
2x
1
+ 3x
2
+ s
2

= 19
x
1
+ x
2
+
s
3
= 8

x
1
, x
2
, s
1
,
s
2
, s
3
> 0
Example 1 in Standard Form
Slack Variables (for <
constraints)
s
1
, s
2
, and s
3

are slack variables
Example 1: Extreme Points
x
1
Feasible
Region
1 2
3
4
5
x
2
8

7

6

5

4

3

2

1
1 2 3 4 5 6 7 8 9 10
(0, 6 1/3)
(5, 3)
(0, 0)
(6, 2)
(6, 0)
End of Session 2
An Introduction to Linear
Programming
Session 3
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Extreme Points and
the Optimal Solution
Computer Solutions
A Simple
Minimization
Problem
Special Cases
Computer Solutions
LP problems involving 1000s of variables and
1000s of constraints are now routinely solved
with computer packages.
Linear programming solvers are now part of
many spreadsheet packages, such as Microsoft
Excel.
Leading commercial packages include CPLEX,
LINGO, MOSEK, Xpress-MP, and Premium
Solver for Excel.
The Management Scientist, a package developed
by the authors of your textbook, has an LP
module.
Interpretation of Computer
Output
In this session we will discuss the following
output:
objective function value
values of the decision variables
reduced costs
slack and surplus
In the next session we will discuss how an
optimal solution is affected by a change in:
a coefficient of the objective function
the right-hand side value of a constraint
Example 2: A Simple
Minimization Problem
LP Formulation
Min 5x
1
+ 2x
2


s.t. 2x
1
+ 5x
2
> 10
4x
1
x
2
> 12
x
1
+ x
2
> 4

x
1
, x
2
> 0
Example 2: Graphical Solution
x
2
4x
1
x
2
> 12
2x
1
+ 5x
2
> 10
x
1
1 2 3 4 5 6
6

5

4

3

2

1
x
1
+ x
2
> 4
Optimal Solution
Optimal Solution:
x
1
= 16/5, x
2
= 4/5,
5x
1
+ 2x
2
= 17.6

Summary of the Graphical Solution
Procedure
for Minimization Problems
Prepare a graph of the feasible solutions for each of
the constraints.
Determine the feasible region that satisfies all the
constraints simultaneously.
Draw an objective function line.
Move parallel objective function lines toward smaller
objective function values without entirely leaving the
feasible region.
Any feasible solution on the objective function line
with the smallest value is an optimal solution.
Surplus Variables
Example 2 in Standard Form
Min 5x
1
+ 2x
2
+ 0s
1
+ 0s
2
+ 0s
3

s.t. 2x
1
+ 5x
2
s
1
= 10
4x
1
x
2
s
2
= 12
x
1
+ x
2
s
3
= 4

x
1
, x
2
, s
1
, s
2
, s
3
> 0
s
1
, s
2
, and s
3
are
surplus variables
Example 2: Spreadsheet Solution
Interpretation of Computer Output

We see from the previous slide that:

Objective Function Value = 17.6
Decision Variable #1 (x
1
) = 3.2
Decision Variable #2 (x
2
) = 0.8
Surplus in Constraint #1 = 10.4 10 = 0.4
Surplus in Constraint #2 = 12.0 12 = 0.0
Surplus in Constraint #3 = 4.0 4 = 0.0
Special Cases
1. Alternative Optimal Solutions
In the graphical method, if the objective function
line is parallel to a boundary constraint in the
direction of optimization, there are alternate
optimalsolutions, with all points on this line
segment being optimal.
2. Unbounded
The solution to a maximization LP problem is
unbounded if the value of the solution may be
made indefinitely large without violating any of the
constraints.
For real problems, this is the result of improper
formulation. (Quite likely, a constraint has been
inadvertently omitted.)

Special Cases
2. Infeasibility
No solution to the LP problem satisfies all
the constraints, including the non-negativity
conditions. Graphically, this means a
feasible region does not exist.
Causes include:
A formulation error has been made.
Managements expectations are too high.
Too many restrictions have been placed on the
problem (i.e. the problem is over-constrained).

End of Session 3
Session 4
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Introduction to
Sensitivity Analysis
Graphical Sensitivity
Analysis
Linear Programming: Sensitivity
Analysis
Introduction to Sensitivity Analysis
Sensitivity analysis (or post-optimality analysis)
is used to determine how the optimal solution is
affected by changes, within specified ranges, in:
the objective function coefficients
the right-hand side (RHS) values
Sensitivity analysis is important to a manager
who must operate in a dynamic environment
with imprecise estimates of the coefficients.
Sensitivity analysis allows a manager to ask
certain what-if questions about the problem.
Example 1
LP Formulation
Max 5x
1
+ 7x
2


s.t. x
1
< 6
2x
1
+ 3x
2
< 19
x
1
+ x
2
< 8

x
1
, x
2
> 0
Example 1
Graphical Solution
2x
1
+ 3x
2
< 19
x
2
x
1
x
1
+ x
2
< 8
Max 5x
1
+ 7x
2
x
1
< 6
Optimal Solution:
x
1
= 5, x
2
= 3
8

7

6

5

4

3

2

1
1 2 3 4 5 6 7 8 9 10
Objective Function Coefficients
Let us consider how changes in the
objective function coefficients might
affect the optimal solution.
The range of optimality for each
coefficient provides the range of values
over which the current solution will
remain optimal.
Managers should focus on those
objective coefficients that have a narrow
range of optimality and coefficients near
the endpoints of the range.
Example 1
Changing Slope of Objective Function
x
1
Feasible
Region
1 2
3
4
5
x
2
Coincides with
x
1
+ x
2
< 8
constraint line
8

7

6

5

4

3

2

1
1 2 3 4 5 6 7 8 9 10
Coincides with
2x
1
+ 3x
2
< 19
constraint line
Objective function
line for 5x
1
+ 7x
2

Range of Optimality
Graphically, the limits of a range of
optimality are found by changing the
slope of the objective function line within
the limits of the slopes of the binding
constraint lines.
Slope of an objective function line, Max
c
1
x
1
+ c
2
x
2
, is -c
1
/c
2
, and the slope of a
constraint, a
1
x
1
+ a
2
x
2
= b, is -a
1
/a
2
.
Example 1
Range of Optimality for c
1

The slope of the objective function line is -c
1
/c
2
.
The slope of the first binding constraint, x
1
+ x
2
= 8, is
-1 and the slope of the second binding constraint,
x
1
+ 3x
2
= 19, is -2/3.
Find the range of values for c
1
(with c
2
staying 7)
such that the objective function line slope lies
between that of the two binding constraints:
-1 < -c
1
/7 < -2/3
Multiplying through by -7 (and reversing the
inequalities):
14/3 < c
1
< 7
Example 1
Range of Optimality for c
2

Find the range of values for c
2
( with
c
1
staying 5) such that the objective
function line slope lies between that of
the two binding constraints:
-1 < -5/c
2
<
-2/3

Multiplying by -1: 1 > 5/c
2
>
2/3
Inverting, 1 < c
2
/5 <
3/2

Multiplying by 5: 5 < c
2
<
15/2
End of Session 4
Session 5
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Sensitivity Analysis:
Computer Solution

Simultaneous
Changes
Linear Programming:
Sensitivity Analysis

Software packages such as The Management Scientist and
Microsoft Excel provide the following LP information:
Information about the objective function:
its optimal value
coefficient ranges (ranges of optimality)
Information about the decision variables:
their optimal values
their reduced costs
Information about the constraints:
the amount of slack or surplus
the dual prices
right-hand side ranges (ranges of feasibility)
Sensitivity Analysis: Computer Solution
Example 1
Range of Optimality for c
1
and c
2
Adjustable Cells
Final Reduced Objective Allowable Allowable
Cell Name Value Cost Coefficient Increase Decrease
$B$8 X1 5.0 0.0 5 2 0.33333333
$C$8 X2 3.0 0.0 7 0.5 2
Constraints
Final Shadow Constraint Allowable Allowable
Cell Name Value Price R.H. Side Increase Decrease
$B$13 #1 5 0 6 1E+30 1
$B$14 #2 19 2 19 5 1
$B$15 #3 8 1 8 0.33333333 1.66666667
Right-Hand Sides
Let us consider how a change in the right-
hand side for a constraint might affect the
feasible region and perhaps cause a change
in the optimal solution.
The improvement in the value of the optimal
solution per unit increase in the right-hand
side is called the dual price.
The range of feasibility is the range over
which the dual price is applicable.
As the RHS increases, other constraints will
become binding and limit the change in the
value of the objective function.
Dual Price
Graphically, a dual price is determined by
adding +1 to the right hand side value in
question and then resolving for the optimal
solution in terms of the same two binding
constraints.
The dual price is equal to the difference in the
values of the objective functions between the
new and original problems.
The dual price for a nonbinding constraint is 0.
A negative dual price indicates that the objective
function will not improve if the RHS is
increased.
Relevant Cost and Sunk Cost
A resource cost is a relevant cost if the
amount paid for it is dependent upon the
amount of the resource used by the decision
variables.
Relevant costs are reflected in the objective
function coefficients.
A resource cost is a sunk cost if it must be
paid regardless of the amount of the resource
actually used by the decision variables.
Sunk resource costs are not reflected in the
objective function coefficients.
Cautionary Note on
the Interpretation of Dual Prices
Resource cost is sunk
The dual price is the maximum amount
you should be willing to pay for one
additional unit of the resource.
Resource cost is relevant
The dual price is the maximum premium
over the normal cost that you should be
willing to pay for one unit of the
resource.
Range of Feasibility
The range of feasibility for a change in
the right hand side value is the range of
values for this coefficient in which the
original dual price remains constant.
Graphically, the range of feasibility is
determined by finding the values of a
right hand side coefficient such that the
same two lines that determined the
original optimal solution continue to
determine the optimal solution for the
problem.
Simultaneous Changes
Range of Optimality and 100% Rule
The 100% rule states that simultaneous changes in
objective function coefficients will not change the
optimal solution as long as the sum of the percentages
of the change divided by the corresponding maximum
allowable change in the range of optimality for each
coefficient does not exceed 100%.
End of Session 5
Linear Programming
Applications
Session 6
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Marketing Applications
Finance & Operations
Applications
Blending Problems
One application of linear programming in
marketing is media selection.
LP can be used to help marketing managers
allocate a fixed budget to various advertising
media.
The objective is to maximize reach, frequency,
and quality of exposure.
Restrictions on the allowable allocation usually
arise during consideration of company policy,
contract requirements, and media availability.
Marketing Applications
Financial Applications
LP can be used in financial decision-making that
involves capital budgeting, make-or-buy, asset
allocation, portfolio selection, financial planning,
and more.
Portfolio selection problems involve choosing
specific investments for example, stocks and
bonds from a variety of investment
alternatives.
This type of problem is faced by managers of
banks, mutual funds, and insurance companies.
The objective function usually is maximization
of expected return or minimization of risk.
Operations Management
Applications
LP can be used in operations management to aid in
decision-making about product mix, production
scheduling, staffing, inventory control, capacity
planning, and other issues.
An important application of LP is multi-period
planning such as production scheduling.
Usually the objective is to establish an efficient, low-
cost production schedule for one or more products
over several time periods.
Typical constraints include limitations on production
capacity, labor capacity, storage space, and more.
Revenue Management
Another LP application is revenue management.
Revenue management involves managing the short-
term demand for a fixed perishable inventory in
order to maximize revenue potential.
The methodology was first used to determine how
many airline seats to sell at an early-reservation
discount fare and many to sell at a full fare.
Application areas now include hotels, apartment
rentals, car rentals, cruise lines, and golf courses.
Portfolio Models and Asset
Management
Asset allocation involves determining how to allocate
investment funds across a variety of asset classes
such as stocks, bonds, mutual funds, real estate.
Portfolio models are used to determine percentage of
funds that should be made in each asset class.
The goal is to create a portfolio that provides the best
balance between risk and return.
End of Session 6
Session 7
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
An Overview of the Simplex
Method
Standard & Tableau Form
Setting Up the Initial
Simplex Tableau
Improving the Solution
Solving a Minimization
Problem
Special Cases
Linear Programming: Simplex
Method
Overview of the Simplex
Method
Steps Leading to the Simplex
Method
Formulate
Problem
as LP
Put In
Standard
Form
Put In
Tableau
Form
Execute
Simplex
Method
Standard Form
An LP is in standard form when:
All variables are non-negative
All constraints are equalities
Putting an LP formulation into standard
form involves:
Adding slack variables to < constraints
Subtracting surplus variables from >
constraints.
Tableau Form
A set of equations is in tableau form if for
each equation:
its right hand side (RHS) is non-negative, and
there is a basic variable. (A basic variable for
an equation is a variable whose coefficient in
the equation is +1 and whose coefficient in all
other equations of the problem is 0.)
To generate an initial tableau form:
An artificial variable must be added to each
constraint that does not have a basic variable.
Setting Up Initial Simplex
Tableau
Step 1: If the problem is a minimization problem,
multiply the objective function by -1.

Step 2: If the problem formulation contains any
constraints with negative right-hand sides, multiply
each constraint by -1.

Step 3: Add a slack variable to each < constraint.

Step 4: Subtract a surplus variable and add an
artificial variable to each > constraint.
Setting Up Initial Simplex Tableau
Step 5: Add an artificial variable to each =
constraint.

Step 6: Set each slack and surplus variable's
coefficient in the objective function equal to zero.

Step 7: Set each artificial variable's coefficient in
the objective function equal to -M, where M is a
very large number.

Step 8: Each slack and artificial variable becomes
one of the basic variables in the initial basic
feasible solution.
Simplex Method
Step 1: Determine Entering Variable
Identify the variable with the most positive value in
the c
j
- z
j
row. (The entering column is called the
pivot column.)
Step 2: Determine Leaving Variable
For each positive number in the entering column,
compute the ratio of the right-hand side values
divided by these entering column values.
If there are no positive values in the entering
column, STOP; the problem is unbounded.
Otherwise, select the variable with the minimal
ratio. (The leaving row is called the pivot row.)
Simplex Method
Step 3: Generate Next Tableau
Divide the pivot row by the pivot element (the
entry at the intersection of the pivot row and pivot
column) to get a new row. We denote this new
row as (row *).
Replace each non-pivot row i with:
[new row i] = [current row i] - [(a
ij
) x (row *)],
where a
ij
is the value in entering column j of row I

Step 4: Calculate z
j
Row for New Tableau
For each column j, multiply the objective function
coefficients of the basic variables by the
corresponding numbers in column j and sum
them.

Simplex Method
Step 5: Calculate c
j
- z
j
Row for New Tableau
For each column j, subtract the z
j
row from the c
j
row.
If none of the values in the c
j
- z
j
row are positive,
GO TO STEP 1.
If there is an artificial variable in the basis with a
positive value, the problem is infeasible. STOP.
Otherwise, an optimal solution has been found. The
current values of the basic variables are optimal. The
optimal values of the non-basic variables are all zero.
If any non-basic variable's c
j
- z
j
value is 0, alternate
optimal solutions might exist. STOP.
Special Cases
Infeasibility
Unboundedness
Alternative Optimal Solution
Degeneracy
Infeasibility
Infeasibility is detected in the simplex
method when an artificial variable remains
positive in the final tableau.
A linear program has an unbounded
solution if all entries in an entering column
are non-positive.

Unboundedness
Alternative Optimal Solution
A linear program has alternate optimal
solutions if the final tableau has a c
j
- z
j

value equal to 0 for a non-basic variable.
Degeneracy
A degenerate solution to a linear program is one in which
at least one of the basic variables equals 0.
This can occur at formulation or if there is a tie for the
minimizing value in the ratio test to determine the leaving
variable.
When degeneracy occurs, an optimal solution may have
been attained even though some c
j
z
j
> 0.
Thus, the condition that c
j
z
j
< 0 is sufficient for
optimality, but not necessary.

End of Session 7
Session 8
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Transportation
Problem
Network
Representation
General LP
Formulation
Transportation Problem: The
Network Model & a Linear
Programming Formulation
Transportation, Assignment,
and Transshipment Problems
A network model is one which can be represented by a
set of nodes, a set of arcs, and functions (e.g. costs,
supplies, demands, etc.) associated with the arcs
and/or nodes.
Transportation, assignment, transshipment, shortest-
route, and maximal flow problems of this chapter as
well as the minimal spanning tree and PERT/CPM
problems (in others chapter) are all examples of
network problems.
Transportation, Assignment,
and Transshipment Problems
Each of the five models of this chapter can be
formulated as linear programs and solved by general
purpose linear programming codes.
For each of the five models, if the right-hand side of the
linear programming formulations are all integers, the
optimal solution will be in terms of integer values for the
decision variables.
However, there are many computer packages (including
The Management Scientist) that contain separate
computer codes for these models which take advantage
of their network structure.
Transportation Problem
The transportation problem seeks to minimize
the total shipping costs of transporting goods
from m origins (each with a supply s
i
) to n
destinations (each with a demand d
j
), when
the unit shipping cost from an origin, i, to a
destination, j, is c
ij
.
The network representation for a
transportation problem with two sources and
three destinations is given on the next slide.
Transportation Problem
Network
Representation
2
c
11
c
12
c
13
c
21
c
22
c
23
d
1
d
2
d
3
s
1
s
2
Sources Destinations
3
2
1
1
Transportation Problem
Linear Programming Formulation

Using the notation:
x
ij
= number of units shipped from
origin i to destination j
c
ij
= cost per unit of shipping from
origin i to destination j
s
i
= supply or capacity in units at origin i
d
j
= demand in units at destination j
continued
Transportation Problem
Linear Programming Formulation
(continued)
1 1
Min
m n
ij ij
i j
c x
= =

1
1, 2, , Supply
n
ij i
j
x s i m
=
s =

1
1, 2, , Demand
m
ij j
i
x d j n
=
s =

x
ij
> 0 for all i and j
LP Formulation Special Cases
Minimum shipping guarantee from i to j:

The objective is maximizing profit or revenue:
x
ij
> L
ij

Maximum route capacity from i to j:

x
ij
< L
ij


Unacceptable route:
Remove the corresponding decision variable.
Transportation Problem
Solve as a maximization problem.
End of Session 8
Session 9
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Assignment Problem
Network
Representation
General LP
Formulation

Assignment Problem: The Network
Model & a Linear Programming
Formulation
Assignment Problem
An assignment problem seeks to minimize the total cost
assignment of m workers to m jobs, given that the cost of
worker i performing job j is c
ij
.
It assumes all workers are assigned and each job is
performed.
An assignment problem is a special case of a
transportation problem in which all supplies and all
demands are equal to 1; hence assignment problems
may be solved as linear programs.
The network representation of an assignment problem
with three workers and three jobs is shown on the next
slide.
Assignment Problem
Network Representation
2
3
1
2
3
1
c
11
c
12
c
13
c
21
c
22
c
23
c
31
c
32
c
33
Agents Tasks
Linear Programming Formulation

Using the notation:

x
ij
= 1 if agent i is assigned to task j
0 otherwise

c
ij
= cost of assigning agent i to task j
Assignment Problem
continued
Linear Programming Formulation
(continued)
Assignment Problem
1 1
Min
m n
ij ij
i j
c x
= =

1
1 1, 2, , Agents
n
ij
j
x i m
=
s =

1
1 1, 2, , Tasks
m
ij
i
x j n
=
= =

x
ij
> 0 for all i and j
LP Formulation Special Cases
Number of agents exceeds the number of tasks:



Number of tasks exceeds the number of agents:

Add enough dummy agents to equalize the
number of agents and the number of tasks.
The objective function coefficients for these
new variable would be zero.
Assignment Problem
Extra agents simply remain unassigned.
Assignment Problem
LP Formulation Special Cases (continued)
The assignment alternatives are evaluated in terms
of revenue or profit:
Solve as a maximization problem.

An assignment is unacceptable:
Remove the corresponding decision variable.

An agent is permitted to work t tasks:
1
1, 2, , Agents
n
ij
j
x t i m
=
s =

End of Session 9
Session 10
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Introduction
Game Models
Two Persons Zero
Sum Games
Saddle Points

Game Theory

Introduction to Game Theory
In decision analysis, a single decision maker seeks to
select an optimal alternative.
In game theory, there are two or more decision makers,
called players, who compete as adversaries against
each other.
It is assumed that each player has the same information
and will select the strategy that provides the best
possible outcome from his point of view.
Each player selects a strategy independently without
knowing in advance the strategy of the other player(s).

continue
Introduction to Game Theory
The combination of the competing strategies provides
the value of the game to the players.
Examples of competing players are teams, armies,
companies, political candidates, and contract bidders.
Two-person means there are two competing players in
the game.
Zero-sum means the gain (or loss) for one player is
equal to the corresponding loss (or gain) for the other
player.
The gain and loss balance out so that there is a zero-
sum for the game.
What one player wins, the other player loses.
Two-Person Zero-Sum Game
Competing for Vehicle Sales
Suppose that there are only two vehicle dealer-
ships in a small city. Each dealership is considering
three strategies that are designed to
take sales of new vehicles from
the other dealership over a
four-month period. The
strategies, assumed to be the
same for both dealerships, are on
the next slide.

Two-Person Zero-Sum Game Example
Strategy Choices

Strategy 1: Offer a cash rebate
on a new vehicle.
Strategy 2: Offer free optional
equipment on a
new vehicle.
Strategy 3: Offer a 0% loan
on a new vehicle.
Two-Person Zero-Sum Game
Example
2 2 1
Cash
Rebate
b
1
0%
Loan
b
3
Free
Options
b
2
Dealership B
Payoff Table: Number of Vehicle Sales
Gained Per Week by Dealership A
(or Lost Per Week by Dealership B)
-3 3 -1
3 -2 0
Cash Rebate a
1
Free Options a
2
0% Loan a
3
Dealership A
Two-Person Zero-Sum Game
Example
Step 1: Identify the minimum payoff for each
row (for Player A).
Step 2: For Player A, select the strategy that provides
the maximum of the row minimums (called
the maximin).
Two-Person Zero-Sum Game
Identifying Maximin and Best Strategy
Row
Minimum
1
-3
-2
2 2 1
Cash
Rebate
b
1
0%
Loan
b
3
Free
Options
b
2
Dealership B
-3 3 -1
3 -2 0
Cash Rebate a
1
Free Options a
2
0% Loan a
3
Dealership A
Best Strategy
For Player A
Maximin
Payoff
Two-Person Zero-Sum Game Example
Step 3: Identify the maximum payoff for each column
(for Player B).
Step 4: For Player B, select the strategy that provides
the minimum of the column maximums
(called the minimax).
Two-Person Zero-Sum Game
Identifying Minimax and Best Strategy
2 2 1
Cash
Rebate
b
1
0%
Loan
b
3
Free
Options
b
2
Dealership B
-3 3 -1
3 -2 0
Cash Rebate a
1
Free Options a
2
0% Loan a
3
Dealership A
Column Maximum 3 3 1
Best Strategy
For Player B
Minimax
Payoff
Two-Person Zero-Sum Game Example
End of Session 10
Session 11
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Pure & Mixed Strategy
Dominance Rule
Limitations of Game
Theory
Game Theory

Pure Strategy
Whenever an optimal pure strategy exists:
the maximum of the row minimums equals the
minimum of the column maximums (Player As
maximin equals Player Bs minimax)
the game is said to have a saddle point (the
intersection of the optimal strategies)
the value of the saddle point is the value of the
game
neither player can improve his/her outcome by
changing strategies even if he/she learns in
advance the opponents strategy
Row
Minimum
1
-3
-2
Cash
Rebate
b
1
0%
Loan
b
3
Free
Options
b
2
Dealership B
-3 3 -1
3 -2 0
Cash Rebate a
1
Free Options a
2
0% Loan a
3
Dealership A
Column Maximum 3 3 1
Pure Strategy Example
Saddle Point and Value of the Game
2 2 1
Saddle
Point
Value of the
game is 1
Pure Strategy Example
Pure Strategy Summary
Player A should choose Strategy a
1
(offer a cash
rebate).
Player A can expect a gain of at least 1 vehicle
sale per week.
Player B should choose Strategy b
3
(offer a 0%
loan).
Player B can expect a loss of no more than 1
vehicle sale per week.
Mixed Strategy
If the maximin value for Player A does not equal the
minimax value for Player B, then a pure strategy is not
optimal for the game.
In this case, a mixed strategy is best.
With a mixed strategy, each player employs more than
one strategy.
Each player should use one strategy some of the time
and other strategies the rest of the time.
The optimal solution is the relative frequencies with
which each player should use his possible strategies.
Mixed Strategy Example
b
1
b
2
Player B
11 5
a
1
a
2
Player A
4 8
Consider the following two-person zero-sum game.
The maximin does not equal the minimax. There is
not an optimal pure strategy.
Column
Maximum
11 8
Row
Minimum
4
5
Maximin
Minimax
Mixed Strategy Example
p = the probability Player A selects strategy a
1
(1 p) = the probability Player A selects strategy a
2
If Player B selects b
1
:

EV = 4p + 11(1 p)

If Player B selects b
2
:

EV = 8p + 5(1 p)

Mixed Strategy Example
4p + 11(1 p) = 8p + 5(1 p)
To solve for the optimal probabilities for Player A
we set the two expected values equal and solve for
the value of p.

4p + 11 11p = 8p + 5 5p
11 7p = 5 + 3p
-10p = -6
p = .6
Player A should select:
Strategy a
1
with a .6 probability and
Strategy a
2
with a .4 probability.

Hence,
(1 p) = .4
Mixed Strategy Example
q = the probability Player B selects strategy b
1
(1 q) = the probability Player B selects strategy b
2
If Player A selects a
1
:

EV = 4q + 8(1 q)

If Player A selects a
2
:

EV = 11q + 5(1 q)

Mixed Strategy Example
Value of the Game
For Player A:

EV = 4p + 11(1 p) = 4(.6) + 11(.4) = 6.8

For Player B:

EV = 4q + 8(1 q) = 4(.3) + 8(.7) = 6.8

Expected gain
per game
for Player A
Expected loss
per game
for Player B
Dominated Strategies Example
Row
Minimum
-2
0
-3
b
1
b
3
b
2
Player B
1 0 3
3 4 -3
a
1
a
2
a
3
Player A
Column
Maximu
m
6 5 3
6 5 -2
Suppose that the payoff table for a two-person zero-
sum game is the following. Here there is no optimal
pure strategy.
Maximin
Minimax
Dominated Strategies Example
b
1
b
3
b
2
Player B
1 0 3
Player A
6 5 -2
If a game larger than 2 x 2 has a mixed strategy,
we first look for dominated strategies in order to
reduce the size of the game.
3 4 -3
a
1
a
2
a
3
Player As Strategy a
3
is dominated by
Strategy a
1
, so Strategy a
3
can be eliminated.
End of Session 11
Session 12
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Types of Integer
Linear Programming
Models
Graphical and
Computer Solutions
for an All-Integer
Linear Program

Integer Linear Programming
Models
Types of Integer Programming
Models
An LP in which all the variables are restricted to be
integers is called an all-integer linear program (ILP).
The LP that results from dropping the integer requirements
is called the LP Relaxation of the ILP.
If only a subset of the variables are restricted to be
integers, the problem is called a mixed-integer linear
program (MILP).
Binary variables are variables whose values are restricted
to be 0 or 1. If all variables are restricted to be 0 or 1, the
problem is called a 0-1 or binary integer linear program.
Example: All-Integer LP
Consider the following all-integer linear
program:

Max 3x
1
+ 2x
2


s.t. 3x
1
+ x
2
< 9
x
1
+ 3x
2
< 7
-x
1
+ x
2
< 1

x
1
, x
2
> 0 and integer
Example: All-Integer LP
LP Relaxation
Solving the problem as a linear
program ignoring the integer constraints,
the optimal solution to the linear program
gives fractional values for both x
1
and x
2
.
From the graph on the next slide, we see
that the optimal solution to the linear
program is:

x
1
= 2.5, x
2
= 1.5,
Max 3x
1
+ 2x
2
= 10.5
Example: All-Integer LP
LP Relaxation
LP Optimal (2.5, 1.5)
Max 3x
1
+ 2x
2
x
1
+ x
2
< 1
x
2
x
1
3x
1
+ x
2
< 9
x
1
+ 3x
2
< 7
1 2 3 4 5 6 7
1
3
2
5
4
Example: All-Integer LP
Rounding Up
If we round up the fractional solution
(x
1
= 2.5, x
2
= 1.5) to the LP relaxation
problem, we get x
1
= 3 and x
2
= 2. From
the graph on the next slide, we see that
this point lies outside the feasible region,
making this solution infeasible.
Example: All-Integer LP
Rounded Up Solution
ILP Infeasible (3, 2)
LP Optimal (2.5, 1.5)
Max 3x
1
+ 2x
2
x
1
+ x
2
< 1
x
2
x
1
3x
1
+ x
2
< 9
x
1
+ 3x
2
< 7
1 2 3 4 5 6 7
1
3
2
5
4
Example: All-Integer LP
Rounding Down
By rounding the optimal solution down to x
1
= 2,
x
2
= 1, we see that this solution indeed is an integer
solution within the feasible region, and substituting in
the objective function, it gives 3x
1
+ 2x
2
= 8.
We have found a feasible all-integer solution, but
have we found the OPTIMAL all-integer solution?
---------------------
The answer is NO! The optimal solution is x
1
= 3
and x
2
= 0 giving 3x
1
+ 2x
2
= 9, as evidenced in the
next two slides.
Example: All-Integer LP
Complete Enumeration of Feasible ILP
Solutions
There are eight feasible integer solutions to this problem:
x
1
x
2
3x
1
+ 2x
2

1. 0 0 0
2. 1 0 3
3. 2 0 6
4. 3 0 9 optimal solution
5. 0 1 2
6. 1 1 5
7. 2 1 8
8. 1 2 7
Example: All-Integer LP
ILP Optimal (3, 0)
Max 3x
1
+ 2x
2
x
1
+ x
2
< 1
x
2
x
1
3x
1
+ x
2
< 9
x
1
+ 3x
2
< 7
1 2 3 4 5 6 7
1
3
2
5
4
Optimal All-Integer
Solution
Modeling Flexibility Provided by
0-1 Variables
When x
i
and x
j
represent binary variables designating
whether projects i and j have been completed, the
following special constraints may be formulated:

At most k out of n projects will be completed:
Ex
j
< k
j
Project j is conditional on project i:
x
j
- x
i
< 0
Project i is a corequisite for project j:
x
j
- x
i
= 0
Projects i and j are mutually exclusive:
x
i
+ x
j
< 1
End of Session 12
Session 13
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Structure of a Waiting
Line System
Queuing System Input
Characteristics
Queuing System
Operating Characteristics
Single-Channel Waiting
Line Model
Waiting Line Models
Queuing theory is the study of waiting
lines.
Four characteristics of a queuing system
are:
the manner in which customers arrive
the time required for service
the priority determining the order of service
the number and configuration of servers in
the system.
Structure of a Waiting Line
System
Structure of a Waiting Line
System
Distribution of Arrivals
Generally, the arrival of customers into the
system is a random event.
Frequently the arrival pattern is modeled as a
Poisson process.
Distribution of Service Times
Service time is also usually a random variable.
A distribution commonly used to describe
service time is the exponential distribution.
Structure of a Waiting Line
System
Queue Discipline
Most common queue discipline is first
come, first served (FCFS).
An elevator is an example of last come,
first served (LCFS) queue discipline.
Other disciplines assign priorities to the
waiting units and then serve the unit with
the highest priority first.
Structure of a Waiting Line System
Single Service Channel



Multiple Service Channels
S
1
S
1
S
2
S
3
Customer
leaves
Customer
leaves
Customer
arrives
Customer
arrives
Waiting line
Waiting line
System
System
Queuing Systems
A three part code of the form A/B/k is
used to describe various queuing
systems.
A identifies the arrival distribution, B
the service (departure) distribution
and k the number of channels for the
system.
Queuing Systems
Symbols used for the arrival and service processes
are: M - Markov distributions
(Poisson/exponential), D - Deterministic (constant)
and G - General distribution (with a known mean
and variance).
For example, M/M/k refers to a system in which
arrivals occur according to a Poisson distribution,
service times follow an exponential distribution and
there are k servers working at identical service rates.
Queuing System Input
Characteristics

= the average arrival rate
1/ = the average time between arrivals
= the average service rate for each
server
1/ = the average service time
o = the standard deviation of the
service time
Queuing System Operating
Characteristics
P
0
= probability the service facility is idle
P
n
= probability of n units in the system
P
w
= probability an arriving unit must wait for
service
L
q
= average number of units in the queue
awaiting service
L = average number of units in the system
W
q
= average time a unit spends in the queue
awaiting service
W = average time a unit spends in the system
Analytical Formulas
For nearly all queuing systems, there is
a relationship between the average time
a unit spends in the system or queue
and the average number of units in the
system or queue.
These relationships, known as Little's
flow equations are:
L = W and L
q
=
W
q

Example: SJJT, Inc. (A)
M/M/1 Queuing System
Joe Ferris is a stock trader on
the floor of the New York Stock
Exchange for the firm of Smith,
Jones, Johnson, and Thomas, Inc.
Stock transactions arrive at a mean
rate of 20 per hour. Each order received by Joe
requires an average of two minutes to process.
End of Session13
Session 14
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Multiple-Channel Waiting
Line Model with Poisson
Arrivals and Exponential
Service Times
Economic Analysis of
Waiting Lines

Waiting Line Models
Example: SJJT, Inc. (B)
M/M/2 Queuing System
Smith, Jones, Johnson, and Thomas, Inc. has
begun a major advertising campaign which it believes
will increase its business 50%. To handle the
increased volume, the company has hired an
additional floor trader, Fred Hanson, who works at
the same speed as Joe Ferris.
Note that the new arrival rate of orders, , is
50% higher than that of problem (A). Thus, =
1.5(20) = 30 per hour.
Example: SJJT, Inc. (C)
Economic Analysis of Queuing Systems
The advertising campaign of Smith,
Jones, Johnson and Thomas, Inc. (see
problems (A) and (B)) was so
successful that business actually
doubled. The mean rate of stock orders
arriving at the exchange is now 40 per
hour and the company must decide how
many floor traders to employ. Each
floor trader hired can process an order
in an average time of 2 minutes.
Example: SJJT, Inc. (C)
Economic Analysis of Queuing Systems
Based on a number of factors the
brokerage firm has determined the
average waiting cost per minute for an
order to be $.50. Floor traders hired will
earn $20 per hour in wages and
benefits. Using this information
compare the total hourly cost of hiring 2
traders with that of hiring 3 traders.
Example: SJJT, Inc. (C)
Economic Analysis of Waiting Lines
Total Hourly Cost
= (Total salary cost per hour)
+ (Total hourly cost for orders in the system)
= ($20 per trader per hour) x (Number of traders)
+ ($30 waiting cost per hour) x (Average number
of orders in the
system)
= 20k + 30L.
Thus, L must be determined for k = 2 traders and
for k = 3 traders with = 40/hr. and = 30/hr. (since the
average service time is 2 minutes (1/30 hr.).
Example: SJJT, Inc. (C)
Cost of Two Servers




P
0
= 1 /
[1+(1/1!)(40/30)]+[(1/2!)(40/30)2(60/(60-
40))]

= 1 / [1 + (4/3) + (8/3)]

= 1/5
P
n k
k
k
n k
n
k
0
0
1
1
=
+

( / )
!
( / )
!
( )


Example: SJJT, Inc. (C)
Cost of Two Servers (continued)

Thus,




L = L
q
+ ( /) = 16/15 + 4/3 =
2.40

Total Cost = (20)(2) + 30(2.40) =
$112.00 per hour
2
0
2 2
( ) (40)(30)(40 30) 16
( ) (1/5)
( 1)!( ) (1!)(2(30) 40) 15
k
q
L P
k k


= = =

Example: SJJT, Inc. (C)
Cost of Three Servers



P
0
= 1/[[1+(1/1!)(40/30)+(1/2!)(40/30)2]+
[(1/3!)(40/30)3(90/(90-
40))] ]

= 1 / [1 + 4/3 + 8/9 + 32/45]

= 15/59
P
n k
k
k
n k
n
k
0
0
1
1
=
+

( / )
!
( / )
!
( )


Example: SJJT, Inc. (C)
Cost of Three Servers (continued)




Thus, L = .1446 + 40/30 = 1.4780

Total Cost = (20)(3) + 30(1.4780) =
$104.35 per hour
3
0
2 2
( ) (30)(40)(40 30)
( ) (15/59) .1446
( 1)!( ) (2!)(3(30) 40)
k
q
L P
k k


= = =

Example: SJJT, Inc. (C)
System Cost Comparison

Wage Waiting Total
Cost/Hr Cost/Hr
Cost/Hr
2 Traders $40.00 $82.00
$112.00
3 Traders 60.00 44.35
104.35

Thus, the cost of having 3 traders is less
than that of 2 traders.
End of Session14
152
Simulation
Session 15
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Introduction to
Simulation
Modeling
Random Variables
Pseudo-Random
Numbers
Time Increments


Simulation
Simulation is one of the most
frequently employed management
science techniques.
It is typically used to model random
processes that are too complex to be
solved by analytical methods.
Simulation Modeling
One begins a simulation by developing
a mathematical statement of the
problem.
The model should be realistic yet
solvable within the speed and storage
constraints of the computer system
being used.
Input values for the model as well as
probability estimates for the random
variables must then be determined.
Random Variables
Random variable values are utilized in the model
through a technique known as Monte Carlo
simulation.
Each random variable is mapped to a set of numbers
so that each time one number in that set is
generated, the corresponding value of the random
variable is given as an input to the model.
The mapping is done in such a way that the likelihood
that a particular number is chosen is the same as the
probability that the corresponding value of the
random variable occurs.
Pseudo-Random Numbers
Because a computer program
generates random numbers for the
mapping according to some formula, the
numbers are not truly generated in a
random fashion.
However, using standard statistical
tests, the numbers can be shown to
appear to be drawn from a random
process.
These numbers are called pseudo-
random numbers.
Time Increments
In a fixed-time simulation model, time
periods are incremented by a fixed
amount. For each time period a
different set of data from the input
sequence is used to calculate the
effects on the model.
In a next-event simulation model, time
periods are not fixed but are
determined by the data values from
the input sequence.
Simulation Programs
The computer program that performs the
simulation is called a simulator.
Flowcharts can be useful in writing such a
program.
While this program can be written in any
general purpose language (e.g. BASIC,
FORTRAN, C++, etc.) special languages
which reduce the amount of code which must
be written to perform the simulation have
been developed.
Special simulation languages include
SIMSCRIPT, SPSS, DYNAMO, and SLAM.
Model Verification/Validation
Verification/validation of both the model
and the method used by the computer to
carry out the calculations is extremely
important.
Models which do not reflect real world
behavior cannot be expected to generate
meaningful results.
Likewise, errors in programming can
result in nonsensical results.
Model Verification/Validation
Validation is generally done by having
an expert review the model and the
computer code for errors.
Ideally, the simulation should be run
using actual past data.
Predictions from the simulation model
should be compared with historical
results.
Experimental Design
Experimental design is an important
consideration in the simulation process.
Issues such as the length of time of the
simulation and the treatment of initial data
outputs from the model must be addressed
prior to collecting and analyzing output data.
Normally one is interested in results for the
steady state (long run) operation of the
system being modeled.
The initial data inputs to the simulation
generally represent a start-up period for the
process and it may be important that the data
outputs for this start-up period be neglected
for predicting this long run behavior.
Experimental Design
For each policy under consideration by
the decision maker, the simulation is run
by considering a long sequence of input
data values (given by a pseudo-random
number generator).
Whenever possible, different policies
should be compared by using the same
sequence of input data.
End of Session 15
164
Simulation
Session 16
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Inventory Simulation
Waiting Line
Simulation
Simulation Model


The price change of shares of Dynogen, Inc.
has been observed over the past 50 trades. The
frequency distribution is as follows:

Price Change Number of Trades
-3/8 4
-1/4 2
-1/8 8
0 20
+1/8 10
+1/4 3
+3/8 2
+1/2 1
Total = 50
Example: Dynogen, Inc.
Example: Dynogen, Inc.
Relative Frequency Distribution and
Random Number Mapping

Price Change Relative Frequency Random
Numbers
-3/8 .08 00 - 07
-1/4 .04 08 - 11
-1/8 .16 12 - 27
0 .40 28 - 67
+1/8 .20 68 - 87
+1/4 .06 88 -
93
+3/8 .04 94 - 97
+1/2 .02 98 - 99
Total 1.00
Example: Dynogen, Inc.
If the current price per share of
Dynogen is
23, use random numbers to simulate the
price per
share over the next 10 trades.
Use the following stream of random
numbers:

21, 84, 07, 30, 94, 57, 57, 19, 84,
84
Example: Dynogen, Inc.
Simulation Worksheet

Trade Random Price Stock
Number Number Change Price
1 21 -1/8 22 7/8
2 84 +1/8 23
3 07 -3/8 22 5/8
4 30 0 22 5/8
5 94 +3/8 23
6 57 0 23
7 57 0 23
8 19 -1/8 22 7/8
9 84 +1/8 23
10 84 +1/8 23 1/8
Example: Dynogen, Inc.
Spreadsheet for Stock Price Simulation
A B C D E F
1 Lower Upper Trade Price Stock
2 Random Random Price Number Change Price
3 Number Number Change 1 0.125 23.125
4 0.00 0.08 -0.375 2 -0.125 23.000
5 0.08 0.12 -0.250 3 0.000 23.000
6 0.12 0.28 -0.125 4 0.000 23.000
7 0.28 0.68 0.000 5 0.000 23.000
8 0.68 0.88 0.125 6 0.500 23.500
9 0.88 0.94 0.250 7 -0.125 23.375
10 0.94 0.98 0.375 8 0.000 23.375
11 0.98 1.00 0.500 9 -0.125 23.250
12 10 -0.125 23.125
A B C D E F
1 Lower Upper Trade Price Stock
2 Random Random Price Number Change Price
3 Number Number Change 1 0.125 23.125
4 0.00 0.08 -0.375 2 -0.125 23.000
5 0.08 0.12 -0.250 3 0.000 23.000
6 0.12 0.28 -0.125 4 0.000 23.000
7 0.28 0.68 0.000 5 0.000 23.000
8 0.68 0.88 0.125 6 0.500 23.500
9 0.88 0.94 0.250 7 -0.125 23.375
10 0.94 0.98 0.375 8 0.000 23.375
11 0.98 1.00 0.500 9 -0.125 23.250
12 10 -0.125 23.125
Example: Dynogen, Inc.
Theoretical Results and Observed Results
Based on the probability distribution, the expected
price change per trade can be calculated by:
(.08)(-3/8) + (.04)(-1/4) + (.16)(-1/8) + (.40)(0)
+ (.20)(1/8) + (.06)(1/4) + (.04)(3/8) + (.02)(1/2) =
+.005
The expected price change for 10 trades is
(10)(.005) = .05. Hence, the expected stock price
after 10 trades is 23 + .05 = 23.05.
Compare this ending price with the spreadsheet
simulation and manual simulation results on the
previous slides.
End of Session 16
172
Simulation
Session 17
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Other Simulation
issues with examples
Advantages &
Disadvantages of
Simulation


Example: Wayne International
Airport
Wayne International Airport primarily serves
domestic air traffic. Occasionally, however,
a chartered plane from abroad will arrive
with passengers bound for Wayne's two
great amusement parks, Algorithmland
and Giffith's Cherry Preserve.
Whenever an international plane
arrives at the airport the two customs
inspectors on duty set up operations to
process the passengers.
Example: Wayne International
Airport


Time Required to Check a
Passenger's
Passport and Visa Probability
20 seconds .20
40 seconds .40
60 seconds .30
80 seconds .10
After having their passports and visas checked,
the passengers next proceed to the second customs
official who does baggage inspections. Passengers
form a single waiting line with the official inspecting
baggage on a first come, first served basis. The time
required for baggage inspection follows the probability
distribution shown on the next slide.
Example: Wayne International Airport
Time Required For
Baggage Inspection Probability

No Time .25
1 minute .60
2 minutes .10
3 minutes .05

Example: Wayne International
Airport
Random Number Mapping

Time Required to
Check a Passenger's Random
Passport and Visa Probability Numbers
20 seconds .20 00 - 19
40 seconds .40 20 - 59
60 seconds .30 60 - 89
80 seconds .10 90 - 99
Example: Wayne International
Airport
Random Number Mapping

Time Required For Random
Baggage Inspection Probability Numbers
No Time .25 00 - 24
1 minute .60 25 - 84
2 minutes .10 85 - 94
3 minutes .05 95 - 99
Example: Wayne International
Airport
Next-Event Simulation Records

For each passenger the following
information must be recorded:
When his service begins at the passport
control inspection
The length of time for this service
When his service begins at the baggage
inspection
The length of time for this service
Example: Wayne International
Airport
Time Relationships

Time a passenger begins service
by the passport inspector

= (Time the previous passenger started
passport service)
+ (Time of previous passenger's
passport service)
Example: Wayne International
Airport
Time Relationships

Time a passenger begins service
by the baggage inspector

( If passenger does not wait in line for baggage inspection)
= (Time passenger completes service
with the passport control inspector)

(If the passenger does wait in line for baggage inspection)
= (Time previous passenger completes
service with the baggage inspector)
Example: Wayne International
Airport
Time Relationships

Time a customer completes service
at the baggage inspector

= (Time customer begins service with
baggage inspector) + (Time required for
baggage inspection)
A chartered plane from abroad lands at
Wayne Airport with 80 passengers. Simulate the
processing of the first 10 passengers through customs.
Use the following random numbers:

For passport control:

93, 63, 26, 16, 21, 26, 70, 55, 72, 89

For baggage inspection:

13, 08, 60, 13, 68, 40, 40, 27, 23, 64
Example: Wayne International
Airport
Example: Wayne International Airport
Simulation Worksheet (partial)

Passport Control Baggage Inspections
Pass. Time Rand. Service Time Time Rand. Service Time
Num Begin Num. Time End Begin Num. Time End

1 0:00 93 1:20 1:20 1:20 13 0:00 1:20
2 1:20 63 1:00 2:20 2:20 08 0:00 2:20
3 2:20 26 :40 3:00 3:00 60 1:00 4:00
4 3:00 16 :20 3:20 4:00 13 0:00 4:00
5 3:20 21 :40 4:00 4:00 68 1:00 5:00
Example: Wayne International
Airport
Simulation Worksheet (continued)

Passport Control Baggage Inspections
Pass. Time Rand. Service Time Time Rand. Service Time
Num Begin Num. Time End Begin Num. Time End

6 4:00 26 :40 4:40 5:00 40 1:00 6:00
7 4:40 70 1:00 5:40 6:00 40 1:00 7:00
8 5:40 55 :40 6:20 7:00 27 1:00 8:00
9 6:20 72 1:00 7:20 8:00 23 0:00 8:00
10 7:20 89 1:00 8:20 8:20 64 1:00 9:20
Example: Wayne International
Airport
Question
How long will it take for the first 10
passengers to clear customs?
Answer
Passenger 10 clears customs after 9
minutes and 20 seconds.
Answer
For each passenger calculate his waiting time:
(Baggage Inspection Begins) - (Passport Control Ends)

= 0+0+0+40+0+20+20+40+40+0 = 120 seconds.

120/10 = 12 seconds per passenger
This is a biased estimate because we assume that the
simulation began with the system empty. Thus, the results tend
to underestimate the average waiting time.
Example: Wayne International
Airport
Question
What is the average length of time a customer waits
before having his bags inspected after he clears passport control? How
is this estimate biased?

Advantages of Simulation
Among the advantages of simulation is
the ability to gain insights into the model
solution which may be impossible to
attain through other techniques.
Also, once the simulation has been
developed, it provides a convenient
experimental laboratory to perform
"what if" and sensitivity analysis.
Disadvantages of Simulation
A large amount of time may be required
to develop the simulation.
There is no guarantee that the solution
obtained will actually be optimal.
Simulation is, in effect, a trial and error
method of comparing different policy
inputs.
It does not determine if some input
which was not considered could have
provided a better solution for the model.
End of Session 17
190
Markov Process
Session 18
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Introduction

Transition Probabilities

Steady-State Probabilities


Markov Processes
Markov process models are useful in studying
the evolution of systems over repeated trials
or sequential time periods or stages.
They have been used to describe the
probability that:
a machine that is functioning in one period
will continue to function or break down in
the next period.
A consumer purchasing brand A in one
period will purchase brand B in the next
period.
Transition Probabilities
Transition probabilities govern the manner
in which the state of the system changes
from one stage to the next. These are
often represented in a transition matrix.
Transition Probabilities
A system has a finite Markov chain with
stationary transition probabilities if:
there are a finite number of states,
the transition probabilities remain constant
from stage to stage, and
the probability of the process being in a
particular state at stage n+1 is completely
determined by the state of the process at
stage n (and not the state at stage n-1). This
is referred to as the memory-less property.
Steady-State Probabilities
The state probabilities at any stage of the
process can be recursively calculated by
multiplying the initial state probabilities by
the state of the process at stage n.
The probability of the system being in a
particular state after a large number of
stages is called a steady-state probability.
Steady-State Probabilities
Steady state probabilities can be found by
solving the system of equations HP = H
together with the condition for probabilities
that Et
i
= 1.
Matrix P is the transition probability matrix
Vector H is the vector of steady state
probabilities.
Example: Norths Hardware
Henry, a persistent salesman,
calls North's Hardware Store once
a week hoping to speak with the
store's buying agent, Shirley.
If Shirley does not accept Henry's
call this week, the probability she
will do the same next week is .35.
On the other hand, if she accepts
Henry's call this week, the
probability
she will not do so next week is
.20.
Example: Norths Hardware
Transition Matrix

Next Week's Call
Refuses Accepts

This Refuses .35 .65
Week's
Call Accepts .20 .80
Steady-State Probabilities
Question
How many times per year can Henry expect to
talk to Shirley?
Answer
To find the expected number of accepted calls per
year, find the long-run proportion (probability) of a
call being accepted and multiply it by 52 weeks.
continued . . .

Question
What is the probability Shirley will accept
Henry's next two calls if she does not accept his
call this week?

Example: Norths Hardware
Example: Norths Hardware
Steady State
Probability

Answer
P = .35(.35) = .1225
P = .35(.65) = .2275
P = .65(.20) = .1300
Refuses
Refuses
Refuses
Refuses
Accepts
Accepts
Accepts
.35
.35
.65
.20
.80
.65
P = .65(.80) = .5200
State Probability
Question
What is the probability of Shirley
accepting exactly one of Henry's next two
calls if she accepts his call this week?
Example: Norths Hardware
End of Session 18
202
Markov Process
Session 19
Dr. Hima Gupta
Faculty Operations
Email: hima.gupta@jiit.ac.in
Agenda
Absorbing States

Transition Matrix with
Submatrices

Fundamental Matrix


Absorbing States
An absorbing state is one in which the
probability that the process remains in that
state once it enters the state is 1.
If there is more than one absorbing state,
then a steady-state condition independent
of initial state conditions does not exist.
Transition Matrix with
Submatrices
If a Markov chain has both absorbing
and nonabsorbing states, the states
may be rearranged so that the transition
matrix can be written as the following
composition of four submatrices: I, 0, R,
and Q:
I 0
R Q
Transition Matrix with Submatrices
I = an identity matrix indicating one always
remains in an absorbing state once it is
reached
0 = a zero matrix representing 0 probability of
transitioning from the absorbing states to
the nonabsorbing states
R = the transition probabilities from the
nonabsorbing states to the absorbing states
Q = the transition probabilities between the
nonabsorbing states
Fundamental Matrix
The fundamental matrix, N, is the
inverse of the difference between the
identity matrix and the Q matrix.

N = (I - Q )
-1

NR Matrix
The NR matrix is the product of the
fundamental (N) matrix and the R matrix.
It gives the probabilities of eventually moving
from each nonabsorbing state to each
absorbing state.
Multiplying any vector of initial nonabsorbing
state probabilities by NR gives the vector of
probabilities for the process eventually
reaching each of the absorbing states. Such
computations enable economic analyses of
systems and policies.

The vice president of personnel at Jetair
Aerospace has noticed that yearly shifts in
personnel can be modeled by a Markov
process. The transition matrix is:

Next Year
Same Pos. Promotion Retire Quit Fired
Current Year
Same Position .55 .10 .05 .20 .10
Promotion .70 .20 0 .10 0
Retire 0 0 1 0 0
Quit 0 0 0 1 0
Fired 0 0 0 0 1
Example: Jetair Aerospace
Example: Jetair Aerospace
Transition Matrix

Next Year
Retire Quit Fired Same Promotion
Current Year
Retire 1 0 0 0 0
Quit 0 1 0 0 0
Fired 0 0 1 0 0
Same .05 .20 .10 .55 .10
Promotion 0 .10 0 .70 .20
Example: Jetair Aerospace
Answer
The answers are given by the bottom row of the NR
matrix. The answers are therefore:

Eventually Retiring = .12
Eventually Quitting = .64
Eventually Being Fired = .24
Absorbing States
Question
What is the probability of someone who was just
promoted eventually retiring? . . . quitting? . . .
being fired?

End of Session 19

You might also like