Top Banner
IE 324 SIMULATION INTRODUCTION TO SIMULATION
52

IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

Dec 19, 2015

Download

Documents

Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

IE 324 SIMULATION

INTRODUCTION TO SIMULATION

Page 2: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

WHAT IS SIMULATION?

• To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

• The imitation of the operation of a real-world process or system over time. [Banks et al. (2005)]

• The process of designing a logical or mathematical model of a real system and then conducting computer based experiments with the model to describe, explain, and predict the behaviour of the real system. [Taylor (1984)]

Page 3: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

WAYS TO STUDY A SYSTEM

System

Experimentwith the

actual system

Experimentwith a modelof the system

Physical Model

Abstract Model

AnalyticalModel

Simulation

Page 4: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

INPUT/OUTPUT PROCESS

SIMULATION MODEL

REAL-LIFE SYSTEM

• Decision variables

• Parameters System response

(X) (Y)

Y=f(X)

Page 5: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

SIMULATION MODEL OF HEALTH CENTRE

• Number of Doctors

• Capacity of equipment

• Arrival rate

• Time in the system

• Utilization of doctors

• Waiting time

EXAMPLE: HEALTH CENTER

Page 6: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

EXAMPLE:SERIAL PRODUCTION LINE

SIMULATION MODEL OF PRODUCTION LINE

• Length of the line

• Size of buffers

• Processing times

• Throughput

• Interdeparture time variability

• Utilizations

1 2 3 N…….

Page 7: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

ORIGIN OF SIMULATION• Lie in statistical sampling theory, e.g., random

numbers, random sampling (Before the 2nd world war)

• Monte Carlo simulation (During the 2nd world war)

• Modern Applications (After the 2nd world war)

Page 8: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

POPULARITY OF SIMULATION

• Consistently ranked as the most useful, popular tool in the broader area of operations research / management science

Page 9: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

SYSTEMA system is a group of objects (or elements) that are joined together in some regular interactions towards the accomplishment of some stated objective or purpose

Page 10: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

COMPONENTS OF A SYSTEM

Entity: is an object of interest in the system (which requires an explicit representation in the system model)

Example: Health Center

Patients,

Doctors & Nurses,

Rooms & beds

Lab equipment, X-Ray machine, etc.

Page 11: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

COMPONENTS OF A SYSTEM

Attribute: is a characteristic of an entity

Example: Patient

Type of illness,

Age,

Sex, etc.

Page 12: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

SYSTEM STATE

• A collection of variables that contains all the information necessary to describe the system at any time

Example: Health Center

Number of patients in the system,

Status of doctors (busy or idles),

Number of idle doctors,

Status of Lab equipment, etc

Page 13: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

EVENT

• An instantaneous occurrence that may change the state of the system

Example: Health Centre

Arrival of a new patient,

Completion of a service (i.e., examination)

Failure of medical equipment, etc.

Page 14: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

VARIABLES

Relevant variables Irrelevant variables

affect the system performance ………..Don’t affect ……...

Endogenous variables Exogenous variables

Page 15: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

EXOGENOUS VARIABLES

• Input variables

• External to the model (i.e., exist independently of the

model) Exogenous variables

Controllable variables(Decision Variables)

Uncontrollable variables (Parameters)

That can be manipulated to an extent by the DM

Cannot be manipulated

Page 16: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

ENDOGENOUS VARIABLES

• Output variables• Internal to the model and are functions of the

exogenous variables and the model dynamics

Examples:

• Performance measures

• State variables

Page 17: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

BE CAREFUL !!!

• Classification of relevant vs. irrelevant variables depends on:

• Classification of controllable vs. uncontrollable variables depends on:

• Purpose of the study

• Scope (Level of Detail)

• Purpose of the study (existing vs. new)

• Resources that are under control of the DM

Page 18: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

MODEL

• Why do we need a model?

• Why do we study a system?

• To design new systems

• To improve system performance

• To solve problems affecting the system performance

• The system does not exist (i.e., conceptual stage)

• Impractical or too costly to experiment with the actual system

Page 19: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

MODEL

