Performance Simulation of Multihop Routing Algorithms for Add-Hoc Wireless Sensor Networks Using TOSSIM

elfinoverwroughtΔίκτυα και Επικοινωνίες

18 Ιουλ 2012 (πριν από 4 χρόνια και 9 μήνες)

633 εμφανίσεις

Performance Simulation of Multihop Routing
Algorithms for Ad-Hoc Wireless Sensor Networks

Shailesh A Notani
Delphi Corp., Bangalore - 560066, INDIA

Abstract — The efficiency of the ad-hoc wireless sensor
networks (WSNs) largely depend upon the routing algorithm
employed. A large number of new routing protocols (Table Driven,
Demand Driven and Hybrid) have also been developed. This paper
analyzes the performance of Destination-Sequenced Distance-
Vector (DSDV) routing protocol (Table Driven) and the Ad-Hoc
On-Demand Distance Vector (AODV) routing protocol (Demand
Driven) for mobile and stationary environments. The metrics -
Packet delivery ratio (PDR), End-to-End Delay and Routing
Overhead are measured by varying the number of nodes and the
traffic load. TOSSIM is used for accurate simulation studies with
30 nodes in many-to-one routing configuration.
Keywords — Ad Hoc, Wireless Sensor Networks, Network
Management, Performance Evaluation, Routing Protocols, AODV,
1. Introduction

The wireless sensor networks are infrastructure-less
networks. This is due to their dynamically variable but limited
communication range and their mobility. Here, every node does
not necessarily come into others communication range and
every node does not need to perform administrative actions.
These nodes dynamically connect to each other in an arbitrary
way. Each node not only transmits its data but also routes
packets (broadcast, multicast or combination of both) from
other nodes in the network to destination which might not be in
its direct transmission range. The nodes participate in an ad-hoc
routing protocol that allows it to discover “multihop” paths
through the network to the sink node (many to one). A classic
application can be when these sensors are used to aid the
soldiers in a battle field by relaying vital information [1] or for
studying natural phenomenon like earthquakes. The sensor
networks can be classified on the basis of applications as
dynamic in which large number of nodes enter and leave the
network and stationary in which the nodes remain relatively
To solve the multi-hop routing and efficient path discovery
many routing algorithms have been proposed. Each one based
on certain assumptions and poses certain limitation. The routing
protocols for ad hoc networks have been classified into two
categories: table-driven protocols and on-demand protocols.
They differ from each other on the way they obtain the routing
information. The table driven protocols usually maintain the
routing table of the whole network whereas the on-demand
protocols only try to keep routes on need to know bases. A third
category hybrid protocols, has also emerged which combines
both table driven and on-demand protocol.

Figure 1: Classification of Ad Hoc Routing Protocols

This paper is the first to provide a realistic, quantitative
analysis[2] comparing the performance of two multi-hop
routing protocols using TOSSIM. TOSSIM[3] is an open-source
network simulation tool. The two routing protocols, Ad-hoc On-
Demand Distance Vector (AODV)[4] and Destination-
Sequenced Distance Vector (DSDV)[5] are investigated. DSDV
is a proactive routing protocol that utilizes a table-driven
technique by recording all routes it finds between all source-
destination pairs regardless of the use or need of such route. On
the other hand AODV establishes routes on demand basis.
Section 2 presents a brief of the related work done. The detailed
study of the two protocols is done in section 3. Section 4
explains the simulation environment. Section 5 lists out the
difference between the TOSSIM[3] and ns-2[7] simulation
environments and state out the reasons of our preference on
using TOSSIM for the experimentation purpose. The results of
the simulations are presented in section 6.

Ad-hoc Routing Protocols
Table Driven
ISBN 978-89-5519-136-3
Feb. 17-20, 2008 ICACT 2008
2. Related Work

Most previous work on routing protocols for ad hoc
networks analyses the performance of only a single algorithm.
The performance of the DSDV routing protocol, which is one
the most famous routing protocols for multi-hop ad hoc
networks, is analyzed in[6].
When developing applications for wireless sensor network
the limitation posed by the hardware in terms of energy
consumption, memory requirements have to be taken into
consideration. The AODV and DSDV protocols are modified
for the highly constrained WSNs. This paper emphasizes upon
simulating the routing protocol in TOSSIM rather than ns-2
enabling us to perform our analysis closer to hardware.

