SlideShare a Scribd company logo
1 of 119
SCC430
Modeling and Simulation
Chapter 06
Input Modeling
Dr. Ahmed Hagag
Faculty of Computers and Artificial Intelligence
Benha University
Fall 2020
• Introduction.
• Data Collection.
• Useful Probability Distributions.
• Identifying the Distribution with Data.
• Distribution-Fitting Software (e.g., ExpertFit ®).
©AhmedHagag SCC430 Modeling and Simulation 2
Chapter 6: Input Modeling
Recall
Introduction (1/6)
Queueing Sim.
©AhmedHagag SCC430 Modeling and Simulation 3
Inventory Sim.
Recall
Introduction (1/6)
Queueing Sim.
©AhmedHagag SCC430 Modeling and Simulation 4
Inventory Sim.
Introduction (2/6)
Input Models
(Distribution)
©AhmedHagag SCC430 Modeling and Simulation 5
Introduction (2/6)
If we know about the desired
distribution, we can build a
random number generator to
generate input samples.
Input Models
(Distribution)
©AhmedHagag SCC430 Modeling and Simulation 6
Introduction (3/6)
Value Probability
1 0.5
2 0.3
3 0.1
4 0.1
Generating RandomVariates
Distribution
Function
PRNs
APPROACHES
1. Inverse Transform
2. Composition
3. Convolution
4. Acceptance-Rejection
5. Ratio of Uniforms
6. {Others … }
©AhmedHagag SCC430 Modeling and Simulation 7
Introduction (3/6)
Select
Distribution
𝑋
෠
Data
𝐹 𝑥
Cumulative
Distribution
𝑈
Generated
PRNs
𝐹−1(𝑢)
Inverse
Distribution
Inputs
𝑋
Output
(Random Variates)
Inverse Transform
©AhmedHagag SCC430 Modeling and Simulation 8
Introduction (3/6)
©AhmedHagag SCC430 Modeling and Simulation 9
Value Probability
1 0.5
2 0.3
3 0.1
4 0.1
Inputs are the independent variables in the system:
• Customer inter-arrival time periods in a single service
facility is an input. It’s a continuous random variable
since the period could be any value between two
limits.
• The demand sizes and for an inventory system is an
input. It’s a discreet random variable since the
demand size can take only specific values.
©AhmedHagag SCC430 Modeling and Simulation 10
Introduction (4/6)
• Input models provide the driving force for a
simulation model.
• One of the biggest tasks in solving a real problem.
• An important factor in controlling simulation quality.
Introduction (5/6)
©AhmedHagag SCC430 Modeling and Simulation 11
Introduction (6/6)
Collect data from the
real system of interest.
Evaluate the chosen distribution and the associated
parameters for goodness of fit.
Y
es
No
Y
es
Identify a probability distribution to
represent the input process.
Yes
Choose parameters that determine a specific
instance of the distribution family.
Yes
Expert opinion and
knowledge of the
process must be used.
No
Y
es
©AhmedHagag SCC430 Modeling and Simulation 12
• If a simulation product does not have good statistical-
analysis features, then it is impossible to obtain
correct results from a simulation study.
1. The software must have a good random-number
generator.
2. Each source of randomness in the system of interest
should be represented in the simulation model by a
probability distribution.
3. Making independent runs of the simulation model.
(e.g., Each run uses separate sets of different random
numbers) and output data analysis.
©AhmedHagag SCC430 Modeling and Simulation 13
Data Collection (1/5)
• If a simulation product does not have good statistical-
analysis features, then it is impossible to obtain
correct results from a simulation study.
1. The software must have a good random-number
generator.
2. Each source of randomness in the system of interest
should be represented in the simulation model by a
probability distribution.
3. Making independent runs of the simulation model.
(e.g., Each run uses separate sets of different random
numbers) and output data analysis.
Data Collection (1/5)
©AhmedHagag SCC430 Modeling and Simulation 14
Probability Distribution:
• If it is possible to find a standard theoretical
distribution (e.g., Uniform, Poisson, Exponential,
Normal) that is a good model for a particular source
of randomness, then this distribution should be used
in the model.
• If a theoretical distribution cannot be found that is a
good representation for a source of randomness, then
an empirical (or user-defined) distribution based on
the data should be used.
©AhmedHagag SCC430 Modeling and Simulation 15
Data Collection (2/5)
Which is Better?
a standard theoretical
• It is preferring
distribution than
distribution.
to use
an empirical (or user-defined)
©AhmedHagag SCC430 Modeling and Simulation 16
Data Collection (3/5)
• Even when model structure is valid simulation results
can be misleading, if the input data is:
 Inaccurately collected.
 Inappropriately analyzed.
 Not representative of the environment.
