Escolar Documentos
Profissional Documentos
Cultura Documentos
Use a new type of link, the radio link, and a new type of node, the mobile
node
Use the time controller to step through time values and relate node
positions and results
Key ConceptWith Wireless functionality, you can model both terrestrial and
satellite radio systems. In this tutorial, you will use OPNET Modeler and
Wireless modeling to create a radio network; you will also observe variations in
the quality of received signal that results from radio noise at the receiving node
in a dynamic network topology.
In this lesson, you will design a simple radio network with a mobile jammer node
and two stationary communications nodes, then demonstrate the differences in
the SNR of the network when the stationary nodes use an isotropic antenna
versus a directional antenna.
Getting Started
The network topology consists of three nodes:
The receiver node measures the quality of the signal emitted by the
stationary transmitter node. It consists of an antenna module, a radio
receiver module, a sink processor module, and an additional processor
module that works with the directional antenna.
The mobile jammer node creates radio noise. The jammers trajectory
takes it in and out of the radio range of the receiver node, increasing and
decreasing interference at the receiver.
Key ConceptTo create node models for each of the network objects, you will
use several modules unique to the Wireless functionality (an antenna module
to model directional gain, a radio transmitter module, and a radio receiver
module), in addition to the processor module.
Antenna patterns are divided into segments for values of the spherical angles
polar and azimuth. The values of polar represent horizontal two-dimensional
(2D) slices (or planes) of the antenna pattern. For each slice, gain values are
specified at regular azimuth intervals around the slice, thus defining the
antenna pattern in that horizontal plane. The three-dimensional (3D) antenna
pattern is represented as a collection of 2D slices.
z polar
gain at polar,azimuth
azimuth
x
Each slice is shown in a graph panel in which sample points specify gain values
for varying degrees of azimuth. You use the polar plane menu to select which
2D slice, or value of polar, is displayed for editing.
For this lesson, you will create a new antenna pattern, one with a gain of about
200 dB in one direction and a gain of about 0 dB in all other directions (a very
directional antenna).
Procedure 5-1
1 Choose File > New and select Antenna Pattern from the pull-down list. Click
OK.
graph panel
For this tutorial, you can use the default number of azimuth divisions (72), so
the largest value of azimuth that has a sample point is 355 degrees. You can
specify sample points with gain equal to about 200 dB for values of azimuth
from 0 to 355 degrees. Specifying any two sample points in the graph panel
automatically sets all sample points in between with linearly-interpolated gain
values. Therefore, you need to specify only two sample points in this plane: one
at 0 degrees and one at 355 degrees.
To adjust the current polar plane to 5 degrees (360/72), perform the following
procedure.
Procedure 5-2
The graph panel displays the curve for the 5-degree polar plane.
2 In the dialog box, enter 201 as the Ordinate Upper Bound and click OK.
4 In the dialog box, enter 199 as the Ordinate Lower Bound and click OK.
The graph panel displays the new ordinate range. This range will make it easier
to enter the desired gain accurately.
Now that you have set the graph panel, specify sample points for polar = 5
degrees, as follows:
Procedure 5-4
1 Move the cursor as close to the 200 dB line as possible and left-click on the first
sample point (0 degrees) in the graph. Move the cursor to the far right (still on the
200 dB line) and left-click on the second point (355 degrees).
All sample points between the two specified points are set automatically with
linearly interpolated gain values. A dotted line marks the range of sample points.
When you define points in the graph panel, the 3D projection view displays a
cone-shaped shell of gain values for phi = 5 degrees to phi = 10 degrees and
for theta = 0 degrees to theta = 360 degrees.
Now that you have specified the gain values for polar = 5 degrees, you need to
set the gain and sample points for the polar = 0 plane. Doing so specifies a gain
of about 200 dB for polar = 05 degrees and for azimuth = 0360 degrees.
This fills in the cone-shaped shell specified in the polar = 5 degrees plane.
Procedure 5-5
1 Press Ctrl-[up arrow] (or, choose Antenna > Decrease Polar Plane).
2 Verify that the Ordinate Upper Bound is 201 and the Ordinate Lower Bound is
199.
3 Move the cursor as close to the 200 dB line as possible and left-click on the first
sample point (0 degrees) in the graph. Move the cursor to the far right (still on the
200 dB line) and left-click on the second point (355 degrees).
Procedure 5-6
1 Click the Normalize the Function tool button to normalize the 3D gain function
over the entire pattern.
Normalization shifts the points in the graph upward, so they might disappear from
view.
2 Choose File > Save. Name the antenna pattern <initials>_mrt_cone, and then
save.
Procedure 5-7
1 Choose File > New and select Process Model from the pull-down list, then click
OK.
2 Using the Create State tool button, place one state in the workspace.
3 Right-click on the state and select Set Name from the Object pop-up menu.
The process model determines the identities of the objects of interest, then
retrieves and modifies the receiver objects attribute values. Kernel Procedures
in the Identification and Topology Packages (prefixed with op_id and op_topo)
do the first task. A Kernel Procedure from the Ima Package (with the prefix
op_ima) does the second task.
1 Double-click on the top half of the point state to open the Enter Executives block.
2 Choose File > Import Select the file listed below, then click the Import button to
import it (OK on Linux platforms).
<reldir>\models\std\tutorial_req\
modeler\mrt_ex
Procedure 5-10
2 Find closure_support in the list of available files and select its checkbox, then click
OK.
1 Left-click on the Compile Process Model tool button. When you are prompted to
save the model, name it <initials>_mrt_rx_point and click Save.
If the model does not compile, see the Troubleshooting chapter in the Modeling
Concepts manual.
2 After the process model has compiled, close the Compilation dialog box and the
Process Editor.
After they are generated, packets move through a packet stream to the radio
transmitter module, which transmits the packets on a channel at
1024 bits/second using 100 percent of the channel bandwidth. The packets then
pass from the transmitter through another packet stream to the antenna module.
The antenna module uses an isotropic antenna pattern (this is the default value)
to apply a transmission gain that is uniform in all directions.
The following procedure describes how to create the transmitter node model.
1 Choose File > New, select Node Model from the pull-down list, and click OK.
2 Create the modules and packet streams as shown, and name the nodes
accordingly. Use the Create Processor, Create Radio Transmitter, Create
Antenna, and Create Packet Stream tool buttons.
To run parameterized simulations, you must promote the power attribute of the
utilized channel. When you promote the attribute, it can be changed easily at
simulation run time.
Procedure 5-13
1 Right-click on the radio_tx node and select Edit Attributes from the pop-up menu.
A dialog box displays showing the Compound Attribute Table for channel.
3 In the Compound Attribute Table for channel, promote the power attribute by
selecting its value and clicking on the Promote button.
Procedure 5-14
2 In the Node types table, change the Supported value to no for the mobile and
satellite types.
3 Except for the promoted radio_tx.channel [0].power attribute, change the Status
of all attributes to hidden.
6 Choose File > Save and save the node model as <initials>_mrt_tx.
Procedure 5-15
2 Right-click on the radio_tx object and select Edit Attributes from the pop-up
menu. Change the modulation attribute to jammod.
4 Choose Interfaces > Node Interfaces, then perform the following steps:
4.1 Change the Supported value to yes for mobile type and no for fixed type.
Procedure 5-16
2 Create the modules and packet streams as shown in the next figure; set node
names accordingly.
Make sure the antenna module has the name ant_rx. This name is referenced by
the <initials>_mrt_rx_point process model.
Procedure 5-17
1 Right-click on rx_point and open its attribute dialog box. Set the value of the
process model attribute to <initials>_mrt_rx_point, and then click OK to close
the dialog box.
2 Right-click on radio_rx and open its attribute dialog box. Set the value of the error
model attribute to dra_error_all_stats, and then click OK to close the dialog box.
3 Right-click on ant_rx and open its attribute dialog box. Right-click on pattern in the
Attribute column and select Promote Attribute to Higher Level from the pop-up
menu.
Next, define the node model interface attributes, as described in the following
procedure.
2 In the Node types table, change the Supported value to no for the mobile and
satellite type.
3 Except for the promoted ant_rx.pattern attribute, change the Status of all
attributes to hidden.
5 Choose File > Save As and save the node model as <initials>_mrt_rx.
Procedure 5-19
1 Choose File > New and select Project from the list of options, then click OK.
3 In the Startup Wizard, use the settings listed in the following table.
4 Open the object palette (if necessary), then switch to the icon view by clicking on
the button in the upper-left corner of the dialog box.
5 Next, click on Configure Palette..., clear the palette, and click the Node Models
button. Add the <initials>_mrt_jam, <initials>_mrt_rx, and <initials>_mrt_tx
node models to the palette. Save the palette as <initials>_mrt_palette.
7 Build the network shown below. The nodes positions will be specified precisely
later, so you just need to place the appropriate nodes for now.
<initials>_mrt_jam
model <initials>_mrt_rx
<initials>_mrt_tx model
model
9.1 Right-click on the node and choose Edit Attribute (Advanced) from the
nodes submenu to view the advanced attributes dialog box.
9.2 Edit the name attribute and the x position and y position attributes for each
node, as listed in the following table.
node_0 rx 4, 2
node_1 tx 3, 2
Make sure you rename the transmitter node (node_1) to tx. This name is
referenced by the <initials>_mrt_rx_point process model.
The relative position of nodes plays an important role in the behavior of wireless
communications. To get the expected results, make sure you place the nodes
exactly as specified.
Key ConceptTo specify node movement, the node model uses an attribute
called trajectory. The value of this attribute is the name of an ASCII text file that
is created in the Project Editor. The file contains data specifying times and
locations that the mobile node will pass through as the simulation progresses.
Now that the network model has been defined, you must specify a trajectory for
the mobile jamming node to follow.
Procedure 5-20
When you click on the Define Path button in the Define Trajectory dialog box, the
dialog box closes; next, the Trajectory Status dialog box displays and your cursor
changes to a line in the Project Editor.
You can specify the traversal information for a segment either as an explicit
duration or based on a specified speed:
Procedure 5-21
1 Move the cursor over the jam node. When the X/Y position in the Trajectory Status
dialog box is equal to 0.5 km/1.5 km, left-click to begin the trajectory.
2 You can zoom in and out or scroll around while defining a trajectory, which helps
for more precise layouts:
NoteIf necessary, you can edit the trajectory file for exact precision.
3 Left-click on the grid when the Trajectory Status dialog box shows X/Y position of
3.5 km and 1.5 km, and the Current segments Length is as close to 3000 m as
possible.
5 Left-click when the X/Y Position is at 3.5km/2.5km and the Current segments
length is about 1000m.
6 Click on Continue to draw the third and last segment of the trajectory.
7 Left-click when the X/Y Position is at 6.5km/2.5km and the Current segments
length is about 3000m. Note that you will probably need to scroll the network view
horizontally.
8 Click on Complete to finish the trajectory definition. This closes the Trajectory
Status and Segment Information dialog boxes.
The trajectory disappears from the screen because it has not yet been
referenced by a mobile node.
You need to assign this trajectory to the jammer in the following steps:
9 Click on the Zoom to Previous tool button to reset the network zoom level.
16 Review the X Pos, Y Pos, and Ground Speed values for each row, as listed in the
following table.
17 Click OK to close the dialog box and to overwrite the existing file if you made any
changes.
You can gather the radio receiver channel statistics for this simulation in the
Project Editor. These statistics include the bit error rate (BER) and throughput
in packets/sec. The packet throughput statistic indicates the average number of
packets the receiver channel successfully received per second. New samples
of this statistic are only generated for packets with BER lower than the receiver
ECC threshold, as specified at the node level in the radio receiver modules ecc
threshold attribute.
Because the radio receiver module used in this tutorial has a value of 0.0
errors/bit for this attribute, only packets that have no bit errors will be accepted.
Key ConceptYou can change the collection mode for different statistics.
These modes specify the way in which statistics are captured (all values,
bucket, sample, glitch removal).
To collect the bit error rate and throughput statistics, perform the following
procedure.
1 Right-click on the rx node object and select Choose Individual DES Statistics
from the rx pop-up menu.
2 Expand the Module Statistics > radio_rx.channel [0] > radio receiver tree.
The right side of the dialog box fills up with information associated with the
statistic.
4 Click the Modify button to the right of the Collection mode information. You can
also right-click on the bit error rate statistic and choose Change Collection Mode
from the pop-up menu.
The new collection mode is shown in the Statistics information area of the
Choose Results dialog box.
To set the collection mode for the throughput statistic, perform the following
procedure.
Procedure 5-23 Setting the collection mode for the throughput statistic
3 Verify that Capture mode is set to bucket, and the Bucket mode is set to
sum/time.
4 Select the Everyseconds radio button and set the sample frequency to 10
seconds.
6 Click OK to close the Capture Mode dialog box, then click OK again to close the
Choose Results dialog box.
Learn about different types of statistics, including some that are not available
in the Project Editor
Key ConceptFor this lesson, you will use the Probe Editor to collect
received power coupled statistics.
So far you have already set up two statistic probes via the Project Editor: bit
error rate and throughput (packets/sec). The Choose Individual DES
Statistics right-click menus provide a simple graphical interface to the
underlying Probe file that stores the defined statistics.
Procedure 5-24
The Probe Editor opens with the probe file of the current scenario in the Project
Editor.
2 Right-click on the pb0 node statistic and select Edit Attributes to display the
probes Attributes dialog box.
3 When you are done reviewing the attribute values, click Cancel to close the dialog
box.
A node statistics probe will collect all the values written to the specified statistics.
But in the case of wireless communication, it is possible to further restrict the
amount of collected data based on the origin of that data. To do so, you use a
Coupled Node Statistic probe. This probe defines both the node where the
statistic is collected and an associated transmitter or receiver node. Only data
resulting from an exchange between the two nodes of the statistic will be
recorded.
In this session, you are going to collect the respective contributions of the
jammer and transmitter nodes to the received power at the receiver
First set up a Coupled Node Statistic probe between transmitter and receiver,
as described in the following procedure.
1 Click the Create Coupled Node Statistic Probe button and a probe appears
below Coupled Node Statistic Probes in the workspace.
2 Right-click on the new Coupled Node Statistic probe and select Choose Probed
Object.
The Choose Probed Object dialog box opens, showing you the current subnet.
The node model content is shown on the right, with the selected module
highlighted.
The Choose Probed Object dialog box closes, and the selected object is shown
in the probe.
6 Right-click on the Coupled Node Statistics probe and select Choose Coupled
Object.
8 Right-click on the Coupled Node Statistics probe and select Edit Attributes.
This dialog box shows the statistic and the group it belongs to (group.statistic), the
statistics dimension (if any), and a description.
Only statistics that can be probed by a Coupled Node Statistics probe appear in
this list.
11 Select radio receiver.received power (W) from the list and click OK.
In the Edit Attributes dialog box, the group attribute changes to radio receiver
and the statistic attribute changes to received power (W).
Next, you need to create a similar probe between the receiver and the jammer.
Procedure 5-26
2 Choose Edit > Copy, then Edit > Paste to duplicate the probe.
3 Right-click on the newly created probe and select Choose Coupled Object.
Now that you have set up the probes correctly to collect the desired statistics,
save the probe file:
Procedure 5-27
Procedure 5-28
1.2 Type network sim in the Search for: field and click Find.
1.3 Verify the Value cell shows (). Delete any other entry.
1 Click on the Inputs tree node, the Object Attributes node, and then on the Add
button to display the Add Attributes dialog box.
2 Click in the Add column for all three of the unresolved attributes, and then click OK.
These are the attributes that you promoted in the Node Editor. Because you did
not assign values when you promoted the attributes, you must assign them now.
Note that the attributes now appear in the Attributes table, but they lack values.
Add the values for the ant_rx.pattern attribute (if necessary, drag the column
divider to expand the Attribute column and show the full attribute names).
Procedure 5-30
3 In the attribute dialog box, click in the Value cell and select isotropic. Move down
to the next row, click again, and select <initials>_mrt_cone. Click OK.
Procedure 5-31
Note that the Number of runs is now 2. This is because the ant_rx.pattern
attribute now has two possible values, so that two separate simulations will run
using a different value for this attribute for each simulation.
Change the Seed and Duration settings for this simulation, as described in the
following procedure.
Procedure 5-32
5 When you are finished making changes in the Configure/Run DES dialog box, click
Run.
The DES Execution Manager dialog box appears and the first simulation run is
launched.
6 When both simulations are complete, close the DES Execution Manager dialog
box. If you had problems, see Troubleshooting Tutorials.
Tabular Statistics
To gain a high-level understanding of network behavior for each type of
antenna, you can look at the Global Packet Statistics report for each simulation
run. These reports contain the number of packets created, copied, and
destroyed, broken down by node, module, and packet format.
The reports are found in the Results Browser under two tabs named DES Run
(<run_number>) Tables. Run 1 contains results for the isotropic antenna case
and run 2 contains results for the directional antenna case.
Use the Global Packet Statistics reports to examine overall packet activity
during the simulation.
Procedure 5-33
1 In the Project Editor, right-click in the workspace and choose View Results from
the pop-up menu.
3 Expand the Report: Packet Info tree node until the node-centric packet statistics
are visible, then select Number of Packets Created.
There were 1,420 packets created during the simulation. The transmitter and
jammer nodes each create one packet per second, from simulation time
10 seconds to 12 minutes; thus, each creates (12 x 60) - 10 = 710 packets, as
shown in the table.
The table shows that the receiver node destroyed 1,418 packets during the
simulation (all but the last packet from each of the transmitter and jammer
nodes, which are still enroute at the end of simulation).
A new window opens with a table showing how many packets were destroyed in
each module of the receiver node.
The radio_rx module destroyed packets that were blocked by interference from
the jammer. The successfully received packets were destroyed in the rx_sink
module. Notice that, for the isotropic antenna used in this simulation, almost all
packets were blocked.
7 Click the DES Run (2) Tables tab and expand the Report: Packet Info tree node
until the node-centric packet statistics are visible.
8 Select Number of Packets Created to verify that Run 2 created the same number
of packets as did Run 1.
9 Select Number of Packets Destroyed and drill down to the module statistics for
the receiver node, as you did for Run 1.
The same number of packets were destroyed in Run 2, but many more (almost
half) were successfully received with the directional antenna.
Graphical Statistics
Now that you have seen the effect of different antennas on packet reception
statistics, check the bit error rate and packet throughput results.
Procedure 5-34
2 In the source treeview, expand the antenna_test node to show the two simulation
runs.
These results correspond to the two simulationsone for the isotropic antenna
pattern and one for the directional antenna pattern.
3 Verify that the checkbox for run 1 is selected and unselect the checkbox for run 2
to restrict data to the first (isotropic antenna) run.
4 In the results (bottom) treeview, expand the Object Statistics > Campus Network
> rx > radio_rx > channel [0] > radio_receiver tree to view the full hierarchy of
available statistics for that simulation run.
5 Select the checkboxes next to bit error rate, throughput (packets/sec), and both
received power coupled statistics, then click the Show button. Move the graph off
to the side.
The graphs show the bit error rate, throughput, and received power statistics for
the isotropic antenna.
Figure 5-33 Bit Error Rate, Throughput, and Received Power Coupled
Statistics of the Isotropic Antenna
As expected, the graph for the isotropic antenna pattern shows that the bit error
rate at the receiver node gradually increased as the distance between the jammer
and receiver nodes decreases, and vice-versa.
The bit error rate reaches a maximum of about 0.35 errors/bit when the distance
between the jammer and the receiver is smallest. The isotropic receiver antenna
receives jammer interference during the entire simulation.
The two humps match the two locations when the jammer is closest to the
receiver.
The received power from the transmitter is constant, which is expected since both
transmitter and receiver are fixed nodes. The received power from the jammer
follows a similar pattern as the bit error rate.
The previously selected statistics are now showing the data from run 2.
The results for the directional antenna that follow are highly dependent on the
antenna gain. If your results do not match those shown here, it is probably due to
small variations in the defined gain.
The graphs show the bit error rate, throughput, and received power statistics for
the directional antenna.
Figure 5-35 Bit Error Rate, Throughput, and Received Power Coupled
Statistics of the Directional Antenna
The bit error rate graph from the directional antenna also reveals that the bit error
rate at the receiver node is non-zero initially as the distance between the jammer
node and receiver node decreases.
However, after about 1 minute, the direction vector between the jammer antenna
and the receiver antenna was no longer in line with the direction of greatest gain
for the receiver antenna. Therefore, the receiver node stopped receiving
interference from the jammer node and the bit error rate at the receiver dropped to
0. This drop dramatically increased the number of packets received from the
stationary transmitter node (as will be seen in the next graphs).
After about 6 minutes, the jammer comes back into the antennas cone, at which
point the bit error rate increases and the number of packets received first drops (as
the jammer approaches the receiver), then increases again (as the jammer moves
away). Once the jammer leaves the antennas cone, the bit error rate drops back
to 0.
Once again, the received power of the jammer matches the bit error rate pattern.
The very large power values from transmitter and jammer are due to the unrealistic
200dB gain provided by the antenna pattern.
3 Click the Play ( ) button to have the time controller iterate through the time
range. At each step, the jammer node is positioned accordingly along its trajectory
and a green vertical line indicates the current time in the graph window.
Key ConceptYou can manually change the current time by entering a value in
the time controllers Current time field.
Procedure 5-36
1 Manually slide the time value to check the position of the jammer for the double
humps and the dip for the isotropic antenna, or the spike in the directional antenna.
If you installed other modules, return to the main tutorial menu and continue with
the tutorials.