3. Routing Protocols

A. Destination-Sequenced Distance-Vector (DSDV) routing
The DSDV (Destination-Sequenced Distance-Vector)
protocol is a routing table based algorithm using the classic
routing mechanism of Bellman-Ford. DSDV algorithm
represents the table-driven protocols as it maintains a loop-free,
fewest-hop (resulting to the creation of fewer forwarded
packets) path to every destination in the network. DSDV
prevents loops by using sequence number distinguishing stale
routes from new ones. This protocol achieves low routing
overhead and low packet delay. Routing information is
exchanged when significant new information is available, for
instance, when the neighborhood of a node changes.
In DSDV each node in the network maintains a routing table
which is referred for packet transmissions to the sink. Each
routing table, at each of the stations, lists all available
destinations, and the number of hops to each. Each route table
entry is tagged with a sequence number which is originated by
the destination station. The consistency of routing tables in a
dynamically varying topology is maintained. Each station
transmits updates periodically and when significant new
information is available. The algorithm does not assume that the
mobile hosts are maintaining any sort of time synchronization.
It makes no assumption about the phase relationship of the
update periods between the mobile hosts. These packets indicate
which stations are accessible from each station and the number
of hops necessary to reach these accessible stations, as is often
done in distance-vector routing algorithms. The metrics for
route selection are the freshness of the sequence numbers
associated with the route and the number of hops to the
DSDV provided by University of California and Intel
Corporation[15] is implemented. The routing pattern
implemented is many-to-one at the end. It includes a hop-count
metric, a reliability metric, an energy metric, and an HSN
(Sphere of Influence or SoI) metric. For tracking the
unidirectional and/or bidirectional link quality between
neighboring nodes a generic mechanism is used (reliability
metric). In the implementation DSDV signals the intercept
interface on all incoming packets even though the mote itself is
the sink node. The sink node returns SUCCESS if the intercept
interface is wired. Otherwise the packet is dropped and the
packet won't be delivered by the receive interface.

B. Ad-Hoc On-Demand Distance Vector (AODV) routing
AODV the on-demand protocol algorithm is selected as
compared to other on-demand protocols as it supports unicast
and multicast (support multi-party wireless communications)
packet transmissions. None of the other on-demand algorithms
incorporate multicast communication. It also appears to achieve
the lowest routing overhead from all other protocols in its
category in accordance with other papers [7, 10]. AODV also
contains mechanisms to select the least congested route.
AODV builds routes between nodes only as desired by
source nodes. It maintains these routes as long as they are
needed by the sources. Additionally, AODV forms trees which
connect multicast group members. The trees are composed of
the group members and the nodes needed to connect the
members. AODV uses sequence numbers to ensure the
freshness of routes. It is loop-free, self-starting and scales to
large numbers of mobile nodes. AODV builds routes using a
route request / route reply query cycle. When a source node
desires a route to a destination for which it does not already
have a route, it broadcasts a route request (RREQ) packet across
the network. Nodes receiving this packet update their
information for the source node and set up backwards pointers
to the source node in the route tables. In addition to the source
node's IP address, current sequence number, and broadcast ID,
the RREQ also contains the most recent sequence number for
the destination of which the source node is aware. A node
receiving the RREQ sends a route reply (RREP) if it is either
the destination or if it has a route to the destination with
corresponding sequence number greater than or equal to that
contained in the RREQ. If this is the case, it unicasts a RREP
back to the source. Otherwise, it rebroadcasts the RREQ. Nodes
keep track of the RREQ's source address and broadcast ID. If
they receive a RREQ which they have already processed, they
discard the RREQ and do not forward it.
As the RREP propagates back to the source, the nodes set up
forward pointers to the destination. Once the source node
receives the RREP, it begins to forward data packets to the
destination. If the source later receives a RREP containing a
greater sequence number or contains the same sequence number
with a smaller hop count, it updates its routing information for
that destination and starts using the better route.
As long as the route remains active, it will continue to be
maintained. A route is considered active as long as there are
data packets periodically traveling from the source to the
destination along that path. Once the source stops sending data
packets, the links will time out and eventually be deleted from
the intermediate node routing tables. If a link break occurs
while the route is active, the node upstream of the break
propagates a route error (RERR) message to the source node to
inform it of the now unreachable destination(s). After receiving
the RERR, if the source node still desires the route, it can
reinitiate route discovery.
TinyAODV[16] is implemented with the route table size and
route cache size of 10. The routing pattern implemented is
many-to-one at end. The implementation of TinyAODV makes
ISBN 978-89-5519-136-3
Feb. 17-20, 2008 ICACT 2008
various simplifications in order to implement the AODV
protocol in a very small footprint due to constrained WSN
environment. The major simplifications in the current
implementation are listed below:
• RREP messages are only generated by the destination.
• Routes never expire.
• Only the hop count metric is used.
• No messages are generated to keep routes active because
routes never expire.