©AhmedHagag SCC430 Modeling and Simulation 17
Data Collection (4/5)
• If we model an existing system, we collect data from
the real system (inter-arrival time or the demand size
as examples). Then, use the collected data to feed the
model.
• If the data is not available, experts guided guessing is
our way to choose a suitable theoretical distribution
then build the random number generator to generate
the input.
©AhmedHagag SCC430 Modeling and Simulation 18
Data Collection (5/5)
Continuous Distributions:
• Uniform.
• Exponential.
• Gamma.
• Normal (Gaussian).
©AhmedHagag SCC430 Modeling and Simulation 19
Useful Prob. Dist. (1/10)
Continuous Distributions (Uniform) (1/2):
• 𝑎 and 𝑏 real numbers with 𝑎 < 𝑏.
Useful Prob. Dist. (2/10)
𝑼(𝒂, 𝒃)
©AhmedHagag SCC430 Modeling and Simulation 20
Continuous Distributions (Uniform) (2/2):
Useful Prob. Dist. (2/10)
𝑼(𝒂, 𝒃)
PRN
©AhmedHagag SCC430 Modeling and Simulation 21
Generating Random Variates 𝑋’s
Continuous Distributions (Exponential) (1/2):
• Scale parameter 𝛽 > 0.
Useful Prob. Dist. (3/10)
expo(𝖰)
Generating Random Variates 𝑋’s
©AhmedHagag SCC430 Modeling and Simulation 22
PRN
Continuous Distributions (Exponential) (2/2):
Useful Prob. Dist. (3/10)
expo(𝖰)
𝖰 = 𝟑
𝖰 = 𝟐
𝖰 = 𝟏
©AhmedHagag SCC430 Modeling and Simulation 23
Continuous Distributions (Gamma):
• Shape parameter 𝛼 > 0, Scale parameter 𝛽 > 0.
Useful Prob. Dist. (4/10)
gamma(𝑎 , 𝖰)
©AhmedHagag SCC430 Modeling and Simulation 24
Continuous Distributions (Gamma) (1/2):
• Shape parameter 𝛼 > 0, Scale parameter 𝛽 > 0.
Useful Prob. Dist. (1/10)
gamma(𝑎 ,𝖰)
©AhmedHagag SCC430 Modeling and Simulation 25
Continuous Distributions (Normal):
• Location parameter 𝜇 ∈ ℝ, Scale parameter 𝜎 > 0.
Useful Prob. Dist. (5/10)
N(𝝁, 𝝈𝟐)
©AhmedHagag SCC430 Modeling and Simulation 26
Discrete Distributions:
• Discrete Uniform.
• Geometric.
• Poisson.
©AhmedHagag SCC430 Modeling and Simulation 27
Useful Prob. Dist. (6/10)
Discrete Distributions (Discrete Uniform) (1/2):
• 𝑖 and 𝑗 integers with 𝑖 ≤ 𝑗.
Useful Prob. Dist. (7/10)
𝑫𝑼(𝒊,𝒋)
©AhmedHagag SCC430 Modeling and Simulation 28
Discrete Distributions (Discrete Uniform) (2/2):
• 𝑖 and 𝑗 integers with 𝑖 ≤ 𝑗.
Useful Prob. Dist. (7/10)
𝑫𝑼(𝒊,𝒋)
©AhmedHagag SCC430 Modeling and Simulation 29
Discrete Distributions (Geometric) (1/3):
• 𝑝 ∈ 0, 1 .
Useful Prob. Dist. (8/10)
geom(𝒑)
©AhmedHagag SCC430 Modeling and Simulation 30
Discrete Distributions (Geometric) (2/3):
• 𝑝 ∈ 0, 1 .
Useful Prob. Dist. (8/10)
geom(𝒑)
©AhmedHagag SCC430 Modeling and Simulation 31
Discrete Distributions (Geometric) (3/3):
• 𝑝 ∈ 0, 1 .
Useful Prob. Dist. (8/10)
geom(𝒑)
Generating Random Variates 𝑋’s
©AhmedHagag SCC430 Modeling and Simulation 32
PRN
Discrete Distributions (Poisson) (1/3):
• 𝜆 > 0.
Useful Prob. Dist. (9/10)
Poisson(𝝀)
©AhmedHagag SCC430 Modeling and Simulation 33
Discrete Distributions (Poisson) (2/3):
• 𝜆 > 0.
Useful Prob. Dist. (9/10)
Poisson(𝝀)
©AhmedHagag SCC430 Modeling and Simulation 34
Discrete Distributions (Poisson) (3/3):
• 𝜆 > 0.
Useful Prob. Dist. (9/10)
Poisson(𝝀)
©AhmedHagag SCC430 Modeling and Simulation 35
Useful Prob. Dist. (10/10)
©AhmedHagag SCC430 Modeling and Simulation 36
Choosing a standard theoretical distribution:
1. Select the type (family) of the distribution.
2. Estimate the parameters of the selected family using
the collected data.
3. Test the selected distribution.
 Heuristic (Graphical Comparison) test.
 Goodness-of-Fit test (Anderson-Darling (AD),
K-S, and Chi-square tests).
Choose the suitable distribution using:
1. Summary Statistics.
2. Histogram.
3. Quantile-Quantile (𝑞-𝑞) Plot.
4. Boxplot.
5. {Others …}
©AhmedHagag SCC430 Modeling and Simulation 37
Ident. the Dist. with Data (1/9)
Summary Statistics (1/3):
Ident. the Dist. with Data (2/9)
=
1
𝑛 − 1
𝑖
=1
𝑛
𝑖
©AhmedHagag SCC430 Modeling and Simulation 38
෠ 𝑥 − 𝑥 ҧ
2
Summary Statistics (2/3):
Ident. the Dist. with Data (2/9)
©AhmedHagag SCC430 Modeling and Simulation 39
Summary Statistics (2/3):
Ident. the Dist. with Data (2/9)
©AhmedHagag SCC430 Modeling and Simulation 40
Summary Statistics (3/3):
For example:
• If the median is equal or near equal to the mean, this
indicates symmetric, (e.g., normal) distribution.
• If the coefficient of variation (cv) is close to 1 this
indicates exponential distribution because its cv is 1.
©AhmedHagag SCC430 Modeling and Simulation 41
Ident. the Dist. with Data (2/9)
Example1 – Summary Statistics (1/4)
A simulation model was developed for a drive-up banking
facility, and data were collected on the arrival pattern for cars.
Over a fixed 90-minute interval, 220 cars arrived, and we noted
the (continuous) interarrival time 𝑋𝑖 (in minutes) between cars 𝑖
and 𝑖 + 1, for 𝑖 = 1, 2,… , 219.
©AhmedHagag SCC430 Modeling and Simulation 42
Ident. the Dist. with Data (3/9)
Example1 – Summary Statistics (2/4)
Ident. the Dist. with Data (3/9)
©AhmedHagag SCC430 Modeling and Simulation 43
Example1 – Summary Statistics (3/4)
Ident. the Dist. with Data (3/9)
©AhmedHagag SCC430 Modeling and Simulation 44
Example1 – Summary Statistics (4/4)
Since:
𝑋
ത219 = 0.399 > 0.270 = 𝑥ො 0.5(219)
and 𝑣
ො 219 = 1.478, this suggests that
the underlying distribution is skewed to
the right, rather than symmetric.
Furthermore, 𝑐
ො 𝑣 219 = 0.953, which
is close to the theoretical value of 1 for the
exponential distribution.
Ident. the Dist. with Data (3/9)
©AhmedHagag SCC430 Modeling and Simulation 45
Example2 – Summary Statistics (1/3)
Given the values and counts for 𝑛 = 156 observations on the
(discrete) number of items demanded in a week from an
inventory system, arranged into increasing order. Rather than
giving all the individual values, we give the frequency counts;
59 𝑋𝑖’s were equal to 0, 26 𝑋𝑖’s were equal to 1, etc.
©AhmedHagag SCC430 Modeling and Simulation 46
Ident. the Dist. with Data (4/9)
Example2 – Summary Statistics (2/3)
Given the values and counts for 𝑛 = 156 observations on the
(discrete) number of items demanded in a week from an
inventory system, arranged into increasing order. Rather than
giving all the individual values, we give the frequency counts;
59 𝑋𝑖’s were equal to 0, 26 𝑋𝑖’s were equal to 1, etc.
Ident. the Dist. with Data (4/9)
©AhmedHagag SCC430 Modeling and Simulation 47
Example2 – Summary Statistics (3/3)
Ident. the Dist. with Data (4/9)
©AhmedHagag SCC430 Modeling and Simulation 48
Histogram (1/3)
To make a histogram, we break up the range of values covered
by the data into 𝑘 disjoint adjacent intervals [𝑏
0, 𝑏1), [𝑏1, 𝑏2), . . . , [𝑏𝑘−1, 𝑏𝑘 ).
All the intervals should be the same width ∆𝑏, which might
necessitate throwing out a few extremely large or small 𝑋𝑖 ’s to
avoid getting an unwieldy-looking histogram plot.
,
∆𝑏 = max 𝑋 −min 𝑋
𝑘 = max 𝑋 −min 𝑋
©AhmedHagag SCC430 Modeling and Simulation 49
𝑘 ∆
𝑏
Ident. the Dist. with Data (5/9)
Histogram (2/3)
For 𝑗 = 1, 2,. . . , 𝑘, let ℎ𝑗 be the proportion of the 𝑋𝑖’s that are in
the 𝑗th interval [𝑏𝑗−1, 𝑏𝑗).
i.e., ℎ1
𝘍
= number of 𝑋 s in 𝑏0, 𝑏1
total number of 𝑋𝘍s
. Finally, we define the function
Ident. the Dist. with Data (5/9)
©AhmedHagag SCC430 Modeling and Simulation 50
Histogram (3/3)
The number of intervals 𝑘 may be chosen according to the
following formula:
However, in general, we do not believe that such rules are very
useful. We recommend trying several different values of ∆𝑏 and
choosing the smallest one that gives a “smooth” histogram.
Ident. the Dist. with Data (5/9)
©AhmedHagag SCC430 Modeling and Simulation 51
Example1 – Histogram (1/8)
Ident. the Dist. with Data (6/9)
©AhmedHagag SCC430 Modeling and Simulation 52
Example1 – Histogram (2/8)
The number of intervals 𝑘 may be chosen according to the
following formula:
𝑘 = 1 + log2 219 = 8
,max 𝑋 = 1.96 ≈ 2 ,
min𝑋 = 0.01 ≈ 0 ∆𝑏 =
2 − 0
8
= 0.25
Ident. the Dist. with Data (6/9)
©AhmedHagag SCC430 Modeling and Simulation 53
Example1 – Histogram (3/8)
The number of intervals 𝑘 may be chosen according to the
following formula:
𝑘 = 1 + log2 219 = 8
,max 𝑋 = 1.96 ≈ 2 ,
min𝑋 = 0.01 ≈ 0 ∆𝑏 =
2 − 0
8
= 0.25
[0, 0.25), [0.25, 0.5),[0. 5, 0.75),[0.75, 1),
[1, 1.25), [1.25, 1.5),[1.5, 1.75), [1.75, 2),
Ident. the Dist. with Data (6/9)
©AhmedHagag SCC430 Modeling and Simulation 54
Example1 – Histogram (4/8)
Ident. the Dist. with Data (6/9)
0.25
©AhmedHagag SCC430 Modeling and Simulation 55
For ∆𝑏 = 0.25 , 𝑘 = 2−0
= 8
Example1 – Histogram (5/8)
Ident. the Dist. with Data (6/9)
0.05
©AhmedHagag SCC430 Modeling and Simulation 56
For ∆𝑏 = 0.05 , 𝑘 = 2−0
= 40
Example1 – Histogram (6/8)
Ident. the Dist. with Data (6/9)
For ∆𝑏 = 0.075 , 𝑘 =
2−0
0.075
©AhmedHagag SCC430 Modeling and Simulation 57
= 27
Example1 – Histogram (7/8)
Ident. the Dist. with Data (6/9)
For ∆𝑏 = 0.1 , 𝑘 = 2−0
= 20
0.1
0.1
©AhmedHagag SCC430 Modeling and Simulation 58
For ∆𝑏 = 0.1 , 𝑘 = 2−0
= 20
Example1 – Histogram (8/8)
Ident. the Dist. with Data (6/9)
Heuristic (Graphical comparison) test
The smoothest-looking histogram appears
to be for ∆𝑏 = 0.1 and its shape resembles
that of an exponential density.
©AhmedHagag SCC430 Modeling and Simulation 59
Quantile-Quantile (𝒒-𝒒) plot (1/8)
When there is a small number of data points, say, 30 or fewer, a
histogram is not as useful for evaluating the fit of the chosen
distribution. Further, our perception of the fit depends on the
widths of the histogram intervals. But, even if the intervals are
well chosen, grouping data into cells makes it difficult to
compare a histogram to a continuous probability density
function. A quantile-quantile (𝑞-𝑞) plot is a useful tool for
evaluating distribution fit, one that does not suffer from these
problems.
©AhmedHagag SCC430 Modeling and Simulation 60
Ident. the Dist. with Data (7/9)
Quantile-Quantile (𝒒-𝒒) plot (2/8)
A quantile-quantile (𝑞-𝑞) plot is a probability plot, which is a
graphical method for comparing two probability distributions
by plotting their quantiles against each other.
©AhmedHagag SCC430 Modeling and Simulation 61
Ident. the Dist. with Data (7/9)
Quantile-Quantile (𝒒-𝒒) plot (3/8)
We plot (x, y), where x’s are observed values (observed data
quantiles) and y’s are the theoretical values (theoretical
quantiles). If we select an appropriate family of theoretical
distributions the plot points (x, y) will be approximately a
straight line. On the other hand, if the assumed distribution is
inappropriate, the points will deviate from a straight line.
©AhmedHagag SCC430 Modeling and Simulation 62
Ident. the Dist. with Data (7/9)
Quantile-Quantile (𝒒-𝒒) plot (4/8)
Example: A robot is used to install the doors on automobiles
along an assembly line. It was thought that the installation times
followed a normal distribution. The robot is capable of
measuring installation times accurately. A sample of 20
installation times was automatically taken by the robot, with the
following results, where the values are in seconds:
©AhmedHagag SCC430 Modeling and Simulation 63
Ident. the Dist. with Data (7/9)
Quantile-Quantile (𝒒-𝒒) plot (5/8)
Ident. the Dist. with Data (7/9)
©AhmedHagag SCC430 Modeling and Simulation 64
Quantile-Quantile (𝒒-𝒒) plot (6/8)
The observations are now ordered from smallest to largest as follows:
Ident. the Dist. with Data (7/9)
©AhmedHagag SCC430 Modeling and Simulation 65
Quantile-Quantile (𝒒-𝒒) plot (7/8)
Ident. the Dist. with Data (7/9)
20 values from the normal distribution with
mean 99.99 and variance 0.2832 2
©AhmedHagag SCC430 Modeling and Simulation 66
Quantile-Quantile (𝒒-𝒒) plot (8/8)
Ident. the Dist. with Data (7/9)
©AhmedHagag SCC430 Modeling and Simulation 67
Quantile-Quantile (𝒒-𝒒) plot (8/8)
Ident. the Dist. with Data (7/9)
©AhmedHagag SCC430 Modeling and Simulation 68
Boxplot (1/4)
Is a way of graphically depicting groups of numerical data
through their five number summaries:
©AhmedHagag SCC430 Modeling and Simulation 69
1st
2nd
3rd
Quartile = Lower Quartile = 𝑄1.
Quartile = Median Quartile = 𝑄2.
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation.
2)
3)
4)
5) Largest observation.
Ident. the Dist. with Data (7/9)
Boxplot (2/4)
Interquartile Range (𝐼𝑄𝑅) = 𝑄3 − 𝑄1
Smallest Non-Outliers = 𝑄1 – (1.5 × 𝐼𝑄𝑅)
Largest Non-Outliers = 𝑄3 + (1.5 × 𝐼𝑄𝑅)
©AhmedHagag SCC430 Modeling and Simulation 70
Ident. the Dist. with Data (7/9)
Boxplot (3/4)
Ident. the Dist. with Data (7/9)
©AhmedHagag SCC430 Modeling and Simulation 71
Boxplot (4/4)
Ident. the Dist. with Data (7/9)
©AhmedHagag SCC430 Modeling and Simulation 72
Example1 – Boxplot (1/5)
Create a boxplot for the following data set of 14 numbers:
1, 30, 6, 7.2, 4, 8, 9, 10, 6.8, 8.3, 2, 2, 10, 1
©AhmedHagag SCC430 Modeling and Simulation 73
Ident. the Dist. with Data (8/9)
Example1 – Boxplot (3/5)
Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30
©AhmedHagag SCC430 Modeling and Simulation 74
Ident. the Dist. with Data (8/9)
Example1 – Boxplot (3/5)
Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30
©AhmedHagag SCC430 Modeling and Simulation 75
1st
2nd
3rd
Quartile = Lower Quartile = 𝑄1.
Quartile = Median Quartile = 𝑄2.
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation.
2)
3)
4)
5) Largest observation.
Ident. the Dist. with Data (8/9)
Example1 – Boxplot (3/5)
Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30
©AhmedHagag SCC430 Modeling and Simulation 76
1st
2nd
3rd
Quartile = Lower Quartile = 𝑄1.
Quartile = Median Quartile = 𝑄2.
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation = 1
2)
3)
4)
5) Largest observation.
Ident. the Dist. with Data (8/9)
Example1 – Boxplot (3/5)
Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30
©AhmedHagag SCC430 Modeling and Simulation 77
1st
2nd
3rd
Quartile = Lower Quartile = 𝑄1.
Quartile = Median Quartile = 𝑄2.
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation = 1
2)
3)
4)
5) Largest observation = 30
Ident. the Dist. with Data (8/9)
Example1 – Boxplot (3/5)
Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30
Quartile = Lower Quartile = 𝑄1.
Quartile = Median Quartile = 𝑄2
1st
2nd
3rd
= 6.8+7.2
= 7.
2
©AhmedHagag SCC430 Modeling and Simulation 78
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation = 1
2)
3)
4)
5) Largest observation = 30
Ident. the Dist. with Data (8/9)
Example1 – Boxplot (3/5)
Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30
Quartile = Lower Quartile = 𝑄1 = 2.
Quartile = Median Quartile = 𝑄2
1st
2nd
3rd
= 6.8+7.2
= 7.
2
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation = 1
2)
3)
4)
5) Largest observation = 30
Ident. the Dist. with Data (8/9)
©AhmedHagag SCC430 Modeling and Simulation 79
Example1 – Boxplot (3/5)
Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30
Quartile = Lower Quartile = 𝑄1 = 2.
Quartile = Median Quartile = 𝑄2
1st
2nd
3rd
= 6.8+7.2
= 7.
2
Quartile = Upper Quartile = 𝑄3 = 9.
1) Smallest observation = 1
2)
3)
4)
5) Largest observation = 30
Ident. the Dist. with Data (8/9)
©AhmedHagag SCC430 Modeling and Simulation 80
Example1 – Boxplot (4/5)
Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30
𝑄1 = 2, 𝑄2 = 7, 𝑄3 = 9
Interquartile Range (𝐼𝑄𝑅) = 𝑄3 − 𝑄1 = 7
= −8.5
Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅
Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅
©AhmedHagag SCC430 Modeling and Simulation 81
= 19.5
Ident. the Dist. with Data (8/9)
Example1 – Boxplot (4/5)
Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30
𝑄1 = 2, 𝑄2 = 7, 𝑄3 = 9
Interquartile Range (𝐼𝑄𝑅) = 𝑄3 − 𝑄1 = 7
= −8.5
Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅
Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 19.5
Ident. the Dist. with Data (8/9)
Outlier
©AhmedHagag SCC430 Modeling and Simulation 82
Example1 – Boxplot (5/5)
𝑄1 = 2, 𝑄2 = 7, 𝑄3 = 9, 𝐼𝑄𝑅 = 7
= −8.5
Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅
Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 19.5
Ident. the Dist. with Data (8/9)
©AhmedHagag SCC430 Modeling and Simulation 83
Example1 – Boxplot (5/5)
𝑄1 = 2, 𝑄2 = 7, 𝑄3 = 9, 𝐼𝑄𝑅 = 7
= −8.5
Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅
Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 19.5
Ident. the Dist. with Data (8/9)
©AhmedHagag SCC430 Modeling and Simulation 84
Example2 – Boxplot (1/5)
Create a boxplot for the following data set of 11 numbers:
150, 130, 160, 170, 140, 80, 190, 100, 160, 160, 130
©AhmedHagag SCC430 Modeling and Simulation 85
Ident. the Dist. with Data (9/9)
Example2 – Boxplot (2/5)
Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190
©AhmedHagag SCC430 Modeling and Simulation 86
Ident. the Dist. with Data (9/9)
Example2 – Boxplot (3/5)
Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190
©AhmedHagag SCC430 Modeling and Simulation 87
1st
2nd
3rd
Quartile = Lower Quartile = 𝑄1.
Quartile = Median Quartile = 𝑄2.
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation.
2)
3)
4)
5) Largest observation.
Ident. the Dist. with Data (9/9)
Example2 – Boxplot (3/5)
Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190
©AhmedHagag SCC430 Modeling and Simulation 88
1st
2nd
3rd
Quartile = Lower Quartile = 𝑄1.
Quartile = Median Quartile = 𝑄2.
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation = 80.
2)
3)
4)
5) Largest observation.
Ident. the Dist. with Data (9/9)
Example2 – Boxplot (3/5)
Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190
©AhmedHagag SCC430 Modeling and Simulation 89
1st
2nd
3rd
Quartile = Lower Quartile = 𝑄1.
Quartile = Median Quartile = 𝑄2.
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation = 80.
2)
3)
4)
5) Largest observation = 190.
Ident. the Dist. with Data (9/9)
Example2 – Boxplot (3/5)
Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190
©AhmedHagag SCC430 Modeling and Simulation 90
1st
2nd
3rd
Quartile = Lower Quartile = 𝑄1.
Quartile = Median Quartile = 𝑄2 = 150.
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation = 80.
2)
3)
4)
5) Largest observation = 190.
Ident. the Dist. with Data (9/9)
Example2 – Boxplot (3/5)
Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190
1st
2nd
3rd
Quartile = Lower Quartile = 𝑄1 = 130.
Quartile = Median Quartile = 𝑄2 = 150.
Quartile = Upper Quartile = 𝑄3.
1) Smallest observation = 80.
2)
3)
4)
5) Largest observation = 190.
Ident. the Dist. with Data (9/9)
©AhmedHagag SCC430 Modeling and Simulation 91
Example2 – Boxplot (3/5)
Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190
1st
2nd
3rd
Quartile = Lower Quartile = 𝑄1 = 130.
Quartile = Median Quartile = 𝑄2 = 150.
Quartile = Upper Quartile = 𝑄3 = 160.
1) Smallest observation = 80.
2)
3)
4)
5) Largest observation = 190.
Ident. the Dist. with Data (9/9)
©AhmedHagag SCC430 Modeling and Simulation 92
Example2 – Boxplot (4/5)
Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190
𝑄1 = 130, 𝑄2 = 150, 𝑄3 = 160
Interquartile Range (𝐼𝑄𝑅) = 𝑄3 − 𝑄1 = 30
Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 = 85
Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅
©AhmedHagag SCC430 Modeling and Simulation 93
= 205
Ident. the Dist. with Data (9/9)
Example2 – Boxplot (4/5)
Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190
𝑄1 = 130, 𝑄2 = 150, 𝑄3 = 160
Interquartile Range (𝐼𝑄𝑅) = 𝑄3 − 𝑄1 = 30
Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 = 85
Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 205
Ident. the Dist. with Data (9/9)
Outlier
©AhmedHagag SCC430 Modeling and Simulation 94
Example2 – Boxplot (5/5)
𝑄1 = 130, 𝑄2 = 150, 𝑄3 = 160
Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 = 85
Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 205
Ident. the Dist. with Data (9/9)
©AhmedHagag SCC430 Modeling and Simulation 95
Example2 – Boxplot (5/5)
𝑄1 = 130, 𝑄2 = 150, 𝑄3 = 160
Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 = 85
Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 205
Ident. the Dist. with Data (9/9)
©AhmedHagag SCC430 Modeling and Simulation 96
Software (1/22)
http://www.averill-law.com/distribution-fitting/
©AhmedHagag SCC430 Modeling and Simulation 97
Software (2/22)
©AhmedHagag SCC430 Modeling and Simulation 98
Software (3/22)
©AhmedHagag SCC430 Modeling and Simulation 99
Software (4/22)
©AhmedHagag SCC430 Modeling and Simulation 100
Software (5/22)
©AhmedHagag SCC430 Modeling and Simulation 101
Software (6/22)
©AhmedHagag SCC430 Modeling and Simulation 102
Software (7/22)
©AhmedHagag SCC430 Modeling and Simulation 103
Software (8/22)
©AhmedHagag SCC430 Modeling and Simulation 104
Software (9/22)
©AhmedHagag SCC430 Modeling and Simulation 105
Software (10/22)
©AhmedHagag SCC430 Modeling and Simulation 106
Software (11/22)
©AhmedHagag SCC430 Modeling and Simulation 107
Software (12/22)
©AhmedHagag SCC430 Modeling and Simulation 108
Software (13/22)
©AhmedHagag SCC430 Modeling and Simulation 109
Software (14/22)
©AhmedHagag SCC430 Modeling and Simulation 110
Software (15/22)
©AhmedHagag SCC430 Modeling and Simulation 111
Software (16/22)
©AhmedHagag SCC430 Modeling and Simulation 112
Software (17/22)
©AhmedHagag SCC430 Modeling and Simulation 113
Software (18/22)
©AhmedHagag SCC430 Modeling and Simulation 114
Software (19/22)
©AhmedHagag SCC430 Modeling and Simulation 115
Software (20/22)
©AhmedHagag SCC430 Modeling and Simulation 116
Software (21/22)
©AhmedHagag SCC430 Modeling and Simulation 117
Software (22/22)
©AhmedHagag SCC430 Modeling and Simulation 118
Dr. AhmedHagag
ahagag@fci.bu.edu.eg

