You are on page 1of 23

Statistical Models in Simulation

CSC304A
Computer Simulation
B. Tech. CSE, 2015

Course Leader:
Santhoshi Kumari
Santoshi.cs.et@msruas.ac.in

1
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Objectives
• At the end of this lecture, student will be able to
– Understand Brief Review of Probability, Discrete Random Variables,
Continuous Random Variables, Cumulative Distribution Function,
Expectation, Measure of Dispersion, Mode
– Understand Useful Statistical Models like Queueing systems, Inventory and
supply-chain systems, Reliability and maintainability, Limited data

2
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Outline
• Brief Review
– Probability
– Discrete Random Variables
– Continuous Random Variables
– Cumulative Distribution Function
– Expectation
– Measure of Dispersion
– Mode
• Useful Statistical Models
– Queueing systems
– Inventory and supply-chain systems
– Reliability and maintainability
– Limited data

3
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Probability (1)
• Is a measure of chance
• Laplace’s Classical Definition: The Probability of an event A is defined a-
priori without actual experimentation as

Number of outcomes favorable to A


P( A) 
Total number of possible outcomes
• provided all these outcomes are equally likely.
• Relative Frequency Definition: The probability of an event A is defined as
nA
P( A)  lim
n n

• where nA is the number of occurrences of A and n is the total number of


trials

4
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review : Probability (2)
• The axiomatic approach to probability, due to Kolmogorov
developed through a set of axioms
• For any Experiment E, has a set S or  of all possible outcomes
called sample space, .
•  has subsets {A, B, C, …..} called events. If A  B   , the empty
set, then A and B are said to be mutually exclusive events.

A
A B A B A

A B A B A
5
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Probability: Axioms of
Probability
• For any event A, we assign a number P(A), called the
probability of the event A. This number satisfies the
following three conditions that act the axioms of probability.

(i) P( A)  0 (Probability is a nonnegative number)


(ii) P()  1 (Probability of the whole set is unity)
(iii) If A  B   , then P( A  B)  P( A)  P( B ).

• (Note that (iii) states that if A and B are mutually


• exclusive (M.E.) events, the probability of their union
• is the sum of their probabilities.)

6
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review : Discrete Random Variables (1)
• X is a discrete random variable if the number of possible values of X
is finite, or countably infinite.
• Example: Consider jobs arriving at a job shop.
• Let X be the number of jobs arriving each week at a job shop.
• Rx = possible values of X (range space of X) = {0,1,2,…}
• p(xi) = probability the random variable is xi = P(X = xi)
• p(xi), i = 1,2, … must satisfy:
1. p ( xi )  0, for all i



2. i 1
p ( xi )  1

– The collection of pairs [xi, p(xi)], i = 1,2,…, is called the probability


distribution of X, and p(xi) is called the probability mass function
(pmf) of X. 7
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Discrete Random Variable (2)
• Consider the experiment of tossing a single die. Define X as the number
of spots on the up face of the die after a toss.
• RX={1,2,3,4,5,6}
• Assume the die is loaded so that the probability that a given face lands
up is proportional to the number of spots showing
xi p(xi)
1 1/21
2 2/21
3 3/21
4 4/21
5 5/21
6 6/21

• What if all the faces are equally likely?? 8


Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Continuous Random Variables (1)

• X is a continuous random variable if its range space Rx is an interval or a


collection of intervals.
• The probability that X lies in the interval [a,b] is given by:
b
P(a  X  b)   f ( x)dx shown as shaded
area
a

• f(x), probability density function (pdf) of X, satisfies:


1. f ( x)  0 , for all x in R X
2.  f ( x)dx  1
RX

3. f ( x)  0, if x is not in RX f(x) is called probability


density function

• Properties1. P( X  x )  0, because x f ( x)dx  0



0

0
x0

2. P ( a  X  b )  P ( a  X  b )  P ( a  X  b )  P ( a  X  b )
9
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Continuous Random Variables (2)

• Example: Life of an inspection device is given by X, a continuous


random variable with pdf:

 1
 ex / 2 , x  0
f ( x)   2

0, otherwise

– X has an exponential distribution with mean 2 years


1 3
(2  the
– ProbabilityPthat )   life
x  3device’s e  x /is2 dx  0.14 2 and 3 years is:
between
2 2
10
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Cumulative Distribution Function (1)
• Cumulative Distribution Function (cdf) is denoted by F(x), measures the
probability that the random variable Xx, i.e., F(x) = P(X x)
– If X is discrete, then F ( x)   p( xi )
all
xi  x
x
– If X is continuous, then F ( x)   f (t )dt