Route errors are generated when a data message can no
longer be sent over the path. This is detected using the TinyOS
link level acknowledgements.

4. Simulation Environment

It is a TinyOS simulator that provides a network model.
TOSSIM is opted for experimentation. It is an event driven
simulator for Mica/Mica2 motes running TinyOS[8]. It uses
algorithms similar to algorithms that will run on the actual
hardware so that the actual implementations can be studied and
the code doesn't have to be written twice. Its primary goal is to
provide a high fidelity, scalability, completeness and bridging
the gap between algorithm and implementation, allowing
developers to test and verify the code that will run on real
hardware. For this reason, it focuses on simulating TinyOS and
its execution, rather than simulating the real world, i.e., it
simulates the entire network, both the operating system and
network stack including network errors. Other simulators like
SimOS[17], ns-2[7], Proteus[18] abstract away a lot of aspects
of a network that actually ought to be simulated. As stated
above TOSSIM works with compiled TinyOS applications. The
simulator runs the same code as the hardware except for a few
parts (ADC, clock, EEPROM, etc). This feature is made
available by modifying the ncc (nesC) compiler so that TinyOS
programs can be compiled to run in TOSSIM by using a
command-line option. TOSSIM simulates the network stack at
the TinyOS component level.

B. ns-2 and its Limitation
ns-2 is the predominant discrete event simulator used in
network systems for experimentation that simulates networks at
the packet level and allows a wide range of heterogeneous
network configurations. Complex models to determine packet
loss rates from physical topologies are written in Tcl or C,
separate from a protocol implementation. Numerous sensor
network research efforts have evaluated algorithms with
simulations using ns-2. Simulations for the PSFQ routing
protocol used 25 nodes with 2Mbps links[9]. There are other
examples of an 802.11 MAC being used in ns-2 to simulate
sensor networks[10], although initial evidence indicates it is
Also, ns-2 does not model application behavior. It is suited
best for the simulation of protocols having well traced layered
structure. In sensor networks the protocols and applications
interact with each other. The protocol layers are often crossed or
ignored to provide time-dependent aggregation of sensor
readings. Thus, it follows a model of integrated layer processing
instead of strict layering[12]. ns-2 is inappropriate to model this
sort of behavior. It is a much more general network simulator
where as in TOSSIM simulates the network and their interaction
and also provides a degree of fidelity, bridging, and
completeness that ns-2 cannot.

C. TOSSIM - Radio Model
TOSSIM simulates the TinyOS network at the bit level,
using TinyOS component implementations almost identical to
the mica 40Kbit RFM-based stack. TOSSIM provides two radio
models: simple and lossy. In TOSSIM, a network signal is
either a one or zero. All signals are of equal strength, and
collision is modeled as a logical OR. This means that distance
does not affect signal strength.
Simple model is generally used for testing single-hop
communication. To test routing the “lossy” model is used. The
lossy radio model places the nodes in a directed graph. Each
edge (a, b) in the graph means a’s signal can be heard by b.
Every edge has a value in the range (0, 1), representing the
probability of corrupted (flipped) bit when b hears it. For
example, a value of 0.01 means each bit transmitted has a 1%
chance of being flipped, while 1.0 means every bit will be
flipped and 0.0 means bits will be transmitted without error.
Each bit is considered independently.
To generate lossy models, the tool has Gaussian packet loss
probability distributions for each distance. In the physical mote
topology, the tool generates packet loss rates for each mote pair
by sampling these distributions. The tool translates packet error
rates into independent bit error rates.

