Presentation is loading. Please wait.

Presentation is loading. Please wait.

Lecture 3 Concepts of Discrete-Event Simulation. 2 Discrete Event Model  In the discrete approach to system simulation, state changes in the physical.

Similar presentations


Presentation on theme: "Lecture 3 Concepts of Discrete-Event Simulation. 2 Discrete Event Model  In the discrete approach to system simulation, state changes in the physical."— Presentation transcript:

1 Lecture 3 Concepts of Discrete-Event Simulation

2 2 Discrete Event Model  In the discrete approach to system simulation, state changes in the physical system are represented by a series of discrete changes or events at specific instants of time and such models are known as discrete event models.  The time and state are the two important coordinates used in describing simulation models.  Between events, the states of the entities remain constant.  The change in state is brought about by events which from the driving force behind every discrete event simulation model.  In the discrete approach to system simulation, state changes in the physical system are represented by a series of discrete changes or events at specific instants of time and such models are known as discrete event models.  The time and state are the two important coordinates used in describing simulation models.  Between events, the states of the entities remain constant.  The change in state is brought about by events which from the driving force behind every discrete event simulation model.

3 3 System Terminology  System:  A collection of entities (e.g., people and machines) that interact together over time to accomplish one or more goals.  Model:  An abstract representation of a system, usually containing structural logical, or mathematical relationships which describe a system in terms of state, entities and their attributes, sets, processes, events, activities, and delays.  System state:  A collection of variables that contain all the information necessary to describe the system at any time.  System:  A collection of entities (e.g., people and machines) that interact together over time to accomplish one or more goals.  Model:  An abstract representation of a system, usually containing structural logical, or mathematical relationships which describe a system in terms of state, entities and their attributes, sets, processes, events, activities, and delays.  System state:  A collection of variables that contain all the information necessary to describe the system at any time.

4 4 System Terminology (cont’)  Entities:  Any object or component in the system which requires explicit representation in the model (e.g., a server, a customer, a machine).  Attributes:  The properties of a given entity (e.g., the priority of a waiting customer, the routing of a job through a job shop).  List (Set, Queue):  A collection of (permanently or temporarily) associated entities, ordered in some logical fashion (such as all customers currently in a waiting line, ordered by first come, first served, or by priority).  Entities:  Any object or component in the system which requires explicit representation in the model (e.g., a server, a customer, a machine).  Attributes:  The properties of a given entity (e.g., the priority of a waiting customer, the routing of a job through a job shop).  List (Set, Queue):  A collection of (permanently or temporarily) associated entities, ordered in some logical fashion (such as all customers currently in a waiting line, ordered by first come, first served, or by priority).

5 5 System Terminology (cont’)  Event:  An instantaneous occurrence that changes the state of a system (such as an arrival of a new customer).  Event notice:  A record of an event to occur at the current or some future time, along with any associated data necessary to execute the event; at a minimum, the record includes the event type and the event time.  Event list:  A list of event notices for future events, ordered by time of occurrence; also known as the future event list (FEL).  Event:  An instantaneous occurrence that changes the state of a system (such as an arrival of a new customer).  Event notice:  A record of an event to occur at the current or some future time, along with any associated data necessary to execute the event; at a minimum, the record includes the event type and the event time.  Event list:  A list of event notices for future events, ordered by time of occurrence; also known as the future event list (FEL).

6 6 System Terminology (cont’)  Activity:  A duration of time of specified length (e.g., a service time or inter- arrival time), which is known when it begins (although it may be defined in terms of a statistical distribution).  Delay:  A duration of time of unspecified indefinite length, which is not known until it ends (e.g., a customer’s delay in a last-in, first-out waiting line which, when it begins, depends on future arrivals).  Clock:  A variable representing simulated time.  Activity:  A duration of time of specified length (e.g., a service time or inter- arrival time), which is known when it begins (although it may be defined in terms of a statistical distribution).  Delay:  A duration of time of unspecified indefinite length, which is not known until it ends (e.g., a customer’s delay in a last-in, first-out waiting line which, when it begins, depends on future arrivals).  Clock:  A variable representing simulated time.

7 7 System Terminology (Example 2.1)  System state:  LQ(t), the number of customer waiting to be served at time t  LC(t), 0 or 1 indicate counter being idle or busy at time t  Entities  Neither the customers nor the servers need to be explicitly represented, unless certain customer averages are desired  Events:  Arrival event  Service completion  System state:  LQ(t), the number of customer waiting to be served at time t  LC(t), 0 or 1 indicate counter being idle or busy at time t  Entities  Neither the customers nor the servers need to be explicitly represented, unless certain customer averages are desired  Events:  Arrival event  Service completion

8 8 System Terminology (Example 2.1)  Activities:  Interarrival time  Service time  Unconditional wait  Delay:  A customer’s wait in queue until counter becomes free  Conditional wait  Activities:  Interarrival time  Service time  Unconditional wait  Delay:  A customer’s wait in queue until counter becomes free  Conditional wait

