SlideShare a Scribd company logo
1 of 36
Download to read offline
Computer Science, Informatik 4
Communication and Distributed Systems
Simulation
Modeling and Performance Analysis with Discrete-Event Simulation
g y
Dr. Mesut Güneş
Computer Science, Informatik 4
Communication and Distributed Systems
Chapter 1
Introduction to Simulation
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction to Simulation
Introduction to Simulation
ƒ Given a system, how do you evaluate its performance?
Given a system, how do you evaluate its performance?
System
System
How to evaluate?
Experiments Analysis Simulation
Develop a mathematical Develop a computer program
Use existing instance of the
system to perform
performance measurements.
abstraction of the system and
derive formulas which
describe the system
performance.
which implements a model of
the system. Perform
experiments by running the
computer program.
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 3
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction to Simulation
Introduction to Simulation
ƒ How to study a system?
y y
• Measurements on an existing system
- What to do, if system does not exist in reality?
- What to do, if changes are very expensive or time consuming?
• Mathematical analysis
- Good solutions, but only feasible for simple systems.
- Real world systems are too complex, e.g., factory, computer, network etc.
Other course from Informatik 4
Modeling and Evaluation of Communication Systems
• Simulation
B ild th b h i f t ithi
- Build the behavior of a system within a program
ƒ The content of this course is described in the subtitle
• Modeling and Performance Analysis of … by means of Discrete-Event
Simulation
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 4
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction to Simulation
Introduction to Simulation
ƒ There are many open questions
There are many open questions
• What is a system?
• What is a model?
• What is performance and how to measure it?
• On what does performance depend?
Ho to b ild a model?
• How to build a model?
• How to numerically evaluate it?
• How to interpret such results?
How to interpret such results?
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 5
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction to Simulation
Introduction to Simulation
System
Experiment with the actual system Experiment with a model of the system
Physical Model Mathematical Model
Analytical Model Simulation
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 6
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction to Simulation
Introduction to Simulation
ƒ Simulation is used to imitate the real
Wooden mechanical horse simulator
during WW1
world
• It is not as new as we think ;-)
ƒ According to Elmaghraby [1968]
• Aid to thought
g
• Communication
• Training/Education
• Experimentation
A soldier in a heavy-wheeled-vehicle
driver simulator
• Experimentation
• Predicting
driver simulator
• Entertainment (this is a new application)
- Video games
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 7
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction – Example 1
Introduction – Example 1
ƒ A storehouse with n loading berths
g
ƒ There are several 100 trucks daily to serve
ƒ Loading time of a truck is 50 minutes
Storehouse
ƒ Goal
• Cost-effective loading and short waiting time
ƒ Usually 2 customer types
1 n
Truck
Truck
Truck
Truck
ƒ Usually 2 customer types
• Type 1: Full load with only one product
• Type 2: Load consisting of several products
k
k
k
k
ƒ Proposals
• Fast loading berth for Type 1 customers
• Special berth for Type 2 customers
Truc
Truc
Truc
Special berth for Type 2 customers
ƒ Problem
• Cannot experiment, changes are expensive!
ck
ck
ck
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 8
Park Slots
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction – Example 2
Introduction – Example 2
ƒ Experiment
p
• Sliding of a leader on the wall
• A leader is at the wall
W d th b tt f th
Top
• We draw the bottom of the
leader and the top of the
leader is leant on the wall and
slides down
slides down.
ƒ Question: Which shape draws
p
the center of the leader?
• Concave
• Convex
• Convex
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 9
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction – Example 2
Introduction – Example 2
ƒ Variant: The leader falls down from the wall
Variant: The leader falls down from the wall
ƒ The resulting shape is convex.
Top
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 10
Experiment 1: Leader falls down from the wall
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction – Example 2
Introduction – Example 2
ƒ One intuitively thinks the driven shape will be concave.
One intuitively thinks the driven shape will be concave.
ƒ However, the resulting shape is also convex.
ƒ Astonished?
Top
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 11
Experiment 2: Leader slides down on the wall
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction – Example 3
Introduction – Example 3
ƒ Clients request some service from a server over a network.
q
• Client = User and web browser
• Service = web page
S b
• Server = web server
• Network = local network,
Internet, wireless network
ƒ Analysis
• Performance of the server
Client 1
Network
(Internet)
• Performance of the server
• Performance of the network
Client k
Server
ƒ Attention
• In this examples the
server as well as
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 12
server as well as
the network is
depicted very simple!
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction – Example 4
Introduction – Example 4
ƒ Mobile multi-hop ad-hoc network
p
(MANET)
• Wireless network consisting of
mobile nodes
• No infrastructure, i.e. no Access
Points or Base Stations
• Two nodes can communicate if
there are in communication
range
• Typically, the source and
destination nodes of a
destination nodes of a
connection are several hops
away
• Thus all nodes have to relay
Thus, all nodes have to relay
data for others
ƒ Mobile node
ƒ Communication range
ƒ Source node
ƒ Relay node
ƒ Destination node
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 13
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction – Example 4
Introduction – Example 4
ƒ For the analysis of a MANET a
y
mobility model is needed
ƒ Assumption
• Movement area: Rectangle without
Movement area: Rectangle without
obstacles
ƒ Simple model: Random-Waypoint
mobility model
mobility model
• A node selects uniformly a point
on the simulation area p=(x, y)
• Velocity v ∈[vmin, vmax]
Velocity v ∈[vmin, vmax]
• Pause time tpause
• The node moves to the point p
with velocity v
with velocity v
• Stays for tpause time units on p and
restarts movement
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 14
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction – Example 4
Introduction – Example 4
ƒ What's about the probability that a
1000
p y
node is on point p = (x,y) on the
movement area?
• Uniformly distributed? 600
800
y
- Since x and y are uniformly selected.
• Are some areas preferred?
200
400
ƒ What's about the influence of the
parameters?
• Velocity
400 800
600
0 200
200
• Velocity
• Pause time
Altho gh simple to describe
2E-6
ƒ Although simple to describe,
mathematically it is hard to get a
closed form formulae.
0
200
400
x
600
0
5E-7
1E-6
1,5E-6
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 15
600
0
0
800
200 400 600 800
1000
1000
y
Computer Science, Informatik 4
Communication and Distributed Systems
Introduction to Simulation
Introduction to Simulation
ƒ What is a simulation?
What is a simulation?
• A simulation is the imitation of the operation of a real-world
system over time.
ƒ What is the method?
G t tifi i l hi t f t
• Generate an artificial history of a system
• Draw inferences from the artificial history concerning the
characteristics of the system
y
ƒ How it is done?
• Develop a model
• Model consists of entities (objects)
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 16
Computer Science, Informatik 4
Communication and Distributed Systems
When simulation is appropriate
When simulation is appropriate
ƒ Simulation can be used for the following purposes:
g p p
• Simulation enables the study of experiments with internal
interactions
• Informational organizational and environmental changes can be
• Informational, organizational, and environmental changes can be
simulated to see the model’s behavior
• Knowledge from simulations can be used to improve the system
Ob i lt f i l ti i i i ht t hi h
• Observing results from simulation can give insight to which
variables are the most important ones
• Simulation can be used as pedagogical device to reinforce the
learning material
• Simulations can be used to verify analytical results, e.g.
queueing systems
• Animation of a simulation can show the system in action, so that
the plan can be visualized
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 17
Computer Science, Informatik 4
Communication and Distributed Systems
When simulation is not appropriate
When simulation is not appropriate
ƒ Simulation should not be used, in the case
Simulation should not be used, in the case
• when problem is solvable by common sense
• when the problem can be solved mathematically
• when direct experiments are easier
• when the simulation costs exceed the savings
hen the sim lation req ires time hich is not a ailable
• when the simulation requires time, which is not available
• when no (input) data is available, but simulations need data
• when the simulation cannot be verified or validated
when the simulation cannot be verified or validated
• when the system behavior is too complex or unknown
ƒ Example: human behavior is extremely complex to model
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 18
Computer Science, Informatik 4
Communication and Distributed Systems
Advantages and disadvantages of simulation
Advantages and disadvantages of simulation
ƒ Advantages of simulation
g
• Policies, procedures, decision rules, information flows can be explored
without disrupting the real system
• New hardware designs, physical layouts, transportation systems can
tested without committing resources
tested without committing resources
• Hypotheses about how or why a phenomena occur can be tested for
feasibility
• Time can be compressed or expanded
e ca be co p essed o e pa ded
- Slow-down or Speed-up
• Insight can be obtained about the interaction of variables
• Insight can be obtained about the importance of variables to the
f f th t
performance of the system
• Bottleneck analysis can be performed to detect excessive delays
• Simulation can help to understand how the system operates rather than
how people think the system operates
how people think the system operates
• “What if” questions can be answered
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 19
Computer Science, Informatik 4
Communication and Distributed Systems
Advantages and disadvantages of simulation
Advantages and disadvantages of simulation
ƒ Disadvantages of simulation
g
• Model building requires training, it is like an art.
- Compare model building with programming.
• Simulation results can be difficult to interpret
• Simulation results can be difficult to interpret
- Most outputs are essentially random variables
- Thus, not simple to decide whether output is randomness or system
behavior
behavior
• Simulation can be time consuming and expensive
- Skimping in time and resources could lead to useless/wrong results
ff f
ƒ The disadvantages are offset as follows
• Simulation packages contain models that only need input data
• Simulation packages contain output-analysis capabilities
p g p y p
• Sophistication in computer technology improves simulation times
• For most of the real-world problems there are no closed form solutions
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 20
Computer Science, Informatik 4
Communication and Distributed Systems
Areas of Application
Areas of Application
ƒ Application areas of simulation
pp
• Manufacturing applications
• Semiconductor manufacturing
Constr ction engineering and project management
• Construction engineering and project management
• Military applications
• Logistics, supply chain and distribution applications
• Transportation models and traffic
• Business process simulation
• Health care
• Health care
• Call-center
• Computers and Networks
• Games
• ...
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 21
Computer Science, Informatik 4
Communication and Distributed Systems
Systems and System Environment
ƒ System
Systems and System Environment
System
• A system is a group of objects that are joined together in some
regular interaction or interdependence toward the
li h t f
accomplishment of some purpose.
• Example: Automobile factory
- Machines, parts, and workers operate jointly to produce a vehicle
, p , p j y p
• Example: Computer network
- User, hosts, routers, lines establish a network
ƒ System environment
• Everything outside the system, but affects the system
ƒ Attention
ƒ Attention
• It is important to decide on the boundary between the system
and the system environment
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation
• This decision depends on the purpose of the study
22
Computer Science, Informatik 4
Communication and Distributed Systems
Components of a System
Components of a System
ƒ In order to understand and analyze a system, we need some
In order to understand and analyze a system, we need some
terms
ƒ General Terminology
• Entity Object of interest in the system
• Attribute Property of an entity
A ti it A ti i d f ifi d l th
• Activity A time period of specified length
• System state Collection of variables required to describe the
system at any time
y y
• Event An instantaneous occurrence that might
change the state of the system
Endogenous Activities and Events occurring within the
• Endogenous Activities and Events occurring within the
system
• Exogenous Activities and Events in the environment
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 23
(outside the system) that affect the system
Computer Science, Informatik 4
Communication and Distributed Systems
Components of System – Examples
Components of System – Examples
System Entities Attributes Activities Events State Variables
Banking Customers Checking-
account
balance
Making deposits Arrival;
departure
Number of busy
tellers
Number of waiting
customer
customer
Rapid rail Riders Source
Destination
Traveling Arrival at
station
Arrival at
Number of riders
at each station
Number of rider in
destination transit
Production Machines Speed
Capacity
Breakdown rate
Welding
Stamping
Breakdown Status of
machines
Breakdown rate
Communications Messages Length
Destination
Transmitting Arrival at
destination
Number of waiting
messages to be
transmitted
Inventory Warehouse Capacity Withdrawing Demand Levels of
inventory
f
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 24
Mobility model Node Position
Velocity
Travel End of
movement
Position
Velocity
Computer Science, Informatik 4
Communication and Distributed Systems
Discrete and Continuous Systems
Discrete and Continuous Systems
ƒ Discrete Systems
y
• State variables change only at
discrete set of points
• Example: Bank
• Example: Bank
C ti S t
ƒ Continuous Systems
• State variables change
continuously over time
• Example: Head of water
behind a dam
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 25
Computer Science, Informatik 4
Communication and Distributed Systems
Model of a System
Model of a System
ƒ What is a model?
• A model is a representation of a system
for the purpose of studying the system.
- It is necessary to consider those aspects of
the system that affect the problem under
investigation Input Output
investigation
ƒ Avoid too much detail
• ”The tendency is nearly always to
simulate to much detail rather than too
little Thus one should always design the
System
Input Output
little. Thus, one should always design the
model around the question to be
answered rather than imitate the real
system exactly.” [Shannon, 1975]
ƒ Physical model
ƒ Physical model
• Prototype of a system for the purpose of
study.
ƒ Mathematical model Model
O(t)
I(t)
• A mathematical model uses symbolic
notation and mathematical equations to
represent a system.
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 26
Computer Science, Informatik 4
Communication and Distributed Systems
Model of a System
ƒ Example 1: Movement
Model of a System
p
• Model:
• Assumptions: Constant velocity v over the whole time t
t
v
d ⋅
=
• Advantage: Simple formulae and intuitive
• Disadvantage: Seldom valid for a whole travel (human, car,
planes)
planes)
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 27
Computer Science, Informatik 4
Communication and Distributed Systems
Model of a System
ƒ Example 2: Radio signal propagation
Model of a System
Example 2: Radio signal propagation
• Free-Space-Modell
⎞
⎛ 2
G
G λ
• Model:
Ass mptions
⎟
⎟
⎠
⎞
⎜
⎜
⎝
⎛
−
= 2
2
2
)
4
(
log
10
)
(
d
G
G
d
PL r
t
dB
π
λ d
• Assumptions:
- Direct line of of sight (LOS) between
communication peers -30
-25
measured mean signal strength
theoretical signal strength
strong signal
Measurements in Computer Science
Department, Informatik 4
- No obstacles
• Advantages:
- Simple asymptotic formulae for open
-40
-35
al
strength
[dBm]
- Simple asymptotic formulae for open
space
• Disadvantages:
N ll f ll f i d d i
-55
-50
-45
received
signa
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation
- Not really usefull for indoor and city
environments
28
5 10 15 20 25
-60
55
distance from access point [m]
weak signal
Computer Science, Informatik 4
Communication and Distributed Systems
Simulation Models
Simulation Models
ƒ Simulation Model
• A simulation model is a particular type of mathematical model of a
system.
T f i l ti d l
ƒ Types of simulation models
• Static: Represent a system at a particular point in time.
• Dynamic: Represent a system over a time interval.
• Deterministic: Simulation models without random variables.
• Stochastic: Simulation models with random variables.
• Discrete: System state changes occur only at discrete time points.
• Continuous: System state changes occur continuously.
We will focus on discrete, dynamic, and stochastic simulation
models
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 29
Computer Science, Informatik 4
Communication and Distributed Systems
Simulation Models
Simulation Models
Models
static dynamic
deterministic stochastic
continuous discrete
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 30
continuous discrete
Computer Science, Informatik 4
Communication and Distributed Systems
Discrete-Event System Simulation
Discrete-Event System Simulation
ƒ Discrete-event Simulation
Discrete event Simulation
• System state changes only at discrete set of points in time.
• Simulation model is analyzed by numerical methods.
• Numerical methods employ computational procedures to “solve”
mathematical models.
• The model is rather “run” than “solved”
• The model is rather run than solved
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 31
Computer Science, Informatik 4
Communication and Distributed Systems
Simulation for static models
ƒ Monte Carlo simulation
Simulation for static models
Monte Carlo simulation
ƒ Mainly used for mathematical problems which are not
analytically tractable
ƒ Example: Approximate π
• Area of a circle:
C t th b f i t i id d t id it t
π
π =
⇒
=
⋅
= A
r
r
A 1
if
2
• Count the number of points inside and outside a unit quarter
circle.
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 32
Computer Science, Informatik 4
Communication and Distributed Systems
Simulation of dynamic continuous models
Simulation of dynamic, continuous models
ƒ System described by ƒ Growth rate of the prey
y y
differential equation
ƒ Typically involves numerical
solution of these equations
p y
population without predators
• r ⋅ x(t)
ƒ Predator change rate
q
ƒ No real difference to a
numerically based
mathematical solution
g
• -s ⋅ y(t)
ƒ Interactions
dx
ƒ Typical example:
predator/prey systems
• Let x(t) be the size of the )
(
)
(
)
(
)
(
)
(
)
(
t
y
t
x
b
t
y
s
d
dy
t
y
t
x
a
t
x
r
dt
dx
⋅
⋅
+
⋅
−
=
⋅
⋅
−
⋅
=
Let x(t) be the size of the
prey population
• Let y(t) be the size of the
predator population
ƒ Parameters
• x(0), y(0), a, b, r, s
)
(
)
(
)
( y
y
dt
x(0), y(0), a, b, r, s
ƒ Metrics
• x(t), y(t)
ƒ Solve system of differential
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation
ƒ Solve system of differential
equations
33
Computer Science, Informatik 4
Communication and Distributed Systems
Steps in a Simulation Study
Steps in a Simulation Study
1. Problem formulation
ƒ Clearly understand problem
Clearly understand problem
ƒ Reformulation of the problem
2. Setting of objectives and overall project plan
ƒ Which questions should be answered?
ƒ Is simulation appropriate?
ƒ Costs?
3. Model conceptualization
ƒ No general guide
ƒ Modeling tools in research, e.g. UML
4. Data collection
ƒ How to get data?
Are random distributions appropriate?
ƒ Are random distributions appropriate?
5. Model translation
ƒ Program
6. Verified?
ƒ Does the program that, what the model describes?
7 Validated?
7. Validated?
ƒ Do the results match the reality?
ƒ In cases with no real-world system, hard to validate
8. Experimental design
ƒ Which alternatives should be run?
ƒ Which paramters should be varied?
p
9. Production runs and analysis
10. More runs?
11. Documentation and reporting
ƒ Program documentation – how does the program work
ƒ Progress documentation – chronology of the work
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 34
g gy
12. Implementation
Computer Science, Informatik 4
Communication and Distributed Systems
Steps in a Simulation Study
Steps in a Simulation Study
Phase 1:
Discovery and
sco e y a d
Orientation
Phase 2:
Phase 2:
Model building
and data
collection
Most crucial step is collection
Most crucial step is
validation.
If model is invalid
results can lead to
Phase 3:
Run the model
dangerous and
expensive
decisions!
Phase 4:
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 35
Implementation
Computer Science, Informatik 4
Communication and Distributed Systems
Summary
Summary
ƒ Motivated the course by examples
Motivated the course by examples
ƒ Introduced simulation as a notion
ƒ Discussed for what purposes simulation is useful
p p
ƒ Introduction of a general terminology
ƒ Introduction of discrete-event simulation
ƒ Discussed the steps of a simulation study
Dr. Mesut Güneş
Chapter 1. Introduction to Simulation 36

More Related Content

Similar to 01.pdf

What is sim?ulation
What is sim?ulationWhat is sim?ulation
What is sim?ulationMusab Cannon
 
Discrete event simulation
Discrete event simulationDiscrete event simulation
Discrete event simulationssusera970cc
 
Introduction to simulation modeling
Introduction to simulation modelingIntroduction to simulation modeling
Introduction to simulation modelingbhupendra kumar
 
20121121101127simulation azmi
20121121101127simulation azmi20121121101127simulation azmi
20121121101127simulation azmiAhmad Nur Faiz
 
Modeling&Simulation_Ch01_part 3.pptx
Modeling&Simulation_Ch01_part 3.pptxModeling&Simulation_Ch01_part 3.pptx
Modeling&Simulation_Ch01_part 3.pptxMaiGaafar
 
Simulation and monte carlo some general principles
Simulation and monte carlo some general principlesSimulation and monte carlo some general principles
Simulation and monte carlo some general principlesAhmedaboraia
 
The principles of simulation system design.pptx
The principles of simulation system design.pptxThe principles of simulation system design.pptx
The principles of simulation system design.pptxubaidullah75790
 
Simulation and Modelling Reading Notes.pptx
Simulation and Modelling  Reading Notes.pptxSimulation and Modelling  Reading Notes.pptx
Simulation and Modelling Reading Notes.pptxDanMuendo1
 
Slides-Introduction-to-System-Dynamics-Modeling-October-20-2021.pdf
Slides-Introduction-to-System-Dynamics-Modeling-October-20-2021.pdfSlides-Introduction-to-System-Dynamics-Modeling-October-20-2021.pdf
Slides-Introduction-to-System-Dynamics-Modeling-October-20-2021.pdfChristineCheong5
 
Simulation of complex systems: the case of crowds (Phd course - lesson 1/7)
Simulation of complex systems: the case of crowds (Phd course - lesson 1/7)Simulation of complex systems: the case of crowds (Phd course - lesson 1/7)
Simulation of complex systems: the case of crowds (Phd course - lesson 1/7)Giuseppe Vizzari
 
Course Learning Outcomes Virtual Systems and Services
Course Learning Outcomes Virtual Systems and ServicesCourse Learning Outcomes Virtual Systems and Services
Course Learning Outcomes Virtual Systems and ServicesKdmFarooqMurad
 
Introduction to simulation and modeling
Introduction to simulation and modelingIntroduction to simulation and modeling
Introduction to simulation and modelingantim19
 
Coursework Assignment Design of a taxi meter .docx
Coursework Assignment   Design of a taxi meter .docxCoursework Assignment   Design of a taxi meter .docx
Coursework Assignment Design of a taxi meter .docxvanesaburnand
 
System simulation & modeling notes[sjbit]
System simulation & modeling notes[sjbit]System simulation & modeling notes[sjbit]
System simulation & modeling notes[sjbit]qwerty626
 
Modeling & simulation in projects
Modeling & simulation in projectsModeling & simulation in projects
Modeling & simulation in projectsanki009
 

Similar to 01.pdf (20)

What is sim?ulation
What is sim?ulationWhat is sim?ulation
What is sim?ulation
 
Discrete event simulation
Discrete event simulationDiscrete event simulation
Discrete event simulation
 
Introduction to simulation modeling
Introduction to simulation modelingIntroduction to simulation modeling
Introduction to simulation modeling
 
Simulation Powerpoint- Lecture Notes
Simulation Powerpoint- Lecture NotesSimulation Powerpoint- Lecture Notes
Simulation Powerpoint- Lecture Notes
 
20121121101127simulation azmi
20121121101127simulation azmi20121121101127simulation azmi
20121121101127simulation azmi
 
Modeling&Simulation_Ch01_part 3.pptx
Modeling&Simulation_Ch01_part 3.pptxModeling&Simulation_Ch01_part 3.pptx
Modeling&Simulation_Ch01_part 3.pptx
 
Simulation and monte carlo some general principles
Simulation and monte carlo some general principlesSimulation and monte carlo some general principles
Simulation and monte carlo some general principles
 
The principles of simulation system design.pptx
The principles of simulation system design.pptxThe principles of simulation system design.pptx
The principles of simulation system design.pptx
 
lecture_1.pptx
lecture_1.pptxlecture_1.pptx
lecture_1.pptx
 
M 3 iot
M 3 iotM 3 iot
M 3 iot
 
Simulation and Modelling Reading Notes.pptx
Simulation and Modelling  Reading Notes.pptxSimulation and Modelling  Reading Notes.pptx
Simulation and Modelling Reading Notes.pptx
 
l1_introduction.pdf
l1_introduction.pdfl1_introduction.pdf
l1_introduction.pdf
 
Slides-Introduction-to-System-Dynamics-Modeling-October-20-2021.pdf
Slides-Introduction-to-System-Dynamics-Modeling-October-20-2021.pdfSlides-Introduction-to-System-Dynamics-Modeling-October-20-2021.pdf
Slides-Introduction-to-System-Dynamics-Modeling-October-20-2021.pdf
 
Simulation of complex systems: the case of crowds (Phd course - lesson 1/7)
Simulation of complex systems: the case of crowds (Phd course - lesson 1/7)Simulation of complex systems: the case of crowds (Phd course - lesson 1/7)
Simulation of complex systems: the case of crowds (Phd course - lesson 1/7)
 
Course Learning Outcomes Virtual Systems and Services
Course Learning Outcomes Virtual Systems and ServicesCourse Learning Outcomes Virtual Systems and Services
Course Learning Outcomes Virtual Systems and Services
 
Introduction to simulation and modeling
Introduction to simulation and modelingIntroduction to simulation and modeling
Introduction to simulation and modeling
 
Coursework Assignment Design of a taxi meter .docx
Coursework Assignment   Design of a taxi meter .docxCoursework Assignment   Design of a taxi meter .docx
Coursework Assignment Design of a taxi meter .docx
 
System simulation & modeling notes[sjbit]
System simulation & modeling notes[sjbit]System simulation & modeling notes[sjbit]
System simulation & modeling notes[sjbit]
 
Mit16 30 f10_lec01
Mit16 30 f10_lec01Mit16 30 f10_lec01
Mit16 30 f10_lec01
 
Modeling & simulation in projects
Modeling & simulation in projectsModeling & simulation in projects
Modeling & simulation in projects
 

Recently uploaded

KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlysanyuktamishra911
 
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
Introduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxupamatechverse
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesPrabhanshu Chaturvedi
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 
UNIT-III FMM. DIMENSIONAL ANALYSIS
UNIT-III FMM.        DIMENSIONAL ANALYSISUNIT-III FMM.        DIMENSIONAL ANALYSIS
UNIT-III FMM. DIMENSIONAL ANALYSISrknatarajan
 
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...ranjana rawat
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduitsrknatarajan
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfKamal Acharya
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSSIVASHANKAR N
 
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTINGMANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTINGSIVASHANKAR N
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Call Girls in Nagpur High Profile
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptxBSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptxfenichawla
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...Call Girls in Nagpur High Profile
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...ranjana rawat
 
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...Call Girls in Nagpur High Profile
 

Recently uploaded (20)

KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghly
 
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
Introduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptx
 
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINEDJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and Properties
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
UNIT-III FMM. DIMENSIONAL ANALYSIS
UNIT-III FMM.        DIMENSIONAL ANALYSISUNIT-III FMM.        DIMENSIONAL ANALYSIS
UNIT-III FMM. DIMENSIONAL ANALYSIS
 
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
The Most Attractive Pune Call Girls Budhwar Peth 8250192130 Will You Miss Thi...
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduits
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
 
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
 
Water Industry Process Automation & Control Monthly - April 2024
Water Industry Process Automation & Control Monthly - April 2024Water Industry Process Automation & Control Monthly - April 2024
Water Industry Process Automation & Control Monthly - April 2024
 
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTINGMANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
 
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptxBSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
 
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
 

01.pdf

  • 1. Computer Science, Informatik 4 Communication and Distributed Systems Simulation Modeling and Performance Analysis with Discrete-Event Simulation g y Dr. Mesut Güneş
  • 2. Computer Science, Informatik 4 Communication and Distributed Systems Chapter 1 Introduction to Simulation
  • 3. Computer Science, Informatik 4 Communication and Distributed Systems Introduction to Simulation Introduction to Simulation ƒ Given a system, how do you evaluate its performance? Given a system, how do you evaluate its performance? System System How to evaluate? Experiments Analysis Simulation Develop a mathematical Develop a computer program Use existing instance of the system to perform performance measurements. abstraction of the system and derive formulas which describe the system performance. which implements a model of the system. Perform experiments by running the computer program. Dr. Mesut Güneş Chapter 1. Introduction to Simulation 3
  • 4. Computer Science, Informatik 4 Communication and Distributed Systems Introduction to Simulation Introduction to Simulation ƒ How to study a system? y y • Measurements on an existing system - What to do, if system does not exist in reality? - What to do, if changes are very expensive or time consuming? • Mathematical analysis - Good solutions, but only feasible for simple systems. - Real world systems are too complex, e.g., factory, computer, network etc. Other course from Informatik 4 Modeling and Evaluation of Communication Systems • Simulation B ild th b h i f t ithi - Build the behavior of a system within a program ƒ The content of this course is described in the subtitle • Modeling and Performance Analysis of … by means of Discrete-Event Simulation Dr. Mesut Güneş Chapter 1. Introduction to Simulation 4
  • 5. Computer Science, Informatik 4 Communication and Distributed Systems Introduction to Simulation Introduction to Simulation ƒ There are many open questions There are many open questions • What is a system? • What is a model? • What is performance and how to measure it? • On what does performance depend? Ho to b ild a model? • How to build a model? • How to numerically evaluate it? • How to interpret such results? How to interpret such results? Dr. Mesut Güneş Chapter 1. Introduction to Simulation 5
  • 6. Computer Science, Informatik 4 Communication and Distributed Systems Introduction to Simulation Introduction to Simulation System Experiment with the actual system Experiment with a model of the system Physical Model Mathematical Model Analytical Model Simulation Dr. Mesut Güneş Chapter 1. Introduction to Simulation 6
  • 7. Computer Science, Informatik 4 Communication and Distributed Systems Introduction to Simulation Introduction to Simulation ƒ Simulation is used to imitate the real Wooden mechanical horse simulator during WW1 world • It is not as new as we think ;-) ƒ According to Elmaghraby [1968] • Aid to thought g • Communication • Training/Education • Experimentation A soldier in a heavy-wheeled-vehicle driver simulator • Experimentation • Predicting driver simulator • Entertainment (this is a new application) - Video games Dr. Mesut Güneş Chapter 1. Introduction to Simulation 7
  • 8. Computer Science, Informatik 4 Communication and Distributed Systems Introduction – Example 1 Introduction – Example 1 ƒ A storehouse with n loading berths g ƒ There are several 100 trucks daily to serve ƒ Loading time of a truck is 50 minutes Storehouse ƒ Goal • Cost-effective loading and short waiting time ƒ Usually 2 customer types 1 n Truck Truck Truck Truck ƒ Usually 2 customer types • Type 1: Full load with only one product • Type 2: Load consisting of several products k k k k ƒ Proposals • Fast loading berth for Type 1 customers • Special berth for Type 2 customers Truc Truc Truc Special berth for Type 2 customers ƒ Problem • Cannot experiment, changes are expensive! ck ck ck Dr. Mesut Güneş Chapter 1. Introduction to Simulation 8 Park Slots
  • 9. Computer Science, Informatik 4 Communication and Distributed Systems Introduction – Example 2 Introduction – Example 2 ƒ Experiment p • Sliding of a leader on the wall • A leader is at the wall W d th b tt f th Top • We draw the bottom of the leader and the top of the leader is leant on the wall and slides down slides down. ƒ Question: Which shape draws p the center of the leader? • Concave • Convex • Convex Dr. Mesut Güneş Chapter 1. Introduction to Simulation 9
  • 10. Computer Science, Informatik 4 Communication and Distributed Systems Introduction – Example 2 Introduction – Example 2 ƒ Variant: The leader falls down from the wall Variant: The leader falls down from the wall ƒ The resulting shape is convex. Top Dr. Mesut Güneş Chapter 1. Introduction to Simulation 10 Experiment 1: Leader falls down from the wall
  • 11. Computer Science, Informatik 4 Communication and Distributed Systems Introduction – Example 2 Introduction – Example 2 ƒ One intuitively thinks the driven shape will be concave. One intuitively thinks the driven shape will be concave. ƒ However, the resulting shape is also convex. ƒ Astonished? Top Dr. Mesut Güneş Chapter 1. Introduction to Simulation 11 Experiment 2: Leader slides down on the wall
  • 12. Computer Science, Informatik 4 Communication and Distributed Systems Introduction – Example 3 Introduction – Example 3 ƒ Clients request some service from a server over a network. q • Client = User and web browser • Service = web page S b • Server = web server • Network = local network, Internet, wireless network ƒ Analysis • Performance of the server Client 1 Network (Internet) • Performance of the server • Performance of the network Client k Server ƒ Attention • In this examples the server as well as Dr. Mesut Güneş Chapter 1. Introduction to Simulation 12 server as well as the network is depicted very simple!
  • 13. Computer Science, Informatik 4 Communication and Distributed Systems Introduction – Example 4 Introduction – Example 4 ƒ Mobile multi-hop ad-hoc network p (MANET) • Wireless network consisting of mobile nodes • No infrastructure, i.e. no Access Points or Base Stations • Two nodes can communicate if there are in communication range • Typically, the source and destination nodes of a destination nodes of a connection are several hops away • Thus all nodes have to relay Thus, all nodes have to relay data for others ƒ Mobile node ƒ Communication range ƒ Source node ƒ Relay node ƒ Destination node Dr. Mesut Güneş Chapter 1. Introduction to Simulation 13
  • 14. Computer Science, Informatik 4 Communication and Distributed Systems Introduction – Example 4 Introduction – Example 4 ƒ For the analysis of a MANET a y mobility model is needed ƒ Assumption • Movement area: Rectangle without Movement area: Rectangle without obstacles ƒ Simple model: Random-Waypoint mobility model mobility model • A node selects uniformly a point on the simulation area p=(x, y) • Velocity v ∈[vmin, vmax] Velocity v ∈[vmin, vmax] • Pause time tpause • The node moves to the point p with velocity v with velocity v • Stays for tpause time units on p and restarts movement Dr. Mesut Güneş Chapter 1. Introduction to Simulation 14
  • 15. Computer Science, Informatik 4 Communication and Distributed Systems Introduction – Example 4 Introduction – Example 4 ƒ What's about the probability that a 1000 p y node is on point p = (x,y) on the movement area? • Uniformly distributed? 600 800 y - Since x and y are uniformly selected. • Are some areas preferred? 200 400 ƒ What's about the influence of the parameters? • Velocity 400 800 600 0 200 200 • Velocity • Pause time Altho gh simple to describe 2E-6 ƒ Although simple to describe, mathematically it is hard to get a closed form formulae. 0 200 400 x 600 0 5E-7 1E-6 1,5E-6 Dr. Mesut Güneş Chapter 1. Introduction to Simulation 15 600 0 0 800 200 400 600 800 1000 1000 y
  • 16. Computer Science, Informatik 4 Communication and Distributed Systems Introduction to Simulation Introduction to Simulation ƒ What is a simulation? What is a simulation? • A simulation is the imitation of the operation of a real-world system over time. ƒ What is the method? G t tifi i l hi t f t • Generate an artificial history of a system • Draw inferences from the artificial history concerning the characteristics of the system y ƒ How it is done? • Develop a model • Model consists of entities (objects) Dr. Mesut Güneş Chapter 1. Introduction to Simulation 16
  • 17. Computer Science, Informatik 4 Communication and Distributed Systems When simulation is appropriate When simulation is appropriate ƒ Simulation can be used for the following purposes: g p p • Simulation enables the study of experiments with internal interactions • Informational organizational and environmental changes can be • Informational, organizational, and environmental changes can be simulated to see the model’s behavior • Knowledge from simulations can be used to improve the system Ob i lt f i l ti i i i ht t hi h • Observing results from simulation can give insight to which variables are the most important ones • Simulation can be used as pedagogical device to reinforce the learning material • Simulations can be used to verify analytical results, e.g. queueing systems • Animation of a simulation can show the system in action, so that the plan can be visualized Dr. Mesut Güneş Chapter 1. Introduction to Simulation 17
  • 18. Computer Science, Informatik 4 Communication and Distributed Systems When simulation is not appropriate When simulation is not appropriate ƒ Simulation should not be used, in the case Simulation should not be used, in the case • when problem is solvable by common sense • when the problem can be solved mathematically • when direct experiments are easier • when the simulation costs exceed the savings hen the sim lation req ires time hich is not a ailable • when the simulation requires time, which is not available • when no (input) data is available, but simulations need data • when the simulation cannot be verified or validated when the simulation cannot be verified or validated • when the system behavior is too complex or unknown ƒ Example: human behavior is extremely complex to model Dr. Mesut Güneş Chapter 1. Introduction to Simulation 18
  • 19. Computer Science, Informatik 4 Communication and Distributed Systems Advantages and disadvantages of simulation Advantages and disadvantages of simulation ƒ Advantages of simulation g • Policies, procedures, decision rules, information flows can be explored without disrupting the real system • New hardware designs, physical layouts, transportation systems can tested without committing resources tested without committing resources • Hypotheses about how or why a phenomena occur can be tested for feasibility • Time can be compressed or expanded e ca be co p essed o e pa ded - Slow-down or Speed-up • Insight can be obtained about the interaction of variables • Insight can be obtained about the importance of variables to the f f th t performance of the system • Bottleneck analysis can be performed to detect excessive delays • Simulation can help to understand how the system operates rather than how people think the system operates how people think the system operates • “What if” questions can be answered Dr. Mesut Güneş Chapter 1. Introduction to Simulation 19
  • 20. Computer Science, Informatik 4 Communication and Distributed Systems Advantages and disadvantages of simulation Advantages and disadvantages of simulation ƒ Disadvantages of simulation g • Model building requires training, it is like an art. - Compare model building with programming. • Simulation results can be difficult to interpret • Simulation results can be difficult to interpret - Most outputs are essentially random variables - Thus, not simple to decide whether output is randomness or system behavior behavior • Simulation can be time consuming and expensive - Skimping in time and resources could lead to useless/wrong results ff f ƒ The disadvantages are offset as follows • Simulation packages contain models that only need input data • Simulation packages contain output-analysis capabilities p g p y p • Sophistication in computer technology improves simulation times • For most of the real-world problems there are no closed form solutions Dr. Mesut Güneş Chapter 1. Introduction to Simulation 20
  • 21. Computer Science, Informatik 4 Communication and Distributed Systems Areas of Application Areas of Application ƒ Application areas of simulation pp • Manufacturing applications • Semiconductor manufacturing Constr ction engineering and project management • Construction engineering and project management • Military applications • Logistics, supply chain and distribution applications • Transportation models and traffic • Business process simulation • Health care • Health care • Call-center • Computers and Networks • Games • ... Dr. Mesut Güneş Chapter 1. Introduction to Simulation 21
  • 22. Computer Science, Informatik 4 Communication and Distributed Systems Systems and System Environment ƒ System Systems and System Environment System • A system is a group of objects that are joined together in some regular interaction or interdependence toward the li h t f accomplishment of some purpose. • Example: Automobile factory - Machines, parts, and workers operate jointly to produce a vehicle , p , p j y p • Example: Computer network - User, hosts, routers, lines establish a network ƒ System environment • Everything outside the system, but affects the system ƒ Attention ƒ Attention • It is important to decide on the boundary between the system and the system environment Dr. Mesut Güneş Chapter 1. Introduction to Simulation • This decision depends on the purpose of the study 22
  • 23. Computer Science, Informatik 4 Communication and Distributed Systems Components of a System Components of a System ƒ In order to understand and analyze a system, we need some In order to understand and analyze a system, we need some terms ƒ General Terminology • Entity Object of interest in the system • Attribute Property of an entity A ti it A ti i d f ifi d l th • Activity A time period of specified length • System state Collection of variables required to describe the system at any time y y • Event An instantaneous occurrence that might change the state of the system Endogenous Activities and Events occurring within the • Endogenous Activities and Events occurring within the system • Exogenous Activities and Events in the environment Dr. Mesut Güneş Chapter 1. Introduction to Simulation 23 (outside the system) that affect the system
  • 24. Computer Science, Informatik 4 Communication and Distributed Systems Components of System – Examples Components of System – Examples System Entities Attributes Activities Events State Variables Banking Customers Checking- account balance Making deposits Arrival; departure Number of busy tellers Number of waiting customer customer Rapid rail Riders Source Destination Traveling Arrival at station Arrival at Number of riders at each station Number of rider in destination transit Production Machines Speed Capacity Breakdown rate Welding Stamping Breakdown Status of machines Breakdown rate Communications Messages Length Destination Transmitting Arrival at destination Number of waiting messages to be transmitted Inventory Warehouse Capacity Withdrawing Demand Levels of inventory f Dr. Mesut Güneş Chapter 1. Introduction to Simulation 24 Mobility model Node Position Velocity Travel End of movement Position Velocity
  • 25. Computer Science, Informatik 4 Communication and Distributed Systems Discrete and Continuous Systems Discrete and Continuous Systems ƒ Discrete Systems y • State variables change only at discrete set of points • Example: Bank • Example: Bank C ti S t ƒ Continuous Systems • State variables change continuously over time • Example: Head of water behind a dam Dr. Mesut Güneş Chapter 1. Introduction to Simulation 25
  • 26. Computer Science, Informatik 4 Communication and Distributed Systems Model of a System Model of a System ƒ What is a model? • A model is a representation of a system for the purpose of studying the system. - It is necessary to consider those aspects of the system that affect the problem under investigation Input Output investigation ƒ Avoid too much detail • ”The tendency is nearly always to simulate to much detail rather than too little Thus one should always design the System Input Output little. Thus, one should always design the model around the question to be answered rather than imitate the real system exactly.” [Shannon, 1975] ƒ Physical model ƒ Physical model • Prototype of a system for the purpose of study. ƒ Mathematical model Model O(t) I(t) • A mathematical model uses symbolic notation and mathematical equations to represent a system. Dr. Mesut Güneş Chapter 1. Introduction to Simulation 26
  • 27. Computer Science, Informatik 4 Communication and Distributed Systems Model of a System ƒ Example 1: Movement Model of a System p • Model: • Assumptions: Constant velocity v over the whole time t t v d ⋅ = • Advantage: Simple formulae and intuitive • Disadvantage: Seldom valid for a whole travel (human, car, planes) planes) Dr. Mesut Güneş Chapter 1. Introduction to Simulation 27
  • 28. Computer Science, Informatik 4 Communication and Distributed Systems Model of a System ƒ Example 2: Radio signal propagation Model of a System Example 2: Radio signal propagation • Free-Space-Modell ⎞ ⎛ 2 G G λ • Model: Ass mptions ⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ − = 2 2 2 ) 4 ( log 10 ) ( d G G d PL r t dB π λ d • Assumptions: - Direct line of of sight (LOS) between communication peers -30 -25 measured mean signal strength theoretical signal strength strong signal Measurements in Computer Science Department, Informatik 4 - No obstacles • Advantages: - Simple asymptotic formulae for open -40 -35 al strength [dBm] - Simple asymptotic formulae for open space • Disadvantages: N ll f ll f i d d i -55 -50 -45 received signa Dr. Mesut Güneş Chapter 1. Introduction to Simulation - Not really usefull for indoor and city environments 28 5 10 15 20 25 -60 55 distance from access point [m] weak signal
  • 29. Computer Science, Informatik 4 Communication and Distributed Systems Simulation Models Simulation Models ƒ Simulation Model • A simulation model is a particular type of mathematical model of a system. T f i l ti d l ƒ Types of simulation models • Static: Represent a system at a particular point in time. • Dynamic: Represent a system over a time interval. • Deterministic: Simulation models without random variables. • Stochastic: Simulation models with random variables. • Discrete: System state changes occur only at discrete time points. • Continuous: System state changes occur continuously. We will focus on discrete, dynamic, and stochastic simulation models Dr. Mesut Güneş Chapter 1. Introduction to Simulation 29
  • 30. Computer Science, Informatik 4 Communication and Distributed Systems Simulation Models Simulation Models Models static dynamic deterministic stochastic continuous discrete Dr. Mesut Güneş Chapter 1. Introduction to Simulation 30 continuous discrete
  • 31. Computer Science, Informatik 4 Communication and Distributed Systems Discrete-Event System Simulation Discrete-Event System Simulation ƒ Discrete-event Simulation Discrete event Simulation • System state changes only at discrete set of points in time. • Simulation model is analyzed by numerical methods. • Numerical methods employ computational procedures to “solve” mathematical models. • The model is rather “run” than “solved” • The model is rather run than solved Dr. Mesut Güneş Chapter 1. Introduction to Simulation 31
  • 32. Computer Science, Informatik 4 Communication and Distributed Systems Simulation for static models ƒ Monte Carlo simulation Simulation for static models Monte Carlo simulation ƒ Mainly used for mathematical problems which are not analytically tractable ƒ Example: Approximate π • Area of a circle: C t th b f i t i id d t id it t π π = ⇒ = ⋅ = A r r A 1 if 2 • Count the number of points inside and outside a unit quarter circle. Dr. Mesut Güneş Chapter 1. Introduction to Simulation 32
  • 33. Computer Science, Informatik 4 Communication and Distributed Systems Simulation of dynamic continuous models Simulation of dynamic, continuous models ƒ System described by ƒ Growth rate of the prey y y differential equation ƒ Typically involves numerical solution of these equations p y population without predators • r ⋅ x(t) ƒ Predator change rate q ƒ No real difference to a numerically based mathematical solution g • -s ⋅ y(t) ƒ Interactions dx ƒ Typical example: predator/prey systems • Let x(t) be the size of the ) ( ) ( ) ( ) ( ) ( ) ( t y t x b t y s d dy t y t x a t x r dt dx ⋅ ⋅ + ⋅ − = ⋅ ⋅ − ⋅ = Let x(t) be the size of the prey population • Let y(t) be the size of the predator population ƒ Parameters • x(0), y(0), a, b, r, s ) ( ) ( ) ( y y dt x(0), y(0), a, b, r, s ƒ Metrics • x(t), y(t) ƒ Solve system of differential Dr. Mesut Güneş Chapter 1. Introduction to Simulation ƒ Solve system of differential equations 33
  • 34. Computer Science, Informatik 4 Communication and Distributed Systems Steps in a Simulation Study Steps in a Simulation Study 1. Problem formulation ƒ Clearly understand problem Clearly understand problem ƒ Reformulation of the problem 2. Setting of objectives and overall project plan ƒ Which questions should be answered? ƒ Is simulation appropriate? ƒ Costs? 3. Model conceptualization ƒ No general guide ƒ Modeling tools in research, e.g. UML 4. Data collection ƒ How to get data? Are random distributions appropriate? ƒ Are random distributions appropriate? 5. Model translation ƒ Program 6. Verified? ƒ Does the program that, what the model describes? 7 Validated? 7. Validated? ƒ Do the results match the reality? ƒ In cases with no real-world system, hard to validate 8. Experimental design ƒ Which alternatives should be run? ƒ Which paramters should be varied? p 9. Production runs and analysis 10. More runs? 11. Documentation and reporting ƒ Program documentation – how does the program work ƒ Progress documentation – chronology of the work Dr. Mesut Güneş Chapter 1. Introduction to Simulation 34 g gy 12. Implementation
  • 35. Computer Science, Informatik 4 Communication and Distributed Systems Steps in a Simulation Study Steps in a Simulation Study Phase 1: Discovery and sco e y a d Orientation Phase 2: Phase 2: Model building and data collection Most crucial step is collection Most crucial step is validation. If model is invalid results can lead to Phase 3: Run the model dangerous and expensive decisions! Phase 4: Dr. Mesut Güneş Chapter 1. Introduction to Simulation 35 Implementation
  • 36. Computer Science, Informatik 4 Communication and Distributed Systems Summary Summary ƒ Motivated the course by examples Motivated the course by examples ƒ Introduced simulation as a notion ƒ Discussed for what purposes simulation is useful p p ƒ Introduction of a general terminology ƒ Introduction of discrete-event simulation ƒ Discussed the steps of a simulation study Dr. Mesut Güneş Chapter 1. Introduction to Simulation 36