Sunteți pe pagina 1din 152

Session 1572

Introduction to Using OPNET Modeler


Network R&D
CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

Session Goals
Learn the basics of using Modeler through a combination of lectures and labs Learn and practice Modeler methodologies and use cases Learn how to create new
Processes Nodes Packets Links Networks

Analyze results from a Discrete Event Simulation

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

Class Format
Lots of material to cover, so class will move quickly Half lecture; half lab Conference proceedings will be available on website Class is interactive; dont hesitate to ask questions Prerequisites Ability to understand C or C++ Basic understanding of networks

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

Course Outline
Introduction Overview Events and event list concepts Packets Network modeling Node modeling Link modeling Running a simulation Process modeling Analyzing and publishing results Additional features and modules Conclusion

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

What is NOT Covered


This session will NOT cover
Using the Standard Model Library, such as How to configure standard protocols (ATM, Ethernet, Wireless LAN, etc.) How to perform studies such as QoS, capacity planning, traffic engineering Interfacing custom models with the Standard Model Library Importing topology and traffic Debugging process models Process Modeling Methodology Dynamic processes Creating custom pipeline models Third-party integrations Wireless studies System-In-The-Loop (SITL)

Above topics covered in other OPNETWORK sessions


CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

OPNET Network R&D Solutions


OPNET Modeler is the de-facto standard for:
Network R&D Modeling and simulation Defense organizations Network equipment manufacturers

Accelerate network R&D and planning:


Design wired and wireless protocols and technologies Test and demonstrate designs in realistic scenarios before production Plan mobile network deployments that accurately incorporate terrain effects Design wireless network protocols to optimally support the warfighter Assess battlefield plans in light of communications effects

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

Solution Portfolio

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

Introduction: Agenda
Methodology and Workflow OPNET Hierarchy
Network Node Process

Navigating the Project Editor


Subnets Zooming

Simulation Output Lab: Exploring a Finished Project

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

Simulation Methodology

Start

Understanding the system

Understanding your goals for the simulation

Choosing aspects to be modeled

Defining input and output

No
Specifying the system model Choosing input and running simulations System results accurate? Results sufficiently detailed? No

Yes

No

Results statistically useful?

End

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

The Project/Scenario Workflow


Create project Create baseline scenario
Import or create topology Import or create traffic Choose results and reports to be collected Run simulation View results

Duplicate scenario
Make changes Re-run simulation Compare results

Iterate

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

10

1572 Introduction to OPNET Modeler

The Three-Tiered OPNET Hierarchy


Three domains: Network, node, and process Node model specifies object in network domain Process model specifies object in node domain

Process model rip_udp_v3

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

11

1572 Introduction to OPNET Modeler

Network Domain: Network Objects


Network models consist of nodes, links and subnets Nodes represent network devices and groups of devices
Servers, workstations, routers, etc. LAN nodes, IP clouds, etc.

Links represent point-to-point and bus links Icons assist the user in quickly locating the correct nodes and links Vendor models are distinguished by a specific color and logo for each company
Generic Devices Vendor Devices

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

12

1572 Introduction to OPNET Modeler

Subnets
Organize network components Represent actual network physical constructs Has no behavioral aspects Logical, Stationary, mobile, or satellite
Subnet Types

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

13

1572 Introduction to OPNET Modeler

Annotation Palette
Open by selecting Topology / Open Annotation Palette Add rectangles, circles, lines and text to models to enhance their appearance This method is an effective way to graphically illustrate and document the changes made to a model Does not affect analysis Annotations can be temporarily hidden

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

14

1572 Introduction to OPNET Modeler

Zooming
Zoom to Rectangle button on the Project Editor toolbar allows the user to define a rectangular area to magnify Zoom to Previous button returns the workspace to the previous magnification level Mouse Scroll Wheel or Page-Up and Page-Down keys for small increments Right-click on the workspace to open the workspace pop-up menu
Zoom in Zoom to all Zoom out Zoom to selection Zoom to window

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

15

1572 Introduction to OPNET Modeler

Node Domain
Basic building blocks (modules) include processors, queues, and transceivers
Processors are fully programmable via their process model Queues also buffer and manage data packets Transceivers are node interfaces

Interfaces between modules


Packet streams Statistic wires
Stat Wire Packet Stream

Receiver Processor

Queues

Transmitters

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

16

1572 Introduction to OPNET Modeler

Process Domain
Process model components
State transition diagrams Blocks of C code OPNET Kernel Procedures (KPs) State variables Temporary variables

A process is an instance of a process model Processes can dynamically create child processes Processes can respond to interrupts

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

17

1572 Introduction to OPNET Modeler

Simulation Output
Three kinds of output
Vectors List of time-value pairs Scalars List of values dependent on parametric input Not plotted vs. time Animations Packet flows Node movements Output to 3DNV

Objects have pre-defined statistics

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

18

1572 Introduction to OPNET Modeler

Lab: Workspace
Go to lab book Practice navigating the project editor
Navigate the project project_environment_ref Load a map Explore the network Navigate subnets Practice zooming features Examine attributes of devices

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

19

1572 Introduction to OPNET Modeler

Event List Concepts: Agenda


Event-Driven Simulation Event List and the Simulation Time Clock Simulation Kernel Interrupts Processes and Interrupts Event List Example

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

20

1572 Introduction to OPNET Modeler

