chapter 6 simulation and resultsshodhganga.inflibnet.ac.in/bitstream/10603/13410/11/11_chapter...
TRANSCRIPT
124
CHAPTER 6
SIMULATION AND RESULTS
For a sensor network to be useful, the location of each node must
be determined (Howard et al 2001 and Winfield et al 2000). Fortunately, it is
possible to determine the location of nodes in a network by conducting
suitable simulation experiments and evaluating their efficiency. Simulation
experiments are conducted aiming at evaluating the network lifetime and
energy efficiency of the deployment patterns with a suitable routing algorithm
and congestion control algorithm. Placement of sensor nodes play a very
important role on sensor networks (Howard et al 2001, Winfield et al 2000
and Bansal et al 2002). Based on the position of the sensor nodes the
efficiency of detecting the signal is improved (Clare et al 1999). Hence this
research analyses seven different distribution patterns of placing the nodes.
6.1 SIMULATION SETUP
The seven patterns shown in Figures 5.1 to 5.7 are simulated using
ns2. Initially, the distance covered by a sensor node is evaluated, considering
only two wireless nodes. With these nodes simulated as wireless nodes and by
varying the antenna height and transmitter power, the minimum required
antenna height and transmitter power required to cover a diagonal distance is
found for each pattern. This power differs slightly for each node.
125
The various simulation parameters assumed are given below:
Channel : Wireless Channel
Propagation : Free Space
Network Interface Type : Wireless Physical Interface
Mac Type : Mac 802.11
Interface Queue Type : Drop Tail / Priority Queue
Antenna : Omni Antenna
Interface Queue Length : 50
Routing Protocol : AODV / DSDV/ DSR/ HETRA
Antenna Height : 0.35 m
With these parameters, the wireless sensor network is simulated
with the seven distribution patterns already discussed. In all the seven
scenario, the source node placed initially at (2, 2), is made mobile. It is
initially made to move towards the point (250, 200) and then towards (2, 500).
The base station node receives the information from the sensor nodes.
To analyze the energy efficiency and NLT of the wireless sensor
network, the different routing protocols are assumed. They are AODV,
DSDV, DSR and HETRA. Along with these routing protocols, five different
TCP variants are assumed in the source node. They are TCP/Tahoe,
TCP/Reno, MIMD-Poly, PIPD-Poly and TCP/Exp.
With the parameters mentioned, simulation is performed by
transmitting packets from source node to the base station node through the
sensor nodes. The simulation scenario generated the patterns which are stored
in a nam file. The nam display for one of the patterns is shown in Figure 6.1.
126
Figure 6.1 Scenario generated by the simulation of Circular pattern
generated by the nam
6.2 SIMULATION RESULTS AND ANALYSIS
The simulation program may include the following statements to
generate the trace file.
set tracefd [open hetra.tr w]
The program used by ns2 to generate the trace is properly modified
that will include the details such as energy spent and the remaining energy
available after each transmission and reception. These trace files are properly
utilized to extract the energy remaining in the nodes after each transmission
and reception. The following AWK program performs this extraction.
set awkCode {
BEGIN { print "" >> "hetra1"; }
{if ($7 == "tcp" && $1 == "s" || $1 == "r")
{time = $2;
energy = $14*1;}
print time, energy >> "hetra1";}}
exec awk $awkCode hetra.tr
127
The above program extracts the information from the trace file
generated (for example hetra.tr). The information extracted is the time
(in seconds) at which the source node or the intermediate node either
transmits ($1=s) or receives ($1=r) and the remaining energy (in Joules) in the
source node or the intermediate node. After extracting the necessary details
the energy versus time plot is drawn using the gnuplot program available in
linux.
The trace file of simulation experiments conducted with the seven
different distribution patterns (ALL, CIRCULAR, CROSS, DIAMOND and
EYE) with the four routing algorithms (AODV, DSDV, DSR and HETRA)
and five congestion control algorithms (TCP, Reno, MIMD, PIPD, Exp) are
used to find the NLT.
The values of NLTs extracted from the trace file of various
simulations are depicted in Figures 6.2 to 6.8. These figures give the variation
of energy from initial 0.5 Joules to zero Joules, in the duration of the NLT of
each simulated network configuration. Assuming the TCP/Exp congestion
control, Figure 6.2 give the values of NLT for AODV, DSDV, DSR and
HETRA routing protocols using the ALL node distribution pattern. Similarly
Figures 4.9 to 4.16 give the NLTs using the other four node distribution
patterns.
128
(a) (b)
(c) (d)
Figure 6.2 Remaining Energy in nodes of WSN with ALL Pattern using
Various Routing Algorithms and TCP/Exp Congestion
Control
Energy versus Time Plot of DSR
En
erg
y i
n J
ou
les
Time in Seconds
Energy versus Time Plot of DSDV
Energy versus Time Plot of AODV Energy versus Time Plot of HETRA
En
erg
y i
n J
ou
les
Time in Seconds
En
erg
y i
n J
ou
les
En
erg
y i
n J
ou
les
Time in Seconds Time in Seconds
129
(a) (b)
(c) (d)
Figure 6.3 Remaining Energy in nodes of WSN with CIRCULAR
Pattern using Various Routing Algorithms and TCP/Exp
Congestion Control
.
Energy versus Time Plot of DSR
En
erg
y i
n J
ou
les
Time in Seconds
Energy versus Time Plot of DSDV
Energy versus Time Plot of AODV Energy versus Time Plot of HETRA
En
erg
y i
n J
ou
les
Time in Seconds
En
erg
y i
n J
ou
les
En
erg
y i
n J
ou
les
Time in Seconds Time in Seconds
130
(a) (b)
(c) (d)
Figure 6.4 Remaining Energy in nodes of WSN with CROSS Pattern
using Various Routing Algorithms and TCP/Exp Congestion
Control
Energy versus Time Plot of DSR
En
erg
y i
n J
ou
les
Time in Seconds
Energy versus Time Plot of DSDV
Energy versus Time Plot of AODV Energy versus Time Plot of HETRA
En
erg
y i
n J
ou
les
Time in Seconds
En
erg
y i
n J
ou
les
En
erg
y i
n J
ou
les
Time in Seconds Time in Seconds
131
(a) (b)
(c) (d)
Figure 6.5 Remaining Energy in nodes of WSN with DIAMOND
Pattern using Various Routing Algorithms and TCP/Exp
Congestion Control
Energy versus Time Plot of DSR
En
erg
y i
n J
ou
les
Time in Seconds
Energy versus Time Plot of DSDV
Energy versus Time Plot of AODV Energy versus Time Plot of HETRA
En
erg
y i
n J
ou
les
Time in Seconds
En
erg
y i
n J
ou
les
En
erg
y i
n J
ou
les
Time in Seconds Time in Seconds
132
(a) (b)
(c) (d)
Figure 6.6 Remaining Energy in nodes of WSN with EYE Pattern using
Various Routing Algorithms and TCP/Exp Congestion
Control
Energy versus Time Plot of DSR
En
erg
y i
n J
ou
les
Time in Seconds
Energy versus Time Plot of DSDV
Energy versus Time Plot of AODV Energy versus Time Plot of HETRA
En
erg
y i
n J
ou
les
Time in Seconds
En
erg
y i
n J
ou
les
En
erg
y i
n J
ou
les
Time in Seconds Time in Seconds
133
(a) (b)
(c) (d)
Figure 6.7 Remaining Energy in nodes of WSN with STEP Pattern
using Various Routing Algorithms and TCP/Exp Congestion
Control
Energy versus Time Plot of DSR
En
erg
y i
n J
ou
les
Time in Seconds
Energy versus Time Plot of DSDV
Energy versus Time Plot of AODV Energy versus Time Plot of HETRA
En
erg
y i
n J
ou
les
Time in Seconds
En
erg
y i
n J
ou
les
En
erg
y i
n J
ou
les
Time in Seconds Time in Seconds
134
(a) (b)
(c) (d)
Figure 6.8 Remaining Energy in nodes of WSN with CHI Pattern using
Various Routing Algorithms and TCP/Exp Congestion
Control
The NLTs of each simulation for all node distribution patterns is
compared in Figure 6.9. This figure shows that the HETRA routing algorithm
increases the NLT. This increase is due to the strategy used to select the
nodes for transmission and reception based on the remaining node energy.
The routing from source to destination is also based on the HET constructed
using the above strategy. The exact values of NLT by assuming an initial
energy of 0.5 Jules are tabulated in Table 6.1 and the same is depicted in
Figure 6.9. The numbers of packets delivered by these are also tabulated in
Table 6.2 and they are compared in Figure 6.10.
Energy versus Time Plot of DSRE
ner
gy
in
Jo
ule
s
Time in Seconds
Energy versus Time Plot of DSDV
Energy versus Time Plot of AODV Energy versus Time Plot of HETRA
En
erg
y i
n J
ou
les
Time in Seconds
En
erg
y i
n J
ou
les
En
erg
y i
n J
ou
les
Time in Seconds Time in Seconds
135
Table 6.1 NLT of WSN with various Routing Algorithms and
TCP/Exp Congestion Control
NLT of various Routing AlgorithmsNode Distribution
Patterns DSR DSDV AODV HETRA
ALL 2.54 2.56 2.55 7.08
CIRCULAR 1.502 2.57 1.54 5.91
CROSS 1.36 2.69 1.42 5.83
DIAMOND 1.53 2.23 1.54 6.96
EYE 1.46 2.47 1.49 6.09
STEP 0.87 2.3 1.14 4.84
CHI SQUARE 1.14 1.18 0.97 4.53
NLT with TCP/Exp Congestion Control
0
1
2
3
4
5
6
7
8
ALL CIRCULAR CROSS DIAMOND EYE STEP CHI
SQUARE
Node Placement Patterns
Ne
two
rk L
ifeti
me i
n S
eco
nd
s
DSR
DSDV
AODV
HETRA
Figure 6.9 NLT of WSN with Various Routing Algorithms and
TCP/Exp Congestion Control
136
Table 6.2 Number of Data Packets delivered in WSN with Various
Routing Algorithms and TCP/Exp Congestion Control
Number of Data packets of various Routing
AlgorithmsNode Distribution
PatternsDSR DSDV AODV HETRA
ALL 1712 1181 1739 1721
CIRCULAR 1705 1687 1713 1710
CROSS 1720 721 1731 1722
DIAMOND 1728 1480 1718 1717
EYE 1733 660 1715 1715
STEP 1511 763 1504 1507
CHI SQUARE 1741 1134 1717 1715
Data Packets Received with TCP/Exp Congestion Control
0
200
400
600
800
1000
1200
1400
1600
1800
2000
ALL CIRCULAR CROSS DIAMOND EYE STEP CHI
SQUARE
Node Placement Patterns
No
. o
f D
ata
Packets
DSR
DSDV
AODV
HETRA
Figure 6.10 Number Data Packets delivered in WSN with various
Routing Algorithms and TCP/Exp Congestion Control
137
This shows that the combination HETRA with TCP/Exp performs
better. This combination has higher energy efficiency and also throughput.
Hence, the NLT of WSN with HETRA/Exp combination has improved the
overall efficiency of the network. As the number of nodes in CROSS pattern
is less compared with other patterns and the energy efficiency is comparable
with other patterns, the CROSS pattern is the most energy efficient pattern
among the seven fixed patterns assumed.
6.3 DANLT PRODUCT – PERFORMANCE METRIC USED FOR
COMPARISON
For comparing the performance of different distribution patterns, a
common parameter is formulated. To arrive at a common parameter, initially
ANLT per node is calculated as given below:
Average network lifetime per node = NLT/Number of nodes (6.1)
This ANLT is calculated for all the simulated patterns. The result
shows that the value is maximum for CROSS pattern. Hence, among the
seven patterns assumed, CROSS pattern with HETRA and TCP/Exp is the
most efficient combination.
Based on the number of data packets delivered and NLT, a new
parameter is formulated to compare the performance of WSN with the
different node placement patterns, routing algorithms and congestion control
algorithms. The parameter is named as Data packets–ANLT product and is
evaluated as given below:
Data packets–ANLT product = Number of Data packets delivered * ANLT
(6.2)
This parameter gives an effective way of comparing the combined
performance of energy efficiency, throughput, Network lifetime and number
138
of nodes in each distribution pattern of WSN. This parameter is very useful
in the comparison of the seven node distribution patterns assumed.
The NLT of the seven patterns (for TCP/Exp congestion control) is
shown in Figure 6.9. This shows that the NLT of WSN with HETRA and
Exp combination is the highest among the four routing algorithms assumed.
Among the patterns, ALL pattern has the highest NLT of 7.08 seconds. The
number of data packets delivered is compared for the seven patterns (with
TCP/Exp) in Figure 6.10. This figure clearly indicates that the number of data
packets delivered is the maximum for the combination of HETRA with
TCP/Exp in cross pattern.
DANLT product is evaluated for combining the NLT and the
number of data packets into a single measure for comparison. This measure
will clearly indicate the most efficient pattern among the seven patterns. This
comparison is depicted in Figure 6.11. This figure clearly indicates that the
DANLT product is the maximum for the combination HETRA with TCP/Exp
in CROSS pattern. Hence this combination proves to be the most efficient in
terms of total energy spent, number of data packets delivered and Network
lifetime.
Similarly in CROSS pattern the five different congestion control
schemes are assumed and simulation is performed to compare the congestion
control algorithm that best suites the WSN. Again the NLT for various
congestion control schemes and routing algorithms are evaluated for the cross
pattern from the trace file. The results are plotted in Figure 6.12. Number of
data packets delivered for the same combination of CROSS/HETRA with
different congestion control schemes are also found from the simulation trace
files and are shown in Figure 6.13. The DANLT product is evaluated and is
shown in Figure 6.14. This parameter indicates that the combination of
CROSS pattern with HETRA and TCP/Exp is the most efficient among all the
patterns.
139
DANLT Product with TCP/Exp Congestion Control
0
100
200
300
400
500
600
ALL CIRCULAR CROSS DIAMOND EYE STEP CHI
SQUARE
Node Placement Patterns
DA
NL
T P
rod
uc
t
DSR
DSDV
AODV
HETRA
Figure 6.11 DANLT product of WSN with various Routing Algorithms
and TCP/Exp Congestion Control
Network Lifetime (NLT) of WSN with various Congestion Control
0
1
2
3
4
5
6
7
TCP Exp Reno MIMD PIPD
Congestion Control Algorithms
NL
T in
Se
cs
.
DSR
DSDV
AODV
HETRA
Figure 6.12 NLT of WSN CROSS Pattern with various Routing and
Congestion Control Algorithms
140
Number of Data Packets delivered in WSN with various Congestion Control
0
200
400
600
800
1000
1200
1400
1600
1800
2000
TCP Exp Reno MIMD PIPD
Congestion Control Algorithms
Nu
mb
er
of
Da
ta P
ac
ke
ts d
eli
ve
red
DSR
DSDV
AODV
HETRA
Figure 6.13 Number of Data Packets delivered in WSN CROSS Pattern
with various Routing and Congestion Control Algorithms
DANLT Product of WSN with various Congestion Control
0
100
200
300
400
500
600
TCP Exp Reno MIMD PIPD
Congestion Control Algorithms
DA
NL
T P
rod
uct
DSR
DSDV
AODV
HETRA
Figure 6.14 DANLT Product of WSN CROSS Pattern with various
Routing and Congestion Control Algorithms
141
In this section, the NLT of WSN with different node distribution
patterns are analysed with the combination of routing algorithms and
congestion control algorithms. Seven node distribution patterns – ALL,
CIRCULAR, CROSS, DIAMOND, STEP, CHI SQUARE and EYE four
routing algorithms – DSDV, AODV, DSR, and HETRA and five TCP
congestion control schemes- TCP, Reno, MIMD, PIPD and Exp are assumed.
Among these, HETRA and Tcp/Exp are the proposed routing algorithm and
congestion control algorithm respectively.
Simulations are performed in ns2 with HETRA/Exp and TCP/Exp
implemented in it. The results of simulation are used for the analysis. The
trace files generated by the simulation experiments are used to evaluate the
parameters such as NLT, ANLT, Data packets delivered and DANLT
product. The NLT of each simulation with TCP/Exp congestion control
algorithm, Four Routing Protocols and Seven node distribution patterns are
shown in Figures 5.1 to 5.7. These parameters are compared in Figures 6.2
to 6.8.
The results clearly indicate that the WSN with the nodes
distributed in the pattern of CROSS with the routing algorithm as HETRA
and congestion control as TCP/Exp, performs most efficiently in terms of the
energy consumption , NLT and throughput.
6.4 PERFORMANCE EVALUATION OF HETRA WITH
TCP/Exp IN WIRELESS SENSOR NETWORK
INTERFACED TO A WIRED TCP/IP NETWORK
WSN is used to solve many critical real life situations and it
provides a very good solutions. Earth quake detection and intelligent
agriculture are two such applications. In many of such applications, data
sensed and collected by WSN needs to be processed further and transported to
servers where the end results are to be analyzed and utilized. For such
142
situations, the data collecting centre (base station node), needs to
communicate the data collected to the end user with the available network.
Since ubiquitous wired networking (i.e. Internet) is available, the base stations
need to transfer the data through these wired networks. For each application
the base station node needs to be interfaced to a wired TCP/IP network
(Dunkels et al 2004). This chapter evaluates the performance of the proposed
algorithms in such an integrated network of WSN interfaced to a wired
TCP/IP network.
6.4.1 Wired Cum Wireless Sensor Networks
This section explains about the simulations conducted to evaluate
the performance of the proposed routing and congestion control algorithms
HETRA and TCP/Exp in the seven node distribution patterns discussed in the
previous chapter. The details of hierarchical addressing used for interfacing
the WSN to the wired TCP/IP network in ns2 are also explained in detail.
Performance of the HETRA and TCP/Exp is evaluated by assuming
a wireless sensor network interfaced to a wired network as shown in
Figure 6.15.
Figure 6.15 WSN interfaced to wired network (Internet)
143
This work is done to establish the following:
The TCP/Exp algorithm is designed for wired network and is
found to perform extremely good in such networks when
compared to the other standard TCP congestion control
algorithms.
HETRA is designed for optimized use of energy and extend
the NLT of WSN. This algorithm also performs very well
compared with the other wireless routing algorithms.
The Combination HETRA and TCP/Exp performs better in
almost all fixed pattern topology of WSN.
Hence, this combination will definitely perform better if a network
topology is created with the wireless sensor network nodes and sink being
connected to a wired network. To justify this, a wireless cum wired topology
is simulated and the performance of the combination HETRA with TCP/Exp
is evaluated.
6.4.2 Node Distribution Pattern for WSN with Wired Interface
The Wireless network remains the same as explained in the
previous chapter and the seven proposed node distributions patterns are used.
The WSN topology uses a central base station node to collect the sensed data.
The wired TCP/IP network is interfaced to such WSN network.
The base station node is connected to a router node and this router in turn is
connected to two sink nodes. Figure 6.16 shows one simulated topology
(ALL Pattern) with the wired network. The wired network may be connected
to any existing wired TCP/IP network.
144
Figure 6.16 Nodes placed as rectangular grid (Pattern - ALL)
6.4.3 Simulation of WSN with Wired Interface
The topologies simulated are the same seven node distribution
patterns used in chapter 5. But a wired network containing a router node
and two sink nodes are interfaced to the base station node of WSN, which
receives the data packets from the sensor nodes. The topologies simulated are
explained below.
In addition to the simulation set up discussed in chapter 3 for
simulating the WSN, additional nodes are added for forming a wired network.
Here, all the wireless nodes and nodes in the wired network are allotted with
hierarchical addressing. The hierarchical addressing in ns2 uses the following
format.
Domain_address. Cluster_address. Node_address.
The nodes are divided into two domains - one containing wireless
nodes including the base station node, the other containing nodes of wired
145
network. The interface between WSN and Wired network is through the base
station node. The data sensed by the sensor nodes are sent to the base station
node through the intermediate sensor nodes. These data received by the base
station node from the various sensor nodes are collected and locally
processed. The information processed is sent to the end user through the
wired TCP/IP network, by sending them first to the gateway (router) node and
then to the required sink node(end user).
The query-response makes use of the hierarchical addresses while
sending a query to the sensor node as well as while transmitting the response
(after sensing the required data) to the end user.
6.4.4 Simulation Program
In ns2, simulation of Hierarchical Addressing is possible only with
AODV and DSDV among the wireless routing protocols available. This is
because these protocols include both domain/clustering support and base
station support. But DSR in ns2 is implemented as a flat routing protocol
only. It does not provide domain/clustering support and base station support.
The proposed HETRA algorithm includes the domain/clustering support and
base station support. Hence the performance evaluation of WSN with wired
network interface compares HETRA with AODV and DSDV only.
The program segment used to define the hierarchical addressing
space is given below:
AddrParams set domain_num_ 2
AddrParams set cluster_num_ {1 1}
AddrParams set nodes_num_ {3 51}
146
As already explained, the entire network nodes are grouped into
two domains. Each domain consists of a single cluster. Each cluster consists
of the nodes. Cluster 0 in domain 0 consists of nodes of wired network, i.e.
one router and two host nodes. Cluster 0 in domain 1 consists of all the
wireless sensor nodes. In addition, this cluster also includes the gateway node
which acts as the interface node between the wireless network and wired
network. Based on these assignments of domain and cluster, each node is
allotted with the IP address as given in the program segment.
set router1 [$ns node 0.0.0]
set host1 [$ns node 0.0.1]
set host2 [$ns node 0.0.2]
set gw1 [$ns node 1.0.0]
set temp {1.0.1 1.0.2 1.0.3 1.0.4 1.0.5 1.0.6 1.0.7 1.0.8 1.0.9 1.0.10 1.0.11
1.0.12 1.0.13 1.0.14 1.0.15 1.0.16 1.0.17 1.0.18 1.0.19 1.0.20 1.0.21 1.0.22
1.0.23 1.0.24 1.0.25 1.0.26 1.0.27 1.0.28 1.0.29 1.0.30 1.0.31 1.0.32 1.0.33
1.0.34 1.0.35 1.0.36 1.0.37 1.0.38 1.0.39 1.0.40 1.0.41 1.0.42 1.0.43 1.0.44
1.0.45 1.0.46 1.0.47 1.0.48 1.0.49 1.0.50}
for {set i 4} {$i < $opt(wirelessNodes)+3 } {incr i} {
set mobile$i [$ns node [lindex $temp [expr $i-4]]]
}
6.5 SIMULATION OF NODE DISTRIBUTION PATTERNS FOR
WSN INTERFACED TO A WIRED TCP/IP NETWORK
Seven node distribution patterns are simulated for evaluating the
performance of the combination of the proposed Routing Algorithm and
Congestion Control Algorithm- HETRA and TCP/Exp. These topologies are
simulated to cover a rectangular area of 800m 500m. This area can be
changed to any size by modifying the size in the tcl program. The simulation
setup for each node distribution patterns is discussed below.
147
6.5.1 ALL Pattern
This pattern shown in Figure 6.17 covers the area by placing a
rectangular grid of sensor nodes. Totally 50 nodes are placed as a 5 10
rectangular array. One node is assumed to be the phenomenon node. This
node is made to move over the entire area during the simulation period, with
the assumption of a phenomenon occurring at different places of the area.
This phenomenon node sends signal to the sensor nodes, which is analogous
to the sensor nodes sensing the phenomenon. With this basic assumption, the
sensor nodes after sensing the phenomenon send the information to a central
node placed at the location (250, 150).
Figure 6.17 Nodes placed as rectangular grid (Pattern - ALL)
This central node is the gateway node or base station node. The
data collected by this gateway node is sent over the wired network. The wired
network is now formed by connecting a router to the gateway node and two
hosts (or destination nodes) connected to the router nodes. The gateway node
sends the data through the router node to the host node, where the data is
processed.
In the case of simulation of WSN interfaced to wired TCP/IP
network, hierarchical addressing is used. This is analogous to the allocation
148
of IP address to each node including the sensor nodes. This facilitates the
gateway node to act as wireless node to collect the sensed data and as a wired
node to communicate on wired TCP/IP network.
The hierarchical addressing in ns2 uses the following format of
addressing, Domain-address. Cluster-address. Node-address.
Here in the simulated topology, two domains are assumed. Each
domain is assumed with one cluster each. One cluster consists of sensor
nodes and gateway node and the other cluster consists of router node and host
nodes of wired network.
In ALL pattern the hierarchical addressing for the router and host
nodes are allocated as shown below:
Router {0.0.0} - node 0
Host 1 {0.0.1} - node 1
Host 2 {0.0.2} - node 2
The address for the wireless sensor nodes are:
Gateway {1.0.0} - node 3
Sensor nodes {1.0.1} TO {1.0.50} - node 4 to 53
With these address allocations, a wireless and wired network
topology is simulated.
149
6.5.2 CIRCULAR Pattern
This pattern covers the area with 42 nodes placed in a CIRCULAR
pattern as shown in Figure 6.18. The gateway node is placed at the location
(250, 250). Here again the phenomena node is made to move around the area
simulating the conditions of occurrence of a natural phenomenon.
Figure 6.18 Nodes placed as a circular pattern (Pattern - CIRCULAR)
The hierarchical addresses of the wired network nodes i.e. router
and host nodes are the same. The gateway node also has the same address as
that allocated in the case of ALL pattern. The sensor node addresses are from
{1.0.1} to {1.0.42}.
6.5.3 DIAMOND Pattern
The sensor nodes are arranged in the form of a DIAMOND pattern
as shown in Figure 6.19 to cover the area. Here 37 sensor nodes are simulated
and the gateway node is placed at (250, 250).
150
Except the sensor nodes, other nodes have allocated with the same
hierarchical address. The sensor nodes have the addresses ranging from
{1.0.1} to {1.0.37}
Figure 6.19 Nodes placed in a diamond pattern (Pattern - DIAMOND)
6.5.4 CROSS Pattern
This pattern covers the area with 20 nodes placed in a CROSS
pattern. This is shown in Figure 6.20. The gateway node is placed at the
location (300, 150). Here again the phenomena node is made to move around
the area simulating the conditions of occurrence of a natural phenomenon.
Figure 6.20 Nodes placed in a cross pattern (Pattern - CROSS)
151
The hierarchical addresses of the wired network nodes i.e. router
and host nodes are the same. The gateway node also has the same address.
The sensor node addresses are ranging from {1.0.1} to {1.0.20}
6.5.5 CHI SQUARE Distribution Pattern
This pattern covers the area with 24 nodes placed in a CHI
SQUARE distribution pattern as shown in Figure 6.21. The gateway node is
placed at the location (164, 92). Here again the phenomena node is made to
move around the area simulating the conditions of occurrence of a natural
phenomenon.
Figure 6.21 Nodes placed in a Chi Square Distribution pattern
(Pattern - CHI)
The hierarchical addresses of the wired network nodes i.e. router
and host nodes are the same. The gateway node also has the same address.
The sensor node addresses are from {1.0.1} to {1.0.24}.
6.5.6 STEP Pattern
The pattern shown in Figure 6.22 covers the area with 19 nodes
placed in a STEP pattern. The gateway node is placed at the location
152
(250, 150). Here again the phenomena node is made to move around the area
simulating the conditions of occurrence of a natural phenomenon.
The hierarchical addresses of the wired network nodes i.e. router
and host nodes are the same. The gateway node also has the same address.
The sensor node addresses are from {1.0.1} to {1.0.19}
Figure 6.22 Nodes placed in a STEP pattern (Pattern - STEP)
6.5.7 EYE Pattern
This pattern covers the area with 33 nodes placed in an EYE pattern
as shown in Figure 6.23. The gateway node is placed at the location
(250, 150). Here again the phenomena node is made to move around the area
simulating the conditions of occurrence of a natural phenomenon.
The hierarchical addresses of the wired network nodes i.e. router
and host nodes are the same. The gateway node also has the same address.
The sensor node addresses are from {1.0.1} to {1.0.33}.
153
Figure 6.23 Nodes placed in an eye pattern (Pattern - EYE)
With these simulated node distribution patterns for the WSN
interfaced to wired network, the network is simulated with the various routing
algorithms and congestion control algorithms. The performance of these
algorithms is measured using the same metric used for the WSN with only
wireless nodes. The number of data packets delivered and the resulting
throughput are evaluated. Then the NLT, ANLT and DANLT product terms
are evaluated for comparison. The next section discusses the results of the
simulation experiments conducted.
6.6 RESULTS AND ANALYSIS OF THE SIMULATION OF
WSN WITH WIRED INTERFACE
The simulation experiments with the routing algorithms (AODV,
DSDV and HETRA), Congestion control algorithms (TCP/Tahoe, TCP/Reno,
MIMD-Poly, PIPD-Poly and TCP/Exp) with different node distribution
patterns are conducted using the tcl program and hierarchical addressing. The
results of the experiments are tabulated and also shown in graphs.
The simulation is performed for two different time duration. One
simulation is conducted for 10 seconds and the other is for 20 seconds.
Simulation is performed by choosing a congestion control algorithm, a
154
routing protocol and a node distribution pattern. The different routing
protocols assumed are AODV, DSDV, and HETRA. The congestion control
algorithms assumed are TCP/Tahoe, Reno, MIMD-Poly, PIPD-Poly and
TCP/Exp. The topologies simulated are wired interface with ALL pattern,
CROSS pattern, CIRCULAR Pattern, DIAMOND pattern, EYE pattern,
STEP pattern and CHI SQUARE Distribution pattern.
For example, the combination of AODV with TCP/Tahoe is
initially assumed in the ALL pattern. Simulation assumes that different
sensor nodes senses the data and send them to the base station node. The base
station node which is also the gateway node collects all the data for an
interval of time and sends them over the wired network. These data through
the router travels to the host node which is assumed to be the server node
when further processing is to be done.
In the simulation experiments, instead of all the sensor nodes
assumed to sense and transmit the data to the base station node, a sample of
four sensor nodes are assumed to transmit the sensed data. These nodes are
assumed to be in four different directions from the central base station node.
The base station node is assumed to collect these data for a fixed
interval of time and send all these collected data over the wired network.
Each simulation experiment conducted will store the details of
simulation in two files: a trace file and a nam file. The nam file is used to
visually show the various activities during the entire simulation period. The
packets traveling from the source node to the destination node through the
intermediate nodes, the dropped packets, the acknowledgement packets from
the destination node to the source node will be visually shown by running the
nam file in the nam editor.
155
The trace file in turn records all these events shown visually by a
nam, in the form of records. Each record gives the following details:
Packet is sent or received
Time at which the packet is sent or received
The packet is a TCP packet, TCP/ACK packet or RTR packet
id of the source node and intermediate nodes
port address
By extracting the information from their trace file, the last
successfully acknowledged data can be formed. Using this information, the
number of data packets successfully received at the base station node can be
evaluated. By using the equation (3.8) the throughput can also be evaluated.
The simulation experiment is now repeated for AODV with
TCP/Reno, MIMD, PIPD and TCP/Exp in ALL pattern. In each case, the
number of data packets successfully received and the corresponding
throughput is found and tabulated.
Similarly, the simulation experiment is repeated with DSDV and all
the congestion control algorithms in ALL pattern. The same experiment is
repeated for HETRA with all congestion control algorithms in ALL pattern.
In each case, the number of data packets successfully received at
the gateway node and the corresponding throughput is evaluated. These
values are presented in Figure 6.24.
156
Figure 6.24 Number of Data Packets received and Throughput in ALL
Pattern
This figure clearly shows that the HETRA routing algorithm
performs better than AODV and DSDV. With HETRA as the routing
algorithm, TCP/Exp produces better results with less number of packet drops
and higher throughput compared with other congestion control algorithms i.e.
TCP/Reno, MIMD, PIPD, TCP/Tahoe.
Hence, the combination HETRA and TCP/Exp perform more
efficiently in ALL pattern compared with other combination of Routing and
congestion control algorithms.
The above simulation experiment is repeated for the patterns,
CROSS, CIRCULAR, DIAMOND, EYE, STEP and CHI SQUARE
Distribtution.
The number of data packets successfully received at the base
station node and the corresponding throughput values are found. These
values are shown in Figures 6.25 to 6.30. All these figures clearly indicate
that in each pattern the combination HETRA performs better compared with
AODV and DSDV with HETRA as the routing algorithm, TCP/Exp
congestion control algorithm produces better results compared with
TCP/Tahoe, Reno, MIMD and PIPD.
157
Figure 6.25 Number of Data Packets received and Throughput in
CIRCULAR Pattern
Figure 6.26 Number of Data Packets received and Throughput in
CROSS Pattern
Figure 6.27 Number of Data Packets received and Throughput in
DIAMOND Pattern
158
Figure 6.28 Number of Data Packets received and Throughput in EYE
Pattern
Figure 6.29 Number of Data Packets received and Throughput in STEP
Pattern
Figure 6.30 Number of Data Packets received and Throughput in CHI
SQUARE Pattern
159
When the result of the combination HETRA and EXP is compared
with the different patterns, CROSS pattern delivers the maximum of
1253 packets in a simulation time of 10 seconds. Next to CROSS pattern,
ALL pattern delivers 1224 packets. But the number of sensor nodes in
CROSS pattern is 20 and in ALL pattern it is 50. Hence the CROSS pattern
is more efficient than the other patterns. Hence, the combination HETRA,
TCP/Exp and CROSS distribution pattern performs most efficiently among
the combinations simulated.
The comparisons of congestion control TCP/Exp with all the
routing algorithms and node distribution patterns is shown in Figure 6.31.
This clearly indicates that the combination HETRA, TCP/Exp and CROSS
pattern is the best choice.
Figure 6.31 Comparisons of TCP/Exp with all the routing algorithms
and node distribution patterns
160
The simulation experiment is repeated for a simulation time of
20 seconds. The same combinations are simulated. These results again prove
that the same combination is the most efficient among all the simulated
combinations.
Simulation experiments are exclusively conducted to evaluate the
energy efficiency of the various combinations of Routing algorithms (AODV,
DSDV and HETRA), congestion control Algorithms (TCP/Tahoe, Reno,
MIMD, PIPD and TCP/Exp) in the seven node distribution patterns (ALL,
CIRCULAR, CROSS, DIAMOND, STEP, EYE AND CHI SQUARE). An
initial energy of 0.5 Joules is assumed in each simulation.
Lifetime of the network is calculated for each simulated network
topology from the trace file. The lifetime of the network is taken as the time
duration from the first packet that is transmitted from a node and the last
packet (before a single node dies out of energy) received at the base station
node. This value is calculated by extracting the information of time instead of
packet transmission/reception and the energy remaining in each node from the
trace file using the awk programming discussed in chapter 5.
From this extracted information, the network lifetime is calculated
and the values are shown for each pattern in the Figures 6.32 (a) to (g). From
these figure we could infer that HETRA, yielding a maximum network
lifetime in each pattern and EXP give better results among the congestion
control algorithm. Hence, in WSN with wired interface, the combination
HETRA with EXP in CROSS pattern yielded the maximum in terms of
throughput as well as NLT.
Again, as a single parameter for comparison of the performance,
the DANLT product is evaluated and is shown in Figure 6.33 (a) through (g)
for all the patterns. This again shows that, the only combination which is
more energy efficient among all the simulated combinations is HETRA,
TCP/Exp in CROSS pattern.
161
0
1
2
3
4
5
6
7
Reno TCP M IM D PIPD EXP
Congestion Control Algorithms
NLT
in
se
co
nd
s
AODV
DSDV
HETRA
0
1
2
3
4
5
6
Reno TCP M IM D PIPD EXP
Congestion Control Algorithms
NLT
in
se
co
nd
s
AODV
DSDV
HETRA
(a) ALL Pattern (b) CIRCULAR Pattern
0
2
4
6
8
Reno TCP M IM D PIPD EXP
Congestion Control Algorithms
NLT
in
se
co
nd
s
AODV
DSDV
HETRA 0
1
2
3
4
5
6
Reno TCP M IM D PIPD EXP
Congestion Control Algorithms
NLT
in
se
co
nd
s
AODV
DSDV
HETRA
(c) CROSS Pattern (d) DIAMOND Pattern
0
0.5
1
1.5
2
2.5
3
3.5
Reno TCP M IM D PIPD EXP
Congestion Control Algorithms
NLT
in
se
co
nd
s
AODV
DSDV
HETRA
0
1
2
3
4
5
6
Reno TCP MIMD PIPD EXP
Congestion Control Algorithm
NL
T i
n s
eco
nd
s
AODV
DSDV
HETRA
(e) EYE Pattern (f) STEP Pattern
0
1
2
3
4
5
6
Reno TCP MIMD PIPD EXP
Congestion Control Algorithm
NL
T in
seco
nd
s
AODV
DSDV
HETRA
(g) CHI SQUARE Distribution Pattern
Figure 6.32 NLT of different node distribution patterns
162
0
50
100
150
Reno TCP M IM D PIPD EXP
Congestion Control Algorithms
DA
NLT
Pro
du
ct
AODV
DSDV
HETRA 0
20
40
60
80
100
120
140
Reno TCP M IM D PIPD EXP
Congestion Control Algorithms
DA
NLT
Pro
du
ct
AODV
DSDV
HETRA
(a) ALL Pattern (b) CIRCULAR Pattern
0
100
200
300
400
500
Reno TCP M IM D PIPD EXP
Congestion Control Algorithms
DA
NLT
Pro
du
ct
AODV
DSDV
HETRA
0
20
40
60
80
100
120
140
Reno TCP M IM D PIPD EXP
Congestion Control Algorithms
DA
NLT
Pro
du
ct
AODV
DSDV
HETRA
(c) CROSS Pattern (d) DIAMOND Pattern
0
20
40
60
80
100
Reno TCP M IM D PIPD EXP
Congestion Control Algorithms
DA
NLT
Pro
du
ct
AODV
DSDV
HETRA
0
100
200
300
400
Reno TCP MIMDPIPD EXP
Congestion Control
Algorithms
DA
NL
T P
rod
uc
t
AODV
DSDV
HETRA
(e) EYE Pattern (f) STEP Pattern
0
50
100
150
200
250
Reno TCP MIMD PIPD EXP
Congestion Control Algorithms
DA
NL
T p
rod
uc
t
AODV
DSDV
HETRA
(g) CHI SQUARE Distribution Pattern
Figure 6.33 DANLT Product of Different Node Distribution Patterns
163
6.7 COMPARISON OF THEORETICAL VALUES OF NLT
WITH THE SIMULATED RESULTS
The maximum theoretical value of NLT may be calculated from the
equation (5.17) by substituting the values of initial energy, energy consumed
for transmission, reception and processing and the number of nodes of each
pattern. The NLTmax for each pattern may be calculated and compared with
the NLTs obtained by conducting the simulation experiments using ns2. The
NLTmax is now calculated for the reference pattern ‘ALL’.
6.7.1 Calculation of NLTmax for ALL Pattern
The values used for the simulation experiments conducted to find
the NLT are used and substituted in equation (5.17).
These values are,
Initial energy Ei = 0.5 Joules or 0.5 watt-seconds
(1 Joule = 2.778 10-7 KWh)
Energy consumed for transmitting the data, et = 0.08w
Energy consumed for receiving the data, er = 0.02w
Energy consumed for sensing and processing the data, ep= 0 w.
Compared to the values of energy consumed for transmission and
reception, the consumption of energy for sensing the phenomenon and
internal processing in the sensor node will be very negligible and hence
assumed as 0 w.
164
The probability of the two nodes involved sensing and transmitting
data to the base station is obtained by substituting x=2 in f(x), the weighting
function. Hence,
f(x) = 2 * 2
2
2
1x
e
= 0.108
navg is the average number of nodes involved in the transmission of data from
the source to the base station and this value for the all pattern is
approximately 5.
The number of nodes in ALL pattern is 50. Hence the cost factor
topo is calculated as,
topo =ALL
p
N
N
= 1 ( since Np = NALL)
Substituting all these values in equation for NLTmax
2
pimax
xALL
2t r p avg
NENLT *
N1(e e e )* 2* e *n
2
0.5*1
(0.08 0.02)*0.108*5
= 9.259 seconds.
This value is the theoretical maximum of the NLT for ALL pattern.
Similarly, the value of NLTmax may be calculated for other patterns. The
values obtained are shown in Table 6.3.
165
Table 6.3 Values of NLTmax for the node placement patterns
Sl.No.Node Placement
Pattern
Number of
nodestopo NLTmax in
seconds
1. ALL 50 1 9.259
2. CHI Square 21 0.648 6.0
3. CIRCULAR 42 0.84 7.78
4. CROSS 20 0.632 5.86
5. DIAMOND 37 0.86 7.96
6. EYE 33 0.81 7.52
7. STEP 20 0.632 7.78
Now the theoretical values obtained above are compared with the
experimental values obtained by the simulation of the above patterns.
Table 6.4 shows this comparison for the various routing algorithms and
various congestion control algorithms for ALL Pattern.
Table 6.4 Comparison of Theoretical and Experimental NLT with
various Routing algorithms and congestion control
algorithms for ALL Pattern
Experimental value of NLT (in seconds) for
Routing Algorithms
Congestion
Control
Algorithms DSR DSDV AODV HETRA
Theoretical
NLTmax
(in seconds)
TCP 1.57 2.54 1.65 5.8
Exp 2.54 2.56 2.55 7.08
Reno 1.58 2.6 2.62 3
MIMD 1.54 2.55 1.56 4.5
PIPD 1.51 2.54 1.51 5.55
9.259
166
The comparison shows that the experimental value of NLT for
HETRA with TCP/Exp and TCP/Tahoe are closer to the theoretical
maximum. The values obtained with the other routing algorithms in
combination with the congestion control algorithms are less than the
theoretical maximum. The reason for this reduction in NLT is due to the fact
that the other routing algorithms do not consider the energy constraint while
forming the routing. Hence, routes formed with the aim of less number of
hops use almost the same set of intermediate nodes for transmission of sensed
data from a particular position of sensing field. This will exhaust the energy in
the intermediate nodes and lead to early network splitting.
A similar comparison may be presented for the other node
placement patterns. These are shown in Tables 6.5 to 6.10.
Table 6.5 Comparison of Theoretical and Experimental NLT with
various Routing algorithms and congestion control
algorithms for CHI Pattern
Experimental value of NLT (in seconds) for
Routing Algorithms
Congestion
Control
Algorithms DSR DSDV AODV HETRA
Theoretical
NLTmax
(in seconds)
TCP 1.09 1.87 0.91 3.747
Exp 1.14 1.18 0.97 4.53
Reno 1.03 1.87 0.94 2.02
MIMD 1.04 1.87 0.93 3.75
PIPD 1 1.85 0.96 3.81
6.0
167
Table 6.6 Comparison of Theoretical and Experimental NLT with
various Routing algorithms and congestion control
algorithms for CIRCULAR Pattern
Experimental value of NLT (in seconds) for
Routing Algorithms
Congestion
Control
Algorithms DSR DSDV AODV HETRA
Theoretical
NLTmax
(in seconds)
TCP 1.52 1.9 1.54 4.93
Exp 1.502 2.57 1.54 5.91
Reno 1.52 2.6 1.56 2.06
MIMD 1.522 2.57 1.527 3.9
PIPD 1.51 2.55 1.55 4.27
7.78
Table 6.7 Comparison of Theoretical and Experimental NLT with
various Routing algorithms and congestion control
algorithms for CROSS Pattern
Experimental value of NLT (in seconds) for
Routing Algorithms
Congestion
Control
Algorithms DSR DSDV AODV HETRA
Theoretical
NLTmax
(in seconds)
TCP 1.38 2.92 1.41 3.84
Exp 1.36 2.69 1.42 5.83
Reno 1.93 2.89 2.42 3
MIMD 1.36 2.91 1.39 3.58
PIPD 1.39 2.92 1.4 4.54
5.86
168
Table 6.8 Comparison of Theoretical and Experimental NLT with
various Routing algorithms and congestion control
algorithms for DIAMOND Pattern
Experimental value of NLT (in seconds) for
Routing Algorithms
Congestion
Control
Algorithms DSR DSDV AODV HETRA
Theoretical
NLTmax
(in seconds)
TCP 1.52 2.17 1.55 5.97
Exp 1.53 2.23 1.54 6.96
Reno 1.53 2.3 1.55 3.07
MIMD 1.53 2.22 1.55 3.96
PIPD 1.52 2.18 1.5 4.74
7.96
Table 6.9 Comparison of Theoretical and Experimental NLT with
various Routing algorithms and congestion control
algorithms for EYE Pattern
Experimental value of NLT (in seconds) for
Routing Algorithms
Congestion
Control
Algorithms DSR DSDV AODV HETRA
Theoretical
NLTmax
(in seconds)
TCP 1.47 3.06 1.48 5.09
Exp 1.46 2.47 1.49 6.09
Reno 1.47 2.92 2.44 2.06
MIMD 1.454 3.07 1.48 3.09
PIPD 1.45 3.07 1.49 4.08
7.52
169
Table 6.10 Comparison of Theoretical and Experimental NLT with
various Routing algorithms and congestion control
algorithms for STEP Pattern
Experimental value of NLT (in seconds) for
Routing Algorithms
Congestion
Control
Algorithms DSR DSDV AODV HETRA
Theoretical
NLTmax
(in seconds)
TCP 0.79 2.27 1 3.44
Exp 0.87 2.3 1.14 4.84
Reno 0.84 2.16 0.98 1.39
MIMD 0.87 2.21 0.98 2.41
PIPD 0.79 2.18 0.95 3.32
5.86
All the above comparisons show that the combinations HETRA
with TCP/Exp have the experimental values closely matching the theoretical
values.