chapter 1 introduction to simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf ·...

18
1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event System Simulation 2 Learning Outcomes After completing this chapter You should be able to: Define key terms When to use/apply simulation? Discuss advantages and disadvantages of simulation Speak about fields and areas for the simulation application Compare between discrete and continuous systems Distinguish between the different types of models Compare between static simulation vs. dynamic simulation Distinguish between stochastic vs. deterministic Define the key terms models of verification and validation

Upload: others

Post on 20-Mar-2020

42 views

Category:

Documents


6 download

TRANSCRIPT

Page 1: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

1

Chapter 1

Introduction to Simulation

Banks, Carson, Nelson & Nicol

Discrete-Event System Simulation

2

Learning Outcomes

After completing this chapter You should be able to:

Define key terms

When to use/apply simulation?

Discuss advantages and disadvantages of simulation

Speak about fields and areas for the simulation application

Compare between discrete and continuous systems

Distinguish between the different types of models

Compare between static simulation vs. dynamic simulation

Distinguish between stochastic vs. deterministic

Define the key terms models of verification and validation

Page 2: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

2

3

What is a Simulation?

A simulation: imitation of the operation of a real-world process or system over time: Involves generation of an artificial history of a system.

Observes that history and draws inferences about system characteristics.

Can be used as: Analysis tool for predicting the effect of changes to existing

systems.

Design tool to predict performance of new systems.

Many real-world systems are very complex that cannot be solved mathematically. Hence, numerical, computer-based simulation can be used to

imitate the system behavior.

4

When to use Simulation?

Simulation can be used for the purposes of:

Study and experiment with internal interactions of a complex

system.

Observe the effect of system alterations on model behavior.

Gain knowledge about the system through design of simulation

model.

Use as a pedagogical device to reinforce analytic solution

methodologies, also to verify analytic solutions.

Experiment with new designs or policies before implementation.

Determine machine requirements through simulating different

capabilities.

For training and learning.

Show animation.

Model complex system.

Page 3: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

3

5

When Not to Use Simulation?

Simulation should not be used when:

Problem can be solved by common sense.

Problem can be solved analytically.

If it is easier to perform direct experiments.

If the costs exceed the savings.

If the resources or time to perform simulation studies are not

available.

If no data, not even estimates, is available.

If there is not enough time or personnel to verify/validate the

model.

If managers have unreasonable expectations: overestimate the

power of simulation.

If system behavior is too complex or cannot be defined.

6

Advantages and Disadvantages of Simulation

Simulation is frequently used in problem solving.

It mimics what happens in a real system.

It is possible to develop a simulation model of a system without dubious assumptions of mathematically solvable models.

In contrast to optimization models, simulation models are “run” rather than solved.

Advantages:

Explore new policies or procedures without disrupting ongoing operations of the real system.

Test new hardware or physical systems without committing to acquisition.

Test hypotheses about how or why certain phenomena occur.

Study speed-up or slow-down of the phenomena under investigation.

Page 4: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

4

7

Advantages and Disadvantages of Simulation

Advantages (cont.):

Study interactions of variables, and their importance to system

performance.

Perform bottleneck analysis.

Understand how the system operates.

Test “what if” questions.

Disadvantages:

Model building requires special training.

Simulation results can be difficult to interpret.

Simulation modeling and analysis can be time consuming and

expensive.

Simulation is used in some cases when an analytical solution is

possible (or even preferable).

8

Areas of Application

The applications of simulation are vast.

The Winter Simulation Conference: an excellent way to learn more about the latest in simulation applications and theory.

Some areas of applications: Manufacturing

Construction engineering and project management.

Military.

Logistics, supply chain, and distribution.

Transportation modes and traffic.

Business process simulation.

Healthcare.

Computer and communication systems.

Page 5: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

5

9

Systems and System Environment

A system is a group of objects (entities) (people, parts,

messages, machines, servers, …) joined together in

some regular interaction or interdependence to