Event-Driven Simulation
Events are specific activities that occur at a certain time OPNET simulations are event-driven Simulation time advances when an event occurs A different method might be to sample at regular intervals
Disadvantages Accuracy of results is limited by the sampling resolution Simulation is inefficient if nothing happens for long periods

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

21

1572 Introduction to OPNET Modeler

Event List Concepts


Single global event list Shared simulation time clock Events scheduled in time order Event removed from event list when it completes

Time Event Type


Head 0.0 0.0 4.3 4.3 Initialize Initialize Timer expires Packet arrives

Module
src.gen src.rte src.gen src.rte

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

22

1572 Introduction to OPNET Modeler

The Simulation Kernel


Manages the event list Delivers each event, in sequence, to the appropriate module Receives requests from processes and inserts new events in the event list

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

23

1572 Introduction to OPNET Modeler

Event Generation and Cancellation


Events can be generated in several ways
BEGSIM/ENDSIM interrupts Self interrupts Packet arrivals (STRM interrupts) Writing to a statwire (STAT interrupts)

Events can be cancelled before they occur

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

24

1572 Introduction to OPNET Modeler

Interrupts
First event in the event list becomes an interrupt Simulation Kernel delivers the interrupt to the designated module Data associated with the interrupt can be obtained by the module Processors and queues can have BEGSIM interrupts

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

25

1572 Introduction to OPNET Modeler

How Does the Event List Work?

New event reaches head of event list, which causes Simulation Kernel to deliver an interrupt to the appropriate module

Process within the module gains control and processes interrupt

Simulation Kernel deletes event from event list, allowing new event to reach head of list

Simulation Kernel regains control from module

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

26

1572 Introduction to OPNET Modeler

Event List Implementation


The Simulation Kernel uses an efficient proprietary algorithm to maintain the event list Event times are expressed as double-precision, floating-point numbers and are used to keep the event list sorted

0.01234 56789 11111 11 0.01234 56789 11111 22 0.01234 56789 11111 33 0.01234 56789 11111 44 0.01234 56789 11111 55 0.01234 56789 11111 66 0.01234 56789 11111 77

Suppose that this interrupt triggers an event to occur at 0.01234 56789 11111 75.

The Simulation Kernel minimizes the time required to place this event at the correct place on the list.

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

27

1572 Introduction to OPNET Modeler

Delivery of Interrupts
When an interrupt is delivered to a module, control passes from the Simulation Kernel to the module If the module is a queue or processor, the interrupt is delivered to the process running within the module Other modules, such as transmitters and receivers, are covered later

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

28

1572 Introduction to OPNET Modeler

Event List Concepts Reviewed


Events must exist in the event list at the start of a simulation
A processor or queue module has the begsim interrupt attribute enabled

Each event may schedule other events The event list is always growing and shrinking An event is pending until executed A pending event can be cancelled

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

29

1572 Introduction to OPNET Modeler

Forced States
Forced (green) and unforced (red) states differ significantly in execution timing In a forced state, the process
Invokes the enter executives Invokes the exit executives Evaluates all condition statements If exactly one condition statement evaluates to true, the transition is traversed to the next state
Forced (green) states

Enter execs invoked No blocking or waiting Exit execs invoked Transition to next state

OPNET convention: Code in enter execs only

Enter execs invoked No blocking or waiting Exit execs invoked

Transition to next state


CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

30

1572 Introduction to OPNET Modeler

Unforced States
In an unforced state, the process
Invokes the enter executives Places a marker at the middle of the state Releases control to the Simulation Kernel and becomes idle Resumes at the marker and processes the exit execs when next invoked
Unforced (red) states

Blocking, waiting for invocation


Exit execs processed when invocation occurs

Start of invocation

Transition to next state

Enter execs invoked

End of invocation

Blocking, wait for next invocation Next invocation starts here

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

31

1572 Introduction to OPNET Modeler

Transitions Between States


After completing the exit executives, the process evaluates the conditions for all transitions from the state One and only one condition statement must evaluate to true The single true transition is taken to the next state A transition with condition = default is true if and only if no other conditions are true A transition with no condition set is termed unconditional and is always true

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

32

1572 Introduction to OPNET Modeler

How a Process Handles an Interrupt


Flow diagram showing how a process handles an interrupt

Find marker

Implement exit execs No

Evaluate condition statements

Follow transition to next state

Implement enter execs

Red state?

Yes

Set marker; block and wait for interrupt

Receive interrupt

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

33

1572 Introduction to OPNET Modeler

Process Model Example


Model with three forced states and one unforced state:
1. Initial interrupt delivered and the enter execs invoked.

4. Enter execs invoked.

7. Enter execs invoked.

3. Transition occurs.

6. Transition occurs.

8. Marker is placed and process stops here.

2. Exit execs invoked immediately. Transition condition (pk_count == 0) evaluates to true.

5. Exit execs invoked immediately.

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

34

1572 Introduction to OPNET Modeler

The Simulation Kernel and Processes


Control passes between the Simulation Kernel (SK) and multiple processes (pr1, pr2, etc.), as described below:
Description
Read first event on event list. Deliver to appropriate process (pr1)

In control SK

Idle All processes

pr1 invoked at initial state. Continues executing states until a red (unforced) state is entered. Release control to SK and becomes idle Remove first event from event list. Advance next event to head of list. Deliver interrupt to pr2.

pr1

SK All other processes All processes

SK

Evaluate condition statements and transition to next state

pr2

SK Other processes
35

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