9 9 Main Approaches  Event-scheduling approach  concentrate on the events and how they affect the system state. The simulation evolves over time by executing events in increasing order of their times of occurrence.  Examples: FORTRAN, GASP IV, C++  Process-interaction approach  concentrate on a single entity (e.g. a customer) and the sequence of events and activities it undergoes as it PASSES THROUGH THE SYSTEM. At any given time, the system may contain many processes (e.g. customers) interacting with each other while competing for a set of resources.  Example: GPSS  Event-scheduling approach  concentrate on the events and how they affect the system state. The simulation evolves over time by executing events in increasing order of their times of occurrence.  Examples: FORTRAN, GASP IV, C++  Process-interaction approach  concentrate on a single entity (e.g. a customer) and the sequence of events and activities it undergoes as it PASSES THROUGH THE SYSTEM. At any given time, the system may contain many processes (e.g. customers) interacting with each other while competing for a set of resources.  Example: GPSS

10 10 Main Approaches (cont’)  Interactive, menu-driven, animated approach  Recently available on PCs.  Examples: PROMODEL, SIGMA  Interactive, menu-driven, animated approach  Recently available on PCs.  Examples: PROMODEL, SIGMA

11 11 Future Event List (FEL)  Both the event-scheduling and the process- interaction approaches use a variable time advance;  that is, when all events and system state changes have occurred at one instant of simulated time, the simulation clock is advanced to the time of the next imminent event on the FEL.  Both the event-scheduling and the process- interaction approaches use a variable time advance;  that is, when all events and system state changes have occurred at one instant of simulated time, the simulation clock is advanced to the time of the next imminent event on the FEL.

12 12 Event-Scheduling Approach  This list contains all event notices for events that have been scheduled to occur at a future time.  Scheduling a future event means that at the instant an activity begins, its duration is computed or drawn as a sample from a statistical distribution and the end-activity event, together with its event time, is placed on the future event list.  In the real world, most future events are not scheduled but merely happen – such as random breakdowns or random arrivals.  This list contains all event notices for events that have been scheduled to occur at a future time.  Scheduling a future event means that at the instant an activity begins, its duration is computed or drawn as a sample from a statistical distribution and the end-activity event, together with its event time, is placed on the future event list.  In the real world, most future events are not scheduled but merely happen – such as random breakdowns or random arrivals.

13 13 Event-Scheduling Approach (Example)  List of all activities’ SCHEDULED TIME OF COMPLETION (EVENTS)  The FEL is a SET ordered in completion times  t 1 < t 2 < … < t n  Example Consider a single server queue with the following arrival times for the first 10 customers: 0 4 8 10 13 14 17 20 27 29 and service times for these customers 5 5 1 3 2 1 4 7 3 1 Assume that completions are given priority over arrivals  List of all activities’ SCHEDULED TIME OF COMPLETION (EVENTS)  The FEL is a SET ordered in completion times  t 1 < t 2 < … < t n  Example Consider a single server queue with the following arrival times for the first 10 customers: 0 4 8 10 13 14 17 20 27 29 and service times for these customers 5 5 1 3 2 1 4 7 3 1 Assume that completions are given priority over arrivals

14 14 Event-Scheduling Approach (Example) Time = 0 FEL 4ARRIVAL 5COMPLETION.... QUEUE 0 

15 15 Event-Scheduling Approach (Example) Time = 4 FEL 5COMPLETION 8ARRIVAL 10COMPLETION 13ARRIVAL 14ARRIVAL 17ARRIVAL 20ARRIVAL 27ARRIVAL 29ARRIVAL QUEUE 4#1 arrival timecustomer

16 16 Process-Interaction Approach  A process is the life cycle of one entity.  This life cycle consists of various events and activities.  Some activities may require the use of one or more resources whose capacities are limited.  These and other constraints cause processes to interact, the simplest example being an entity forced to wait in a queue (on a list) because the resource it needs is busy with another entity.  A process is the life cycle of one entity.  This life cycle consists of various events and activities.  Some activities may require the use of one or more resources whose capacities are limited.  These and other constraints cause processes to interact, the simplest example being an entity forced to wait in a queue (on a list) because the resource it needs is busy with another entity.

17 17 Process-Interaction Approach (cont’)  In more precise terms, a process is a time- sequenced list of events, activities, and delays, including demands for resources, that define the life cycle of one entity as it moves through a system.  We see the interaction between two customer processes as customer n + 1 is delayed until the previous customer’s “end-service event” occurs.  In more precise terms, a process is a time- sequenced list of events, activities, and delays, including demands for resources, that define the life cycle of one entity as it moves through a system.  We see the interaction between two customer processes as customer n + 1 is delayed until the previous customer’s “end-service event” occurs.

18 18 Process-Interaction Approach (Example) Time Arrival event Arrival event Begin service Begin service End- service- event End- service- event Interaction Activity Delay Customer n Customer n + 1


Download ppt "Lecture 3 Concepts of Discrete-Event Simulation. 2 Discrete Event Model  In the discrete approach to system simulation, state changes in the physical."

Similar presentations


Ads by Google