• Properties
1. F is nondecreasing function. If a  b, then F (a )  F (b)
2. lim x  F ( x)  1
3. lim x  F ( x )  0

• All probability questions about X can be answered in terms of the cdf,


e.g.: P( a  X  b)  F (b)  F (a), for all a  b

11
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Cumulative Distribution Function (2)
• Consider the loaded die example
x (­,1) [1,2) [2,3) [3,4) [4,5) [5,6) [6, )

F(x) 0 1/21 3/21 6/21 10/21 15/21 21/21

12
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Cumulative Distribution Function (3)
• Example: An inspection device has cdf:
1 x t / 2
F ( x)   e dt  1  e  x / 2
2 0
– The probability that the device lasts for less than 2 years:

P(0  X  2)  F (2)  F (0)  F (2)  1  e 1  0.632

– The probability that it lasts between 2 and 3 years:


P (2  X  3)  F (3)  F (2)  (1  e  ( 3 / 2 ) )  (1  e 1 )  0.145

13
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Expectation (1)
• The expected value of X is denoted by E(X)=µ
– If X is discrete
E ( X )   xi p( xi )
all i

– If X is continuous 
E ( X )   xf ( x)dx


– Expected value is also known as the mean (), or the 1st


moment of X
– A measure of the central tendency
)   xi of
• E(Xn), n 1 is called nEth( Xmoment p( xX
n n
i)
– If X is discrete all i

E ( X n )   x n f ( x)dx


– If X is continuous 14
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Measures of Dispersion (1)
• The variance of X is denoted by V(X) or var(X) or s2
– Definition: V(X) = E[(X – E[X])2] = E[(X – )2]
– Also, V(X) = E(X2) – [E(X)]2 = E(X2)- 2
– A measure of the spread or variation of the possible
values of X around the mean 
• The standard deviation of X is denoted by s
– Definition: square root of V(X) i.,e
s  V (X )

– Expressed in the same units as the mean

15
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Measure of Dispersion (2)
• Example: The mean of life of the previous inspection device
is: 
1  x/ 2 x / 2
E ( X )   xe dx   xe

  e  x / 2 dx  2 years
2 0 0
0

• To compute variance of X, we first compute E(X2):



1 x / 2
E ( X )   x e dx   x e
 
2 2 x / 2 2  2 xe  x / 2 dx  8
2 0 0
0

• Hence, the variance and standard deviation of the device’s


life are:

16
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Brief Review: Mode

• I 17
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
2. Useful Statistical Models

–Q 18
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Useful Models : Queueing Systems
• In a queueing system, inter arrival and service-time
patterns can be probabilistic (for more queueing examples, see Chapter 2).
• Sample statistical models for inter arrival or service time
distribution:
– Exponential distribution: if service times are completely random
– Normal distribution: fairly constant but with some random
variability (either positive or negative)
– Truncated normal distribution: similar to normal distribution but
with restricted value.
– Gamma and Weibull distribution: more general than exponential
(involving location of the modes of pdf’s and the shapes of tails.)

19
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Useful Models: Inventory and supply chain
• In realistic inventory and supply-chain systems, there are at least
three random variables:
– The number of units demanded per order or per time period
– The time between demands
– The lead time (time between the placing of an order for stocking
the inventory system and the receipt of that order)
• Sample statistical models for lead time distribution:
– Gamma
• Sample statistical models for demand distribution:
– Poisson: simple and extensively tabulated.
– Negative binomial distribution: longer tail than Poisson (more
large demands).
– Geometric: special case of negative binomial given at least one
demand has occurred.
20
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Useful Models: Reliability and maintainability

• Time to failure (TTF)


– Exponential: failures are random
– Gamma: for standby redundancy where each component has an
exponential TTF
– Weibull: failure is due to the most serious of a large number of
defects in a system of components
– Normal: failures are due to wear

21
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Useful Models: Other areas

• F 22
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences
Summary
• Brief Review of Probability, Discrete Random Variables, Continuous
Random Variables, Cumulative Distribution Function, Expectation,
Measure of Dispersion, Mode
• Useful Statistical Models like Queueing systems, Inventory and
supply-chain systems, Reliability and maintainability, Limited data
• Useful Statistical Models
– In a queueing system, inter arrival and service-time patterns can be
probabilistic
– In realistic inventory and supply-chain systems
– For cases with limited data, some useful distributions are: Uniform, triangular
and beta

23
Faculty of Engineering & Technology © Ramaiah University of Applied Sciences

You might also like