Event List Example


Node model: dest1
Consider this model:
Node model

Node model

Network model

Node model: src

Network model
36

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

Event List Example (cont.)


The network model has three nodes (src, dest1, dest2) relying on two node models (both dest nodes use the same node model) In the src node model, packets are generated at gen and sent by queue to either transmitter (tx0 / tx1) Packets then flow across a link to a destination node (dest1, dest2) where they are received (rx) and thrown out (sink) Three modules (gen, queue, and sink) have process models associated with them

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

37

1572 Introduction to OPNET Modeler

The BEGSIM Interrupt


Occurs at simulation time 0.0 before any other type of interrupt Usually initializes a module and schedules future events Any processor or queue can have its begsim intrpt attribute enabled, resulting in an event being placed on the event list for time 0.0

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

38

1572 Introduction to OPNET Modeler

Event List Example (cont.)


The begsim intrpt attribute for modules src.gen and src.queue is enabled; this places two events in the event list
Time
0.0 0.0

Event Type
BEGSIM BEGSIM

Module
src.gen src.queue

Node model

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

39

1572 Introduction to OPNET Modeler

Processing the First Interrupt


Consider the process model specified by the src.gen module

Process model: gen

Node model: src

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

40

1572 Introduction to OPNET Modeler

Starting the Simulation


Simulation Kernel reads the event at the head of the event list, and delivers control to the process in the src.gen module Process begins execution at the initial state, marked with the black arrow Process executes the Init states enter execs

Time
0.0 0.0

Event Type
BEGSIM BEGSIM

Module
src.gen src.queue

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

41

1572 Introduction to OPNET Modeler

Processing the First Interrupt in Process gen (cont.)

Process model: gen

Process model

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

42

1572 Introduction to OPNET Modeler

Processing the First Interrupt in Process gen (cont.)


Because Init is a forced (green) state, process immediately invokes and completes the exit execs Process evaluates all condition statements. This state has only one departing transition which evaluates to true Process transitions to Wait state

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

43

1572 Introduction to OPNET Modeler

Processing the First Interrupt in Process gen (cont.)


Process invokes and completes the enter execs of Wait

Process model

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

44

1572 Introduction to OPNET Modeler

Processing the First Interrupt in Process gen (cont.)


Line 8 of the enter execs schedules a self interrupt using a KP. This adds an event to the event list Since that was the last line of the enter executives, process places a marker at the middle of Wait Process becomes idle

Time
0.0 0.0 4.3

Event Type
BEGSIM BEGSIM SELF

Module
src.gen src.queue src.gen

Marker

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

45

1572 Introduction to OPNET Modeler

Processing the Second Interrupt at Module src.queue


Simulation Kernel removes the first event and advances the next event to the head of the event list. The simulation time remains 0.0. Simulation Kernel delivers a BEGSIM interrupt to src.queue. Process in src.queue module gains control. It executes until it reaches an unforced (red) state, places a marker, and then becomes idle. (This model is not shown.)

Time First event is removed


0.0 4.3

Event Type
BEGSIM SELF

Module
src.queue src.gen

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

46

1572 Introduction to OPNET Modeler

Processing the Next Interrupt at Module src.gen


Simulation Kernel removes the previous event and advances the next event to the head of the event list. The simulation time becomes 4.3 seconds. Simulation Kernel delivers the SELF interrupt to the gen process. The process resumes at the marker in the middle of Wait. Process invokes and completes the exit execs of Wait.

Time
4.3

Event Type
SELF

Module
src.gen

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

47

1572 Introduction to OPNET Modeler

Continuing the Process at gen


Process evaluates all condition statements when leaving Wait. This state has one outgoing conditional transition that evaluates to true.

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

48

1572 Introduction to OPNET Modeler

Continuing the Process at gen (cont.)


Process transitions to Send. Process invokes the enter execs of Send and calls op_pk_send( ) to send a packet. This results in an event of type STRM being placed on the event list.

Time
4.3 4.3

Event Type
SELF STRM

Module
src.gen src.queue

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

49

1572 Introduction to OPNET Modeler

Continuing the Process at gen (cont.)


Process immediately invokes and completes the exit execs, because Send is a forced (green) state Process evaluates all possible transitions. One evaluates to true Process transitions to Wait Process invokes enter execs of Wait, schedules another SELF interrupt in the event list and becomes idle Simulation Kernel takes control and processes the next event in the list

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

50

1572 Introduction to OPNET Modeler

Simulation Termination
Simulations terminate in one of four ways:
The event list is emptied Simulation attribute duration expires A process calls for termination, using the KP op_sim_end() A fatal error occurs

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

51

1572 Introduction to OPNET Modeler

How Does Time Advance?


Simulation time advances only when an event with a later time is processed from the event list No simulation time occurs during the execution of a process No time elapses during transitions between states A process model must always have an unforced (red) state so time can advance
Avoid endless looping between forced (green) states

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

52

1572 Introduction to OPNET Modeler

Events and Event List Concepts: Summary


Forced and unforced states execute differently Any processor or queue can have the attribute begsim intrpt enabled, scheduling an event for time 0.0 Control passes dynamically between the Simulation Kernel and individual processes

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

53

1572 Introduction to OPNET Modeler

Packets: Agenda
Packets in Modeler Packet Formats Lab: Create a Packet Format Packet Events

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

54

1572 Introduction to OPNET Modeler

