i
DATA AGGREGATION TO EXTEND
LIFE OF WIRELESS SENSOR
NETWORK
By
Rathod Gaurang Dhirubhai
Guided by
Prof. Niteen Patel
(Associate Professor)
A Thesis submitted to
Gujarat Technological University
In Partial Fulfillment of Requirement for
The Degree of Master of Engineering
In Electronics and communication
MAY 2014
Department of Electronics & Communication Engineering
Sarvajanik College of Engineering & Technology
Dr. R.K. Desai Marg,
Athwalines, Surat - 395001, India.
ii
Prof. Niteen Patel
Associate Professor
Electronics & Communication Department
Sarvajanik College of Engineering &
Technology, Surat
Dr. Vaishali Mungurwadi
Principal,
Faculty of Engineering
Sarvajanik College of Engineering &
Technology, Surat
Certificate
This is to certify that research work embodied in this thesis entitled Data
Aggregation to Extend Life of Wireless Sensor Network was carried out by Mr.
Gaurang Dhirubhai Rathod (120420704005) at Sarvajanik College of Engineering
and Technology (042) for partial fulfillment of M.E. degree to be awarded by Gujarat
Technological University. This research work has been carried out under my supervision
and is to the satisfaction of department.
Date:
Place: Sarvajanik College of Engineering & Technology, Surat
Seal of Institute
iii
Signature of Guide:
Name of Guide: Prof. Niteen Patel
Institute Code: 042
Dr. Vaishali Mungurwadi
Principal, Faculty of Engineering
Sarvajanik College of Engineering &
Technology, Surat
Compliance Certificate
This is certify that research work embodied in this thesis entitled Data Aggregation to
Extend Life of Wireless Sensor Network, was carried out by Mr. Gaurang
Dhirubhai Rathod (120420704005) studying at Sarvajanik College of Engineering
and Technology(042) for partial fulfillment of M.E. degree to be awarded by Gujarat
Technological University. He has complied with the comments given by the Dissertation
phase I as well as Mid Semester Thesis Reviewer to my satisfaction.
Date:
Place: Sarvajanik College of Engineering and Technology, Surat
Signature of Student:
Name of Student: Rathod Gaurang
Enrollment No: 120420704005
Seal of Institute
iv
Thesis Approval Certificate
This is to certify that research work embodied in this entitled Data Aggregation to
Extend Life of Wireless Sensor Network was carried out by Mr. Gaurang Rathod
(120420704005) at Sarvajanik College of Engineering & Technology is approved for
the degree of Master of Engineering in Electronics & Communications by Gujarat
Technological University.
Date
Place:
Examiners Sign and Name:
.. ..
( ) ( )
v
Declaration of Originality
We hereby certify that we are the sole authors of this thesis and that neither any part of
this thesis nor the whole of the thesis has been submitted for a degree to any other
University or Institution.
We certify that, to the best of our knowledge, the current thesis does not infringe upon
anyones copyright nor violate any proprietary rights and that any ideas, techniques,
quotations or any other material from the work of other people included in our thesis,
published or otherwise, are fully acknowledged in accordance with the standard
referencing practices. Furthermore, to the extent that we have included copyrighted
material that surpasses the boundary of fair dealing within the meaning of the Indian
Copyright (Amendment) Act 2012, we certify that we have obtained a written permission
from the copyright owner(s) to include such material(s) in the current thesis and have
included copies of such copyright clearances to our appendix.
We declare that this is a true copy of thesis, including any final revisions, as approved by
thesis review committee.
We have checked write up of the present thesis using anti-plagiarism database and it is in
allowable limit. Even though later on in case of any complaint pertaining of plagiarism,
we are responsible for the same and we understand that as per UGC norms, University
can even revoke Master of Engineering degree conferred to the student submitting this
thesis.
Date:
Place: Sarvajanik College of Engineering and Technology, Surat
Signature of Student :
Name of Student : Rathod Gaurang
Enrollment No : 120420704005
Signature of Guide :
Name of Guide : Prof. Niteen Patel
Institute Code : 042
vi
Acknowledgement
First and foremost, I would like to express my sincere gratitude to my guide, Prof. Niteen
Patel, Head of Electronics and Communication Department for immense help, guidance,
stimulating suggestion, and encouragement all the time with this thesis work. He always
provides a motivating and enthusiastic atmosphere to work; it is a great pleasure to do thesis
under his supervision.
I am equally grateful to Pritesh Saxena, Assistant Professor of Electronics and
Communication Department for helping me in sorting out the procedural work and his
precious guidance.
I also thank my friends and colleagues who provided help and valuable suggestion. And last
but not the least I wish to thank my parents for their encouragement and moral support.
Rathod Gaurang
vii
Table of Contents
Certificate ........................................................................................................................... ii
Compliance Certificate .................................................................................................... iii
Thesis Approval Certificate ............................................................................................. iv
Declaration of Originality .................................................................................................. v
Acknowledgement ............................................................................................................. vi
Table of Contents ............................................................................................................. vii
List of Figures ..................................................................................................................... x
List of Tables ..................................................................................................................... xi
Abstract ............................................................................................................................. xii
1. Introduction ................................................................................................................ 1
1.1 Introduction .............................................................................................................. 1
1.2 Motivation ................................................................................................................ 1
1.3 Objective .................................................................................................................. 2
1.4 Thesis Organization ................................................................................................. 2
2. Introduction of Wireless Sensor Network .................................................................. 3
2.1 Introduction ............................................................................................................. 3
2.2 Sensor Node ............................................................................................................. 5
2.3 Challenges in the End Device (Node) ...................................................................... 6
2.3.1 Limited Memory .............................................................................................. 6
2.3.2 Limited Energy Resource ................................................................................. 6
2.3.3 Limited CPU Performance ............................................................................... 6
2.3.4 Tamper-Resistant Hardware............................................................................. 7
viii
2.4 Challenges in the Network ....................................................................................... 7
2.4.1 Hostile & Remote Environment ...................................................................... 7
2.4.2 Random Topology ........................................................................................... 7
2.4.3 Latency ............................................................................................................. 7
2.5 Wireless Sensor Network Application ..................................................................... 8
2.5.1 Event Detection ................................................................................................ 8
2.5.2 Periodic Reporting ........................................................................................... 8
2.5.3 Base Station Querying ..................................................................................... 8
2.5.4 Tracking ........................................................................................................... 8
3. Data Aggregation: An Overview ............................................................................... 9
3.1 Data Aggregation ..................................................................................................... 9
3.2 Factors Affected by Data Aggregation .................................................................. 11
3.3 Data Aggregation Techniques ................................................................................ 12
3.3.1 Flat Networks ................................................................................................. 13
3.3.2 Hierarchical Networks ................................................................................... 13
3.3.3 Structure Free Network .................................................................................. 19
3.4 Comparison between Hierarchical Networks and Flat network ............................ 19
3.5 Advantages and Disadvantages of Data Aggregation in WSN .............................. 20
4. Data Aggregation by Precision Allocation ............................................................. 21
4.1 Introduction of Aggregation for Continuous Data Measuring ............................... 21
4.2 Aggregation and Lifetime of Node ........................................................................ 22
4.3 Basics of Error Bound for Nodes ........................................................................... 22
4.4 Types of Aggregation Based on Precision Allocation ........................................... 23
4.5 Error Bound and Communication between Node and Sink ................................... 24
4.6 Optimal Precision Allocation ................................................................................. 24
4.7 Candidate Based Precision Allocation ................................................................... 25
4.8 Algorithm for Optimal Precision Allocation ......................................................... 26
ix
4.9 Adaptive Precision Allocation ............................................................................... 26
5. Experimental Work A ............................................................................................. 29
5.1 Nodes Data (temperature) Generation .................................................................. 29
5.2 Error Bound of Node ............................................................................................. 29
5.3 Adjustment in Error Bound of Node ...................................................................... 30
5.4 Assumptions and Simulation Environment ........................................................... 31
5.4.1 Error Bounds of Nodes .................................................................................. 32
5.4.2 Error Bound Changing Parameters ................................................................ 33
5.4.3 Residual Energy and Communication Frequency of Node............................ 34
5.5 Network with Multiple Monitoring Sensors .......................................................... 35
6. Experimental Work B.............................................................................................. 37
6.1 Simulation Environment ........................................................................................ 37
6.2 Steps for Creating Script in NS2 ............................................................................ 37
6.3 Simulation Parameters and Assumptions............................................................... 37
6.4 Description of Simulation ...................................................................................... 38
6.4.1 Same Error Bound Case ................................................................................. 39
6.4.2 Random Different Error Bound Case ............................................................ 42
6.4.3 Error Bound Based on Node Position (Energy) Case .................................... 43
6.4.4 Packet to Delivery Ratio ................................................................................ 45
Conclusion ........................................................................................................................ 46
References ......................................................................................................................... 47
Appendix: A Review Card ........................................................................................... 49
Appendix: B-Compliance Report of Review Card ....................................................... 50
x
List of Figures
Figure 2-1 A Typical Wireless Sensor Network Architecture [1]
........................................ 3
Figure 2-2 Architecture of Sensor Node [1]
.......................................................................... 5
Figure 3-1 Without Data Aggregation With Six Transmission [3]
..................................... 10
Figure 3-2 With Data Aggregation With Four Transmission [3]
........................................ 10
Figure 3-3 Effect of Data aggregation [3]
........................................................................... 11
Figure 3-4 Taxonomy of Data Aggregation [3]
.................................................................. 13
Figure 3-5 Cluster Based Sensor Network [4]
.................................................................... 14
Figure 3-6 Chain Based Sensor Network [4]
...................................................................... 15
Figure 3-7 Minimum Spanning Tree Based Routing [4]
.................................................... 16
Figure 3-8 Grid Based Data Aggregation [4]
...................................................................... 17
Figure 3-9 In-network Data Aggregation Scheme [4]
......................................................... 18
Figure 5-1 Temperature Data Profile ................................................................................. 29
Figure 5-2 Network Topology ........................................................................................... 31
Figure 5-3 Initial Error Bound for Node ............................................................................ 32
Figure 5-4 Error Bound of Node at Simulation End .......................................................... 32
Figure 5-5 Highest Residual Energy Node at Every Adjustment Period End ................... 33
Figure 5-6 Lowest Residual Energy Node at Every Adjustment Period End .................... 33
Figure 5-7 Value of Delta at Every Adjustment Period End ............................................. 34
Figure 5-8 No. of Times Node Send Data to Base Station ................................................ 35
Figure 5-9 Residual Energy of Node at Simulation End ................................................... 35
Figure 6-1 Simulation Topology ........................................................................................ 39
Figure 6-2 Hand Shaking Packets Transmit by Nodes ...................................................... 40
Figure 6-3 Residual Energy of all Node vs Time .............................................................. 40
Figure 6-4 Residual Energy of all Nodes vs Time ............................................................. 42
Figure 6-5 Residual Energy of all Nodes vs Time ............................................................. 44
xi
List of Tables
Table 3-1 Comparison between Hierarchical and Flat Networks ...................................... 19
Table 5-1 Network Parameters .......................................................................................... 31
Table 6-1 Network Parameters ........................................................................................... 38
Table 6-2 Remaining Energy of Node at Simulation End ................................................. 41
Table 6-3 Remaining Energy of Node at Simulation End ................................................. 43
Table 6-4 Remaining Energy of Node at Simulation End ................................................. 44
xii
DATA AGGREGATION TO EXTEND LIFE OF WSN
Submitted By
Rathod Gaurang Dhirubhai
Supervised By
Prof. Niteen Patel
Head of Department,
Electronics and Communication Engineering,
Sarvajanik College of Engineering and Technology,
Surat -395001, India.
Abstract
The fast advancement of hardware technology has enabled the development of tiny and
powerful sensor nodes, which are capable of sensing, computation and wireless
communication. This revolutionizes the deployment of wireless sensor network for
monitoring some area and collecting regarding information. However, limited energy
constraint presents a major challenge such vision to become reality. Data communication
between nodes consumes a large portion of the total energy consumption of the WSNs.
Consequently, Wireless sensor nodes are very small in size and have limited processing
capability with very low battery power. This restriction of low battery power makes the
sensor network prone to failure.
Data aggregation may be effective technique because it reduces the number of packets to
be sent to sink by aggregating the similar packets. Data aggregation has been put forward
as an essential technique to achieve power efficiency in sensor networks. The main goal
of data aggregation is to gather and aggregate data in an energy efficient manner so that
network lifetime is enhanced.
The data aggregation technique of precision allocation helps to balance the energy
consumption of network. By optimum precision allocation given to node, helps to control
xiii
the frequency of communication between node and base station. This way, effectively it
reduces less communication between sources and sink, which helps to reduce the energy
consumption.
In experiment work, assigning same precision, random precision and precision based on
distance and residual energy of node to all nodes in network and summarize energy
consumption of node. By periodically adjusting the precision of node extend the life time
of network compared to without aggregation and random precision allocation method.
This technique suits to problem of continues data measuring, like temperature, humidity,
water level, etc.
1
1. Introduction
1.1 Introduction
A wireless sensor network is a collection of wireless sensor nodes having limited resource
constrain and that may be mobile or stationary. Sensor nodes are located on a
dynamically changing environment. WSNs inherit many characteristics/features of
wireless ad hoc networks such as the ability for infrastructure-less setup, ability of the
nodes to self-organize and self-configure without the involvement of a centralized
network manager. These features help to set up WSNs in situations where there is no
existing network setup or fixed infrastructure network. On the other hand small size, low
power and the ability of wireless communication makes WSNs the ideal solution for
numerous applications such as remote environmental monitoring, medical healthcare
monitoring, agriculture monitoring, military surveillance, etc.
1.2 Motivation
Wireless sensor networks are expected to find wide applicability and increasing
deployment in the near future. WSN have tremendous potential because they expand
human ability to monitor and interact remotely with the physical world. This is the
upcoming field and because of its benefits, it is recent area of research. Wireless sensor
network is consists of thousands of densely deployed sensor nodes which can be used for
a number of applications. Sensor nodes are tiny devices which are composed of a sensing
unit, a radio, a processor & a limited battery power. A network of thousands of sensor
nodes could be setup for many applications such as environmental monitoring, health
monitoring, disaster management, industrial areas, military application and many more.
As world is growing up, human have some requirements to measure/monitor some of the
parameters in the remote area. At this movement WSN helps a lot to human being.
In Sensor Network, the energy is mainly consumed for three purposes: data transmission,
signal processing, and hardware operation. It is said that 70% of energy consumption is
due to data transmission. So for maximizing the network lifetime, the process of data
transmission should be optimized. The data transmission can be optimized by using
efficient routing protocols and effective ways of data aggregation.
2
Routing protocols have their own ways to save energy of nodes in the network by
providing or creating an optimal route from sensor nodes to base station or sink. Data
aggregation plays an important role in energy conservation of sensor network. Data
aggregation methods are used not only for finding an optimal path from source to
destination but also to eliminate the redundancy of data. Also multiple sensors may see
the same phenomenon, from different view and if this data can be reconciled into a more
meaningful form as it passes through the network, it becomes more useful to an
application. One more benefit of data aggregation is that if data is processed as it is
passed through the network, it may be compressed thus occupying less bandwidth. This
also reduces the amount of transmission power expended by nodes. Hence Data
aggregation can be considered as a very challenging problem in wireless sensor network.
1.3 Objective
Wireless sensor networks are energy constrained network. Since most of the energy
consumed for transmitting and receiving data, the process of data aggregation becomes an
important issue and optimization is needed. By data aggregation mechanism, we can save
energy of network and this way extend the life time of sensor network.
By precision allocation, the energy consumption of node can be balanced. Energy of node
can be saved by assigning different precision to each node. And by that precision, we
control the frequency of communication between node and sink and reduce data
transmission. And this way save the energy of node and extend the life time of network.
1.4 Thesis Organization
With the end of chapter 1, the whole thesis is organized as follows: Chapter 2 gives a
detailed study of wireless sensor network. Chapter 3 gives a detailed overview of data
aggregation. This chapter also presents the literature survey that had been done. Chapter 4
introduces and describes the precision allocation method for data aggregation. Chapter 5
presents the performance analysis of the experiment work which is done in MATLAB.
This chapter gives idea about error bound and how energy of network is balanced.
Chapter 6 explains experiment work done in NS2 tool. This chapter is more elaborates on
energy of nodes. It also provides the comparison results.
3
2. Introduction of Wireless Sensor Network
2.1 Introduction
The recent advances and the convergence of micro electro-mechanical systems
technology, integrated circuit technologies, microprocessor hardware and
nanotechnology, wireless communications, Ad-hoc networking routing protocols,
distributed signal processing, and embedded systems have made the concept of Wireless
Sensor Networks (WSNs). Sensor network nodes are limited with respect to energy
supply, restricted computational capacity and communication bandwidth. WSN [1]
are
usually infrastructure less networks that rely on each sensor to function as part of the
network.
Figure 2-1 A Typical Wireless Sensor Network Architecture [1]
Advances in microelectronics have enabled the development of exceptionally tiny sensor
nodes that have the ability of measuring ambient conditions such as temperature,
pressure, humidity, light intensity, and motion. The sensed data can then be transmitted
through an on-board radio transmitter to a single or multiple base stations (BSs) where it
can be further processed. The tiny size and inexpensive cost of such emerging sensor
nodes has encouraged practitioners to explore using them collaboratively in a network
formed in ad-hoc manner. Such networked sensor system not only is cost -effective but
4
also can provide fast and accurate information gathering in remote and risky areas. Figure
2.1 depicts typical Wireless Sensor Network architecture. The BS acts as a gateway for
linking the sensors to multiple command nodes.
The basic goals [1]
of a WSN are to
Determine the value of physical variables at a given location.
Detect the occurrence of events of interest, and estimate parameters of the detected
event or events
Classify a detected object
Track an object.
WSNs will be beneficial to detect the pre-cursors of these disasters, early warn the
population, evacuate them, and save their life. However, these disasters are largely
unpredictable and occur within very short spans of time. Therefore technology has to be
developed to capture relevant signals with minimum monitoring delay. Wireless sensors
are one of the cutting edge technologies that can quickly respond to rapid changes of data
and send the sensed data to a data analysis centre in areas where cabling is
inappropriate [3]
.
The Important Requirements of a WSN are
Use of a large number of sensors
Attachment of stationary sensors
Low energy consumption.
.Self organization capability
Collaborative signal processing.
Querying ability
Less delay
5
2.2 Sensor Node
The architecture of sensor node is shown in Figure 2.2.
Figure 2-2 Architecture of Sensor Node [1]
The end device in WSN (sensor node) is composed of four basic units
1. Sensing Unit
It consists of an array of sensors that can measure the physical characteristics of its
environment, like temperature, light, vibration, and others. Each sensor has the ability to
sense environmental characteristics via the sensing unit and then use the Analog to
Digital Converter (ADC) to convert the sensed analog data into digital.
2. Processing Unit
It is, in most cases, composed of an internal memory to store data and application
programs, and a microcontroller to process the data. The microcontroller can be
considered as a highly constrained computer that contains the memory and interfaces
required to create simple applications. This unit should be able to work with a limited
resource of energy and process efficiently the digital data delivered by the sensing unit.
3. Power Unit
It provides the energy required by all the sensor components, and such energy may come
from either a battery or from renewable sources.
6
4. Transceiver Unit
It is able to send and receive messages through a wireless channel. In other words, it gives
the sensor the ability to talk to other sensor nodes and form an Ad Hoc Network.
2.3 Challenges in the End Device (Node)
All security approaches require a certain amount of resources for the implementation,
including data memory, code space, and energy to power the sensor during the run of the
approach. However, currently these resources are very limited in a tiny wireless sensor
node. The hardware specifications for three types of sensor node, namely MICA2 [16]
,
FLECK [16]
, and MICAZ [16]
and highlights the resource constraints in the end device of
WSNs The challenges in the sensors hardware are discussed as follows:
2.3.1 Limited Memory
A sensor node is a tiny device with only a small amount of memory and storage space for
the code. In order to build an effective security mechanism, it is necessary to limit the
code size of the security algorithm. For example, one common sensor type (MICA2) has
4K RAM, 128K program memory, and 512K flash storage.
2.3.2 Limited Energy Resource
The energy resource is the biggest challenge in WSNs. It is assumed that once sensor
nodes are deployed in a WSN, their batteries cannot be easily replaced due to the high
operating costs of being deployed in remote areas. Some current versions of sensor nodes
such as MICA2 are powered by 2AA batteries. Therefore, the battery charge taken with
them to the field must be conserved to prolong the life of the individual sensor node and
the entire sensor network. For example, when implementing a cryptographic function or
protocol in a sensor node, the energy impact of the proposed solution should be
considered.
2.3.3 Limited CPU Performance
The CPU used in MICA2 sensors, for example, is the16 bit, 8 MHz Texas Instruments
MSP430 microcontrollers [16]
. Embedded processors are generally not as powerful as
7
those in nodes of a wired network. As such, complex cryptographic algorithms should be
avoided in WSNs.
2.3.4 Tamper-Resistant Hardware
The most obvious tamper-resistance strategies are hardware-based ones, which involve
extra cost to implement special complex hardware circuits in the electronic device. To run
these circuits, extra energy should be ensured. Due to the targeted low cost and the
limited power resource existing in sensor nodes, the hardware-based tamper protection
solutions are very limited.
2.4 Challenges in the Network
Sensor nodes are usually scattered randomly in the field to perform certain tasks. There is
usually no infrastructure support for sensor networks. Sensor nodes self-organize to
form a network. However, some network challenges exist. These challenges are discussed
as follows:
2.4.1 Hostile & Remote Environment
Depending on the function of a particular sensor network, the sensor nodes may be left
unattended for long periods of time. Most WSNs are deployed in remote or hostile
environments such as battlefields. Therefore, sensor nodes without tamper-resistant
hardware cannot be protected from physical attacks since the deployment area accessible
to anyone. An adversary could capture a sensor node or even introduce his own malicious
nodes inside the network.
2.4.2 Random Topology
WSN is often deployed in random distribution since it is mostly used in remote or hostile
environments. Consequently, there is no chance to know its topology beforehand. Also,
the topology after the deployment keeps changing because some sensors disappear due to
drained resources, or for instance by being damaged, or faulty.
2.4.3 Latency
The communication range of most sensor nodes is limited in order to conserve energy.
The MICA2, FLECK, and MICAZ sensor nodes have radio coverage area up to
8
152m, 500m, and 75m, respectively. To move a packet from one end of the network to
another, a multi-hop routing approach is needed. So it consume time for transmission
from node to sink.
2.5 Wireless Sensor Network Application
WSN applications [2]
are classified into four classes:
2.5.1 Event Detection
The objective of sensor networks in this application class is to detect rare events, such as
forest fires or intrusions, and to promptly communicate a report of such as event the sink.
2.5.2 Periodic Reporting
The objective of the sensor networks in this type of application is to send periodic
updates to the sink. Thus, there is regularity in terms of data gathering phases, and
there is a steady flow of data from the sensor nodes to the sink. In-network Data
Aggregation is useful in such applications because measurement of neighboring nodes
are likely to be correlated, and could be used to reduce the amount of data that needs to
be communicated to the sink. This in turn reduces communication energy expenditure of
the nodes, and prolongs the lifetime of the network.
2.5.3 Base Station Querying
In several application classes, the sink is not interested in data updates from all the nodes
in the network. The sink may want updates from different regions at different times.
Thus, requiring all the nodes to send their data to the sink at all the times increases the
energy consumption on communication as well as on computation. In such cases, the
sink selectively queries a set of sensor nodes located in the region of interest.
2.5.4 Tracking
Tracking applications are interested in detecting, localizing and tracking targets, and
conveying the relevant information to the sink, in a timely fashion. They combine some
of the characteristics of the three application classes discussed earlier. Landslide detection
system using a WSN is the first in India, one of the first in the world of its kind. It is
also one of the first landslide field deployments backed up by laboratory setup.
9
3. Data Aggregation: An Overview
3.1 Data Aggregation
Data Aggregation is the good technique to save energy of sensor nodes. Usually in a
sensor network thousand of sensor nodes are deployed for area monitoring. Most of them
sense the environment parameters and send the data to the base station. Base station
combines all the information for the desired output. If data aggregate before reaching the
base station the potentially decrease the number of packets in the network so less number
of packet send to base station and that can save the energy of sensor nodes. In typical
wireless sensor networks, sensor nodes are usually resource-constrained and battery-
limited. In order to save resources and energy, data must be aggregated to avoid
overwhelming amounts of traffic in the network. Data aggregation [3]
is the process of one
or several sensors then collects the detection result from other sensor. The collected data
must be processed by sensor to reduce transmission.
Wireless sensor networks (WSNs) consist of several sensor nodes and one or more base
station (BS) or sink. Sensor nodes have limited processing capability and low power
battery. The wireless sensor network has consisted three types of nodes: simple regular
sensor nodes, aggregator node and querier node. Regular sensor nodes sense data packet
from the environment and send to the aggregator nodes basically these aggregator nodes
collect data from multiple sensor nodes of the network, aggregates the data packet using a
some aggregation function like sum, average, count, max min and then sends aggregates
result to upper aggregator node or the querier node who generate the query. It can be the
base station or sometimes an external user who has permission to interact with the
network.
Data transmissions between sensor nodes, aggregators and the querier consume lot of
energy in wireless sensor network. Sensor nodes sense the physical environment and send
the data in the form of signals to the base station. Each of these scattered sensor nodes
has the capabilities to collect data and route data back to the sink. Data are routed back to
the sink by a multi hop infrastructure less architecture through the sink.
10
Figure 3-1 Without Data Aggregation With Six Transmission [3]
Figure 3-2 With Data Aggregation With Four Transmission [3]
The effect of the data aggregation is shown in figure 3.3. With the data aggregation
mechanism there is less no. of packets is wasted as well as the chance of the collisions is
also less. It may adversely affect other performance metrics such as retransmission,
energy consumption and throughput.
11
Figure 3-3 Effect of Data aggregation [3]
3.2 Factors Affected by Data Aggregation
Data aggregation attempts to collect the most critical data from the sensors and make it
available to the sink in an energy efficient manner with minimum data latency. Data
latency is important in many applications such as environment monitoring [2]
, where the
freshness of data is also an important factor. It is critical to develop energy-efficient data-
aggregation algorithms so that network lifetime is enhanced. There are several factors
which determine the energy efficiency of a sensor network, such as network architecture,
the data-aggregation mechanism, and the underlying routing protocol. The influence of
these factors on the energy efficiency of the network in the context of data aggregation is
described below.
Energy Efficiency: The functionality of the sensor network should be extended as long
as possible. In an ideal data-aggregation scheme, each sensor should have expended the
same amount of energy in each data gathering round. A data-aggregation scheme is
energy efficient if it maximizes the functionality of the network. If we assume that all
sensors are equally important, we should minimize the energy consumption of each
sensor. This idea is captured by the network lifetime which quantifies the energy
efficiency of the network.
12
Network lifetime, data accuracy, and latency are some of the important performance
measures of data-aggregation algorithms. The definitions of these measures are highly
dependent on the desired application.
Network Lifetime: Network lifetime is defined as the number of data-aggregation rounds
until a percent of sensors die where a percent is specified by the system designer. For
instance, in applications where the time that all nodes operate together is vital, lifetime is
defined as the number of rounds until the first sensor is drained of its energy. The main
idea is to perform data aggregation such that there is uniform energy drainage in the
network. In addition, energy efficiency and network lifetime are synonymous in that
improving energy efficiency enhances the lifetime of the network.
Data Accuracy: The definition of data accuracy [4]
depends on the specific application
for which the sensor network is designed. For instance, in a target localization problem,
the estimate of the target location at the sink determines the data accuracy.
Latency: Latency is defined as the delay involved in data transmission, routing, and data
aggregation. It can be measured as the time delay between the data packets received at the
sink and the data generated at the source nodes.
3.3 Data Aggregation Techniques
Data gathering is defined as the systematic collection of sensed data from multiple
sensors to be eventually transmitted to the base station for processing. Since sensor nodes
are energy constrained, it is inefficient for all the sensors to transmit the data directly to
the base station. Data generated from neighboring sensors is often redundant and highly
correlated. In addition, the amount of data generated in large sensor networks is usually
enormous for the base station to process. Hence, methods for combining data into high-
quality information at the sensors or intermediate nodes which can reduce the number of
packets transmitted to the base station resulting in conservation of energy and bandwidth.
This can be accomplished by aggregation. Data aggregation can be categorized on the
basis of network topology, network flow, quality of services and many more. Data
aggregation technique as shown in Figure 3.4.Data Aggregation technique into parts:
structure based and structure free. Structure based Data Aggregation can be further
divided into four parts flat network based, cluster based, tree based and grid based.
13
Figure 3-4 Taxonomy of Data Aggregation [3]
3.3.1 Flat Networks
In flat networks, each sensor node plays the same role. Node is equipped with
approximately the same battery power. In such networks, data aggregation is
accomplished by data centric routing where the sink usually transmits a query message to
the sensors. Sensors which have data matching the query send response messages back to
the sink. The choice of a particular communication protocol depends on the specific
application at hand.
3.3.2 Hierarchical Networks
A flat network can result in excessive communication and computation burdens at the
sink node, resulting in a faster depletion of its battery power. The death of the sink node
breaks down the functionality of the network. Hence, in view of scalability and energy
efficiency, several hierarchical data-aggregation approaches have been proposed.
Hierarchical data aggregation involves data fusion at special nodes, which reduces the
number of messages transmitted to the sink. This improves the energy efficiency of the
network.
3.3.2.1. Data Aggregation in Cluster-Based Networks
In energy constrained sensor networks of large size, it is inefficient for sensors to transmit
the data directly to the sink. In such scenarios, sensors can transmit data to a local
aggregator or cluster head which aggregates data from all the sensors in its cluster and
transmits the concise digest to the sink. This results in significant energy savings for the
energy-constrained sensors. Figure 3.5 shows a cluster-based sensor network
14
organization. The cluster heads can communicate with the sink directly via long range
transmissions or multi hopping through other cluster heads.
Figure 3-5 Cluster Based Sensor Network [4]
For example, The LEACH protocol is distributed and sensor nodes organize themselves
into clusters for data fusion. A designated node (cluster head) in each cluster transmits the
fused data from several sensors in its cluster to the sink. This reduces the amount of
information that is transmitted to the sink. The data fusion is performed periodically at the
cluster heads. LEACH is suited for applications which involve constant monitoring and
periodic data reporting.
3.3.2.2. Chain-Based Data Aggregation
In cluster-based sensor networks, sensors transmit data to the cluster head where data
aggregation is performed. However, if the cluster head is far away from the sensors, they
might expend excessive energy in communication. Further improvements in energy
efficiency can be obtained if sensors transmit only to close neighbors. The key idea
behind chain-based data aggregation is that each sensor transmits only to its closest
neighbor.
15
Figure 3-6 Chain Based Sensor Network [4]
For example, in Power-Efficient Data-Gathering Protocol for Sensor Information Systems
(PEGASIS) protocol, nodes are organized into a linear chain for data aggregation. The
nodes can form a chain by employing a greedy algorithm or the sink can determine the
chain in a centralized manner. Greedy chain formation assumes that all nodes have global
knowledge of network. The farthest node from the sink initiates chain formation and, at
each step, the closest neighbor of a node is selected as its successor in the chain. In each
data-gathering round, a node receives data from one of its neighbors, fuses the data with
its own, and transmits the fused data to its other neighbor along the chain. Eventually, the
leader node which is similar to cluster head transmits the aggregated data to the sink.
Figure 3.6 shows the chain-based data-aggregation procedure in PEGASIS.
3.3.2.3. Tree-Based Data Aggregation
In a tree-based network, sensor nodes are organized into a tree where data aggregation is
performed at intermediate nodes along the tree and a concise representation of the data is
transmitted to the root node. Tree-based data aggregation is suitable for applications
which involve in-network data aggregation. An example application is radiation-level
monitoring in a nuclear plant where the maximum value provides the most useful
information for the safety of the plant. One of the main aspects of tree-based networks is
the construction of an energy efficient data-aggregation tree. Figure 3.7 shows tree based
data aggregation.
16
Figure 3-7 Minimum Spanning Tree Based Routing [4]
For example, Energy Aware Distributed Heuristic (EADAT) to construct and maintain a
data-aggregation tree in sensor networks. The algorithm is initiated by the sink which
broadcasts a control message. The sink assumes the role of the root node in the
aggregation tree. The control message have five fields indicating the sensor ID, its parent,
its residual power, the status (leaf, non leaf node, or undefined state) and the number of
hops from the sink. After receiving the control message for the first time, a sensor v sets
up its timer to Tv. Tv counts down when the channel is idle. During this process, the sensor
v chooses the node with the higher residual power and shorter path to the sink as its
parent. This information is known to node v through the control message. When the timer
times out, the node v increases its hop count by one and broadcast the control message. If
a node u receives a message indicating that its parent node is node v, then u marks itself
as a non leaf node. Otherwise the node marks itself as a leaf node.
17
The process continues until each node broadcasts once and the result is an aggregation
tree rooted at the sink. The main advantage of this algorithm is that sensors with higher
residual power have a higher chance to become a non leaf tree node. To maintain the tree,
a residual power threshold Pth is associated with each sensor. When the residual power of
a sensor falls below Pth, it periodically broadcasts help messages for Td time units and
shuts down its radio. A child node, upon receiving a help message, switches to a new
parent. Otherwise it enters into a danger state. If a danger node receives a hello message
from a neighboring node v with shorter distance to the sink, it invites v to join the tree.
3.3.2.4. Grid-Based Data Aggregation
There are two data-aggregation schemes which are based on dividing the region
monitored by a sensor network into several grids. They are: grid-based data aggregation
and in network data aggregation. In grid-based data aggregation, a set of sensors is
assigned as data aggregators in fixed regions of the sensor network. The sensors in a
particular grid transmit the data directly to the data aggregator of that grid. Hence, the
sensors within a grid do not communicate with each other.
Figure 3-8 Grid Based Data Aggregation [4]
18
In grid-based data aggregation, the data aggregator is fixed in each grid and it aggregates
the data from all the sensors within the grid. This is similar to cluster-based data
aggregation in which the cluster heads are fixed. Grid based data aggregation is suitable
for mobile environments such as military surveillance and weather forecasting and adapts
to dynamic changes in the network and event mobility.
Figure 3-9 In-network Data Aggregation Scheme [4]
In in-network aggregation, the sensor with the most critical information aggregates the
data packets and sends the fused data to the sink. Each sensor transmits its signal strength
to its neighbors. If the neighbor has higher signal strength, the sender stops transmitting
packets. After receiving packets from all the neighbors, the node that has the highest
signal strength becomes the data aggregator. The in-network aggregation scheme is best
19
suited for environments where events are highly localized. This type of aggregation is
shown in fig 3.9.
3.3.3 Structure Free Network
In structure free data aggregation any type of structure cannot be maintained. This method
is very useful in event based application where event region changes very frequently and
if structure based approach is used then the structure can be maintained again and again.
In structure free environment because structure cannot be maintained so to reconstruct of
the structure at the time of node failure or the changing of event region is not required
There are two main challenges in performing structure free data aggregation. First, as
there is no pre constructed structure, routing decisions for the efficient aggregation of
packets need to be made on-the-fly. Second, as nodes do not explicitly know their
upstream nodes, they cannot explicitly wait on data from any particular node before
forwarding their own data. The benefit of this approach is that structure cannot be
maintained all the time whereas in structured environment reconstruct of structure is
necessary at the time of when some nodes fail due to energy failure.
3.4 Comparison between Hierarchical Networks and Flat network
Table 3-1 Comparison between Hierarchical and Flat Networks
Hierarchical Networks Flat Network
Data aggregation performed by cluster
heads or a leader node.
Data aggregation is performed by
different nodes along the multi-hop path.
Overhead involved in cluster or chain
formation throughout the network.
Data aggregation routes are formed only
in regions that have data for transmission.
Even if one cluster head fails, the network
may still be operational.
The failure of sink node may result in the
breakdown of entire network.
Lower latency is involved since sensor
nodes perform short-range transmissions.
Higher latency is in data transmission to
the sink via a multi hop path.
20
Routing structure is simple but not
necessarily optimal.
Optimal routing can be guaranteed with
additional overhead.
Node heterogeneity can be exploited by
assigning high energy nodes as cluster
heads.
Does not utilize node heterogeneity for
improving energy efficiency.
3.5 Advantages and Disadvantages of Data Aggregation in WSN
Advantages
With the help of data aggregation process the robustness and accuracy of information can
be enhanced which is obtained by entire network, certain redundancy exists in the data
collected from sensor nodes thus data fusion processing [5]
is needed to reduce the
redundant information. Another advantage is those reduces the traffic load and conserve
energy of the sensors.
Disadvantages
The cluster head means data aggregator nodes send fuse these data to the base station.
This cluster head or aggregator node may be attacked by malicious attacker. If a cluster
head is compromised, then the base station (sink) cannot be sure the correctness of the
aggregate data that has been send to it. Another drawback [5]
is existing systems are
several copies of the aggregate result may be sent to the base station (sink) by
uncompromised nodes .It increase the power consumed at these nodes.
21
4. Data Aggregation by Precision Allocation
4.1 Introduction of Aggregation for Continuous Data Measuring
While the base station can have continuous power supply, the sensor nodes are usually
battery powered. The batteries are inconvenient and sometimes even impossible to
replace. When a sensor node runs out of energy, its coverage is lost. The mission of a
sensor application would not be able to continue if the coverage loss is remarkable.
Therefore, the practical value of a sensor network is determined by the time duration
before it fails to carry out the mission due to insufficient number of alive sensor
nodes. This duration is referred to as the network lifetime. It is both mission-critical and
economically desirable to manage sensor data in an energy efficient way to extend the
lifetime of sensor networks.
The data captured by the sensor nodes are often converted into an aggregate form
requested by the applications (e.g., average temperature reading). Primarily designed for
monitoring purposes, many sensor applications require continuous aggregation of sensor
data. Exact data aggregation requires substantial energy consumption because each sensor
node has to report every reading to the base station. In wireless sensor networks,
communication is a dominant source of energy consumption. To save energy, data
semantics can be relaxed to allow approximate data aggregation with precision
guarantees[6]
. The precision can, for example, be specified in the form of quantitative error
bounds: average temperature reading of all sensor nodes within an error bound of 1 C. In
this way, the sensor nodes do not have to report all readings to the base station. Only the
updates necessary to guarantee the desired level of precision need is sent to the base
station.
It is, however, a challenging task to optimize network life time under approximate data
aggregation because the sensor nodes are inherently heterogeneous in energy
consumption. First, when the data captured by different sensor nodes change at different
magnitudes and frequencies, the sensor nodes may report data at different rates. Second,
the wireless communication cost depends on the transmission distance. Due to the
geographically distributed nature of sensor networks, the sensor nodes are likely to
differ significantly in the energy cost of sending a message to the base station. Even if all
22
sensor nodes report data at the same rate, their energy consumption can be highly
unbalanced, thereby reducing network lifetime. In addition to reporting local sensor
readings, the intermediate nodes in a multi-hop network are also responsible for relaying
the data originated from other nodes to the base station.
4.2 Aggregation and Lifetime of Node
Three factors affecting the lifetime of sensor nodes in the context of approximate data
aggregation [7]
:
1) The changing pattern of sensor readings;
2) The residual energy of the sensor nodes;
3) The communication cost between the sensor nodes and the base station.
In this chapter, a candidate-based method for precision allocation and prove its optimality
for single-hop networks is discussed. Based on this method, an adaptive scheme is
proposed to dynamically adjust the error bounds allocated to the sensor nodes. The
adjustment period is also dynamically set to control the communication overhead.
4.3 Basics of Error Bound for Nodes
Here consider data aggregation with precision guarantees in a network of n sensor nodes.
The sensor nodes are geographically distributed in an operational area. They periodically
sample the local phenomena such as temperature and humidity. Without loss of
generality, the sampling period is assumed to be 1 time unit.
The base station collects data from the sensor nodes and feeds them to an application. The
application specifies the precision constraint of data aggregation by an upper bound E
(called the error bound) on the quantitative difference between an approximate result and
the exact result. That is, on receiving an aggregate result from the sensor network, the
application would like to be assured that the exact aggregate result lies in the interval.
In approximate data aggregation, not all sensor readings have to be sent to the base
station. To reduce communication cost, the designated error bound on aggregate data can
be partitioned and allocated to individual sensor nodes (call it precision allocation). Each
sensor node updates a new reading with the base station only when the new reading
23
significantly deviates from the last update to the base station and violates the allocated
error bound. To guarantee the designated precision of aggregate data, the error bounds
allocated to individual sensor nodes have to satisfy certain feasibility constraints.
Different aggregation functions impose different constraints.
4.4 Types of Aggregation Based on Precision Allocation
Three commonly used types of aggregations[8]
are as below
1. SUM
2. COUNT
3. AVERAGE
For SUM and COUNT aggregations, to guarantee an error bound on aggregate data, the
total error bound allocated to the sensor nodes cannot exceed E.
1
,n
i
i
e E
................................................................. (4.1)
Where, ei is the error bound allocated to node i and n is the number of sensor nodes
For AVERAGE aggregation, the total error bound allocated to the sensor nodes cannot
exceed n.E.
1
1,
n
i
i
e En
(4.2)
Eligible precision allocation under the feasibility constraint is not unique. For example, in
a network of 10 temperature sensor nodes, if the given error bound on AVERAGE
aggregation is 1 C, we can allocate an error bound of 1 C to each sensor node. Alternatively,
we can also allocate an error bound of 5.5 C to a selected node and an error bound 0.5 C to
each of the remaining nodes. This offers the flexibility to adjust the energy consumption of
individual sensor nodes by careful precision allocation. In general, to collect the readings
of a sensor node at higher precision (i.e., smaller error bound), the sensor node needs to
send data updates to the base station more frequently, which introduces higher energy
consumption.
24
4.5 Error Bound and Communication between Node and Sink
Let denote the energy consumed by sensor node i to send and receive a data update by si
and vi respectively. They can take different forms to cater for a wide range of factors. In
the simplest case, if all sensor nodes use a default radio communication range, sis are the
same for all nodes.
More sophisticatedly, if the sensor nodes know the locations of the receivers, they can
adapt the power level to the transmission distance. The sensor nodes with longer
transmission distances would be associated with higher si.
In addition, reliability can also be modeled in the energy cost. The sensor nodes incident
to less reliable links are entitled to higher sis and vis due to possible retransmissions. Let
simply assume that each sensor node i knows si and vi .
4.6 Optimal Precision Allocation
Let e1, e2, e3, e3en 0 be the error bounds [7] currently allocated to sensor nodes 1,
2,...n respectively. The quantitative relationship between the rate of data updates sent by a
sensor node and its allocated error bound depends on the changing pattern of sensor
readings. Without loss of generality, consider the update rate of each sensor node i as a
function of the allocated error bound ei. is essentially the rate at which node i
s reading changes by more than ei. Intuitively, is a non-increasing function with
respect to ei.
Since the sensor nodes in a single-hop network are not involved in relaying data from
other sensor nodes to the base station, the energy consumption rate of node i is simply
( ).i i iu e s (4.3)
where si refers to the energy cost for node to send a data update to the base station.
Suppose the residual energy of node i is Pi
( ).
i
i i i
p
u e s.. (4.4)
Therefore, the network lifetime is given by
25
min
1( ).
i
i i i
pi n
u e s
(4.5)
The objective of precision allocation is to find a set of error bounds e1, e2, , en that maximize the network lifetime under the constraint
1
n
i
i
e E
. (4.6)
Now analyze the optimal precision allocation. For simplicity, assume functions ui(.)s are continuous and denote the inverse function of ui(.) by ui
-1(.).
Since ui(.) is non-increasing, the minimum life time of sensor node I is given by
(0).
ii
i i
pl
u s
.... (4.7)
Now for node i having error bound ei, the lifetime of node is given as below,
( ).
ii
i i i
pl
u e s
. (4.8)
An optimal precision allocation (error bound) for node is given by
1
.
ii
i
pe u
l s
(4.9)
4.7 Candidate Based Precision Allocation
In practice, the exact forms of ui-1
(.)s (i.e., the changing patterns of sensor readings) may
not be known a priori and they may even change dynamically. The key idea is to let each
sensor node estimate [9]
and report to the base station the normalized energy consumption
rates for a number of candidate error bounds based on historical sensor readings. The base
station optimizes precision allocation based on these candidates to extend network
lifetime.
Since the general relationships between error bounds and update rates are not known, we
restrict the error bound allocated to each sensor node to one of its candidates. Such
allocations are called candidate precision allocations and the one that maximizes network
lifetime is called the optimal candidate precision allocation.
Assume that each sensor node chooses m candidates[10]
. For each node i , let
,1 ,2 ,...i i i me e e be the list of candidate error bounds, and ,1 ,2 ,, ,...,i i i mr r r be the
26
corresponding normalized energy consumption rates. It follows that,1 ,2 ,...i i i mr r r .
Suppose the smallest candidate error bounds for the sensor nodes do not add up to the
designated bound on data aggregation, i.e., 1,1 2,1 ,1... ne e e E .
4.8 Algorithm for Optimal Precision Allocation
Input:
E: error bound of data aggregation
,* ,*,i ie r : Candidate error bounds and normalized energy consumption rates
Output
, ii xe : error bound of each node in optimal allocation
1. for 1i to n do
2. 1;ix
3. end for
4. while min
1 i n ix m do
5. argj max
1 i n , ii x
r ;
6. if , 1 ,i ij x i xi j
e e E
then
7. break; 8. end if
9. 1;j jx x
10. end while
Initially, the error bound of each sensor node is set to its smallest candidate (steps 13). In
each iteration of steps 410, the error bound of the node having the highest energy
consumption rate is replaced with its next smallest candidate. The iteration stops if a new
replacement would make the total error bound of the sensor nodes exceeds the designated
bound on data aggregation (steps 67).
4.9 Adaptive Precision Allocation
Now present an adaptive precision allocation scheme that works by adjusting the error
bounds of the sensor nodes periodically. The interval between two successive adjustments
is called an adjustment period. At the beginning of an adjustment period, each sensor
node selects a list of candidate error bounds,1 ,2 ,, ,...,i i i me e e .The node keeps track of the
27
update counts under these error bounds as it captures new readings. At the end of the
adjustment period, node normalizes the counts by the length of period to obtain the data
update rate ,i ju for each ,i je . Node i then compute the normalized energy consumption rate
,i jr for each ,i je
by
,
,
.,
i j i
i j
i
u sr
p
(4.10)
Where pi is the present residual energy of node i. Node sends a candidate report message
including the,i je s and ,i jr s to the base station. On receiving the messages from all sensor
nodes, the base station computes the optimal precision allocation.
In case,,
1
n
i xi
i
e E
, the leftover error bound ,1
n
i xi
i
E e
is simply allocated to the node
with the highest normalized energy consumption rate since doing so would only extend
network lifetime. Finally, the base station sends a precision allocation message to the
sensor nodes including the new error bounds for their adjustments.
The closer the candidates to the current error bound, the smaller the difference between
neighboring candidates [11]
. The motivation is to adjust the error bounds at coarse
granularity when they are far away from the optimum, and adjust them at fine granularity
when they are close to the optimum.
Let ei be the current error bound of sensor node i. Then, the candidate error bounds of
node range from (1/2)ei to (3/2)ei. Given the number of candidates m=2k+1 , the
candidate error bounds are selected as
1 3 2 1 2 1 5 3, ,..., , , ,..., , .
2 4 2 2 4 2
k k
i i i i i i ik ke e e e e e e
(4.11)
Note that the network lifetime is determined by the lifetime [12]
of the most energy-
consuming node. Thus, to control the energy overhead of adjustments, we propose to cap
the energy overhead at the most energy-consuming node by a given portion of its
energy budget. This is done by dynamically adapting the adjustment period at each
adjustment. Specifically, each sensor node i count the number of data updates [13]
sent to
28
the base station in the adjustment periods. At an adjustment, node estimates its energy
consumption rate by
. iN s
L (4.12)
where is N the update count in the past adjustment period, si is the energy cost for
sending, and L is the duration of the past adjustment period.
Note that at an adjustment, each sensor node needs to send a candidate report message to
and receive a precision allocation message from the base station. Thus, the energy cost at
node due to an adjustment is si+vi, where si and vi are the sending and receiving costs
respectively. To limit it at a portion of the energy consumed by node i, the duration of
the next adjustment period Li should be set such that
.. ,i i i
s v N s
Li L
. (4.13)
i.e.,
( )
. .
i i
i
L s vLi
N s
(4.14)
Each sensor node i computes Li and includes it in the candidate report message sent to the
base station at the end of an adjustment period. Among all Lis received, the base station
selects the lowest one L as the next adjustment period so as to cap the adjustment
overhead at a portion of the energy consumed at the most consuming node. L is then
included in the precision allocation message sent by the base station to all sensor nodes.
29
5. Experimental Work A
5.1 Nodes Data (temperature) Generation
Change in temperature is not an abrupt process. In general, temperature changes
gradually. In simulation, assume initially all nodes sense same temperature say 28 C and
temperature changes as time goes on. The change in new sense temperature compared to
previous sensed temperature is between -2C and 2C. Fig. 5.1 shows temperature profile
for a node 1.
Figure 5-1 Temperature Data Profile
5.2 Error Bound of Node
As temperature changes gradually, nodes need not to send all sense temperature to base
station. This is controlled by error bound of node. Error bound decides which data to be
send to base station. Data which significantly deviates from previous sense reading are
necessary to send base station and this deviation is controlled by error bound of node.
Suppose for a node, error bound is 1C then deviation more than of 1C from previous
sense reading is sent to base station otherwise no need to send data. Data which closely
near to previous sense reading is never send to base station.
30
Initially total error bound (E) of network is assigned. Total error bound is divided to all
nodes. Assignment of error bounds to all nodes is such that summation of error bounds (e)
of all nodes gives total error bound of network. Initially all node have same error bound
which is decided by total error bound of network (E). If there are 10 nodes in network,
total error bound of network is 10C then error bound is 1C per node. So temperature
change is more than 1C then node send data to base station.
5.3 Adjustment in Error Bound of Node
Initially all node assigned same error bound. So nodes communicate with base station if
change in temperature is same. Due to this energy consumption of node is not nearly
equal. Energy consumption of node which is very far away from base station or near to
the environment where temperature changes frequently due to non avoidable disturbances
is very large.
To overcome above problem, error bound of node is changed at fixed time interval. This
time interval is known as adjustment interval. New error bound for node is calculated
based on residual energy of node.
For example, error bounds (eb1 and eb2) of two nodes having maximum energy
compared to other nodes are decreased by delta. Delta is similar to step size parameter.
= 1+2
2 .(5.1)
New error bound (eb1) for node is simply calculated by subtracting delta from its old
error bound. Similar calculation is applied to eb2 also.
1 = 1 (5.2)
2 = 2 ....(5.3)
where eb1 and eb2 are updated error bounds.
Error bounds of two nodes having lowest residual energy at end of adjustment interval are
also updated. For these nodes instead of substitution of delta to error bound addition
operation is done. So overall network error bound remain constant.
Consider eb4 and eb5 are the error bounds of node which have minimum residual energy
at the end of adjustment period then updated error bound is calculated as below equations.
31
4 = 4 + .(5.4)
5 = 5 + .(5.5)
where eb4 and eb5 are the updated error bounds.
5.4 Assumptions and Simulation Environment
For realization of the simple wireless sensor environment, the base station is fixed and
located far from the sensors at (500m, 500m). All nodes of network and base station are
static.
Table 5-1 Network Parameters
Description Value
Network Area 500m x 500m
Number of nodes 25
Initial energy 100 J
Data packet size 200 bytes
Electronics energy 50 nJ/bit
Free space energy 10 pJ/bit/m2
Figure 5-2 Network Topology
32
Fig. 5.2 shows deployment of nodes in sensor network of 500m x 500m area. Base station
is located at upper right corner (500,500).
5.4.1 Error Bounds of Nodes
Fig. 5.3 shows initially error bounds of nodes which is same and equal to nearly 1C.
After every adjustment period, error bound of nodes having lowest and highest energy is
updated. Error bound of node at the end of simulation is shown in fig. 5.4.
Figure 5-3 Initial Error Bound for Node
Figure 5-4 Error Bound of Node at Simulation End
33
5.4.2 Error Bound Changing Parameters
After every adjustment period error bound is updated based on residual energy of node.
Change in error bound is done only with two nodes which have highest energy and other
two nodes which have lowest energy. So other nodes error bounds are not affected at
every adjustment period. And base station need not send error bound of all nodes after
every adjustment period.
Figure 5-5 Highest Residual Energy Node at Every Adjustment Period End
Figure 5-6 Lowest Residual Energy Node at Every Adjustment Period End
34
Error bound of node which has highest residual energy is reduced by minus delta from
error bound of that node. Fig. 5.5 shows node from which delta is minus for error bound
update at every adjustment period end. Fig. 5.6 shows node which has lowest residual
energy at every adjustment period end. Error bound of this node is change by adding delta
to its error bound. The value of delta which is calculated at every adjustment period end is
shown in fig. 5.7.
Figure 5-7 Value of Delta at Every Adjustment Period End
5.4.3 Residual Energy and Communication Frequency of Node
Fig. 5.8 shows how many times node send data to base station. Due to different error
bound assign to all nodes, all nodes send different amount of data to base station. Fig. 5.8
shows though all nodes communicate with base station not equal times. Fig. 5.9 shows by
updating error bound of nodes after every adjustment period; energy consumption of
network is balanced. Network life time is defined by the life of first dying node. So by
balanced energy consumption, all nodes residual energy at the end of simulation is very
nearer which is shown in fig. 5.9. After adjustment period error bound of node which
have minimum residual energy is increased by delta and error bound of node which has
maximum energy is decreased by delta. The values of delta after every adjustment period
is as in fig. 5.7
35
Figure 5-8 No. of Times Node Send Data to Base Station
Figure 5-9 Residual Energy of Node at Simulation End
5.5 Network with Multiple Monitoring Sensors
Many times sensor network consists of nodes which sense more than one type of
parameters like temperature, humidity, etc. For such a network also, energy consumption
of node will be more without data aggregation. Though energy effective routing, energy
consumption of network can be reduced but using data aggregation, in a way due to less
data transmission system computation at base station side can be reduced. The concept of
error bound is also applicable to this case.
36
Suppose network monitors two parameters say X and Y. Then give total error bound (Ex)
for parameter X sensing and total error bound (Ey) for parameter Y sensing. Computation
for updated error bound values for such case is in line of single parameter sensing. For
two parameters, two error bound values (one for X and other for Y) is allocated to
particular sensing node. One can apply same method for error bound allocation and error
bound adjustment to node for X and Y parameters.
37
6. Experimental Work B
6.1 Simulation Environment
We have plenty of simulation tools or simulators for simulating wireless networks. The
simulators which are most popular are NS-2, OPNET, OMNet++, J-Sim, GlomoSim,
Qualnet, TOSSIM and so on. Since wireless sensor networks are special type of wireless
networks, most of the simulators available are not enough supported for simulating a
wireless sensor network scenario. The literature shows that the simulators which are
mostly used for wireless sensor network are NS-2 [15]
, J-Sim, GlomoSim, OPNET, and
TOSSIM. Even MATLAB is also used.
6.2 Steps for Creating Script in NS2
Step 1: Simulation parameters setup
Step 2: Initialization of a network
a) Create a ns simulator
b) Setup topography object
c) Open the NS trace file
d) Open the NAM trace file
Step 3: Mobile node parameter setup
Step 4: Configuration of a nodes like (x, y) dimensions
Step 5: Create a TCP or UDP agent and connect in to source nodes.
Step 6: Create TCP Sink and NULL agent and connect it to the destination node.
Step 7: Call End Procedure
6.3 Simulation Parameters and Assumptions
For simulation, following assumptions are considered.
1. All sensor nodes are homogeneous in physical characteristics such as initial energy,
antenna gain, etc.
38
2. All nodes are stationary.
3. Base station is also stationary and has infinite energy.
Table 6-1 Network Parameters
Parameters Values
Channel Type Wireless 802.11
Propagation Type Two Ray Ground
MAC protocol MAC 802.11
Queue Type Drop tail
Antenna Omni Antenna
Number of nodes 25
Queue Length 50
Routing protocol AODV
Traffic type CBR
Packet size 200 bytes
Initial energy 2 Joules
Network Area 500 m x 500 m
6.4 Description of Simulation
In simulation, base station is located at co ordinate (500m, 500m). Assume it has infinite
energy. All 25 nodes are placed randomly in the sensor network area 500m x 500m. All
nodes send data to base station. Simulation starting time is 0 second and ending time is
100 seconds i.e. communication between node and base station start at 0 second and end
at 100 second. Simulation runs for 100 seconds.
39
How many times node sends data to base station is controlled by the error bound. In other
word, number of times node communicates with base station is function of error bound.
And data rate of node is decides how many times node communicates with base station.
So data rate is also analogous to error bound of node.
There are three different cases taken for simulation.
1. Equal data rate for all nodes which is analogous to same error bound allocation.
2. Different random data rate for all nodes which is analogous to different error bound
allocation.
3. Data rate according to nodes position (energy) which is analogous to energy saving
error bound allocation.
6.4.1 Same Error Bound Case
Fig. 6.1 shows simulation topology in which 25 nodes placed randomly in 500m x 500m
area and base station at co ordinate (500m, 500m). All nodes communicate with base
station same number of times. After every 2 seconds node sense data and send it to base
station. Fig. 6.2 shows advertise packets send by all nodes for hand shaking purpose in
AODV protocol. AODV routing protocol is very fair enough for successfully
transmission of data from sensor nodes to the base station without data packets drop.
Figure 6-1 Simulation Topology
40
Figure 6-2 Hand Shaking Packets Transmit by Nodes
6.4.1.1. Residual Energy of Node
In fig. 6.3, residual energy of each node is shown. Due to same precision allocation to
each node, the rate of energy consumption of each node is not same because of all nodes
are placed at different location. The energy consumption is not balance for this case as
node represented by red in below fig. 6.3 consumes more energy compared to other
nodes.
Figure 6-3 Residual Energy of all Node vs Time
41
Life time of network is defined by first dying node in network then due to node having
more energy consumption rate die first and decrease the life time of network. So energy
consumption of all node must be balance or nearly equal for increasing the life of wireless
sensor network.
By decreasing the data transmission of low residual energy of node, the energy
consumption can be reduced. And life time of network can be increase. But due to same
data rate which is analogous to same error bound all node communicate with base station
same times irrespective to their residual energy.
6.4.1.2. Remaining Energy of Node at Simulation End
The variation of remaining energy of node is very large because of not balance energy
consumption rate of node.
Table 6-2 Remaining Energy of Node at Simulation End
Node Energy in Joule Node Energy in Joule
0 1.5216 12 1.4927
1 1.5066 13 1.5207
2 1.5212 14 1.4755
3 1.4236 15 1.5209
4 1.5216 16 1.3288
5 1.5077 17 1.3287
6 1.5215 18 1.5213
7 1.5218 19 1.5219
8 1.5206 20 1.5080
9 1.5210 21 1.5215
10 1.5211 22 1.5204
11 1.4175 23 1.6813
42
6.4.2 Random Different Error Bound Case
In this case also 25 nodes placed randomly in 500m x 500m area and base station at co-
ordinate (500m, 500m). All nodes communicate with base station different number of
times which is analogous to random error bound of node.
In this case, data rate of all nodes are not same. All nodes are allocated random data rate
irrespective to their location with respect to base station and their residual energy. Due to
this reasons this case has less life time compared to case 3 in which data rate of node is
define based on location of node with respect to base station.
6.4.2.1. Residual Energy of Each Node
In case of different precision (error bound) allocation, the rate of energy consumption of
node is not same for all nodes. Energy consumption rate is balanced compared to same
error bound allocation as shown in fig. 6.4.
Figure 6-4 Residual Energy of all Nodes vs Time
6.4.2.2. Remaining Energy of Node at Simulation End
The variation of remaining energy of node at the end of simulation is less compared to
same error bound case and more compared to case 3(error bound based on nodes
location)
43
Table 6-3 Remaining Energy of Node at Simulation End
Node Energy in Joule Node Energy in Joule
0 1.6736 13 1.6857
1 1.6383 14 1.6608
2 1.6823 15 1.6441
3 1.6827 16 1.6849
5 1.6346 17 1.6714
6 1.6686 18 1.7172
7 1.6786 19 1.6004
8 1.6847 20 1.6808
9 1.6450 21 1.6819
10 1.6851 22 1.6600
11 1.6812 23 1.6722
12 1.6838 24 1.6813
6.4.3 Error Bound Based on Node Position (Energy) Case
All nodes placed randomly in 500m x 500m area and base station is located at co-ordinate
(500m, 500m). In this case error bound is defined by considering distance between node
and base station. The node which is far away from base station compared to other node
has more error bound compared to other near node to base station.
As error bound is analogous to data rate of node, node which is far away from the base
station have low data rate compared to node which is near to base station. In other word,
node which is far away communicates with base station less compared to other nodes.
44
6.4.3.1. Residual Energy of Each Node
By this way, energy consumption of node is better and balanced as shown in fig. 6.5. This
kind of allocation provides good energy utilization of node compared to other two cases.
According to this allocation life time of network significantly increase compared to
previous cases.
Figure 6-5 Residual Energy of all Nodes vs Time
6.4.3.2. Remaining Energy of Node at Simulation End
The variation of remaining energy of node is very less because of balance energy
consumption rate of node compared to previous two cases.
Table 6-4 Remaining Energy of Node at Simulation End
Node Energy in Joule Node Energy in Joule
0 1.8562 13 1.8589
1 1.8582 14 1.8424
2 1.8592 15 1.8597
45
3 1.8586 16 1.8534
5 1.8455 17 1.8561
6 1.8592 18 1.8572
7 1.8480 19 1.8586
8 1.8585 20 1.8527
9 1.8563 21 1.8580
10 1.8588 22 1.8554
11 1.8576 23 1.8505
12 1.8592 24 1.8562
6.4.4 Packet to Delivery Ratio
In same error bound case, all nodes send data to base station at fixed intervals which is
same for all nodes. While in case of random error bound assignment, data rate is different
for all nodes so, less numbers of data is sent to base station. For error bond based on
location of node case, data rate of node which is far away from base station is less
compared to other nodes.
Case Sent Packets Received Packets Ratio
Same Error Bound 1250 12