More Related Content

Similar to BU_FCAI_SCC430_Modeling&Simulation_Ch06.pptx

2014-mo444-practical-assignment-04-paulo_faria
2014-mo444-practical-assignment-04-paulo_faria2014-mo444-practical-assignment-04-paulo_faria
2014-mo444-practical-assignment-04-paulo_faria
Paulo Faria
 
AIAA-MAO-RegionalError-2012
AIAA-MAO-RegionalError-2012AIAA-MAO-RegionalError-2012
AIAA-MAO-RegionalError-2012
OptiModel
 
BU_FCAI_SCC430_Modeling&Simulation_Ch03.pdf
BU_FCAI_SCC430_Modeling&Simulation_Ch03.pdfBU_FCAI_SCC430_Modeling&Simulation_Ch03.pdf
BU_FCAI_SCC430_Modeling&Simulation_Ch03.pdf
MaiGaafar
 

Similar to BU_FCAI_SCC430_Modeling&Simulation_Ch06.pptx (20)

2014-mo444-practical-assignment-04-paulo_faria
2014-mo444-practical-assignment-04-paulo_faria2014-mo444-practical-assignment-04-paulo_faria
2014-mo444-practical-assignment-04-paulo_faria
 
Presentation 7.pptx
Presentation 7.pptxPresentation 7.pptx
Presentation 7.pptx
 