accomplish some purpose.

e.g., a production system: machines, component parts & workers

operate jointly along an assembly line to produce vehicle.

Affected by changes occurring outside the system.

System environment: “outside the system”, defining the

boundary between system and it environment is

important.

e.g., for a factory, the environment affects the arrival of

raw materials.

e.g., for a bank, the environment affects the interest rate

that can be paid.

10

Components of a System

An entity: an object of interest in the system, e.g., computing

jobs in queue. E.g., customers at a bank

An attribute: a property of an entity, e.g., priority class, or

vector of resource requirements. E.g., checking account balance. For server busy or idle,…

An activity: represents a time period of a specified length, e.g.

job receiving service. E.g., making bank deposits

The state of a system: collection of variables necessary to describe the system at any time, relative to the objectives of the study, e.g. the number of busy servers, the number of jobs in queue.

An event: an instantaneous occurrence that may change the system state, can be endogenous or exogenous, e.g. a new job arrival, or service time completion

Page 6: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

6

Examples of systems and components

11

12

Examples of systems and components

Ex. Elevator systems

Entities

Elevators, people

Sets

People waiting at each floor

Attributes

Elevators – capacity, speed, destination, current

location of each elevator

People – inter-arrival time at each floor,

destination of each people

Page 7: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

7

13

Examples of systems and components

Ex. Elevator systems

State of system:

# of people on each elevator

# of people in each floor

Activities

Load/Unloading passenger

Travel to next floor (speed and distance)

Persons travel to elevator

14

Delays:

Persons waiting for elevator

Events:

Elevator arrival

End unloading

End Loading

Person Arrival

Examples of systems and components

Ex. Elevator systems

Page 8: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

8

15

Discrete and Continuous Systems

Discrete system: in which state variable(s) change only at a

discrete set of points in time.

e.g., the number of jobs in queue changes when a new job arrives

or when service is completed for another

Continuous system: in which state variable(s) change

continuously over time.

e.g., the head of water behind a dam.

Discrete System Continuous System

16

Model of a System

Studies of systems are often accomplished with a model

of a system.

A model: a representation of a system for the purpose of

studying the system.

A simplification of the system.

Should be sufficiently detailed to permit valid conclusions to be

drawn about the real system.

Should contain only the components that are relevant to the

study.

Page 9: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

9

17

Types of Models

Two types of models:

mathematical or physical.

Mathematical model: uses

symbolic notation and

mathematical equations to

represent a system.

Simulation is a type of mathematical

model.

Simulation models:

Static or dynamic.

Deterministic or stochastic.

Discrete or continuous.

Our focus: discrete, dynamic, and

stochastic models.

Simulation vs. analytic modeling

Advantage:

various performance measures

greater realism

easier to understand

model the steady-state as well as the transit

behavior.

Can work good for too large sized models.

Disadvantage:

May not provide you with the optimal solution

time to construct model will be longer.

Page 10: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

10

Simulation vs. Physical

Advantage:

High Speed

Not disruptive

Replication easy

Control variations

Generally less costly

Disadvantage:

Realism

Validity

Static Simulation vs. Dynamic Simulation

There are two types of simulation models,

static and dynamic.

Definition: A static simulation model is a

representation of a system at a particular

point in time. (i.e., time plays no role)

We usually refer to a static simulation as a

Monte Carlo simulation. Examples

Determine the probability of a winning solitaire hand

Page 11: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

11

Static Simulation vs. Dynamic Simulation

Definition: A dynamic simulation is a representation of a system as it evolves over time. Main focus of this course

Within these two classifications, a simulation may be deterministic or stochastic.

A deterministic simulation model is one that contains no random variables; a stochastic simulation model contains one or more random variables.

Stochastic vs. Deterministic

Stochastic simulation: a simulation that contains random (probabilistic) elements, e.g., Examples

Inter-arrival time or service time of customers at a restaurant or store

Amount of time required to service a customer