A representation of a system for the purpose of studying the system ….by Banks et al. (2005).

Page 20: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

CLASSIFICATION OF MODELS

Models

Physical Models Abstract Models

Use symbolic notation & mathematical equations to represent a systems

Resemble the real system physically (a small scale representation

BEGIN;

EI=BI+PROD-DEMAND

.

END;

Page 21: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

ABSTRACT MODELS

Prescriptive (Normative Models)

Descriptive Models

Used to formulate & solve a problem Used to describe the system behaviour

Examples: Examples:

• Linear Programming

• Dynamic Programming

• Simulation

• Queuing Models

Page 22: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

ABSTRACT MODELS

Analytical Numerical

Employ the deductive reasoning of mathematics to solve the model

Employ computational procedures to solve the mathematical models

Examples: Examples:

• Queuing models

• Differential calculus

• Simulation

• Linear programming

Page 23: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

ABSTRACT MODELS

Stochastic Deterministic

Contains one or more random variables Does not contain a random variable

Examples: Examples:

• Simulation

• Stochastic programming

• LP, MIP and DP

• Simulation

Page 24: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

ABSTRACT MODELS

Static Dynamic

Represents the system at a particular point in time

Represents the system as it changes over time

Examples: Examples:

• Many optimization models covered in our curriculum

• Monte Carlo simulation

• Simulation

•Dynamic Programming

•Control Models

•Queueing Models

Page 25: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

ABSTRACT MODELS

Discrete Continuous

May only take a limited or specified values May take on the value of any real number

Examples: Examples:

• Integer Programming

• Simulation

• Simulation

•Queueing Models

Page 26: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

CHARACTERISTICS OF SIMULATION

• Abstract

• Numerical

• Descriptive

• Deterministic/Stochastic

• Static/Dynamic

• Discrete/Continuous

Page 27: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

ANALYTICAL VS SIMULATION

• Use analytical model whenever possible

• Use simulation when

1) Complete mathematical formulation does not exist or an analytical solution cannot be developed

2) Analytical methods are available, but the mathematical procedures are so complex that simulation provides a simpler solution

3) It is desired to observe a simulated history of the process over a period of time in addition to estimating certain system performances

Page 28: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

CAPABILITIES OF SIMULATION

•Time compression and expansion

• Explains “why?”

• Allows to explore possibilities (What if?”)

• Helps diagnosing problems & identify constraints

• Requires fewer assumptions

• Handles randomness and uncertainty

• Handles dynamic behaviour

• Flexible and easy to change

• Credible and results are easier to explain

Page 29: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

LIMITATIONS OF SIMULATION• “Run” rather than “solve”

• Random output obtained from stochastic simulations (Statistical analysis of output is required)

• Cannot generate optimal solution on its own

• Requires specialized training (probability, statistics, computer programming, modelling, system analysis, simulation methodology)

• Costly (software and hardware)

Page 30: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

SIMULATION APPLICATIONS

Page 31: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

STEPS IN A SIMULATION STUDY

Problemformulation

Setting ofobjectivesand overallproject plan

Modelconceptualization

Datacollection

Modeltranslation

Verified?

No

Validated?

No

No ExperimentalDesign

Production runsand analysis

More runs?

Documentationand reporting

No

Implementation

Yes

YesYes

Yes

Page 32: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

PROBLEM FORMULATION

• A statement of the problem– the problem is clearly understood by the simulation

analyst– the formulation is clearly understood by the client

• Problem, but not symptoms• Criteria for selecting a problem:

– Technical, economic and political feasibility– Perceived urgency for a solution

Page 33: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

SETTING OBJECTIVES & PROJECT PLAN (PROJECT PROPOSAL)

• Determine the questions that are to be answered• Identify scenarios to be investigated• Scope (Level of detail) • Determine the end-user• Determine data requirements• Determine hardware, software, & personnel

requirements • Prepare a time plan

• Cost plan and billing procedure

Page 34: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

MODEL DEVELOPMENT

Conceptual model

Logical model

Simulation model

Real World System

Page 35: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

CONCEPTUAL MODEL