Packets
Information-carrying entities that circulate among system components General data structures, organized into fields of user-defined information Dynamically created and destroyed as the simulation progresses A single system may rely on multiple types of packets with different formats

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

55

1572 Introduction to OPNET Modeler

Packet Formats
Packets can either be unformatted or formatted Unformatted packets have no user-defined data fields Formatted packets have zero or more fields Field types
Integer Floating point Structure Packet Information

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

56

1572 Introduction to OPNET Modeler

Lab: Create a Formatted Packet


Create a packet with two fields
Destination Node Source Node

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

57

1572 Introduction to OPNET Modeler

Events for Packet Transmission


All packet transmissions are modeled with four events
Start of Transmission End of Transmission Start of Reception End of Reception

Simulation Kernel automatically schedules these events

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

58

1572 Introduction to OPNET Modeler

Packets: Summary
The basic elements for data exchange
Between modules in nodes Between nodes in a network

Can be formatted with user-defined fields Dynamic simulation objects

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

59

1572 Introduction to OPNET Modeler

Building Models: Agenda


Creating Network Models
Drag-and-drop Rapid configuration Startup Wizard

Map Backgrounds Annotations Deriving and Creating New Models Object Attributes Online Documentation

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

60

1572 Introduction to OPNET Modeler

Creating Network Models


There are two ways to create new network models
Import OPNET Products (e.g. ACE, VNE Server) Network management data (e.g., Network Node Manager) Files (e.g. router configuration files, XML) Manual Creation Drag-and-drop Rapid configuration

Note: Topology Import Sessions


1617: Importing IP and Layer-2 Networks with XDI 1623: Using VNE Server Introduction

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

61

1572 Introduction to OPNET Modeler

Rapid Configuration
Rapid configuration allows you to quickly create networks of any size Available topology configurations:
Bus Ring Star Tree Mesh Unconnected

Specify the number of nodes, the node and link models used, how nodes will be arranged, and node locations within the workspace

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

62

1572 Introduction to OPNET Modeler

Startup Wizard
The Startup Wizard can quickly configure a new scenario There are several settings for each scenario:
Name Initial topology Network scale Network size Technologies

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

63

1572 Introduction to OPNET Modeler

Background Maps
View/hide maps by choosing View / Background / Set Properties Geotiff, MapInfo, MrSID, and CADRG images automatically appear at the correct latitude and longitude position.

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

64

1572 Introduction to OPNET Modeler

Deriving New Models


Derive a new model based on any existing model Can alter the attributes of the newly derived model

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

65

1572 Introduction to OPNET Modeler

Device Creator
Automatically create a particular device with a specific configuration Launched from Topology menu Select any number of interfaces and protocols

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

66

1572 Introduction to OPNET Modeler

Object Attributes
Control aspects of objects behavior Are values that may vary
From one model to the next Between objects of the same model type

Right-click on an object and select Edit Attributes to view or change Can be promoted to
Set the value at a higher layer Specify a range of values at runtime

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

67

1572 Introduction to OPNET Modeler

Where to Get Help


Online Documentation from the Help menu Model help accessible by right-clicking object icons in the object palette or by right-clicking objects in the Project workspace and selecting View Node Description Tool Tips
Hold mouse over any object to get a brief description of that object

Attribute help accessible by clicking on the question mark next to the attribute

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

68

1572 Introduction to OPNET Modeler

Node Modeling: Agenda


Node Modules Module Connections Interfaces Node Statistics Lab: Creating Node Models

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

69

1572 Introduction to OPNET Modeler

Node Objects: Modules


Modules are the basic building blocks of node models
Processors Queues Transceivers Transmitters Receivers Antennas

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

70

1572 Introduction to OPNET Modeler

Node Objects: Processors and Queues


Processors
General-purpose building blocks of node models Fully programmable
Processor

Queues
Offer all the functionality of processors Can also buffer and manage a collection of data packets
Queue

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

71

1572 Introduction to OPNET Modeler

Node Objects: Transceivers


Transceivers are the interfaces between objects inside a node and communication links outside it
Transmitters are the outbound interfaces Receivers are the inbound interface

Some transceiver attributes:


Number of channels Data rate Supported packet formats

Point-to-point transceivers

Bus transceivers

Radio transceivers

Transmitter

Receiver

Transmitter

Receiver

Transmitter

Receiver

These require the Wireless add-on module

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

72

1572 Introduction to OPNET Modeler

Node Objects: Antennas Antennas may be used with radio transceivers to specify antenna properties
Antenna

Note: Wireless modeling is covered in other sessions


1942 Introduction to Using 3D Network Visualizer (3DNV) 1943 Creating Custom 3D Network Visualizations using Modeler 1332 Planning and Analyzing Wireless LANs 1530 Modeling Custom Wireless Effects 1529 Understanding WLAN Model Internals, Interfaces, and Performance 1941 Understanding MANET Model Internals, Interfaces, and Performance 1527 Accelerating Wireless Simulations Using Scalability Techniques
CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

73

1572 Introduction to OPNET Modeler

Module Connections
Packet streams carry data packets from a source to a destination module Statistic wires carry a single data value from a source to a destination module Logical associations tie individual transmitters and receivers together to make a transceiver pair

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

74

1572 Introduction to OPNET Modeler

Node Model: Example


Node models can support:
Layering of protocol functions Dynamic inter-module monitoring Arbitrary node architectures
ethernet_wkstn_adv Node Model

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

75