Output is a random quantity (multiple runs required analyze output)

Deterministic simulation: a simulation containing no random elements Examples

Simulation of a digital circuit

The arrivals at a dentist’s office if it is at the scheduled appointment.

Output is deterministic for a given set of inputs

Page 12: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

12

Discrete Event vs. Continuous Event

Simulation

Discrete event:

state of system changes only at discrete points in

time(events)

ex. Machine repair problem

banks

Programming

Look at system only when events occur; time is

advanced from event to event.

Discrete Event vs. Continuous Event

Simulation

Continuous event:

state of system changes continuously over time

Ex. Level of fluid in tank

Programming:

Advances time in small intervals. Use differential

equations to represent flows.

Page 13: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

13

25

Discrete Event System Simulation

This book is about discrete-event system simulation.

Simulation models are analyzed by numerical methods

rather than by analytical methods.

Analytical methods: deductive reasoning of mathematics to

“solve” the model.

Numerical methods: computational procedures to “solve”

mathematical models.

26

Steps in a Simulation Study

Page 14: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

14

Problem Formulation and Setting objectives

(1&2)

State the objective of the study. (the questions to

be answered by the simulation)

Identify the Problem. Determine any underlying

causes if possible.

Is simulation is a appropriate methodology.

The stated simulation project plan should include:

• Evaluation of alternative methodologies

• Number of people involved, cost of study, number

of days required.

• The results expected at the end of the study.

Model Conceptualization

Determine the input variables.

Controllable Variables.

Uncontrollable Variables.

Make assumptions / boundaries that were used

to simplify the model.

Determine Performance measures used to

measure the objective. (Output)

It is advisable to involve the model users in

model conceptualization to enhance quality and

increase confidence of the model user in the

application of it.28

Page 15: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

15

Data collection/acquisition

Determine the Data Collection System or Estimates to be used. Observe the system

Historical or Similar Systems

Theoretical Estimates

Engineering Estimates

Operator Estimates

Identify the data collected.

How it was collected.

How it was represented in the model.

Model Construction or Development

Identify The Real System

Determine Conceptual Model -Activities and

Events

Develop the Logical Model.

Identify the Programming Language used.

Computer Implementation (Promodel, Arena,

Slam Systems).

Page 16: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

16

Model Construction or Development

Modeling Tips

Art vs. Science

Over Simplification vs. Unnecessary Detail

Start Simple

Add stronger assumptions

Model Verification and Validation

Verification: Determining whether

simulation model works as intended.

(pertains to computer model)

Did I build the model right?

Verifying the Model.

Structure: Walk Through of the Model

Debugger.

Trace = print or writing in process calculations.

Animation.

Model testing

Analytical Model.

Page 17: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

17

Model Verification and Validation

Validation: Determine whether Simulation of

The Model is a credible representation of a

Real System. Did I build the right model?

Compare the model with the actual systems

by performing statistical tests. T-Test & C.I.

Conceptual Model.

Does the model contain all relevant elements, events

and relationships?

Will the model answer the questions of concern?

Model Verification and Validation

Logical Model. Does the model contain all events included in the

conceptual model?

Does the model contain all the relationships of the conceptual model?

Computer Model/Simulation Model. Is the computer model a valid representation of the real

system?

Can the computer model duplicate the performance of the real system?

Does the computer model output have credibility with system experts and decision makers?

Page 18: Chapter 1 Introduction to Simulationsite.iugaza.edu.ps/aschokry/files/2019/09/chapetr1-done.pdf · 1 Chapter 1 Introduction to Simulation Banks, Carson, Nelson & Nicol Discrete-Event

18

Experimentation and Analysis of

Results

Experimentation – The execution of the

simulation model to obtain output values

Analysis of Results – The process of analyzing

the simulation outputs to draw inferences and

make recommendations for problem resolution

Implementation and Documentation

The process of implementing decisions resulting

from the simulation and documenting the model

and its use.