AIAA-MAO-RegionalError-2012
AIAA-MAO-RegionalError-2012AIAA-MAO-RegionalError-2012
AIAA-MAO-RegionalError-2012
 
Fpga human detection
Fpga human detectionFpga human detection
Fpga human detection
 
Copy of CRICKET MATCH WIN PREDICTOR USING LOGISTIC ...
Copy of CRICKET MATCH WIN PREDICTOR USING LOGISTIC                           ...Copy of CRICKET MATCH WIN PREDICTOR USING LOGISTIC                           ...
Copy of CRICKET MATCH WIN PREDICTOR USING LOGISTIC ...
 
Using Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning ModelsUsing Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning Models
 
Using Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning ModelsUsing Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning Models
 
BU_FCAI_SCC430_Modeling&Simulation_Ch03.pdf
BU_FCAI_SCC430_Modeling&Simulation_Ch03.pdfBU_FCAI_SCC430_Modeling&Simulation_Ch03.pdf
BU_FCAI_SCC430_Modeling&Simulation_Ch03.pdf
 
IRJET-Hardware Co-Simulation of Classical Edge Detection Algorithms using Xil...
IRJET-Hardware Co-Simulation of Classical Edge Detection Algorithms using Xil...IRJET-Hardware Co-Simulation of Classical Edge Detection Algorithms using Xil...
IRJET-Hardware Co-Simulation of Classical Edge Detection Algorithms using Xil...
 
model simulating
model simulatingmodel simulating
model simulating
 
Comparative Study of Pre-Trained Neural Network Models in Detection of Glaucoma
Comparative Study of Pre-Trained Neural Network Models in Detection of GlaucomaComparative Study of Pre-Trained Neural Network Models in Detection of Glaucoma
Comparative Study of Pre-Trained Neural Network Models in Detection of Glaucoma
 
M3AT: Monitoring Agents Assignment Model for the Data-Intensive Applications
M3AT: Monitoring Agents Assignment Model for the Data-Intensive ApplicationsM3AT: Monitoring Agents Assignment Model for the Data-Intensive Applications
M3AT: Monitoring Agents Assignment Model for the Data-Intensive Applications
 
AIRLINE FARE PRICE PREDICTION
AIRLINE FARE PRICE PREDICTIONAIRLINE FARE PRICE PREDICTION
AIRLINE FARE PRICE PREDICTION
 
Probability and random processes project based learning template.pdf
Probability and random processes project based learning template.pdfProbability and random processes project based learning template.pdf
Probability and random processes project based learning template.pdf
 
MACHINE LEARNING.pptx
MACHINE LEARNING.pptxMACHINE LEARNING.pptx
MACHINE LEARNING.pptx
 
Efficient anomaly detection via matrix sketching
Efficient anomaly detection via matrix sketchingEfficient anomaly detection via matrix sketching
Efficient anomaly detection via matrix sketching
 
“Deep Neural Network Training: Diagnosing Problems and Implementing Solutions...
“Deep Neural Network Training: Diagnosing Problems and Implementing Solutions...“Deep Neural Network Training: Diagnosing Problems and Implementing Solutions...
“Deep Neural Network Training: Diagnosing Problems and Implementing Solutions...
 
Introduction to simulation and modeling
Introduction to simulation and modelingIntroduction to simulation and modeling
Introduction to simulation and modeling
 
IRJET - Finger Vein Extraction and Authentication System for ATM
IRJET -  	  Finger Vein Extraction and Authentication System for ATMIRJET -  	  Finger Vein Extraction and Authentication System for ATM
IRJET - Finger Vein Extraction and Authentication System for ATM
 
DSUS_MAO_2012_Jie
DSUS_MAO_2012_JieDSUS_MAO_2012_Jie
DSUS_MAO_2012_Jie
 

More from MaiGaafar

Modeling&Simulation_Ch01_lecture 2.pptx
Modeling&Simulation_Ch01_lecture 2.pptxModeling&Simulation_Ch01_lecture 2.pptx
Modeling&Simulation_Ch01_lecture 2.pptx
MaiGaafar
 
Introduction to Time Series Analysis.pptx
Introduction to Time Series Analysis.pptxIntroduction to Time Series Analysis.pptx
Introduction to Time Series Analysis.pptx
MaiGaafar
 
Modeling_Simulation_ch3_lecture_1.pptx
Modeling_Simulation_ch3_lecture_1.pptxModeling_Simulation_ch3_lecture_1.pptx
Modeling_Simulation_ch3_lecture_1.pptx
MaiGaafar
 
strategic-planning_chp (1).pptx
strategic-planning_chp (1).pptxstrategic-planning_chp (1).pptx
strategic-planning_chp (1).pptx
MaiGaafar
 
HU200-Introduction-2020-2021.pptx
HU200-Introduction-2020-2021.pptxHU200-Introduction-2020-2021.pptx
HU200-Introduction-2020-2021.pptx
MaiGaafar
 
Modeling&Simulation_Ch01_part 3.pptx
Modeling&Simulation_Ch01_part 3.pptxModeling&Simulation_Ch01_part 3.pptx
Modeling&Simulation_Ch01_part 3.pptx
MaiGaafar
 
HU200-Supply-modified2020.pptx
HU200-Supply-modified2020.pptxHU200-Supply-modified2020.pptx
HU200-Supply-modified2020.pptx
MaiGaafar
 
