Modeling and Simulation
Modeling and Simulation
What Is A Model ?
A Representation of an object, a
system, or an idea in some form
other than that of the entity itself.
(Shannon)
2
Types of Models:
Physical
(Scale models, prototype plants,…)
Mathematical
(Analytical queueing models, linear
programs, simulation)
3
WHAT IS SIMULATION?
• The imitation of the operation of a real-world process or
system over time…
– Most widely used tool (along LP) for decision making
– Usually on a computer with appropriate software
– An analysis (descriptive) tool – can answer what if questions
– A synthesis (prescriptive) tool – if complemented by other tools
• Applied to complex systems that are impossible to solve
mathematically
APPLICATIONS
Systems – facility or process, actual or planned
Examples
Manufacturing facility
Bank operation
Airport operations (passengers, security, planes, crews, baggage)
Transportation/logistics/distribution operation
Hospital facilities (emergency room, operating room, admissions)
Computer network
Power system
Communication Systems
Business process (insurance office)
Criminal justice system
Chemical plant
Fast-food restaurant
Supermarket
Theme park
Emergency-response system
SYSTEM
• A set of interacting components or entities
operating together to achieve a common goal or
objective.
• Examples:
– A manufacturing system with its machine centers,
inventories, conveyor belts, production schedule, items
produced.
– A telecommunication system with its messages,
communication network servers.
– Power Generation/Transmission/Distribution Systems
Mathematical
Simulation
Analysis
MATHEMATICAL MODEL
• An abstract and simplified representation of a system
• Specifies
– Important components
– Assumptions/approximations about how the system works
• Not an exact re-creation of the original system!
• If model is simple enough, study it with Queueing Theory,
Linear Programming, Differential Equations...
• If model is complex, Simulation is the only way!!!
GETTING ANSWERS FROM MODELS
ACTUAL SYSTEM
Operating Policies
• Single queue, parallel servers
• FIFO Output Parameters
(X) (Y)
Input Parameters • Waiting Times
• No of servers MODEL • System Size
• Inter-arrival Time Distribution • Utilizations
• Service Time Distributions
Y = f (X)
STOCHASTIC MODELS
• Randomness or uncertainty is inherent
• Example: Bank with customers and tellers
m
l
m
Represents the system at a particular point Represents the system behaviour over time
in time
Continuous Simulation:
IID observations
• (Stochastic) Differential Equations
• Queueing Systems
• Inventory Systems
HOW TO SIMULATE
• By hand
– Buffon Needle and Cross Experiments (see Kelton et al.)
• Spreadsheets
• Programming in General Purpose Languages
– MATLAB
• Simulation Languages
– SIMAN, MATLAB
• Simulation Packages
– Arena
Issue: Modeling Flexibility vs. Ease of Use
ADVANTAGES OF SIMULATION
• When mathematical analysis methods are not
available, simulation may be the only investigation tool
• When mathematical analysis methods are available,
but are so complex that simulation may provide a
simpler solution
• Allows comparisons of alternative designs or
alternative operating policies
• Allows time compression or expansion
DISADVANTAGES OF SIMULATION
• For a stochastic model, simulation estimates the
output while an analytical solution, if available,
produces the exact output
• Often expensive and time consuming to develop
• An invalid model may result with confidence in
wrong results.
STEPS IN A SIMULATION STUDY
Model
No
conceptualization Experimental
Design
Setting of Yes
Problem objectives Model Yes
Verified? Validated? Production runs
formulation and overall translation
project plan and analysis
No
Yes Yes
Data No More runs?
collection
No
Documentation
Implementation and reporting
PROBLEM FORMULATION
Setting of Yes
Problem objectives Model Yes
Verified? Validated? Production runs
formulation and overall translation
project plan and analysis
No
Yes Yes
Data No More runs?
collection
No
Documentation
Implementation and reporting
MODEL CONCEPTUALIZATION
Real World System
Assumed system
Conceptual model
Logical model
CONCEPTUAL MODEL
• Abstract essential features
– Events, activities, entities, attributes, resources,
variables, and their relationships
– Performance measures
– Data requirements
• Select correct level of details (assumptions)
LEVELS OF DETAIL
• Low levels of detail may result in lost of
information and goals cannot be
accomplished
• High levels of detail require:
– more time and effort
– longer simulation runs
– more likely to contain errors
COMPONENTS OF A SYSTEM
Entity: is an object of interest in the system
– Dynamic objects — get created, move around, change status,
affect and are affected by other entities, leave (maybe)
– Usually have multiple realizations floating around
– Can have different types of entities concurrently
Patients
Visitors
COMPONENTS OF A SYSTEM
Attribute: is a characteristic of all entities, but
with a specific value “local” to the entity that can
differ from one entity to another.
Example: Patient
Type of illness,
Age,
Sex,
Temperature,
Blood Pressure
COMPONENTS OF A SYSTEM
Resources: what entities compete for
– Entity seizes a resource, uses it, releases it
– Think of a resource being assigned to an entity, rather than an
entity “belonging to” a resource
– “A” resource can have several units of capacity which can be
changed during the simulation
Doctors, Nurses
X-Ray Equipment
COMPONENTS OF A SYSTEM
Variable: A piece of information that reflects some
characteristic of the whole system, not of specific
entities
– Entities can access, change some variables
Surgery,
Checking temperature,
X-Ray.
STEPS IN A SIMULATION STUDY
Model
No
conceptualization Experimental
Design
Setting of Yes
Problem objectives Model Yes
Verified? Validated? Production runs
formulation and overall translation
project plan and analysis
No
Yes Yes
Data No More runs?
collection
No
Documentation
Implementation and reporting
DATA COLLECTION & ANALYSIS
Setting of Yes
Problem objectives Model Yes
Verified? Validated? Production runs
formulation and overall translation
project plan and analysis
No
Yes Yes
Data No More runs?
collection
No
Documentation
Implementation and reporting
MODEL TRANSLATION
Coding
Setting of Yes
Problem objectives Model Yes
Verified? Validated? Production runs
formulation and overall translation
project plan and analysis
No
Yes Yes
Data No More runs?
collection
No
Documentation
Implementation and reporting
VERIFICATION AND VALIDATION
Logical model
VERIFICATION
Simulation model
STEPS IN A SIMULATION STUDY
Model
No
conceptualization Experimental
Design
Setting of Yes
Problem objectives Model Yes
Verified? Validated? Production runs
formulation and overall translation
project plan and analysis
No
Yes Yes
Data No More runs?
collection
No
Documentation
Implementation and reporting
EXPERIMENTAL DESIGN
Setting of Yes
Problem objectives Model Yes
Verified? Validated? Production runs
formulation and overall translation
project plan and analysis
No
Yes Yes
Data No More runs?
collection
No
Documentation
Implementation and reporting
DOCUMENTATION & REPORTING
• Program Documentation
– Allows future modifications
– Creates confidence
• Progress Reports
– Frequent reports (e.g. monthly) are suggested
– Alternative scenarios
– Performance measures or criteria used
– Results of experiments
– Recommendations
IMPLEMENTATION