1572 Introduction to OPNET Modeler

Specifying Node Interfaces


Specify various characteristics of the node
Rename attributes Set attribute values Hide attributes Specify node types Add comments

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

76

1572 Introduction to OPNET Modeler

Specifying Available Node Statistics


Specify statistics to be available from project editor Selecting an empty field in the Orig. Name column opens a table of available statistics Selecting a statistic from the Available Statistics table adds the statistic to the Statistic Promotion table

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

77

1572 Introduction to OPNET Modeler

Lab: Node Modeling


The Worst National Bank wants to model the flow of bank transactions (represented as packets) from Washington, D.C. to Philadelphia
Bank transactions originate in Washington, D.C., and are routed to Philadelphia via a modem at 9,600 bits/second. The size of a transaction varies according to a normal distribution with a mean size of 3,200 bits and a variance of 400 bits. Transactions are modeled as exponential interarrivals, with a mean interarrival time of 0.5 sec/trans.

Analyze the system in steady state


Does the queue size of the WDC transmitter steadily increase? What is the throughput (in bits/second) at the WDC transmitter? What is the throughput (in bits/second) at the Philadelphia receiver? What is the utilization of the DC-to-Philadelphia link?

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

78

1572 Introduction to OPNET Modeler

Node Modeling: Summary


Modules include processors, queues, transceivers, and antennas Modules are connected with packet streams and stat wires Node interfaces include
Icon to be used Mobility types (Fixed, mobile or satellite) Statistics to be promoted

Lab accomplishments
Built generator to send out packets (using simple_source model) Built receiver to accept and destroy packets (using sink model)

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

79

1572 Introduction to OPNET Modeler

Link Modeling: Agenda


Link Types Link Editor Lab: Create a Link Model

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

80

1572 Introduction to OPNET Modeler

Link Types
Link objects model physical layer effects between nodes, such as delays, noise, etc.
A point-to-point link transfers data between two fixed nodes.

A bus link transfers data among many nodes and is a shared media.

A radio link, established during a simulation, can be created between any radio transmitter-receiver channel pair. Satellite and mobile nodes must use radio links. Fixed nodes may use radio links. A radio link is not drawn but is established if nodes contain radio transceivers.

Radio link

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

81

1572 Introduction to OPNET Modeler

Link Editor
Create or modify links Choose link types Modify attributes

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

82

1572 Introduction to OPNET Modeler

Verify Links
Ensures that point-to-point and bus link connections are valid
Enough transmitters and receivers to support all of the incoming and outgoing links Data rates of the connected transmitter and receiver match the data rate of the link Transceivers support the attached link technology

It is always a good idea to use the Verify Links feature (Ctrl+L) before running a simulation to ensure connectivity

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

83

1572 Introduction to OPNET Modeler

Lab: Creating a Link Model


Create a custom link
Point-to-point Simplex or Duplex Data rate of 9600 bps

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

84

1572 Introduction to OPNET Modeler

Link Modeling: Summary


Link Types
Point-to-point Bus Radio

Created new link Verify Links

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

85

1572 Introduction to OPNET Modeler

Statistics: Agenda
Statistic Collection Configuring Simulations Viewing Results Lab: Complete Bank Model and Analyze Results

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

86

1572 Introduction to OPNET Modeler

Statistic Collection
Statistic Attributes Descriptions of Statistics Statistic Collection Modes

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

87

1572 Introduction to OPNET Modeler

Statistic Attributes
Right-clicking on a statistic while in the Choose Results dialog box presents a menu of statistic attributes

Statistic attributes include:


Record Statistic Animation Generate Live Statistic Change Collection Mode Change Draw Style

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

88

1572 Introduction to OPNET Modeler

Statistic Collection Modes


Normal mode: Every data point is collected from a statistic Sample mode: The data is collected according to a user-defined time interval or sample count Bucket mode: All the data points in a bucket are collected and processed according to a userdefined parameter
Max Min Sum Count Sample mean Time average

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

89

1572 Introduction to OPNET Modeler

Understanding Statistics
Define the goals of the study, and as a result, understand the statistics that should be collected to get useful results

Browse available statistics and view their descriptions Understand the default collection mode to help interpret results

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

90

1572 Introduction to OPNET Modeler

Configuring Simulations
Scenarios automatically provide a default duration and random number seed for simulations Users can set simulation attributes by choosing Configure Simulation from the Simulation menu, or by clicking on the running man icon:

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

91

1572 Introduction to OPNET Modeler

Running a Simulation
The Simulation Sequence window shows the progress of simulation Elapsed time bar displays the progress of the simulation
Appears after 1,000,000 events by default

Elapsed/Remaining Time: Real time elapsed and remaining time Simulation Time: Simulation time elapsed and number of events processed

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

92

1572 Introduction to OPNET Modeler

Viewing Results
Results can be displayed by:
Selecting the View Results button on the tool bar Selecting View Results from the Results menu Right-clicking the project workspace and selecting from the pop-up menu

View Results dialog box allows the user to select the results to display.
- Note: Only the statistics you chose for collection will be available

The Show button in the View Results dialog box displays a graph of the selected statistics

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

93

1572 Introduction to OPNET Modeler

Viewing Results (cont.)


Multiple graph panels can be displayed at the same time Each panel can contain one or more traces in an Overlaid or Stacked layout

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

94

1572 Introduction to OPNET Modeler

Lab: Creating a Network


