You are on page 1of 15

A variety of Modeling Approaches

Chapter 2

contents
General considerations Time handling: Time slicing approach and next event technique Deterministic and Stochastic Systems

General considerations
Model building is the first and most important step in simulation modeling First step in model building is problem analysis and information collection and then data collection follows
Identification of input parameters Identification of Performance measure of interest Identifying relationship among parameters and variables Systematic representation

Model construction, verification and validation


Estimate model input parameters and outputs, determine type of random variables to be used Verify model if it is correctly constructed w.r.t. spec Validate the model by comparing output of the model with experimental or data collected from physical system

Model Taxonomy

Parts of a simple simulation model


Entity Something that changes the state of the system Example: in a client server system, request from a client Batch size, inter arrival times and entity attributes Queue Is a buffer where entities wait for service Once an entity enter the queue, it has to wait until it gets service Length of a queue is dependent on system If queue is full, an entity will be rejected or ignored Resources Resources can be servers, ATM machines, etc A resource can be either idle or busy In more complex systems, they can be either in failed state or temporarily in active

Time handling: Time slicing approach and next event technique


One basic advantage of simulation
Experimentation in compressed time Simulation which takes months or years can be experimented in minutes The two most important techniques Time slicing Next event approach Simulation worldview(paradigm or philosophy) Developer worldview designers of simulation software User worldview users of simulation software Discrete event simulation
Simulation system has a state at any instant of time Events trigger jump or change of state Time is sliced at the point of occurrence of events The main concept in the simulation is to track next event

Example single machine or single server


Jobs arrive randomly and are processed. If machine is busy wait in the FIFO buffer

Inputs are inter arrival times and processing times System state s(t)= number of jobs in system=number of jobs in queue +1=n System entities are job arrival and job departure Output/ performance measure average waiting time Time taken by a job=waiting time +processing time

Simulation event list


Is a means of keeping track of different things that occur during a simulation run
An event is anything which occurs during a simulation run and can affect the state of the system Example: Arrival to the queue, start of service, end of service

It is controlled by advances in simulation clock Infinite combinations of arrival, queue and service start and finish will occur and have to be tracked for computation of performance measures

Performance measures
There are four types of performance measures used usually
System time Queue time Time average number in queue utilization

System time
Total amount of time that the entity spends in the system

Ti is the system time of an individual entity n is the total number of entities

Queue time
Time that an entity spends in queue

Where Di is the queue time for an individual

Time average number in queue


Average number of entities expected in the queue at any time t

Where

Q is number in queue for a given length of time dt is the length of time that Q is observed T is total length of time for the simulation

Utilization At any time a resource may be idle(utilization level of zero) or busy(utilization level of 1)

B is utilization level which is zero or 1 dt is the length of time that B is observed T the total length of the simulation

Example : A single server single queue system has the following inter arrival times and service times
Inter arrival time Service time 1 3 2 4 1 4 4 2 3 5 2 4 4 1

Calculate summary statistics for the average number in queue, average system time, average utilization based on 20min
Solution: We have to form simulation event list. Let us use table
Arrival number 1 2 3 4 Arrival time 1 5 3 7 4 8 Begin sv. time 1 5 4 10 8 12 End service time 3 4 10 8 14 12 14 System time Waiting time 2 3 5 7 8 6 0 0 1 3 4 4

5 6
7

11 13
17

14 19
23

19 23
24

8 10
6

3 6
5

Performance measures Average system time for 20min simulation time, only 5 customers have left the server
358 6 8 AST 6 5 Time average number in queue- for this calculation, it is better to form a graph of number in queue verses time
Numb er in queue 5
4 3 2 1 1 3 4 8 11 12 13 14 17 19 time

Time average in queue then is

1* 8 2 *1 1*1 2 *1 1* 3 2 * 2 1*1 TAQ 1.05 20


Resource utilization

20 RU 1 20

Simulation modeling is not free of cost Modeling cost A good model should have only necessary detail(right amount of detail only) Should have good validation result Coding cost Simulation runs Simulation modeling uses extensive statistics Adequate number of experiments have to be performed for statistical reliability Model should have optimum resource requirements Output analysis

Deterministic and Stochastic Systems


Mathematical models of systems can be deterministic or stochastic
Deterministic input and output variables are fixed Inputs occur in the same sequence and fixed order System responds in same manner every time Simulation study may not be necessary Stochastic at least one of the input/output variables is probabilistic Model random phenomenon that occur in time Arrival streams, service times, routing decisions etc Simulation runs typically generate extensive realizations of multiple interacting stochastic process

You might also like