OPNET Modeler
M/M/1 Queue
(Compiled from
OPNET Modeler M/M/1 Tutorial)
Hue Tran
Spring 2002
Version 1.0
src queue sink
Read the OPNET tutorial on OPNET Modeler of M/M/1 queue
system from the help file carefully.
Getting started:
Create project and scenario
- Lclick
File
- Project:
new
- Scenario:
new
- Project
name: your_initial_mm1net
- Scenario:
mm1. è
Start Up Wizard window opens
- Select
Quit for Startup Wizard è Project Editor window
opens
Node Editor:
Create Node model:
- Lclick
File
- Lclick
New
- Lclick
Node model
- Lclick
OK è
To Open Node Editor window
Investigate and familiar with the name of each icon
on the Node Editor.
Create Processor Module:
- Lclick
and drag the Create Processor icon to the Node Editor workspace.
- Rclick
to end.
- Lclick
on the Processor module to open Process Model window (Finite State
Machine level)
- Investigate
the state diagram.
- Close
the window.
Set processor module’s attributes:
- Rclick
on the Processor module
- Select
Edit Attributes è To Open Attributes
dialog window
- Name:
src
- Process
model: simple_source
- Lclick
Value column of Packet Interarrival Time è
To open Packet Interarrival Time Specification dialog window.
- Distribution
name: Exponential
- Mean
Outcome: 1.0
- Lclick
OK è
To Close Packet Interarrival Time Specification dialog window.
- Lclick
on Value column of Packet Size è
Open Packet Size Specification dialog window.
- Distribution
name: Exponential
- Mean
Outcome: 9000
- Lclick
OK è
To Close Packet Size Specification
dialog window.
- Lclick
OK è
To Close Attributes dialog window.
Create Queue Module:
- Lclick
and drag the Queue icon to the Node Editor workspace.
- Rclick
to end.
Set queue module’s attributes:
- Rclick
on Queue module
- Select
Edit Attributes è To Open Attributes
dialog window
- Name:
queue
- Process
model: Select acb_fifo
- Service_rate:
9600.
- Lclick
OK èTo Close Attributes dialog window
Create Processor Module (Add a sink module to destroy a
temporary entity):
- Lclick
and drag the Create Processor module to the Node Editor workspace.
- Rclick
to end.
Processor module’s attributes:
- Rclick
on Processor module
- Edit
Attributes è
Open Attributes dialog window
- Name:
sink
- Lclick
OK è
To Close Attributes dialog window.
Create packet stream (modules connection)
- Lclick
on Create Packet Stream icon.
- Lclick
on src module then lclick on queue è
connect src module to queue module
- Lclick
on queue module then lclick on sink module
- Rclick
to end.
The model is now completed
Save the model:
- Lclick
File
- Lclick
Save è
Name: your_initial_mm1
- Lclick
Ok è
To Close Node Editor.
- Get
a print of the model.
The model is now
available to be used in a network.
Create network model:
For this example, the network will consist of a single node
object based on the M/M/1 model created above. This is achieved by first
creating a new object palette.
Create a new object palette
- Lclick
Open Object palette
- LClick
Configure Palette è To open Configure
Palette window
Activate Model List
- Lclick
Clear
- Lclick
Node Models è
To open list of available node models
- Find
your_initial_mm1 node model created earlier.
- Lclick
on Status column to include the node model
- Lclick
OK è
To Close the list
- Lclick
Save è
name: your_initial_mm1_palette
- Lclick
OK è
To save
- Lclick
OK è
To close Configure Palette window
Create network model
- Lclick
and drag your_initial_mm1 node model from object palette to
workplace.
- Rclick
to end
- Rclick
on the node è
To open Object window
- Name:
m1
- Lclick
OK è
To close Object window.
- Lclick
File
- Lclick
Save (the name should be your_initial_mm1net)
- Lclick
OK è
To save the network
Statistics Collection using Probe Editor
To provide statistics to be collected during simulation and
for report generation after simulation.
- Lclick
File
- Lclick
New
- Select
Probe Model
- Lclick
OK è
To open Probe Editor window
Set network model
- Click
Objects on menu
- Select
Set Network Model è To open network model
window
- Select
your_initial_mm1net-mm1 network model from network model window.
Set probes
- Lclick
Create Node Statistic Probe è a probe appears below
Node Statistic Probe
- Rclick
on the probe
- Select
Choose Probed Object
- Lclick
on the arrow next to m1 node to show its components
- Lclick
queue module in a node diagram
- Lclick
OK è
To close dialog window
- Rclick
on probe
- Select
Edit Attributes è To open Attributes
window
- Name:
queue delay
- Submodule:
subqueue[0]
- Lclick
in the Value column of statistic row è
To open Available Statistics dialog window.
- Select
queue.queueing delay
- Lclick
OK to apply
- Lclick
OK è
To close Attributes window.
- Lclick
Create Node Statistic Probe
- Rclick
on new probe
- Select
Edit Attributes è To open Attributes
window
- Name:
queue size
- Subnet:
top
- Node:
m1
- Module:
queue
- Submodule:
subqueue[0]
- Group:
queue
- Statistic:
queue size (packets)
- Lclicl
OK è
To close Attribute dialog window
- Lclick
File
- Lclick
Save è
name: your_initial_mm1probe
At this point, modeling process is finished.
The model has been created completely
Data to be collected for analysis have been specified.
The next step is simulation.
Simulation
·
Lclick Simulation on
menu of Project Editor è To open simulation menu
- Lclick
Configure Simulation (Advanced) è
To open Simulation Tools
- Rclick
on the Scenario
- Select
Edit Attributes
- Probe
File: your_initial_mm1probe
- Seed:
431
- Duration:
7 hours
- Lclick
OK
- Lclick
Execute Simulation Sequence to begin simulation session.
Wait until the simulation finish.
Analysis Tools
View average queueing delay
- Lclick
File
- Lclick
Open
- Select
Analysis Configuration
- Select
your_initial_mm1net-mm1
- Lclick
OK è
To open Analysis Tool window
- Lclick
Create A Graph Of A Statistic è
To open View Results dialog window
- Lclick
File Statistics
- Lclick
your_initial_mm1net-mm1
- Lclick
Object Statistics
- Lclick
m1
- Lclick
queue
- Lclick
subqueue[0]
- Lclick
queue
- Lclick
queueing delay è To enable the statistic
- Lclick
average
- Lclick
Show è
the graph of average queueing delay appears.
View time-averaged queue size
Do not close the graph window of
queueing delay
- Lclick
queueing delay è To disable the statistic
- Lclick
queue size (packets) è To enable the statistic
- Select
Time-average
- Lclick
Show è
the graph of time-averaged queue size appears
View queue size versus time-averaged queue size
- Close
view results window
- Rclick
on the graph of time-averaged queue size
- Select
Add Statistic è To open new view result
window
- Lclick
File Statistics
- Lclick
your_initial_mm1net-mm1
- Lclick
Object Statistics
- Lclick
m1
- Lclick
queue
- Lclick
subqueue[0]
- Lclick
queue
- Lclick
queue size(packets)
- Lclick
Add è
To add the graph of queue size (packets)
- Get
hard copies of the model and all graphs