Create a new project Place topology Choose Statistics Run Simulation Analyze Results

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

95

1572 Introduction to OPNET Modeler

Checking Our Predictions


Compare actual results to expected output Explain any differences Modify your model as necessary

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

96

1572 Introduction to OPNET Modeler

Modeling Traffic
Three traffic types
Explicit/Discrete (modeled packet-by-packet) Flows (modeled analytically using source-to-destination pairs) Loads (modeled analytically using a background load on a link)

All three types can be combined to create a Hybrid Simulation

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

97

1572 Introduction to OPNET Modeler

Application Characterization Environment (ACE)


Module allows users to model their own custom networked applications Import real-world data Visualize performance Diagnose performance problems Simulate in OPNET environment to explore solutions

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

98

1572 Introduction to OPNET Modeler

Running a Simulation: Summary


Understand Available Statistics Choose Statistics to Collect During Simulation Configure Simulation Options Run Simulation View Results

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

99

1572 Introduction to OPNET Modeler

Multiple Simulation Runs: Agenda


Benefits of Multiple Simulations Runs Random Seeds vs. Expectation Confidence Intervals Lab: Using Multiple Random Seeds

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

100

1572 Introduction to OPNET Modeler

Benefits of Multiple Simulations Runs


Model Accuracy
Stochastic simulation results in richer data which takes into account varying parameters

Save Man Hours


Multiple simulations can be run concurrently which gets results in a shorter amount of time

Leverage Available Resources


Available processing resources can be utilized to run multiple simulations

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

101

1572 Introduction to OPNET Modeler

Importance of Multiple Simulations Runs


Many simulations rely on stochastic modeling of certain elements Usually characterized by associating probabilities with a set of outcomes
Traffic loads Deference processes Generation and placement of bit errors

Each time the simulation is run


The network topology and configuration remain the same Outcome of random variables differ Statistic results are unique for different outcomes

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

102

1572 Introduction to OPNET Modeler

Random Seeds vs. Expectation


Stochastically modeled elements depend on a random number source on which to base their behavior. By "drawing" from the source, these elements can incorporate variability into appropriate actions or decisions as they are taken. Changing the random seed changes the outcomes that are drawn from this source of random numbers.

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

103

1572 Introduction to OPNET Modeler

Confidence Intervals
Used to indicate the reliability of an estimate, based on a trial or series of random trials Determines whether the values collected can be used with confidence to make statements about the typical behavior of the modeled system Example: With probability 0.95 one will find the parameter x between a pair of stochastic endpoints

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

104

1572 Introduction to OPNET Modeler

Multiple Simulations in OPNET


Sequentially
Single runtime license

Parallel
In parallel on the same machine requiring a single runtime license Models must be properly codified for parallel simulation

Distributed
Multiple simulations automatically distributed to other machines using multiple runtime licenses or a site license

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

105

1572 Introduction to OPNET Modeler

Lab: Using Multiple Random Seeds


At this point, the simulation has been run a single time We will now run a series of simulations using a different random seed for each run

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

106

1572 Introduction to OPNET Modeler

Lab Summary

10 Simulation runs Previously link utilization plotted w.r.t. time Mean of link utilization plotted w.r.t. random seed

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

107

1572 Introduction to OPNET Modeler

Process Modeling: Agenda


Process Models Process Editor
State Transitions Executive Blocks

Kernel Procedures Examine acb_fifo Lab: Modify a Process Model

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

108

1572 Introduction to OPNET Modeler

Process Models
Process models represent algorithms
Communications protocols and algorithms Shared-resource managers Queuing disciplines Specialized traffic generators Statistic-collection mechanisms Control Processes

Process Editor provides the features for creating process models

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

109

1572 Introduction to OPNET Modeler

Process Editor

Toolbar Buttons:
1 2 3 4 5 6 7 8 9 10

1. Create state 2. Create transition 3. Set initial state 4. Edit state variable 5. Edit temporary variable 6. Edit header block 7. Edit function block 8. Edit diagnostic block 9. Edit termination block 10. Compile process model

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

110

1572 Introduction to OPNET Modeler

State Transitions
Transitions connect states
Conditional Unconditional

Exactly one condition must evaluate to true If the condition statement (x == y) is true, the transition executive (Reset_Timers) is invoked

Condition statement

Transition executive

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

111

1572 Introduction to OPNET Modeler

State Executive Blocks


Each state has two executive blocks
Enter executives are invoked upon entering a state Exit executives are invoked before exiting a state

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

112

1572 Introduction to OPNET Modeler

Introduction to Kernel Procedures


Pre-written functions for difficult, tedious, or common operations KPs free users from addressing memory management, data structure, handling event processing, etc. KPs focus on communication modeling All KPs begin with prefix op_

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

113

1572 Introduction to OPNET Modeler

Common Kernel Procedures

Packet Package: op_pk_create () op_pk_create_fmt () op_pk_copy () op_pk_get () op_pk_total_size_get () op_pk_nfd_set () op_pk_nfd_get () op_pk_send () op_pk_send_delayed () op_pk_destroy ()

Subq Package: op_subq_pk_insert () op_subq_pk_remove ()

Interrupt Package: op_intrpt_schedule_self () op_intrpt_type () op_intrpt_strm () op_intrpt_code () Simulation and Event Packages: op_ev_cancel () op_sim_time ()

Distribution Package: op_dist_load () op_dist_outcome ()