Modeling&Simulation_Ch04 (1). part 2pptx.pptx
Modeling&Simulation_Ch04 (1). part 2pptx.pptxModeling&Simulation_Ch04 (1). part 2pptx.pptx
Modeling&Simulation_Ch04 (1). part 2pptx.pptx
MaiGaafar
 

More from MaiGaafar (10)

Modeling&Simulation_Ch01_lecture 2.pptx
Modeling&Simulation_Ch01_lecture 2.pptxModeling&Simulation_Ch01_lecture 2.pptx
Modeling&Simulation_Ch01_lecture 2.pptx
 
Lecture 01 - Introduction and Review.ppt
Lecture 01 - Introduction and Review.pptLecture 01 - Introduction and Review.ppt
Lecture 01 - Introduction and Review.ppt
 
Introduction to Time Series Analysis.pptx
Introduction to Time Series Analysis.pptxIntroduction to Time Series Analysis.pptx
Introduction to Time Series Analysis.pptx
 
Modeling_Simulation_ch3_lecture_1.pptx
Modeling_Simulation_ch3_lecture_1.pptxModeling_Simulation_ch3_lecture_1.pptx
Modeling_Simulation_ch3_lecture_1.pptx
 
strategic-planning_chp (1).pptx
strategic-planning_chp (1).pptxstrategic-planning_chp (1).pptx
strategic-planning_chp (1).pptx
 
HU200-Introduction-2020-2021.pptx
HU200-Introduction-2020-2021.pptxHU200-Introduction-2020-2021.pptx
HU200-Introduction-2020-2021.pptx
 
sm-161216124538.pptx
sm-161216124538.pptxsm-161216124538.pptx
sm-161216124538.pptx
 
Modeling&Simulation_Ch01_part 3.pptx
Modeling&Simulation_Ch01_part 3.pptxModeling&Simulation_Ch01_part 3.pptx
Modeling&Simulation_Ch01_part 3.pptx
 
HU200-Supply-modified2020.pptx
HU200-Supply-modified2020.pptxHU200-Supply-modified2020.pptx
HU200-Supply-modified2020.pptx
 
Modeling&Simulation_Ch04 (1). part 2pptx.pptx
Modeling&Simulation_Ch04 (1). part 2pptx.pptxModeling&Simulation_Ch04 (1). part 2pptx.pptx
Modeling&Simulation_Ch04 (1). part 2pptx.pptx
 

Recently uploaded

會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
中 央社
 
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes GuàrdiaPersonalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
EADTU
 

Recently uploaded (20)

ANTI PARKISON DRUGS.pptx
ANTI         PARKISON          DRUGS.pptxANTI         PARKISON          DRUGS.pptx
ANTI PARKISON DRUGS.pptx
 
MOOD STABLIZERS DRUGS.pptx
MOOD     STABLIZERS           DRUGS.pptxMOOD     STABLIZERS           DRUGS.pptx
MOOD STABLIZERS DRUGS.pptx
 
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdfFICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
 
Including Mental Health Support in Project Delivery, 14 May.pdf
Including Mental Health Support in Project Delivery, 14 May.pdfIncluding Mental Health Support in Project Delivery, 14 May.pdf
Including Mental Health Support in Project Delivery, 14 May.pdf
 
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
 
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community PartnershipsSpring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
 
OS-operating systems- ch05 (CPU Scheduling) ...
OS-operating systems- ch05 (CPU Scheduling) ...OS-operating systems- ch05 (CPU Scheduling) ...
OS-operating systems- ch05 (CPU Scheduling) ...
 
An overview of the various scriptures in Hinduism
An overview of the various scriptures in HinduismAn overview of the various scriptures in Hinduism
An overview of the various scriptures in Hinduism
 
The Story of Village Palampur Class 9 Free Study Material PDF
The Story of Village Palampur Class 9 Free Study Material PDFThe Story of Village Palampur Class 9 Free Study Material PDF
The Story of Village Palampur Class 9 Free Study Material PDF
 
Stl Algorithms in C++ jjjjjjjjjjjjjjjjjj
Stl Algorithms in C++ jjjjjjjjjjjjjjjjjjStl Algorithms in C++ jjjjjjjjjjjjjjjjjj
Stl Algorithms in C++ jjjjjjjjjjjjjjjjjj
 
Đề tieng anh thpt 2024 danh cho cac ban hoc sinh
Đề tieng anh thpt 2024 danh cho cac ban hoc sinhĐề tieng anh thpt 2024 danh cho cac ban hoc sinh
Đề tieng anh thpt 2024 danh cho cac ban hoc sinh
 
Mattingly "AI & Prompt Design: Named Entity Recognition"
Mattingly "AI & Prompt Design: Named Entity Recognition"Mattingly "AI & Prompt Design: Named Entity Recognition"
Mattingly "AI & Prompt Design: Named Entity Recognition"
 
Improved Approval Flow in Odoo 17 Studio App
Improved Approval Flow in Odoo 17 Studio AppImproved Approval Flow in Odoo 17 Studio App
Improved Approval Flow in Odoo 17 Studio App
 
OSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & SystemsOSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & Systems
 
ESSENTIAL of (CS/IT/IS) class 07 (Networks)
ESSENTIAL of (CS/IT/IS) class 07 (Networks)ESSENTIAL of (CS/IT/IS) class 07 (Networks)
ESSENTIAL of (CS/IT/IS) class 07 (Networks)
 
Observing-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptxObserving-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptx
 
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
 
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
 
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes GuàrdiaPersonalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
 
How To Create Editable Tree View in Odoo 17
How To Create Editable Tree View in Odoo 17How To Create Editable Tree View in Odoo 17
How To Create Editable Tree View in Odoo 17
 