D. TOSSIM: Data Link Layer
The data link layer of the network stack uses the CSMA
protocol with single error correction/double error detection, data
encoding and a full-packet CRC. Packet loss (CRC failure) is
also modeled using data collected from a real 26 node network.
TOSSIM simulates the behavior of the TinyOS networking
stack at high fidelity, thus, accurately capturing the interaction
between application and low level protocols. The routing
protocol resides over this layer.

5. Methodology

A. Performance Metrics
The paper compares the performance of DSDV and AODV
routing protocols under defined network conditions[13].
Performance measurements that are being evaluated are:

1) Packet Delivery Ratio (PDR): This metric shows the
percentage of successfully delivered packets. It is the fraction
between the number of packets sent by sensor source node and
the number of received packets by the sensor sink node at
destination[14]. This affects the maximum throughput that the
network can support. This metric characterizes both the
completeness and correctness of the routing protocol.

2) Routing Overhead (Forwarded packets): Routing overhead is
the additional packets required apart from the data packets to
send the data to sink node. It measures the scalability of a
ISBN 978-89-5519-136-3
Feb. 17-20, 2008 ICACT 2008
protocol. It tells about the degree to which the protocol will
function in congested or low-bandwidth environments, and its
efficiency in terms of consuming node battery power. Protocols
that send large numbers of routing packets increase the
probability of packet collisions delay data packets in network
interface transmission queues.

3) Average Delay time: It is the average time delay between the
instance when a data packet is given to the source node and the
instance when the packet arrives at the destination node.
Reducing the routing overhead leads to better packet delivery
times[14]. It serves as an important metric in measuring the
efficiency of the protocol in finding the optimum path. It is
dependent upon the other parameters like channel utilization by
the MAC and the total number of packets sent in the network.

B. Simulation Method
The aim of these experiments is to measure the ability of the
routing protocols to react to network topology change while
successfully continuing deliver data packets to their
destinations. For measurement the basic methodology applied is
to simulate the network to a variety of workloads. Each data
packet originated by a sender is tested to know whether the
routing protocol can at that time route to the destination of that
packet. The simulation was conducted by:
• Varying the total number of nodes and then
• Varying the connection speed i.e. number of packets sent
per second.

Figure 2: The Network simulator TOSSIM and the arrangement of
nodes for calculating end to end delay

The nodes are placed with distribution pattern as shown in
Figure 2. Node 0 is made the destination (sink) following many-
to-one at end routing pattern. For varying the number of nodes
the density of nodes is changed but the distribution pattern
remains the same.

1) Varying the total number of nodes: The maximum number of
nodes used for experimentation was 30 and the simulation time
was kept 90 seconds. In the simulation the connection rate of 10
packets/second was kept constant throughout the simulation
time and the metrics packet delivery ratio, end to end delay and
routing overhead were calculated

2) Varying the connection rate (Packets/sec): Under this setup
15 nodes were used and kept constant throughout the
experiment. And the connection rate was varied. The data
packet was 20 bytes long and the routing protocol added
another 8 bytes header to the packet. The simulation time was
kept 90 seconds and the metrics, packet delivery ratio; end to
end delay and routing overhead were calculated.

6. Simulation Results

At stated in section 5 the experimentation is done in two parts.
The results obtained after simulation carried out and the graphs
obtained for the performance are presented.

A. Packet Delivery Ratio
Figure 3(a) and 3(b) show the effect of increasing the
number of nodes and the connection rate on the evaluation
metric, packet delivery ratio. As the number of nodes is
increased from 5 nodes to 30 nodes in steps of 5 the packet
delivery starts to drop from 95% for 5 nodes to 72% for 20
nodes for AODV protocol and then becomes constant from 20
nodes to 30 nodes. For DSDV protocol the packet delivery ratio
is 80% for 5 nodes and decreases to 66% for 20 nodes and then
becomes constant from 20 nodes to 30 nodes. When the number
of nodes is kept constant to 15 and connection rate is increased
from 1 packet to 25 packets per second the packet delivery ratio
decreases from 95% at 1 packet per second to 80% at 15
packets per second and then becomes constant. Similarly for
DSDV the packet delivery ratio decreases from 80% at 1 packet
per second to 66% at 15 packets per second and then further on
it becomes constant.

