Network Protocol Simulation A look at Discrete Event

  • Slides: 26
Download presentation
Network Protocol Simulation: A look at Discrete Event Simulation Grant D. Lanterman 5/21/2004

Network Protocol Simulation: A look at Discrete Event Simulation Grant D. Lanterman 5/21/2004

Overview § Network Protocol Example § Simulation § Overview § Why? § Discrete Event

Overview § Network Protocol Example § Simulation § Overview § Why? § Discrete Event Simulation § Why? § Example § Software

Example: TCP/IP § Driving force of the internet § Layered protocol

Example: TCP/IP § Driving force of the internet § Layered protocol

TCP/IP Layers § § § Physical layer Network access layer Internet layer Host-to-host, or

TCP/IP Layers § § § Physical layer Network access layer Internet layer Host-to-host, or transport layer Application layer

Network Protocols § Difficult to simulate activity with small test networks § Dynamic

Network Protocols § Difficult to simulate activity with small test networks § Dynamic

The Answer! § § § Simulation Imitating real-world situations Two types § Analytical modeling

The Answer! § § § Simulation Imitating real-world situations Two types § Analytical modeling § Computer simulation

Analytical Modeling § Use of mathematical equations to represent a network § May lead

Analytical Modeling § Use of mathematical equations to represent a network § May lead to oversimplification § Can’t effectively model the dynamic nature of a network § Less Practical

Computer Simulation § § § Preferred simulation type for networks Can adapt to dynamic

Computer Simulation § § § Preferred simulation type for networks Can adapt to dynamic nature of networks Use of a computer to simulate what will happen in real-world events § Discrete Event Simulation usually used § Example: § What would be the effect of adding an extra cashier to a bank

Simulation Terminology § § § § Simulation Model Attributes Entities Activities Delays States Events

Simulation Terminology § § § § Simulation Model Attributes Entities Activities Delays States Events

Simulation Model § Set of assumptions about the system being simulated § Includes assumptions

Simulation Model § Set of assumptions about the system being simulated § Includes assumptions based on: § Algorithms § Mathematical equations § Conditions imposed by the system § Simplified § Replace real parts of the system by concepts

Entities § Objects that will participate in the simulation § Part of the model

Entities § Objects that will participate in the simulation § Part of the model § Examples from a Bank Simulation: § Customers § Employees § Managers

Attributes § Properties of entities within the system § Examples from Bank Simulation: §

Attributes § Properties of entities within the system § Examples from Bank Simulation: § Gender of a customer § Name of an employee

Activities and Delays § § Activity is a duration of known time A delay

Activities and Delays § § Activity is a duration of known time A delay is a length of unknown time Can change state of system Activity Example: § A customer checking their account balance § Delay Example: § Time it takes for n customers to enter the bank

States § The current configuration of the system § Sate variables represent the current

States § The current configuration of the system § Sate variables represent the current system § Example: § The length of the line of customers in the bank

Events § § § Instantaneous in time Often change the state of the system

Events § § § Instantaneous in time Often change the state of the system Example: § A customer enters the bank

Simulation Process

Simulation Process

Discrete Event Simulation (DES) § Asks the questions: § What events are possible and

Discrete Event Simulation (DES) § Asks the questions: § What events are possible and do they change the state? § What activities and what are their duration? § What events begin/end each activity? § How are delays defined? § How do we start the simulation?

DES § Models a system as it evolves § Represents changes as separate discrete

DES § Models a system as it evolves § Represents changes as separate discrete events § Simulation executive § Next event § Time slicing

DES Approaches § Event § Commonly used § Describes an instantaneous change § Activity

DES Approaches § Event § Commonly used § Describes an instantaneous change § Activity § Examines as a duration of time § Easy to understand but not efficient § Process § Groups activities to describe the life cycle of an entity § Most efficient and effective but difficult to impliment

Event Types § Primary § Scheduled at a specific time § New cashier comes

Event Types § Primary § Scheduled at a specific time § New cashier comes to work § Conditional § Triggered by a condition § Customer moving from the line to a cashier

Event List § § § Often called the FEL or future event list Main

Event List § § § Often called the FEL or future event list Main data structure of a DES Ordered in increasing time of event notice Contains only primary events Contains all information needed to execute the events in it § Efficiency of simulator depends on efficiency of FEL

DES Algorithm § § § Remove first event(l, E) from FEL Advance simulation to

DES Algorithm § § § Remove first event(l, E) from FEL Advance simulation to time t Update sate variables according to E Insert new events into FEL according to E Compute statistics

Bank Queuing Example § Owner asks: What would the effects of adding another cashier

Bank Queuing Example § Owner asks: What would the effects of adding another cashier to the bank have? § Customer wait time § Bank congestion

Bank (Cont. ) § Can use DES to simulate the randomness of customers arriving

Bank (Cont. ) § Can use DES to simulate the randomness of customers arriving § Calculate wait times with n cashiers § Gather statistics on multiple runs

Network Simulators § Many software packages available § Example: § OPNET § Assist in

Network Simulators § Many software packages available § Example: § OPNET § Assist in building simulation model § Run simulation and collect results

Questions? § Comments? § Hearing None…

Questions? § Comments? § Hearing None…