BU_FCAI_SCC430_Modeling&Simulation_Ch06.pptx

  • 1. SCC430 Modeling and Simulation Chapter 06 Input Modeling Dr. Ahmed Hagag Faculty of Computers and Artificial Intelligence Benha University Fall 2020
  • 2. • Introduction. • Data Collection. • Useful Probability Distributions. • Identifying the Distribution with Data. • Distribution-Fitting Software (e.g., ExpertFit ®). ©AhmedHagag SCC430 Modeling and Simulation 2 Chapter 6: Input Modeling
  • 3. Recall Introduction (1/6) Queueing Sim. ©AhmedHagag SCC430 Modeling and Simulation 3 Inventory Sim.
  • 4. Recall Introduction (1/6) Queueing Sim. ©AhmedHagag SCC430 Modeling and Simulation 4 Inventory Sim.
  • 6. Introduction (2/6) If we know about the desired distribution, we can build a random number generator to generate input samples. Input Models (Distribution) ©AhmedHagag SCC430 Modeling and Simulation 6
  • 7. Introduction (3/6) Value Probability 1 0.5 2 0.3 3 0.1 4 0.1 Generating RandomVariates Distribution Function PRNs APPROACHES 1. Inverse Transform 2. Composition 3. Convolution 4. Acceptance-Rejection 5. Ratio of Uniforms 6. {Others … } ©AhmedHagag SCC430 Modeling and Simulation 7
  • 9. Introduction (3/6) ©AhmedHagag SCC430 Modeling and Simulation 9 Value Probability 1 0.5 2 0.3 3 0.1 4 0.1
  • 10. Inputs are the independent variables in the system: • Customer inter-arrival time periods in a single service facility is an input. It’s a continuous random variable since the period could be any value between two limits. • The demand sizes and for an inventory system is an input. It’s a discreet random variable since the demand size can take only specific values. ©AhmedHagag SCC430 Modeling and Simulation 10 Introduction (4/6)
  • 11. • Input models provide the driving force for a simulation model. • One of the biggest tasks in solving a real problem. • An important factor in controlling simulation quality. Introduction (5/6) ©AhmedHagag SCC430 Modeling and Simulation 11
  • 12. Introduction (6/6) Collect data from the real system of interest. Evaluate the chosen distribution and the associated parameters for goodness of fit. Y es No Y es Identify a probability distribution to represent the input process. Yes Choose parameters that determine a specific instance of the distribution family. Yes Expert opinion and knowledge of the process must be used. No Y es ©AhmedHagag SCC430 Modeling and Simulation 12
  • 13. • If a simulation product does not have good statistical- analysis features, then it is impossible to obtain correct results from a simulation study. 1. The software must have a good random-number generator. 2. Each source of randomness in the system of interest should be represented in the simulation model by a probability distribution. 3. Making independent runs of the simulation model. (e.g., Each run uses separate sets of different random numbers) and output data analysis. ©AhmedHagag SCC430 Modeling and Simulation 13 Data Collection (1/5)
  • 14. • If a simulation product does not have good statistical- analysis features, then it is impossible to obtain correct results from a simulation study. 1. The software must have a good random-number generator. 2. Each source of randomness in the system of interest should be represented in the simulation model by a probability distribution. 3. Making independent runs of the simulation model. (e.g., Each run uses separate sets of different random numbers) and output data analysis. Data Collection (1/5) ©AhmedHagag SCC430 Modeling and Simulation 14
  • 15. Probability Distribution: • If it is possible to find a standard theoretical distribution (e.g., Uniform, Poisson, Exponential, Normal) that is a good model for a particular source of randomness, then this distribution should be used in the model. • If a theoretical distribution cannot be found that is a good representation for a source of randomness, then an empirical (or user-defined) distribution based on the data should be used. ©AhmedHagag SCC430 Modeling and Simulation 15 Data Collection (2/5)
  • 16. Which is Better? a standard theoretical • It is preferring distribution than distribution. to use an empirical (or user-defined) ©AhmedHagag SCC430 Modeling and Simulation 16 Data Collection (3/5)
  • 17. • Even when model structure is valid simulation results can be misleading, if the input data is:  Inaccurately collected.  Inappropriately analyzed.  Not representative of the environment. ©AhmedHagag SCC430 Modeling and Simulation 17 Data Collection (4/5)
  • 18. • If we model an existing system, we collect data from the real system (inter-arrival time or the demand size as examples). Then, use the collected data to feed the model. • If the data is not available, experts guided guessing is our way to choose a suitable theoretical distribution then build the random number generator to generate the input. ©AhmedHagag SCC430 Modeling and Simulation 18 Data Collection (5/5)
  • 19. Continuous Distributions: • Uniform. • Exponential. • Gamma. • Normal (Gaussian). ©AhmedHagag SCC430 Modeling and Simulation 19 Useful Prob. Dist. (1/10)
  • 20. Continuous Distributions (Uniform) (1/2): • 𝑎 and 𝑏 real numbers with 𝑎 < 𝑏. Useful Prob. Dist. (2/10) 𝑼(𝒂, 𝒃) ©AhmedHagag SCC430 Modeling and Simulation 20
  • 21. Continuous Distributions (Uniform) (2/2): Useful Prob. Dist. (2/10) 𝑼(𝒂, 𝒃) PRN ©AhmedHagag SCC430 Modeling and Simulation 21 Generating Random Variates 𝑋’s
  • 22. Continuous Distributions (Exponential) (1/2): • Scale parameter 𝛽 > 0. Useful Prob. Dist. (3/10) expo(𝖰) Generating Random Variates 𝑋’s ©AhmedHagag SCC430 Modeling and Simulation 22 PRN
  • 23. Continuous Distributions (Exponential) (2/2): Useful Prob. Dist. (3/10) expo(𝖰) 𝖰 = 𝟑 𝖰 = 𝟐 𝖰 = 𝟏 ©AhmedHagag SCC430 Modeling and Simulation 23
  • 24. Continuous Distributions (Gamma): • Shape parameter 𝛼 > 0, Scale parameter 𝛽 > 0. Useful Prob. Dist. (4/10) gamma(𝑎 , 𝖰) ©AhmedHagag SCC430 Modeling and Simulation 24
  • 25. Continuous Distributions (Gamma) (1/2): • Shape parameter 𝛼 > 0, Scale parameter 𝛽 > 0. Useful Prob. Dist. (1/10) gamma(𝑎 ,𝖰) ©AhmedHagag SCC430 Modeling and Simulation 25
  • 26. Continuous Distributions (Normal): • Location parameter 𝜇 ∈ ℝ, Scale parameter 𝜎 > 0. Useful Prob. Dist. (5/10) N(𝝁, 𝝈𝟐) ©AhmedHagag SCC430 Modeling and Simulation 26
  • 27. Discrete Distributions: • Discrete Uniform. • Geometric. • Poisson. ©AhmedHagag SCC430 Modeling and Simulation 27 Useful Prob. Dist. (6/10)
  • 28. Discrete Distributions (Discrete Uniform) (1/2): • 𝑖 and 𝑗 integers with 𝑖 ≤ 𝑗. Useful Prob. Dist. (7/10) 𝑫𝑼(𝒊,𝒋) ©AhmedHagag SCC430 Modeling and Simulation 28
  • 29. Discrete Distributions (Discrete Uniform) (2/2): • 𝑖 and 𝑗 integers with 𝑖 ≤ 𝑗. Useful Prob. Dist. (7/10) 𝑫𝑼(𝒊,𝒋) ©AhmedHagag SCC430 Modeling and Simulation 29
  • 30. Discrete Distributions (Geometric) (1/3): • 𝑝 ∈ 0, 1 . Useful Prob. Dist. (8/10) geom(𝒑) ©AhmedHagag SCC430 Modeling and Simulation 30
  • 31. Discrete Distributions (Geometric) (2/3): • 𝑝 ∈ 0, 1 . Useful Prob. Dist. (8/10) geom(𝒑) ©AhmedHagag SCC430 Modeling and Simulation 31
  • 32. Discrete Distributions (Geometric) (3/3): • 𝑝 ∈ 0, 1 . Useful Prob. Dist. (8/10) geom(𝒑) Generating Random Variates 𝑋’s ©AhmedHagag SCC430 Modeling and Simulation 32 PRN
  • 33. Discrete Distributions (Poisson) (1/3): • 𝜆 > 0. Useful Prob. Dist. (9/10) Poisson(𝝀) ©AhmedHagag SCC430 Modeling and Simulation 33
  • 34. Discrete Distributions (Poisson) (2/3): • 𝜆 > 0. Useful Prob. Dist. (9/10) Poisson(𝝀) ©AhmedHagag SCC430 Modeling and Simulation 34
  • 35. Discrete Distributions (Poisson) (3/3): • 𝜆 > 0. Useful Prob. Dist. (9/10) Poisson(𝝀) ©AhmedHagag SCC430 Modeling and Simulation 35
  • 36. Useful Prob. Dist. (10/10) ©AhmedHagag SCC430 Modeling and Simulation 36 Choosing a standard theoretical distribution: 1. Select the type (family) of the distribution. 2. Estimate the parameters of the selected family using the collected data. 3. Test the selected distribution.  Heuristic (Graphical Comparison) test.  Goodness-of-Fit test (Anderson-Darling (AD), K-S, and Chi-square tests).
  • 37. Choose the suitable distribution using: 1. Summary Statistics. 2. Histogram. 3. Quantile-Quantile (𝑞-𝑞) Plot. 4. Boxplot. 5. {Others …} ©AhmedHagag SCC430 Modeling and Simulation 37 Ident. the Dist. with Data (1/9)
  • 38. Summary Statistics (1/3): Ident. the Dist. with Data (2/9) = 1 𝑛 − 1 𝑖 =1 𝑛 𝑖 ©AhmedHagag SCC430 Modeling and Simulation 38 ෠ 𝑥 − 𝑥 ҧ 2
  • 39. Summary Statistics (2/3): Ident. the Dist. with Data (2/9) ©AhmedHagag SCC430 Modeling and Simulation 39
  • 40. Summary Statistics (2/3): Ident. the Dist. with Data (2/9) ©AhmedHagag SCC430 Modeling and Simulation 40
  • 41. Summary Statistics (3/3): For example: • If the median is equal or near equal to the mean, this indicates symmetric, (e.g., normal) distribution. • If the coefficient of variation (cv) is close to 1 this indicates exponential distribution because its cv is 1. ©AhmedHagag SCC430 Modeling and Simulation 41 Ident. the Dist. with Data (2/9)
  • 42. Example1 – Summary Statistics (1/4) A simulation model was developed for a drive-up banking facility, and data were collected on the arrival pattern for cars. Over a fixed 90-minute interval, 220 cars arrived, and we noted the (continuous) interarrival time 𝑋𝑖 (in minutes) between cars 𝑖 and 𝑖 + 1, for 𝑖 = 1, 2,… , 219. ©AhmedHagag SCC430 Modeling and Simulation 42 Ident. the Dist. with Data (3/9)
  • 43. Example1 – Summary Statistics (2/4) Ident. the Dist. with Data (3/9) ©AhmedHagag SCC430 Modeling and Simulation 43
  • 44. Example1 – Summary Statistics (3/4) Ident. the Dist. with Data (3/9) ©AhmedHagag SCC430 Modeling and Simulation 44
  • 45. Example1 – Summary Statistics (4/4) Since: 𝑋 ത219 = 0.399 > 0.270 = 𝑥ො 0.5(219) and 𝑣 ො 219 = 1.478, this suggests that the underlying distribution is skewed to the right, rather than symmetric. Furthermore, 𝑐 ො 𝑣 219 = 0.953, which is close to the theoretical value of 1 for the exponential distribution. Ident. the Dist. with Data (3/9) ©AhmedHagag SCC430 Modeling and Simulation 45
  • 46. Example2 – Summary Statistics (1/3) Given the values and counts for 𝑛 = 156 observations on the (discrete) number of items demanded in a week from an inventory system, arranged into increasing order. Rather than giving all the individual values, we give the frequency counts; 59 𝑋𝑖’s were equal to 0, 26 𝑋𝑖’s were equal to 1, etc. ©AhmedHagag SCC430 Modeling and Simulation 46 Ident. the Dist. with Data (4/9)
  • 47. Example2 – Summary Statistics (2/3) Given the values and counts for 𝑛 = 156 observations on the (discrete) number of items demanded in a week from an inventory system, arranged into increasing order. Rather than giving all the individual values, we give the frequency counts; 59 𝑋𝑖’s were equal to 0, 26 𝑋𝑖’s were equal to 1, etc. Ident. the Dist. with Data (4/9) ©AhmedHagag SCC430 Modeling and Simulation 47
  • 48. Example2 – Summary Statistics (3/3) Ident. the Dist. with Data (4/9) ©AhmedHagag SCC430 Modeling and Simulation 48
  • 49. Histogram (1/3) To make a histogram, we break up the range of values covered by the data into 𝑘 disjoint adjacent intervals [𝑏 0, 𝑏1), [𝑏1, 𝑏2), . . . , [𝑏𝑘−1, 𝑏𝑘 ). All the intervals should be the same width ∆𝑏, which might necessitate throwing out a few extremely large or small 𝑋𝑖 ’s to avoid getting an unwieldy-looking histogram plot. , ∆𝑏 = max 𝑋 −min 𝑋 𝑘 = max 𝑋 −min 𝑋 ©AhmedHagag SCC430 Modeling and Simulation 49 𝑘 ∆ 𝑏 Ident. the Dist. with Data (5/9)
  • 50. Histogram (2/3) For 𝑗 = 1, 2,. . . , 𝑘, let ℎ𝑗 be the proportion of the 𝑋𝑖’s that are in the 𝑗th interval [𝑏𝑗−1, 𝑏𝑗). i.e., ℎ1 𝘍 = number of 𝑋 s in 𝑏0, 𝑏1 total number of 𝑋𝘍s . Finally, we define the function Ident. the Dist. with Data (5/9) ©AhmedHagag SCC430 Modeling and Simulation 50
  • 51. Histogram (3/3) The number of intervals 𝑘 may be chosen according to the following formula: However, in general, we do not believe that such rules are very useful. We recommend trying several different values of ∆𝑏 and choosing the smallest one that gives a “smooth” histogram. Ident. the Dist. with Data (5/9) ©AhmedHagag SCC430 Modeling and Simulation 51
  • 52. Example1 – Histogram (1/8) Ident. the Dist. with Data (6/9) ©AhmedHagag SCC430 Modeling and Simulation 52
  • 53. Example1 – Histogram (2/8) The number of intervals 𝑘 may be chosen according to the following formula: 𝑘 = 1 + log2 219 = 8 ,max 𝑋 = 1.96 ≈ 2 , min𝑋 = 0.01 ≈ 0 ∆𝑏 = 2 − 0 8 = 0.25 Ident. the Dist. with Data (6/9) ©AhmedHagag SCC430 Modeling and Simulation 53
  • 54. Example1 – Histogram (3/8) The number of intervals 𝑘 may be chosen according to the following formula: 𝑘 = 1 + log2 219 = 8 ,max 𝑋 = 1.96 ≈ 2 , min𝑋 = 0.01 ≈ 0 ∆𝑏 = 2 − 0 8 = 0.25 [0, 0.25), [0.25, 0.5),[0. 5, 0.75),[0.75, 1), [1, 1.25), [1.25, 1.5),[1.5, 1.75), [1.75, 2), Ident. the Dist. with Data (6/9) ©AhmedHagag SCC430 Modeling and Simulation 54
  • 55. Example1 – Histogram (4/8) Ident. the Dist. with Data (6/9) 0.25 ©AhmedHagag SCC430 Modeling and Simulation 55 For ∆𝑏 = 0.25 , 𝑘 = 2−0 = 8
  • 56. Example1 – Histogram (5/8) Ident. the Dist. with Data (6/9) 0.05 ©AhmedHagag SCC430 Modeling and Simulation 56 For ∆𝑏 = 0.05 , 𝑘 = 2−0 = 40
  • 57. Example1 – Histogram (6/8) Ident. the Dist. with Data (6/9) For ∆𝑏 = 0.075 , 𝑘 = 2−0 0.075 ©AhmedHagag SCC430 Modeling and Simulation 57 = 27
  • 58. Example1 – Histogram (7/8) Ident. the Dist. with Data (6/9) For ∆𝑏 = 0.1 , 𝑘 = 2−0 = 20 0.1 0.1 ©AhmedHagag SCC430 Modeling and Simulation 58 For ∆𝑏 = 0.1 , 𝑘 = 2−0 = 20
  • 59. Example1 – Histogram (8/8) Ident. the Dist. with Data (6/9) Heuristic (Graphical comparison) test The smoothest-looking histogram appears to be for ∆𝑏 = 0.1 and its shape resembles that of an exponential density. ©AhmedHagag SCC430 Modeling and Simulation 59
  • 60. Quantile-Quantile (𝒒-𝒒) plot (1/8) When there is a small number of data points, say, 30 or fewer, a histogram is not as useful for evaluating the fit of the chosen distribution. Further, our perception of the fit depends on the widths of the histogram intervals. But, even if the intervals are well chosen, grouping data into cells makes it difficult to compare a histogram to a continuous probability density function. A quantile-quantile (𝑞-𝑞) plot is a useful tool for evaluating distribution fit, one that does not suffer from these problems. ©AhmedHagag SCC430 Modeling and Simulation 60 Ident. the Dist. with Data (7/9)
  • 61. Quantile-Quantile (𝒒-𝒒) plot (2/8) A quantile-quantile (𝑞-𝑞) plot is a probability plot, which is a graphical method for comparing two probability distributions by plotting their quantiles against each other. ©AhmedHagag SCC430 Modeling and Simulation 61 Ident. the Dist. with Data (7/9)
  • 62. Quantile-Quantile (𝒒-𝒒) plot (3/8) We plot (x, y), where x’s are observed values (observed data quantiles) and y’s are the theoretical values (theoretical quantiles). If we select an appropriate family of theoretical distributions the plot points (x, y) will be approximately a straight line. On the other hand, if the assumed distribution is inappropriate, the points will deviate from a straight line. ©AhmedHagag SCC430 Modeling and Simulation 62 Ident. the Dist. with Data (7/9)
  • 63. Quantile-Quantile (𝒒-𝒒) plot (4/8) Example: A robot is used to install the doors on automobiles along an assembly line. It was thought that the installation times followed a normal distribution. The robot is capable of measuring installation times accurately. A sample of 20 installation times was automatically taken by the robot, with the following results, where the values are in seconds: ©AhmedHagag SCC430 Modeling and Simulation 63 Ident. the Dist. with Data (7/9)
  • 64. Quantile-Quantile (𝒒-𝒒) plot (5/8) Ident. the Dist. with Data (7/9) ©AhmedHagag SCC430 Modeling and Simulation 64
  • 65. Quantile-Quantile (𝒒-𝒒) plot (6/8) The observations are now ordered from smallest to largest as follows: Ident. the Dist. with Data (7/9) ©AhmedHagag SCC430 Modeling and Simulation 65
  • 66. Quantile-Quantile (𝒒-𝒒) plot (7/8) Ident. the Dist. with Data (7/9) 20 values from the normal distribution with mean 99.99 and variance 0.2832 2 ©AhmedHagag SCC430 Modeling and Simulation 66
  • 67. Quantile-Quantile (𝒒-𝒒) plot (8/8) Ident. the Dist. with Data (7/9) ©AhmedHagag SCC430 Modeling and Simulation 67
  • 68. Quantile-Quantile (𝒒-𝒒) plot (8/8) Ident. the Dist. with Data (7/9) ©AhmedHagag SCC430 Modeling and Simulation 68
  • 69. Boxplot (1/4) Is a way of graphically depicting groups of numerical data through their five number summaries: ©AhmedHagag SCC430 Modeling and Simulation 69 1st 2nd 3rd Quartile = Lower Quartile = 𝑄1. Quartile = Median Quartile = 𝑄2. Quartile = Upper Quartile = 𝑄3. 1) Smallest observation. 2) 3) 4) 5) Largest observation. Ident. the Dist. with Data (7/9)
  • 70. Boxplot (2/4) Interquartile Range (𝐼𝑄𝑅) = 𝑄3 − 𝑄1 Smallest Non-Outliers = 𝑄1 – (1.5 × 𝐼𝑄𝑅) Largest Non-Outliers = 𝑄3 + (1.5 × 𝐼𝑄𝑅) ©AhmedHagag SCC430 Modeling and Simulation 70 Ident. the Dist. with Data (7/9)
  • 71. Boxplot (3/4) Ident. the Dist. with Data (7/9) ©AhmedHagag SCC430 Modeling and Simulation 71
  • 72. Boxplot (4/4) Ident. the Dist. with Data (7/9) ©AhmedHagag SCC430 Modeling and Simulation 72
  • 73. Example1 – Boxplot (1/5) Create a boxplot for the following data set of 14 numbers: 1, 30, 6, 7.2, 4, 8, 9, 10, 6.8, 8.3, 2, 2, 10, 1 ©AhmedHagag SCC430 Modeling and Simulation 73 Ident. the Dist. with Data (8/9)
  • 74. Example1 – Boxplot (3/5) Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30 ©AhmedHagag SCC430 Modeling and Simulation 74 Ident. the Dist. with Data (8/9)
  • 75. Example1 – Boxplot (3/5) Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30 ©AhmedHagag SCC430 Modeling and Simulation 75 1st 2nd 3rd Quartile = Lower Quartile = 𝑄1. Quartile = Median Quartile = 𝑄2. Quartile = Upper Quartile = 𝑄3. 1) Smallest observation. 2) 3) 4) 5) Largest observation. Ident. the Dist. with Data (8/9)
  • 76. Example1 – Boxplot (3/5) Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30 ©AhmedHagag SCC430 Modeling and Simulation 76 1st 2nd 3rd Quartile = Lower Quartile = 𝑄1. Quartile = Median Quartile = 𝑄2. Quartile = Upper Quartile = 𝑄3. 1) Smallest observation = 1 2) 3) 4) 5) Largest observation. Ident. the Dist. with Data (8/9)
  • 77. Example1 – Boxplot (3/5) Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30 ©AhmedHagag SCC430 Modeling and Simulation 77 1st 2nd 3rd Quartile = Lower Quartile = 𝑄1. Quartile = Median Quartile = 𝑄2. Quartile = Upper Quartile = 𝑄3. 1) Smallest observation = 1 2) 3) 4) 5) Largest observation = 30 Ident. the Dist. with Data (8/9)
  • 78. Example1 – Boxplot (3/5) Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30 Quartile = Lower Quartile = 𝑄1. Quartile = Median Quartile = 𝑄2 1st 2nd 3rd = 6.8+7.2 = 7. 2 ©AhmedHagag SCC430 Modeling and Simulation 78 Quartile = Upper Quartile = 𝑄3. 1) Smallest observation = 1 2) 3) 4) 5) Largest observation = 30 Ident. the Dist. with Data (8/9)
  • 79. Example1 – Boxplot (3/5) Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30 Quartile = Lower Quartile = 𝑄1 = 2. Quartile = Median Quartile = 𝑄2 1st 2nd 3rd = 6.8+7.2 = 7. 2 Quartile = Upper Quartile = 𝑄3. 1) Smallest observation = 1 2) 3) 4) 5) Largest observation = 30 Ident. the Dist. with Data (8/9) ©AhmedHagag SCC430 Modeling and Simulation 79
  • 80. Example1 – Boxplot (3/5) Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30 Quartile = Lower Quartile = 𝑄1 = 2. Quartile = Median Quartile = 𝑄2 1st 2nd 3rd = 6.8+7.2 = 7. 2 Quartile = Upper Quartile = 𝑄3 = 9. 1) Smallest observation = 1 2) 3) 4) 5) Largest observation = 30 Ident. the Dist. with Data (8/9) ©AhmedHagag SCC430 Modeling and Simulation 80
  • 81. Example1 – Boxplot (4/5) Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30 𝑄1 = 2, 𝑄2 = 7, 𝑄3 = 9 Interquartile Range (𝐼𝑄𝑅) = 𝑄3 − 𝑄1 = 7 = −8.5 Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 ©AhmedHagag SCC430 Modeling and Simulation 81 = 19.5 Ident. the Dist. with Data (8/9)
  • 82. Example1 – Boxplot (4/5) Sort: 1, 1, 2, 2, 4, 6, 6.8, 7.2, 8, 8.3, 9, 10, 10, 30 𝑄1 = 2, 𝑄2 = 7, 𝑄3 = 9 Interquartile Range (𝐼𝑄𝑅) = 𝑄3 − 𝑄1 = 7 = −8.5 Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 19.5 Ident. the Dist. with Data (8/9) Outlier ©AhmedHagag SCC430 Modeling and Simulation 82
  • 83. Example1 – Boxplot (5/5) 𝑄1 = 2, 𝑄2 = 7, 𝑄3 = 9, 𝐼𝑄𝑅 = 7 = −8.5 Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 19.5 Ident. the Dist. with Data (8/9) ©AhmedHagag SCC430 Modeling and Simulation 83
  • 84. Example1 – Boxplot (5/5) 𝑄1 = 2, 𝑄2 = 7, 𝑄3 = 9, 𝐼𝑄𝑅 = 7 = −8.5 Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 19.5 Ident. the Dist. with Data (8/9) ©AhmedHagag SCC430 Modeling and Simulation 84
  • 85. Example2 – Boxplot (1/5) Create a boxplot for the following data set of 11 numbers: 150, 130, 160, 170, 140, 80, 190, 100, 160, 160, 130 ©AhmedHagag SCC430 Modeling and Simulation 85 Ident. the Dist. with Data (9/9)
  • 86. Example2 – Boxplot (2/5) Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190 ©AhmedHagag SCC430 Modeling and Simulation 86 Ident. the Dist. with Data (9/9)
  • 87. Example2 – Boxplot (3/5) Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190 ©AhmedHagag SCC430 Modeling and Simulation 87 1st 2nd 3rd Quartile = Lower Quartile = 𝑄1. Quartile = Median Quartile = 𝑄2. Quartile = Upper Quartile = 𝑄3. 1) Smallest observation. 2) 3) 4) 5) Largest observation. Ident. the Dist. with Data (9/9)
  • 88. Example2 – Boxplot (3/5) Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190 ©AhmedHagag SCC430 Modeling and Simulation 88 1st 2nd 3rd Quartile = Lower Quartile = 𝑄1. Quartile = Median Quartile = 𝑄2. Quartile = Upper Quartile = 𝑄3. 1) Smallest observation = 80. 2) 3) 4) 5) Largest observation. Ident. the Dist. with Data (9/9)
  • 89. Example2 – Boxplot (3/5) Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190 ©AhmedHagag SCC430 Modeling and Simulation 89 1st 2nd 3rd Quartile = Lower Quartile = 𝑄1. Quartile = Median Quartile = 𝑄2. Quartile = Upper Quartile = 𝑄3. 1) Smallest observation = 80. 2) 3) 4) 5) Largest observation = 190. Ident. the Dist. with Data (9/9)
  • 90. Example2 – Boxplot (3/5) Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190 ©AhmedHagag SCC430 Modeling and Simulation 90 1st 2nd 3rd Quartile = Lower Quartile = 𝑄1. Quartile = Median Quartile = 𝑄2 = 150. Quartile = Upper Quartile = 𝑄3. 1) Smallest observation = 80. 2) 3) 4) 5) Largest observation = 190. Ident. the Dist. with Data (9/9)
  • 91. Example2 – Boxplot (3/5) Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190 1st 2nd 3rd Quartile = Lower Quartile = 𝑄1 = 130. Quartile = Median Quartile = 𝑄2 = 150. Quartile = Upper Quartile = 𝑄3. 1) Smallest observation = 80. 2) 3) 4) 5) Largest observation = 190. Ident. the Dist. with Data (9/9) ©AhmedHagag SCC430 Modeling and Simulation 91
  • 92. Example2 – Boxplot (3/5) Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190 1st 2nd 3rd Quartile = Lower Quartile = 𝑄1 = 130. Quartile = Median Quartile = 𝑄2 = 150. Quartile = Upper Quartile = 𝑄3 = 160. 1) Smallest observation = 80. 2) 3) 4) 5) Largest observation = 190. Ident. the Dist. with Data (9/9) ©AhmedHagag SCC430 Modeling and Simulation 92
  • 93. Example2 – Boxplot (4/5) Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190 𝑄1 = 130, 𝑄2 = 150, 𝑄3 = 160 Interquartile Range (𝐼𝑄𝑅) = 𝑄3 − 𝑄1 = 30 Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 = 85 Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 ©AhmedHagag SCC430 Modeling and Simulation 93 = 205 Ident. the Dist. with Data (9/9)
  • 94. Example2 – Boxplot (4/5) Sort: 80, 100, 130, 130, 140, 150, 160, 160, 160, 170, 190 𝑄1 = 130, 𝑄2 = 150, 𝑄3 = 160 Interquartile Range (𝐼𝑄𝑅) = 𝑄3 − 𝑄1 = 30 Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 = 85 Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 205 Ident. the Dist. with Data (9/9) Outlier ©AhmedHagag SCC430 Modeling and Simulation 94
  • 95. Example2 – Boxplot (5/5) 𝑄1 = 130, 𝑄2 = 150, 𝑄3 = 160 Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 = 85 Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 205 Ident. the Dist. with Data (9/9) ©AhmedHagag SCC430 Modeling and Simulation 95
  • 96. Example2 – Boxplot (5/5) 𝑄1 = 130, 𝑄2 = 150, 𝑄3 = 160 Smallest Non-Outliers = 𝑄1 – 1.5 × 𝐼𝑄𝑅 = 85 Largest Non-Outliers = 𝑄3 + 1.5 × 𝐼𝑄𝑅 = 205 Ident. the Dist. with Data (9/9) ©AhmedHagag SCC430 Modeling and Simulation 96
  • 98. Software (2/22) ©AhmedHagag SCC430 Modeling and Simulation 98
  • 99. Software (3/22) ©AhmedHagag SCC430 Modeling and Simulation 99
  • 100. Software (4/22) ©AhmedHagag SCC430 Modeling and Simulation 100
  • 101. Software (5/22) ©AhmedHagag SCC430 Modeling and Simulation 101
  • 102. Software (6/22) ©AhmedHagag SCC430 Modeling and Simulation 102
  • 103. Software (7/22) ©AhmedHagag SCC430 Modeling and Simulation 103
  • 104. Software (8/22) ©AhmedHagag SCC430 Modeling and Simulation 104
  • 105. Software (9/22) ©AhmedHagag SCC430 Modeling and Simulation 105
  • 106. Software (10/22) ©AhmedHagag SCC430 Modeling and Simulation 106
  • 107. Software (11/22) ©AhmedHagag SCC430 Modeling and Simulation 107
  • 108. Software (12/22) ©AhmedHagag SCC430 Modeling and Simulation 108
  • 109. Software (13/22) ©AhmedHagag SCC430 Modeling and Simulation 109
  • 110. Software (14/22) ©AhmedHagag SCC430 Modeling and Simulation 110
  • 111. Software (15/22) ©AhmedHagag SCC430 Modeling and Simulation 111
  • 112. Software (16/22) ©AhmedHagag SCC430 Modeling and Simulation 112
  • 113. Software (17/22) ©AhmedHagag SCC430 Modeling and Simulation 113
  • 114. Software (18/22) ©AhmedHagag SCC430 Modeling and Simulation 114
  • 115. Software (19/22) ©AhmedHagag SCC430 Modeling and Simulation 115
  • 116. Software (20/22) ©AhmedHagag SCC430 Modeling and Simulation 116
  • 117. Software (21/22) ©AhmedHagag SCC430 Modeling and Simulation 117
  • 118. Software (22/22) ©AhmedHagag SCC430 Modeling and Simulation 118