B. Routing Overhead
Figure 3(c) and 3(d) show the routing packets. The first
graph shows the gradual increase in the overhead in case of
DSDV as the number of nodes increase from 5 to 30 and starts
saturating after 25 nodes at an approximate value of 80 packets
(connection rate, 15 packets/second). In case of AODV the
routing overhead first increases to 100 packets for 15 nodes
(connection rate, 15 packets/second) and then starts decreasing
and attains a nearly constant value of 30 (approx) after 25
nodes. Initially routing overhead increases due to less number
of nodes route not being mapped efficiently. After 20 nodes in
the network the mapping of the routes becomes easier and
routing overhead decreases. The routing overhead after
dropping as shown in the graph will increase again when
number of nodes is increased as more route requests would be
forwarded in different paths. In the variation of Routing
overhead against the connection rate when the number of nodes
is kept constant at 15 is seen, DSDV maintains a constant
routing overhead of 5 irrespective of the number of nodes. In
case of AODV Protocol the overhead increases and attains a
constant value at 15 packets per second of 100 packets. This is
because routing tables are refreshed when new routes have been

ISBN 978-89-5519-136-3
Feb. 17-20, 2008 ICACT 2008
Packet Delivery Ratio Vs No. of Nodes
5 10 15 20 25 30
Number of Nodes
Packet Delivery Ratio
Packet Delivery Ratio Vs Connection
1 5 10 15 20 25
Connection Rate (Packets/Sec)
Packet Delivery Ratio
Routing Overhead Vs Connection Rate
1 5 10 15 20 25
Connection Rate (Packets/Sec)
Routing Overhead
Routing Overhead Vs No. of Nodes
5 10 15 20 25 30
Number of Nodes
Routing Overhead
End to End Delay Vs No. of Nodes
5 10 15 20 25 30
Number of Nodes
End to End Delay (sec)
End to End Delay Vs Connection Rate
1 5 10 15 20 25
Connection Rate (Packets/Sec)
End to End Delay (sec)
(e) (f)
Figure 3: Performance Evaluation Metrics against Number of Nodes and Connection Rate

The DSDV protocol sends periodic update packets and
transmits updates whenever new information is available. Thus,
when the number of nodes increases, more information is
exchanged so routing overhead increases. But when the number
of nodes remains constant routing overhead also remains

C. End to End Delay
Figure 3(e) and 3(f) indicate the end to end delay metric. In
both the cases i.e., varying the number of nodes and varying the
connection rate the routing overhead increases gradually. The
DSDV protocol performs better than the AODV protocol at this
metric. The DSDV protocol has nearly 25% better performance
as compared to AODV in terms of end to end delay.
The end to end delay increases when more number of
packets are sent per second, it can be related to proper channel
allocation. The packet would be colliding thus increasing the
end to end delay for both the protocols. When the number of
nodes is kept constant it is expected that the end to end delay of
DSDV would be less, still it increases with connection rate.
While varying the number of nodes the end to end delay
becomes constant after a certain number of nodes.
The end to end delay will further increase with increase in
number of nodes and the area they are spread in due to limited
transmission range. It becomes constant for a set of nodes as
there are different shortest paths available with increase in
number of nodes.

7. Conclusion

The above analysis accentuates that routing is very
important but is a difficult issue to deal in wireless sensor
networks. These routing protocols cannot be fully implemented
in wireless sensor networks due to constrain of memory, energy

efficiency and latency requirements. This paper provides a
performance analysis of by means of simulation using open-
source network simulator software called TOSSIM which
bridges the gap between the algorithm and its hardware
implementation on the motes. The same code which runs on the
hardware is simulated and results have been obtained.
As the applications being developed in wireless sensor
network diversify, the search for a versatile routing protocol is
becoming difficult. Thus, routing protocols are being selected
according to the application and the environment requirement.
Considering the tradeoffs of memory, energy efficiency, latency
and overall efficiency for an application developed the routing
is done and appropriate modifications are also done in the
algorithms to enhance certain features. AODV performs better
than DSDV in terms of packet delivery ratio in all the
environments. On the other hand a trade-off lies in its high
routing overhead which also comes down when optimum
number of nodes are used in the cluster for AODV. In terms of
latency the DSDV performs better than the AODV. Thus when
packet delivery ratio is important and the number of cluster
nodes are more i.e., the network is mapped properly; AODV is
the protocol of choice. But, when there is a definite limit to the
acceptable latency DSDV protocol with required update
broadcast intervals should be used as it is quite predictable
making it more reliable.