Subsystem of interest

Conceptual model

Real World System

Page 36: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

CONCEPTUAL MODEL

• Questions to be answered

• Scope (Level of detail)

• Performance measures

• Events, entities, attribute, exogenous variables, endogenous variables, & their relationships

• Data requirements

Page 37: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

SCOPE

• More detailed the model is, more representative it is of the actual system (if the modeling is done correctly)

• A more detailed model requires:– more time and effort– longer simulation runs– more likely to contain errors

Page 38: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

Accuracy of the model

Scope & level of detail

Scope & level of detail

Cost of model

Page 39: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

SCOPE

Modeller

Novice Modeller Experienced Modeller

Tends toward too much detail Tends toward greater detail

Page 40: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

LEVELS OF DETAIL• Evaluate if the candidate systems

work

• Compare two or more systems to determine better ones

• Accurately predict the performance of selected system

Scope

Page 41: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

LOGICAL (FLOWCHART) MODEL

• Shows the logical relationships among the elements of the model

start

Read data

checkGenerate data

Set new event

CalculateStats

Print checkStop

Page 42: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

SIMULATION (OPERATIONAL) MODEL

• The model that executes the logic contained in the flow-chart model

Coding

General Purpose Languages Special Purpose Languages & Environments

FORTRAN, C, PASCAL

Examples:

SIMAN, ARENA. AUTOSIM

Examples:

Page 43: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

SIMAN MODEL

--- MODEL FILE ---BEGIN;CREATE,1:,EXPO(40):EX(40):MARK(1);QUEUE,1;SEIZE:DOCTOR;DELAY:EXPO(30);TALLY:1,INT(1);RELEASE:DOCTOR;COUNT:1:DISPOSE;END: ----EXPERIMENTAL FILE -----

BEGIN;PROJECT,HEALTH_CENTRE, IHSA SABUNCUOGLU,24/1/2000;DISCRETE,100,1,1;RESOURCES:1,DOCTORS;DSTATS:1,NQ(!),NUMBER_IN_QUEUE: 2,NR(1),DOCTOR UTILIZATION;TALLIES:1, TIME IN HEALTH_CENTRE;COUNTERS:1,No. OF PATIENTS SERVED;END:

Page 44: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

ARENA MODEL

Page 45: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

Java Model

// Loop until first "TotalCustomers" have departed while(NumberOfDepartures < TotalCustomers ) { Event evt = (Event)FutureEventList.getMin(); // get imminent event FutureEventList.dequeue(); // be rid of it Clock = evt.get_time(); // advance simulation time if( evt.get_type() == arrival ) ProcessArrival(evt); else ProcessDeparture(evt); } ReportGeneration(); }

Page 46: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

DATA COLLECTION & ANALYSIS

• The client often collects the data & submit it in electronic format

• Simulation Analyst:– Determines the random variables

– Determines the data requirements

– Analyses the data

– Fits distribution functions

Page 47: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

VERIFICATION AND VALIDATION

• Verification: the process of determining if the operational logic of the model is correct.

• Validation:the process of determining if the model accurate representation of the system.

Page 48: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

VERIFICATION AND VALIDATION

Conceptual model

Logical model

Simulation model

Real World System

VERIFICATION

VALIDATION

Page 49: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

EXPERIMENTAL DESIGN

• Alternative scenarios to be simulated

• Type of output data analysis (steady state vs. transient state analysis)

• Number of simulation runs

• Length of each run

• Initialization

• Variance reduction

Page 50: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

ANALYSIS OF RESULTS

• Determine the simulation runs necessary to estimate the performance measures

• Statistical tests for significance and ranking

• Interpretation of results

Page 51: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

DOCUMENTATION

• General model logic

• Key elements of the model

• Data structures

• Alternative scenarios

• Performance measures or criteria used

• Results of experiments

• Recommendations

Page 52: IE 324 SIMULATION INTRODUCTION TO SIMULATION. WHAT IS SIMULATION? To feign, to obtain the essence of, without reality. [Webster’s Collegiate Dictionary]

IMPLEMENTATION