ID, Topo and Internal Model Access Packages: op_id_self () op_topo_parent () op_topo_child () op_ima_obj_attr_get ()

Naming convention for Kernel Procedures op_<family name describing object >_<action>

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

114

1572 Introduction to OPNET Modeler

Kernel Procedures Help


From the Help menu, select Online Documentation, and refer to the Simulation Kernel manual
Divided into sections by KP family Animation Packets Statistics Events Each KP described in several paragraphs, including Purpose Syntax Example

When in the Process Editor:


Press <Control> + <h> to view Essential Kernel Procedures Press <Control> + <Shift> + <h> to view All Kernel Procedures
CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

115

1572 Introduction to OPNET Modeler

Proto-C
State transition diagrams C programming language Library of OPNET Kernel Procedures (KPs) State variables (private to each process) Temporary variables

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

116

1572 Introduction to OPNET Modeler

Example Process Model: acb_fifo


Queue process model Characteristics
Has a service rate, in bits/sec FIFO queue

Active Concentrating Bit-oriented First In First Out queue


Active: Has a processor Concentrating: Will take from many input streams and output to only one stream Bit-oriented: Delay is based on number of bits processed

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

117

1572 Introduction to OPNET Modeler

acb_fifo: State Overview


Purpose of each state
init initializes state variables arrival queues packets svc_start calculates when the packet can be sent svc_compl sends the packet idle is the wait state

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

118

1572 Introduction to OPNET Modeler

acb_fifo: idle State


Packet arrival
Packet is queued in arrival To svc_start if not busy Back to idle if busy

Service completion
Sends queued packet in svc_compl To svc_start if queue nonempty Back to idle if queue empty

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

119

1572 Introduction to OPNET Modeler

acb_fifo: arrival State


Gets the incoming packet Tries to queue packet Destroys packet if queue is full

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

120

1572 Introduction to OPNET Modeler

acb_fifo: svc_start State


Begins servicing the packet Schedules an interrupt for service completion

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

121

1572 Introduction to OPNET Modeler

acb_fifo: svc_compl State


Sends the serviced packet Receiving module will get control immediately

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

122

1572 Introduction to OPNET Modeler

Lab: Expand the Network


The banks network has expanded to four source nodes, 12 switch nodes, and three destination nodes New switch model needed with four inputs and two outputs This switch takes an input from any input port and sends it to a random output port

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

123

1572 Introduction to OPNET Modeler

Process Modeling: Summary


Process models
Finite state machines Proto-C acb_fifo

Kernel Procedures

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

124

1572 Introduction to OPNET Modeler

Lab Description
Uses the project bank_net, to model changes in the transaction rate and measure the effects of those changes Create modified sink process model to compute ETE delay
Get the packet Obtain the creation time Write out its ETE delay as a global statistic Destroy the packet

Incorporate new sink process model into existing node model Create ETE delay statistic probe Run simulation Filter the View Results graphs to answer questions

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

125

1572 Introduction to OPNET Modeler

Lab Description
Provide answers to the banks CIO
What is the average end-to-end delay (ETE delay) for all transactions when the generation rate is 0.4 seconds/transaction (or 2.5 transactions/second)? For this generation rate, what percentage of the packets incurred an ETE delay of less than 1 second?

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

126

1572 Introduction to OPNET Modeler

Analyzing and Publishing : Agenda


Collecting Statistics Configuring Simulations Exporting Statistic Data Web Reports

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

127

1572 Introduction to OPNET Modeler

Probe Editor
In previous chapters, statistics were selected and results collected in the Project Editor The Probe Editor enables you to configure where information is collected and what statistics are measured You can save collections of probes to a file for use in different scenarios

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

128

1572 Introduction to OPNET Modeler

Probe Editor
1 2 3 4 5 6 7 8 9 10 11

Toolbar
1. Global Statistic Probe 2. Node Statistic Probe 3. Link Statistic Probe 4. Path Statistic Probe 5. Demand Statistic Probe 6. Coupled Statistic Probe 7. Attribute Probe 8. Automatic Animation Probe 9. Statistic Animation Probe 10. Custom Animation Probe 11. Live Statistic Probe

Probe Workspace

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

129

1572 Introduction to OPNET Modeler

Exporting Data
Export collected statistics to a text file or spreadsheet Spreadsheet application can be specified If no spreadsheet application is specified the data is written to an ASCII file

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

130

1572 Introduction to OPNET Modeler

Exporting Data Spreadsheets

Right-click inside graph on desired panel Select Export Graph Data to Spreadsheet Modeler launches the appropriate program with data
131

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

1572 Introduction to OPNET Modeler

Generating Web Reports


Web Reports contain data and statistic graphics Can be created after a simulation has run Created in op_admin folder

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

132

1572 Introduction to OPNET Modeler

Why Use Web Reports?


Allows results to be shared with non OPNET-users Automatically generated and present data in a manner that is easy to use, navigate, and interpret Include a simple text summary consisting of information about SLA violations, and top-most utilized links, nodes, etc.

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

133

1572 Introduction to OPNET Modeler

How to Generate Web Reports


After running a simulation, select Generate Web Report from the Results menu

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

134

1572 Introduction to OPNET Modeler

Web Topology Export


Export network topology and configuration to HTML Under the Scenario menu, select Generate Scenario Web Report

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

135

1572 Introduction to OPNET Modeler

Analyzing and Publishing: Summary


Probe Editor Exporting data Topology and data export to HTML

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