[1] National Science Foundation. Research priorities in wireless
and mobile communications and networking: Report of a
workshop held March 24–26, 1997, Airlie House, Virginia.
Available at:
[2] J. Broch, D. A. Maltz, D. B. Johnson, Y. Hu, and J. Jetcheva, “A
Performance Comparison of Multi-hop Wireless ad hoc Networking
Routing Protocols,” Proceedings of Mobicom ‘98, pp. 85 – 97, Dallas,
October 1998.
ISBN 978-89-5519-136-3
Feb. 17-20, 2008 ICACT 2008
[3] P. Levis, N. Lee, M. Welsh, and D. Culler, “TOSSIM: Accurate and
scalable simulation of entire TinyOS applications,” In Proceedings of the
First ACM Conference on Embedded Networked Sensor Systems (SenSys),
[4] C. E. Perkins and E. Royer, “Ad-Hoc On-Demand Distance Vector
Routing”, Proceeding of 2nd IEEE Workshop on Mobile Computing &
Systems and Applications, pp. 90–100, Feb 1999.
[5] C. E. Perkins and P. Bhagwat, “Highly Dynamic Destination-Sequenced
Distance-Vector Routing (DSDV) for Mobile Computers”, Computer
Communications Review, pp. 234– 244, Oct 1994.
[6] Vahid Garousi, Simulating Network traffic in Multi-hop Wireless Ad Hoc
Networks based on DSDV (Destination Sequenced Distance Vector)
protocol using NS (Network Simulator) Package, University of Waterloo,
Fall 2001.
[7] The network simulator – ns-2.29,
[8] Philip Levis, et al, “The Emergence of Networking Abstractions and
Techniques in TinyOS,” In Proceedings of the First Symposium on
Networked Systems Design and Implementation, pp. 1-14, 2004.
[9] C.Y. Wan, A. T. Campbell, and L. Krishnamurthy. PSFQ: A Reliable
Transport Protocol for Wireless Sensor Networks. In Proceedings of the
First ACM International Workshop on Wireless Sensor Networks and
Applications, pages 1–11. ACM Press, 2002.
[10] F. Ye, H. Luo, J. Cheng, S. Lu, and L. Zhang. A Two-Tier Data
Dissemination Model for Large-Scale Wireless Sensor Networks. In
Proceedings of the First ACM International Workshop on Wireless Sensor
Networks and Applications, 2002

[11] C. Intanagonwiwat, R. Govindan, and D. Estrin. Directed Diffusion: A
Scalable And Robust Communication Paradigm For Sensor Networks. In
Proceedings of the International Conference on Mobile Computing and
Networking, Aug. 2000.
[12] D. D. Clark and D. L. Tennenhouse. Architectural Considerations for a
New Generation of Protocols. In Proceedings of SIGCOMM, September
[13] A. Iwata, C.-C. Chiang, G. Pei, M. Gerla and T.-W. Chen, Scalable
Routing Strategies for Ad Hoc Wireless Networks, IEEE Journal on
Selected Areas in Communications, JSAC99, Vol. 17, No. 8, August 1999,
pp. 1369-1379.
[14] VD Park and MS Corson, A highly adaptive distributed routing algorithm
for mobile wireless networks, Proc. INFOCOM'97April 1997.
[15] M. D. Yarvis, W. S. Conner, L. Krishnamurthy, A. Mainwaring, J.
Chhabra, and B. Elliott. Real-World Experiences with an Interactive Ad
Hoc Sensor Network. In International Conference on Parallel Processing
orkshops, 2002.
[16] Tiny AODV.
hsn/. Last visited: 13.01.2007.
[17] M. Rosenblum, S. A. Herrod, E. Witchel, and A. Gupta. Complete
Computer Simulation: The SimO Approach. IEEE Parallel and Distributed
Technology, 3(4):34{43, Winter 1995.
[18] E. A. Brewer, C. Dellarocas, A. Colbrook, and W. E. Weihl. PROTEUS:
A High-Performance Parallel-Architecture Simulator. Measurement and
Modeling of Computer System, pages 247–8, 1992.
ISBN 978-89-5519-136-3
Feb. 17-20, 2008 ICACT 2008