Upload
neil-ray
View
238
Download
5
Tags:
Embed Size (px)
Citation preview
© Copyright 2015 Dr. Jeffrey Strickland
Discrete Event Simulation with ExtendSimChapter 1
Introduction to Modeling and Simulation
NASA Ares I
NASA planned to use Ares I to launch Orion, the spacecraft intended for NASA human spaceflight missions after the Space Shuttle was retired in 2011.
However, the Constellation program, including Ares I was canceled in October 2010 by the passage of the 2010 NASA authorization bill.
Dr. Strickland and a team of engineers design the Reliability and Launch Availability of the Ares I using ExtendSim.
© Copyright 2015 Dr. Jeffrey Strickland8/12/2015 Chapter 1 -2
© Copyright 2015 Dr. Jeffrey Strickland
Why simulation is important
Simulation involves designing a model of a system and carrying out experiments on it as it progresses through time.
Models enable you to see how a real-world activity will perform under different conditions and test various hypotheses at a fraction of the cost of performing the actual activity.
One of the principal benefits of a model is that you can begin with a simple approximation of a process and gradually refine the model as your understanding of the process improves.
This “stepwise refinement” enables you to achieve good approximations of very complex problems surprisingly quickly. As you add refinements, the model more closely imitates the real-life process1
1 ExtendSim user’s guide
8/12/2015 Chapter 1 -3
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -4
What is a Model?
A physical, mathematical, or otherwise logical representation of a system, entity, phenomenon, or process
An abstraction of a real world problem, based on simplifying assumption.
Since a modeling is a representation, abstraction, or approximation of the “system” being modeled, we must understand that it is not an “exact” representation, i.e., we can’t model every aspect of the system.
Example: Weather Model
Many degrees of freedom (DOF) with a vast array of environmental factors
Simplify model with only a few of the most important factors (other non-representative factors represent the error in the model)
Example: Marketing Model
People have a propensity to buy due to demographics, online activity, visual stimulation, emotions, etc.
Model model based on demographics and online activity
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -5
Model Definitions & Contrasts
Physical model
Mock-up model
Scale model
Iconic model
Fashion model
Symbolic Model
Narrative model
Graphical model
Tabular model
Software model
Mathematical model
x f (x) f ' (x)0 0 01 1 22 4 43 9 64 16 8
Specifications:• 30 GB HD• 1 GB RAM• CD RW/DVD
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -6
Contrasting Model Examples
Deterministic (Static) modelsStochastic (Dynamic) models
Descriptive modelsPredictive models
Discrete modelsContinuous models
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -7
A Sampling of Model Examples
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -8
A Sampling of ExamplesAccounts Receivable at Spring Mills
0
400
800
1200
1600
2000
2400
0.0 7.5 15.0 22.5 30.0 37.5 45.0
Days
Am
ou
nt
Correlation = 0.489
Scatterplot of Amount versus Days for All Customers: Data Model
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -9
A Sampling of ExamplesCompetitive Bidding by SciTools Incorporated
FALSE 0
0 0
Bid?
12200
30.0% 0.3
20000 15000
TRUE Any competing bid?
0 12200
80.0% 0.56
20000 15000
70.0% Win bid?
0 11000
20.0% 0.14
0 -5000
TRUE How much to bid
-5000 12200
30.0% 0
25000 20000
FALSE Any competing bid?
0 9500
40.0% 0
25000 20000
70.0% Win bid?
0 5000
60.0% 0
0 -5000
30.0% 0
30000 25000
FALSE Any competing bid?
0 6100
10.0% 0
30000 25000
70.0% Win bid?
0 -2000
90.0% 0
0 -5000
SciTools Bidding
No
Yes
$115K
$120K
$125K
No
Yes
Yes
No
No
Yes
Yes
No
No
Yes
Yes
No
Decision Tree Model
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -10
A Sampling of Examples
Analysis of Auditing Example: Parameter Model (Confidence Interval for a Mean)
Auditing example for an exact Confidence Interval Width
Confidence Level 95%sample mean 1500
sample standard deviation 390sample size 45
z value 1.9600
upper confidence limit 1613.95lower confidence limit 1386.05
width of CI 227.9000
upper confidence limit 1575.00lower confidence limit 1425.00Goal Seek for CI width 150.00
sample size needed 103.8757
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -11
A Sampling of ExamplesExplaining Overhead Costs at Bendrix
Data for new employees: Regression Model
Training Weeks (X)
# of completed Projects
(Y)1.2 1010.8 921.0 1101.3 1200.7 900.8 821.0 930.6 750.9 911.1 105
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -12
A Sampling of ExamplesQuarterly Sales at Intel
Time series plot of Sales
Exponential trend line
y = 292.46e0.0664x
R2 = 0.9848
0
2000
4000
6000
8000
Quarter
Sale
s
Time Series Plot of Quarterly Sales at Intel: Forecasting Model
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -13
A Sampling of ExamplesBasic Combat Attrition Model
aydt
dx
bxdt
dy
0 510 15 20 25 30 35 40 45 50
55
60
X(t)Y(t)
0
5
10
15
20
25
30
Fo
rce
Str
eng
th
Time
Square Law Time Solutions
X(t)
Y(t)
0 510 15 20 25 30 35 40 45 50
55
60
X(t)Y(t)
0
10
20
30
40
50
60
Fo
rce
Str
eng
th
Time
Square Law Time Solutions
X(t)
Y(t)
Y(0) ↑ 60
b ↑ 0.16
X(0) = Y(0) = 30
a = b = 0.14
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -14
A Sampling of ExamplesTracking Market Shares of Two Dominant Companies in the Iced Tea Market
Iced tea market share simulation
Input section
Current market shares of dominant companies Sweetness 0.49 IceT 0.49
Current data on small companiesNumber 3Combined market share 0.02
Probability any small company will exit industry in any year0.5
Mean number of new entries in any year (Poisson distributed)1
Percentage of market share of each exiter that goes to Sweetness - the rest go to IceT (triangularly distributed)
Minimum Most likelyMaximum0.4 0.5 0.6
Percentage of companies' market shares lost to each other and to small companiesMinimum Most likelyMaximum
Sweetness to IceT 0.01 0.05 0.1 to each small company 0.005 0.01 0.03IceT to Sweetness 0.01 0.05 0.1 to each small company 0.005 0.01 0.03Small companies to Sweetness 0.05 0.1 0.15 to IceT 0.05 0.1 0.15
Input for Iced Tea Example: Monte Carlo Simulation Model
8/12/2015 © Copyright 2015 Dr. Jeffrey Strickland Lesson 1 -15
A Sampling of ExamplesDiscrete Event Simulation of a Transportation System
© Copyright 2015 Dr. Jeffrey Strickland
What is Simulation?
A simulation is the execution of a model over time ot other parameter.
Simulation involves designing a model of a system and carrying out experiments on it.
The purpose of these "what if” experiments is to determine how the real system performs and to predict the effect of changes to the system as time progresses.
For example, you use simulation to answer questions like:
Will this change to our process result in higher yields or quality?
How many people are required to maintain service at a specified level, for example, in a processing station?
Can we design this weapon system with fewer components and still maintain measures of performance, such as availability or lethality?
Does this force structure meet the capability requirement specified by the commander?
8/12/2015 Chapter 1 -16
© Copyright 2015 Dr. Jeffrey Strickland
Formal Definitions of Simulation
A formal definition of simulation is given by the Department of Defense Directive:
Definition 1: A method for implementing a model over time. Also, a technique for testing, analysis, or training in which real-world systems are used, or where real-world and conceptual systems are reproduced by a model.
Another definition is given by Winston & Albright, in Practical Management Science, 2001:
Definition 2: A simulation model is a computer model that imitates a real-life situation
8/12/2015 Chapter 1 -17
© Copyright 2015 Dr. Jeffrey Strickland
Different Kinds of Simulation
Monte Carlo SimulationEstimate stochastic, static model quantities that are difficult to compute by exact computations. A scheme employing random numbers which is used for solving certain stochastic problems where the passage of time plays no substantive role.
1
Dynamic SimulationDynamic system simulations observe the behavior of the system models over time. The time advance mechanism used here include continuous, discrete time, and discrete event.
2
Differential Equation System Specification (DESS)2a
Discrete Time System Specification (DTSS)2b
Discrete Event System Specification (DEVS)2b
8/12/2015 Chapter 1 -18
© Copyright 2015 Dr. Jeffrey Strickland
Discrete-Event Simulation
Estimate stochastic, dynamic, and discrete model outputs. A scheme for modeling a system as it evolves over time by a representation in which state variables change instantaneously at separate points in time.In simple terms, DES describes how a system with discrete flow units or jobs evolves over time.Technically, this means that a computer tracks how and when state variables, such as queue lengths and resource availability, change over time.State variables change as the result of an event (or discrete event) occurring in the system.A characteristic is that discrete-event models focus only on the time instances when these discrete events occur.This feature allows for significant time compression because it allows the model to skip through all time segments between events when the state of the system remains unchanged.
8/12/2015 Chapter 1 -19
© Copyright 2015 Dr. Jeffrey Strickland
Bank Model
Hierarchical modeling
Statistics collection
Buttons
Notebooks
Ghost Connectors
Multiple random inputs
8/12/2015 Chapter 1 -20
© Copyright 2015 Dr. Jeffrey Strickland
Circuit Card Assembly
Multiple queuesMultiple servicesParallel servises
Serial servicesConveyer beltsBatching
8/12/2015 Chapter 1 -21
© Copyright 2015 Dr. Jeffrey Strickland
Transportation
Labor pools
Task completion delays
Transferring goods
Transporting goods8/12/2015 Chapter 1 -22
© Copyright 2015 Dr. Jeffrey Strickland
Languages for Simulation
1950’s began seeking languages specifically designed for simulation problemsGeneral Simulation Program (GSP) 1960
The First Simulation-specific Programming LanguageBy K.D. Tocher and D.G. Owen, General ElectricProceedings of the Second International Conference on Operations Research
8/12/2015 Chapter 1 -23
© Copyright 2015 Dr. Jeffrey Strickland
Evolved Definition of Simulation Language
Six key characteristics:
Generate Random Numbers
Transformation for Statistical Distributions
List Processing
Statistical Analysis
Report Generation
Timing Execution
8/12/2015 Chapter 1 -24
© Copyright 2015 Dr. Jeffrey Strickland
Typical Simulation Program
Finished?
Start
Stop
0. Invoke Initialization1. Invoke Timing2. Invoke Event Handler
Main
0. Update state variables1. Increment counters2. Generate future events
Event Routines
1. Compute interest data2. Write reports
Reports
1. Select next event2. Advance sim clock
Timing
1. Statistical distributions2. Mathematical operations
Mathematics
1. Set clock2. Set state variables3. Load event list
Initialization
NO
YESLegend
Programmer’sresponsibility
Language’sResponsibility
8/12/2015 Chapter 1 -25
© Copyright 2015 Dr. Jeffrey Strickland
Activity
Scan
GSP
SIMPAC
CSL
ESP
ECSL
OPS-1,2
OPS-3
OPS-4
1960
1965
1970
1980
1990
GPSS V6000
ProcessInteraction
GPSS
GPSS II
GPSS III
GPSS/360
GPSS IV
GPSS/H
GPSS 85GPSS PC
GPSS PL/I
SIMULA I
SIMULA 67
NGPSS
CONSUM
EventInteraction
GASP
GASP II
GERTS
GASP IV
GASP PL/I
SLAM
SIMAN SLAM II
GEMS
SPS-1
SIMSCRIPT
QUICKSCRIPT
SIMSCRIPT II
SIMSCRIPT II+
SIMSCRIPT II.5
SIMFACTORY II.5
MOSIM
NETWORK II.5
COMNET II
8/12/2015 Chapter 1 -26
© Copyright 2015 Dr. Jeffrey Strickland
Sim Language Comparisons
GPSS/H
SIMULATEGENERATE RVEXPO(1,1.0)QUEUE SERVERSEIZE SERVER
LVEQ DEPART SERVERQTEST L N$LVEQ, 1000, STOPADVANCE RVEXPO(2,0.5)
STOP RELEASE SERVERTERMINATE 1START 1000END
SLAM II
GEN, 1,,,,,,72;LIM,1,1,100;NETWORK;
RESOURCE/SERVER(1),1CREATE,EXPON(1.0,1),1,1;AWAIT(1),SERVER;COLCT,INT(1),DELAY IN QUEUE,,2;
ACTIVITY,EXPON(0.5,2),,DONE;ACTIVITY,,,CNTTR;
DONE FREE,SERVERTERM;
CNTR TERM,1000;END;
;INIT;FIN;
SIMAN
BEGIN
CREATE,,EX(1,1):EX(1,1);MARK(1);QUEUE, 1;SEIZE :SERVER;TALLY :1, INT(1);COUNT :1,1;DELAY :EX(2,2);RELEASE :SERVER;DISPOSE;
END;
8/12/2015 Chapter 1 -27
© Copyright 2015 Dr. Jeffrey Strickland
Visual Interactive Simulation (1)
Arena (SIMAN)SimProcess (SimScript II.5)
8/12/2015 Chapter 1 -28
© Copyright 2015 Dr. Jeffrey Strickland
Visual Interactive Simulation (2)
ExtendOPNET
8/12/2015 Chapter 1 -29
© Copyright 2015 Dr. Jeffrey Strickland
Alan Pritsker’s Seven Principles
1. Conceptualizing a model requires system knowledge, engineering judgment, and model-building tools.
2. The secret to being a good modeler is the ability to remodel3. The modeling process is evolutionary because the act of modeling reveals important
information piecemeal.4. The problem or problem statement is the primary controlling element in model-base problem
solving.5. In modeling combined systems, the continuous aspects of the problem should be considered
first. The discrete aspects of the problem should then be developed.6. A model should be evaluated according to its usefulness. From an absolute perspective, a
model is neither good or bad, nor is it neutral.7. The purpose of simulation modeling is knowledge and understanding, not models.
8/12/2015 Chapter 1 -30
© Copyright 2015 Dr. Jeffrey Strickland
“All models are wrong; but some are useful.”
George E.P. Box
8/12/2015 Chapter 1 -31
© Copyright 2015 Dr. Jeffrey Strickland
References
Banks, J., Carson, J.S. II, Nelson, B., & Nicol, D.M. (2001). Discrete-Event System Simulation. Prentice Hall.Cloud, D.J. & Rainey, L.B. (Eds.). (1998). Applied Modeling and Simulation: An integrated Approach to Development and Operation. McGraw-Hill.Law, A.M. & Kelton, D.W. (1998). Simulation Modeling & Analysis, 2nd Ed., 234-266. McGraw-Hill.Schriber, T.J. & Brunner, D.T. (1998). How discrete-event simulation software works. In Handbook of Simulation, 765-811. Wiley. Chapter 24. Zeigler, B.P, Praehofer, H., & Kim, T.G. (2000). Theory of Modeling and Simulation, 2nd Ed., 75-96. Academic Press.
8/12/2015 Chapter 1 -32