136

1572 Introduction to OPNET Modeler

Wrap-Up Section: Agenda


Model Library Traffic Types Application Characterization Environment (ACE) Wireless Module Terrain Modeling Module

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

137

1572 Introduction to OPNET Modeler

Model Library
Extensive library of standards-based and vendor models OPNETs Model Research and Development division designs, develops, and maintains the model library Models are created using published standards and widely-used vendor implementations
IEEE Specifications (e.g., 802.1q, 802.3, 802.11, etc.) ANSI Standards (e.g., X3.139, T1.513, etc.) ATM Forum Specifications (e.g, UNI 3.1, TM 4.0, etc.) RFC Documents (e.g., RFC-793, RFC-1058, RFC-1771, etc.) Vendor Technologies (e.g., VLAN tagging, EIGRP, etc.)

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

138

1572 Introduction to OPNET Modeler

Model Library Components


Traffic sources and sinks (workstations, servers, stations, etc.) Network devices (hubs, bridges, switches, routers, etc.) Links (SONET, PPP, FDDI, 10BaseT, ISDN, xDSL, etc.) Vendor device models (Cisco Systems, 3Com, Juniper, Lucent, HP, etc.)

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

139

1572 Introduction to OPNET Modeler

Available Models
Standard Models
Essential models that support the majority of OPNET users Generic Vendor (Cisco, Lucent, Marconi, etc.)

Specialized Models
Models of interest to more focused communities within the OPNET user base They are available on a fee/license basis Current specialized models include UMTS DOCSIS IPv6 Circuit Switching MPLS PNNI
CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

140

1572 Introduction to OPNET Modeler

Modeler Wireless
Wireless nodes and protocols Node mobility
Trajectory Orbit (for satellite nodes)

RF effects Terrain Effects Modeler Wireless for Defense also includes:


3D Network Visualizer HLA TIREM propagation models

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

141

1572 Introduction to OPNET Modeler

OPNET Development Kit (ODK)


Accelerate OPNET Modeler Projects Key application areas:
Build network topologies programmatically Construct custom workflows to facilitate model configuration Customize network visualization Create custom workflows to selectively enable Modeler functionality

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

142

1572 Introduction to OPNET Modeler

ODK Overview
C/C++ APIs Highlights
Custom Network data import/export OPNET Advanced Graphical Interface Wizard-driven topology creation and configuration Custom Visualization Report generation and export

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

143

1572 Introduction to OPNET Modeler

Programmatically Build Network Topologies

ODK enables a user to develop custom mechanisms for importing topology, traffic and configuration data from text files, databases, spreadsheets, etc.

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

144

1572 Introduction to OPNET Modeler

Construct Custom Workflows


Use ODKs dialog box editor and APIs to construct workflows that simplify the configuration process Example uses of ODK in IT Guru, SP Guru, and Modeler products
Create DES Application Demands Configure Routing Protocols Configure VLANS for Selected Nodes Active Attributes

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

145

1572 Introduction to OPNET Modeler

Custom Network Visualizations


ODK can be used to define custom visualizations to provide a quick top level view of network configuration

Color Links by Utilization Visualize IP Routing Protocols

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

146

1572 Introduction to OPNET Modeler

Create Custom Workflows Using a Limited GUI


Tailor the UI to narrow access to required features, and customize workflows to support the target use cases Customized network management applications
Slimmed down version of Modeler

Example uses Spectral optical design solution


Many consulting projects

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

147

1572 Introduction to OPNET Modeler

Questions

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

148

1572 Introduction to OPNET Modeler

OPNET Web Site


http://www.opnet.com Services
Training Consulting

Support Center
FAQs Licenses Mailing List Contributed models and papers Updates (software, models, documentation) Tech Support Login assistance

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

149

1572 Introduction to OPNET Modeler

Documentation References
Modeler Tutorials Model User Guides Methodologies and Case Studies FAQs on www.opnet.com
78: How can I map more than one dimension into the code in op_intrpt_schedule_self ()? 166: What mechanisms can be used by the model developer to share data among processes without using invocations or interrupts? 182: How do I get the beginsim intrpt attribute enabled? 1091: How do I track what line of code is causing a syntax error and/or other compilation errors? 1209: How can I generate distribution outcomes from my own function instead of standard distributions or an external file? Many many others (over 1400 FAQs)

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

150

1572 Introduction to OPNET Modeler

Related OPNETWORK Sessions


Recommended OPNETWORK sessions
1574: Modeling and Simulation Using Advanced Modeler Features 1432: Modeling Applications with the ACE Whiteboard Model usage sessions (ATM, TCP, etc.) Process Modeling 1502: Debugging Simulation Models Intro 1503: Debugging Simulation Models Advanced 1501: Process Modeling Methodology/Dynamic Processes 1505: Building Traffic Source Models Wireless 1530: Modeling Custom Wireless Effects 1527: Accelerating Wireless Simulations Using Scalability Techniques

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

151

1572 Introduction to OPNET Modeler

Take-Away Points
OPNET simulations are event driven OPNET modeling hierarchy
Network Node Process

Model design is modular Results can be displayed in many ways Almost everything can be customized to fit your needs

CONFIDENTIAL RESTRICTED ACCESS: This information may not be disclosed, copied, or transmitted in any format without the prior written consent of OPNET Technologies, Inc. 2008 OPNET Technologies, Inc.

152

S-ar putea să vă placă și