Performance Analysis of Routing Protocols of Wireless Sensor Networks


Published on

1 Comment
1 Like
  • Nice work Darpan.
    I want to cite your research work on my Thesis. Can u please email me your thesis on
    Are you sure you want to  Yes  No
    Your message goes here
No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Performance Analysis of Routing Protocols of Wireless Sensor Networks

  1. 1. Performance Analysis of Routing Protocols of Wireless Sensor Networks BY DARPAN DEKIVADIYA 09BCE008 VIVEK VADHARIA 09BCE090 DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING AHMEDABAD-382481 November 2012
  2. 2. Performance Analysis of Routing Protocols of Wireless Sensor Networks Minor Project Submitted in partial fulfillment of the requirements For the degree of Bachelor of Technology In Computer Engineering By DARPAN DEKIVADIYA 09BCE008 VIVEK VADHARIA 09BCE090 Guide Prof. Vijay Ukani DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING AHMEDABAD-382481 November 2012
  3. 3. Certificate This is to certify that the Minor Project entitled ”Performance Analysis of RoutingProtocols of Wireless Sensor Networks” submitted by DARPAN DEKIVADIYA(09BCE008),towards the partial fulfillment of the requirements for the degree of Bachelor of Technologyin Computer Engineering of Nirma University of Science and Technology, Ahmedabad is therecord of work carried out by him under my supervision and guidance. In my opinion, thesubmitted work has reached a level required for being accepted for examination. The resultsembodied in this Seminar, to the best of my knowledge, haven’t been submitted to any otheruniversity or institution for award of any degree or diploma. Prof.Vijay Ukani Dr. Sanjay Garg Guide and Assistant Professor, Professor and Head, Dept. of Computer Science & Engg., Dept. of Computer Science & Engg., Institute of Technology, Institute of Technology, Nirma University, Ahmedabad Nirma University, AhmedabadDr. Sanjay GargProfessor and Head,Dept. of Computer Science & Engg.Institute of Technology,Nirma University, Ahmedabad iii
  4. 4. Certificate This is to certify that the Minor Project entitled ”Performance Analysis of Routing Pro-tocols of Wireless Sensor Networks” submitted by VIVEK VADHARIA(09BCE090), towardsthe partial fulfillment of the requirements for the degree of Bachelor of Technology in Com-puter Engineering of Nirma University of Science and Technology, Ahmedabad is the recordof work carried out by him under my supervision and guidance. In my opinion, the sub-mitted work has reached a level required for being accepted for examination. The resultsembodied in this Seminar, to the best of my knowledge, haven’t been submitted to any otheruniversity or institution for award of any degree or diploma. Prof.Vijay Ukani Dr. Sanjay Garg Guide and Assistant Professor, Professor and Head, Dept. of Computer Science & Engg., Dept. of Computer Science & Engg., Institute of Technology, Institute of Technology, Nirma University, Ahmedabad Nirma University, AhmedabadProf. Tejal UpadhyayDept. of Computer Science & Engg.Institute of Technology,Nirma University, Ahmedabad iv
  5. 5. Acknowledgements I would like to express my heartfelt gratitude to Prof.Vijay Ukani,Professor in Departmentof computer science and engineering for her valuable time and guidance that made theseminar project work a success. Thanking all my friends and all those who had helped mein carrying out this work. I am also indebted to the library resources centre and interestservices that enabled us to ponder over the vast subject of ”Performance Analysis of RoutingProtocols of Wireless Sensor Networks”. - DARPAN DEKIVADIYA 09BCE008 - VIVEK VADHARIA 09BCE090 v
  6. 6. Abstract This project involves implementation & Performance Analysis of Routing Protocols forWireless Sensor Network. A wireless sensor network (WSN) consists of spatially distributedautonomous sensors to monitor physical or environmental conditions, such as temperature,sound, vibration, pressure, humidity, motion or pollutants and to cooperatively pass theirdata through the network to a main location. The sensor networks can be used in DisasterRelief, Emergency Rescue operation, Military, Habitat Monitoring, Health Care, Environ-mental monitoring, Home networks, detecting chemical, biological, radiological, nuclear,and explosive material etc. Sensor network nodes are limited with respect to energy supply,restricted computational capacity and communication bandwidth. Most of the attention,however, has been given to the routing protocols since they might differ depending on theapplication and network architecture. To prolong the lifetime of the sensor nodes, designingefficient routing protocols is critical. Even though sensor networks are primarily designedfor monitoring and reporting events, since they are application dependent, a single routingprotocol cannot be efficient for sensor Networks across all applications. The Comparison ofRouting Protocols reveals the important features that need to be taken into considerationWhile designing and evaluating new routing protocols for sensor networks. Routing in WSNs is very challenging due to the inherent characteristics that distinguishthese networks from other wireless networks like mobile ad hoc networks or cellular networks.First, due to the relatively large number of sensor nodes, it is not possible to build a globaladdressing scheme for the deployment of a large number of sensor nodes as the overheadof ID mainte-nance is high. Thus, traditional IP-based protocols may not be applied toWSNs. In contrast to typical communication networks, almost all applications of sensornetworks require the flow of sensed data from multiple sources to a particular BS. This,however, does not prevent the flow of data to be in other forms (e.g., multicast or peerto peer). sensor nodes are tightly constrained in terms of energy, processing, and storagecapacities. Thus, they require careful resource management. sensor networks are applicationspecific, i.e., design requirements of a sensor network change with application. For example,the challenging problem of low-latency precision tactical surveillance is different from thatrequired for a periodic weather-monitoring task. vi
  7. 7. ContentsAcknowledgements vAbstract vi1 Introduction to WSN 12 Classification Of Routing Protocols 3 2.1 Based on Mode of Functioning and Type of Target Applications . . . . . . . 3 2.1.1 Proactive :- . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 2.1.2 Reactive :- . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 2.1.3 Hybrid :- . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 2.2 According to the Participation style of the Nodes. . . . . . . . . . . . . . . . 4 2.2.1 Direct Communication :- . . . . . . . . . . . . . . . . . . . . . . . . . 4 2.2.2 Flat :- . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 2.2.3 Clustering Protocols :- . . . . . . . . . . . . . . . . . . . . . . . . . . 4 2.3 Depending on the Network Structure . . . . . . . . . . . . . . . . . . . . . . 5 2.3.1 Data Centric :- . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 2.3.2 Hierarchical :- . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 2.3.3 Location Based :- . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 Routing Challenges and Design Issues in WSNs 64 Routing Protocols in WSNs 8 4.1 Direct Diffusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 4.2 Sensor Protocol for Information via Negotiation . . . . . . . . . . . . . . . . 10 4.3 Low Energy Adaptive Clustering Hierarchy (LEACH). . . . . . . . . . . . . 12 4.4 CTP : Collection Tree Protocol . . . . . . . . . . . . . . . . . . . . . . . . . 14 4.5 Greedy Perimeter Stateless Routing(GPSR) . . . . . . . . . . . . . . . . . . 17 4.5.1 States of Neighbors . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 4.5.2 Beaconing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 4.5.3 Greedy Forwarding . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 4.5.4 Perimeter Forwarding . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 4.6 Power Efficient Gathering for Sensor Information Systems . . . . . . . . . . 18 4.7 Binary Scheme . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 4.8 Chain Based Three level Scheme . . . . . . . . . . . . . . . . . . . . . . . . . 20 vii
  8. 8. 5 Simulation And Analysis 21 5.1 Greedy Perimeter Stateless Routing(GPSR) . . . . . . . . . . . . . . . . . . 21 5.2 Collection Tree Protocol (CTP) . . . . . . . . . . . . . . . . . . . . . . . . . 22 5.3 Low-Energy Adaptive Clustering Hierarchy (LEACH) . . . . . . . . . . . . . 266 References 30 viii
  9. 9. Chapter 1Introduction to WSN A wireless sensor network (WSN) consists of spatially distributed autonomous sensorsto monitor physical or environmental conditions, such as temperature, sound, vibration,pressure, motion or pollutants and to cooperatively pass their data through the network toa main location[2]. The more modern networks are bi-directional, also enabling control of sensor activity.The development of wireless sensor networks was motivated by military applications suchas battlefield surveillance; today such networks are used in many industrial and consumerapplications, such as industrial process monitoring and control, machine health monitoring,and so on. Figure 1.1: Typical multi-hop wireless sensor network architecture 1
  10. 10. The WSN is built of ”nodes” from a few to several hundreds or even thousands, whereeach node is connected to one (or sometimes several) sensors. Each such sensor network nodehas typically several parts: a radio transceiver with an internal antenna or connection to anexternal antenna, a microcontroller, an electronic circuit for interfacing with the sensors andan energy source, usually a battery or an embedded form of energy harvesting. A sensor node might vary in size from that of a shoebox down to the size of a grainof dust, although functioning ”motes” of genuine microscopic dimensions have yet to becreated. The cost of sensor nodes is similarly variable, ranging from a few to hundreds ofdollars, depending on the complexity of the individual sensor nodes. Size and cost constraintson sensor nodes result in corresponding constraints on resources such as energy, memory,computational speed and communications bandwidth. The topology of the WSNs can vary from a simple star network to an advanced multi-hopwireless mesh network. The propagation technique between the hops of the network can berouting or flooding. 2
  11. 11. Chapter 2Classification Of Routing Protocols Routing techniques are required for sending data between sensor nodes and the basestations for communication. Different routing protocols are proposed for wireless sensornetwork. These protocols can be classified according to different parameters.[1]. Figure 2.1: Routing protocols in WSNs2.1 Based on Mode of Functioning and Type of Target Applications2.1.1 Proactive :- In a Proactive Protocol the nodes switch on their sensors and transmitters, sense theenvironment and transmit the data to a BS through the predefined route. e.g. The Low Energy Adaptive Clustering hierarchy protocol (LEACH) utilizes this typeof protocol.2.1.2 Reactive :- 3
  12. 12. if there are sudden changes in the sensed attribute beyond some pre-determined thresholdvalue, the nodes immediately react. This type of protocol is used in time critical applications. e.g. The Threshold sensitive Energy Efficient sensor Network (TEEN) is an example ofa reactive protocol.2.1.3 Hybrid :- Hybrid protocols incorporate both proactive and reactive concepts. They first computeall routes and then improve the routes at the time of routing. e.g. Adaptive Periodic TEEN(APTEEN) is an example of a reactive protocol.2.2 According to the Participation style of the Nodes.2.2.1 Direct Communication :- In this type of protocols, any node can send information to the Base Station(BS) directly.When this is applied in a very large network, the energy of sensor nodes may be drainedquickly. Its scalability is very small. e.g. SPIN is an example of this type of protocol.2.2.2 Flat :- In the case of flat protocols,if any node needs to transmit data, it first searches for a validroute to the BS and then transmits the data. Nodes around the base station may drain theirenergy quickly. Its scalability is average. e.g. Rumor Routing is an example of this type of protocol.2.2.3 Clustering Protocols :- According to the clustering protocol,the total area is divided into numbers of clusters.Each and every cluster has a cluster head (CH) and this cluster head directly communicateswith the BS. All nodes in a cluster send their data to their corresponding CH. e.g. TEEN is an example of this type of protocol. 4
  13. 13. 2.3 Depending on the Network Structure2.3.1 Data Centric :- Data centric protocols are query based and they depend on the naming of the desireddata, thus it eliminates much redundant transmissions. The BS sends queries to a certainarea for information and waits for reply from the nodes of that particular region. Since datais requested through queries, attribute based naming is required to specify the properties ofthe data. Depending on the query, sensors collect a particular data from the area of interestand this particular information is only required to transmit to the BS and thus reducing thenumber of transmissions. e.g. SPIN was the first data centric protocol.2.3.2 Hierarchical :- Hierarchical routing is used to perform energy efficient routing, i.e., higher energy nodescan be used to process and send the information; low energy nodes are used to perform thesensing in the area of interest. examples: LEACH, TEEN, APTEEN.2.3.3 Location Based :- Location based routing protocols need some location information of the sensor nodes.Location information can be obtained from GPS (Global Positioning System) signals, re-ceived radio signal strength, etc. Using location information, an optimal path can be formedwithout using flooding techniques. e.g. Geographic and Energy-Aware Routing(GEAR) 5
  14. 14. Chapter 3Routing Challenges and Design Issuesin WSNsDespite the innumerable applications of WSNs, these networks have several restrictions,e.g., limited energy supply, limited computing power, and limited bandwidth of the wirelesslinks connecting sensor nodes. One of the main design goals of WSNs is to carry out datacommunication while trying to prolong the lifetime of the network and prevent connectivitydegradation by employing aggressive energy management techniques. The design of routingprotocols in WSNs is inuenced by many challenging factors. These factors must be overcomebefore ecient communication can be achieved in WSNs. In the following, we summarize someof the routing challenges and design issues that affect routing process in WSNs[3]. ˆ Node deployment :- Node deployment in WSNs is application dependent and affects the performance of the routing protocol. The deployment can be either deterministic or randomized. In determinis- tic deployment, the sensors are manually placed and data is routed through pre-determined paths. However, in random node deployment, the sensor nodes are scattered randomly creating an infras- tructure in an ad hoc manner. If the resultant distribution of nodes is not uniform, optimal clustering becomes nec- essary to allow connectivity and enable energy ecient network operation. Inter-sensor communication is normally within short transmission ranges due to energy and band- width limita- tions. Therefore, it is most likely that a route will consist of multiple wireless hops. ˆ Energy Efficiency :- sensor nodes can use up their limited supply of energy perform- ing computations and transmitting information in a wireless environment. As such, energy- conserving forms of communication and computation are essential. Sensor node lifetime shows a strong dependence on the battery lifetime[8]. In a multihop WSN, each node plays a dual role as data sender and data router. The malfunctioning of some sensor nodes due to power failure can cause signicant topological changes and might require rerouting of packets and reorganization of the network. ˆ Data Reporting Model:- Data sensing and reporting in WSNs is dependent on the application and the time criticality of the data reporting. Data reporting can be catego- rized as either time-driven (continuous), event-driven, query-driven, and hybrid[9].The time-driven delivery model is suitable for applications that require periodic data moni- toring. As such, sensor nodes will periodically switch on their sensors and transmitters, 6
  15. 15. sense the environment and transmit the data of interest at constant periodic time in- tervals. In event-driven and query-driven models, sensor nodes react immediately to sudden and drastic changes in the value of a sensed attribute due to the occurrence of a certain event or a query is generated by the BS. As such, these are well suited for time critical applications. A combination of the previous models is also possible. The routing protocol is highly inuenced by the data reporting model with regard to energy consumption and route stability.ˆ Fault Tolerance:- Some sensor nodes may fail or be blocked due to lack of power, physical damage, or environmental interference. The failure of sensor nodes should not aect the overall task of the sensor network. If many nodes fail, MAC and routing protocols must accommodate formation of new links and routes to the data collec- tion base stations. This may require actively adjusting transmit powers and signaling rates on the existing links to reduce energy consumption, or rerouting packets through regions of the network where more energy is available. Therefore, multiple levels of redundancy may be needed in a fault-tolerant sensor network.ˆ Scalability:- The number of sensor nodes deployed in the sensing area may be in the order of hundreds or thousands, or more. Any routing scheme must be able to work with this huge number of sensor nodes. In addition, sensor network routing protocols should be scalable enough to respond to events in the environment. Until an event occurs, most of the sensors can remain in the sleep state, with data from the few remaining sensors providing a coarse quality.ˆ Quality of Service:- In some applications, data should be delivered within a cer- tain period of time from the moment it is sensed, otherwise the data will be useless. Therefore bounded latency for data delivery is another condition for time-constrained applications. However, in many applications, conservation of energy, which is directly related to network lifetime, is considered relatively more important than the quality of data sent. As the energy gets depleted, the network may be required to reduce the quality of the results in order to reduce the energy dissipation in the nodes and hence lengthen the total network lifetime. Hence, energy-aware routing protocols are required to capture this requirement. 7
  16. 16. Chapter 4Routing Protocols in WSNs Data dissemination is the process by which queries or data are routed in the sensornetwork. The data collected by sensor nodes has to be communicated to the BS or to anyother node interested in the data. The node that generates data is called a source and theinformation to be reported is called an event. Anode which is interested in an event and seeksinformation about it is called a sink. Traffic Models have been developed for sensor networkssuch as the data collection and data dissemination (diffusion) models. In the data collectionmodel, the source sends the data it collects to a collection entity such as the BS. This couldbe periodic or on demand. The data is processed in the central collection entity[1]. Datadiffusion, on the other hand, consists of a two-step process of interest propagation and datapropagation. an interested is a descriptor for a particular, intrusion or presence of bio-agents.For every event that a sink is interested in , it broadcasts its interest to its neighbors andperiodically refreshes its interest. The interest is propagated across the network and everynode maintains an interest cache of all events to be reported.4.1 Direct Diffusion Directed diffusion is a data-centric (DC) and application- aware paradigm in the sense thatall data generated by sensor nodes is named by attribute-value pairs. The main idea ofthe DC paradigm is to combine the data coming from dierent sources enroute (in-networkaggregation) by eliminating redundancy, minimizing the number of transmissions; thus sav-ing network energy and prolonging its lifetime. Unlike traditional end-to-end routing, DCrouting finds routes from multiple sources to a single destination that allows in-network con-solidation of redundant data[3]. This potocol is useful in scenario where the sensor nodesthemselves generate requests/queries for data sensed by other nodes, instead of all queriesarising only from a BS. Hence the sink for the query could be a BS or a sensor node. Thedirect diffusion routing protocol improves on data diffusion using interest gradients. Eachsensor node names its data with one or more attributes and other nodes express their interestdepending on these attributes. Attribute value pairs can be used to describe an interest inintrusion data as follows. The sink has to periodically refresh its interest if it still requires the data to be reportedit. Data is propagated along the reverse path of the interest propagation. Each path isassociated with a gradient that is formed at the time of interest propagation. Each path 8
  17. 17. is associated with the gradient that is formed at the time of interest propagation. Whilethe positive gradients encourage the data flow along the path, Negative gradients inhibitthe distribution of data along a perticular path. The strength of the interest is differenttoward different neighbors, resulting into source to sink paths with different gradients. Thegradient coresponding to an interest is derived from the interval/data-rate field specified inthe interest. In directed diffusion, sensors measure events and create gradients of information in theirrespective neighborhoods. The base station requests data by broadcasting interests. Interestdescribes a task required to be done by the network. Interest diuses through the networkhop-by-hop, and is broad- cast by each node to its neighbors. As the interest is propagatedthroughout the network, gradients are setup to draw data satisfying the query towards therequesting node, i.e., a BS may query for data by disseminating interests and intermediatenodes propagate these interests. Each sensor that receives the interest setup a gradienttoward the sensor nodes from which it receives the interest. This process continues untilgradients are setup from the sources back to the BS. More generally, a gradient specifiesan attribute value and a direction. The strength of the gradient may be different towardsdifferent neighbors resulting in different amounts of information ow. At this stage, loops arenot checked, but are removed at a later stage. Figure 4.1: An example of interest diffusion in sensor network 9
  18. 18. Figure 4.1 shows an example of the working of directed diffusion ((a) sending interests,(b) building gradients, and (c) data dissemination). When interests fit gradients, paths ofinformation ow are formed from multiple paths and then the best paths are reinforced so asto prevent further ooding according to a local rule. In order to reduce communication costs,data is aggregated on the way. The goal is to nd a good aggregation tree which gets thedata from source nodes to the BS. The BS periodically refreshes and re-sends the interestwhen it starts to receive data from the source(s). This is necessary because interests are notreliably transmitted throughout the network. All sensor nodes in a directed diusion-based network are application-aware, which enablesdiffusion to achieve energy savings by selecting empirically good paths and by caching andprocessing data in the network. Caching can increase the eciency, robustness and scalabilityof coordination between sensor nodes which is the essence of the data diusion paradigm.Other usage of directed diusion is to spontaneously propagate an important event to somesections of the sensor network. Such type of information retrieval is well suited only forpersistent queries where requesting nodes are not expecting data that satisfy a query forduration of time. This makes it unsuitable for one-time queries, as it is not worth settingup gradients for queries, which use the path only once. Directed diffusion differs from SPIN in two aspects. First, directed diffusion issues ondemand data queries as the BS send queries to the sensor nodes by flooding some tasks. InSPIN, however, sensors advertise the availability of data allowing interested nodes to querythat data. Second, all communication in directed diffusion is neighbor-to-neighbor with eachnode having the capability of performing data aggregation and caching. Unlike SPIN, thereis no need to maintain global network topology in directed diffusion. However, directeddiusion may not be applied to applications (e.g., environmental monitoring) that requirecontinuous data delivery to the BS. This is because the query- driven on demand data modelmay not help in this regard. Moreover, matching data to queries might require some extraoverhead at the sensor nodes.4.2 Sensor Protocol for Information via Negotiation SPIN uses Negotiation and resources and adaption to address the defi-ciencies of flooding.Negotiation Reduces overlap and implosion, and a threshold based resource-aware operationis used to prolong network lifetime. Meta-data, or data describing data, is transmittedinstead of row data. This requires fewer bytes and can be in an application-specific format.SPIN has three types of messages: ADV, REQ, and DATA. A sensor node broadcasts anADV containing meta-data describing actual data. If a neighbor is interested in the data, itsends REQ for the data. Then the sensor node sends the actual DATA to the neighbor[3]. The neighbor again sends ADVs to its neighbors and this process con-tinues to dissemi-nate the data throughout the network. The simple version is shown in figure. The SPIN family is designed to address the deficiencies of classic flooding by negotiationand resource adaptation. The SPIN family of protocols is designed based on two basic ideas: 10
  19. 19. Figure 4.2: Sensor Protocol for Information via Negotiation ˆ Sensor nodes operate more efficiently and conserve energy by sending data that describe the sensor data instead of sending all the data; for example, image and sensor nodes must monitor the changes in their energy resources. ˆ Conventional protocols like flooding or gossiping based routing protocols waste energy and bandwidth when sending extra and un-necessary copies of data by sensors cover- ing overlapping areas. The drawbacks of flooding include implosion, which is caused by duplicate messages sent to the same node, overlap when two nodes sensing the same region will send similar packets to the same neighbor and resource blindness by consuming large amounts of energy without Consideration for the energy Constraints. Gossiping avoids the problem of implosion by just selecting a random node to send the packet to rather than broadcasting the packet blindly. However, this causes delays in propagation of data through the nodes. SPIN’s meta-data negotiation solves the classic problems of ooding, and thus achieving alot of energy eciency. SPIN is a 3-stage protocol as sensor nodes use three types of messagesADV, REQ and DATA to communicate. ADV is used to advertise new data, REQ to requestdata, and DATA is the actual message itself. The protocol starts when a SPIN node obtainsnew data that it is willing to share. It does so by broadcasting an ADV message containingmeta-data. If a neighbor is interested in the data, it sends a REQ message for the DATAand the DATA is sent to this neighbor node. The neighbor sensor node then repeats thisprocess with its neighbors. As a result, the entire sensor area will receive a copy of the data. 11
  20. 20. The SPIN family of protocols includes many protocols. The main two protocols arecalled SPIN-1 and SPIN-2, which incorporate negotiation before transmitting data in orderto ensure that only useful information will be transferred. Also, each node has its ownresource manager which keeps track of resource consumption, and is polled by the nodesbefore data transmission. The SPIN-1 protocol is a 3-stage protocol, as described above.An extension to SPIN-1 is SPIN-2, which incorporates threshold-based resource awarenessmechanism in addition to negotiation. When energy in the nodes is abundant, SPIN-2communicates using the 3-stage protocol of SPIN-1. However, when the energy in a nodestarts approaching a low energy threshold, it reduces its participation in the protocol, i.e.,it participates only when it believes that it can complete all the other stages of the protocolwithout going below the low-energy threshold. In conclusion, SPIN-l and SPIN-2 are simpleprotocols that eciently disseminate data, while maintaining no per-neighbor state. Theseprotocols are well-suited for an environment where the sensors are mobile because they basetheir forwarding decisions on local neighborhood information. ˆ SPIN-BC: This protocol is designed for broadcast channels. ˆ SPIN-PP: This protocol is designed for a point to point communication, i.e., hop-by- hop routing. ˆ SPIN-EC: This protocol works similar to SPIN-PP, but with an energy heuristic added to it. ˆ SPIN-RL: When a channel is lossy, a protocol called SPIN-RL is used where adjust- ments are added to the SPIN-PP protocol to account for the lossy channel. The advantages of SPIN is that topological changes are localized since each node needsto know only its single-hop neighbors. SPIN provides much energy savings than flooding andmeta- data negotiation almost halves the redundant data. However, SPINs data advertise-ment mechanism cannot guarantee the delivery of data. To see this, consider the applicationof intrusion detection where data should be reliably reported over periodic intervals andassume that nodes interested in the data are located far away from the source node and thenodes between source and destination nodes are not interested in that data, such data willnot be delivered to the destination at all.4.3 Low Energy Adaptive Clustering Hierarchy (LEACH). LEACH is a cluster-based protocol, which includes distributed cluster formation. LEACHrandomly selects a few sensor nodes as clusterheads (CHs) and rotate this role to evenlydistribute the energy load among the sensors in the network. In LEACH, the clusterhead(CH) nodes compress data arriving from nodes that belong to the respective cluster, andsend an aggregated packet to the base station in order to reduce the amount of informationthat must be transmitted to the base station. LEACH uses a TDMA/CDMA MAC toreduce inter-cluster and intra-cluster collisions. However, data collection is centralized andis performed periodically. Therefore, this protocol is most appropriate when there is a needfor constant monitoring by the sensor network. A user may not need all the data immediately. 12
  21. 21. Hence, periodic data transmissions are unnecessary which may drain the limited energy ofthe sensor nodes. After a given interval of time, a randomized rotation of the role of theCH is conducted so that uniform energy dissipation in the sensor network is obtained. Theauthors found, based on their simulation model, that only 5% of the nodes need to act ascluster heads. The operation of LEACH is separated into two phases, the setup phase and the steadystate phase. In the setup phase, the clusters are organized and CHs are selected. In thesteady state phase, the actual data transfer to the base station takes place. The duration ofthe steady state phase is longer than the duration of the setup phase in order to minimizeoverhead. During the setup phase, a predetermined fraction of nodes, p, elect themselves asCHs as follows. A sensor node chooses a random number, r, between 0 and 1. If this randomnumber is less than a threshold value, T(n), the node becomes a cluster-head for the currentround. The threshold value is calculated based on an equation that incorporates the desiredpercentage to become a cluster-head, the current round, and the set of nodes that have notbeen selected as a cluster-head in the last (1/P) rounds, denoted by G. It is given by: p T (n) = if n G (4.1) 1 − p(rmod(1 = p))where G is the set of nodes that are involved in the CH election[3]. Each elected CHbroadcast an advertisement message to the rest of the nodes in the network that they arethe new cluster-heads. All the non-cluster head nodes, after receiving this advertisement,decide on the cluster to which they want to belong to. This decision is based on the signalstrength of the advertisement. The non cluster-head nodes inform the appropriate cluster-heads that they will be a member of the cluster. After receiving all the messages from thenodes that would like to be included in the cluster and based on the number of nodes in thecluster, the cluster-head node creates a TDMA schedule and assigns each node a time slotwhen it can transmit. This schedule is broadcast to all the nodes in the cluster. During thesteady state phase, the sensor nodes can begin sensing and transmitting data to the cluster-heads. The cluster-head node, after receiving all the data, aggregates it before sending itto the base-station. After a certain time, which is determined a priori, the network goesback into the setup phase again and enters another round of selecting new CH. Each clustercommunicates using different CDMA codes to reduce interference from nodes belonging toother clusters. Although LEACH is able to increase the network lifetime, there are still anumber of issues about the assumptions used in this protocol. LEACH assumes that allnodes can transmit with enough power to reach the BS if needed and that each node hascomputational power to support different MAC protocols. Therefore, it is not applicable tonetworks deployed in large regions. It also assumes that nodes always have data to send, andnodes located close to each other have correlated data. It is not obvious how the numberof the predetermined CHs (p) is going to be uniformly distributed through the network.Therefore, there is the possibility that the elected CHs will be concentrated in one part ofthe network. Hence, some nodes will not have any CHs in their vicinity. Furthermore, theidea of dynamic clustering brings extra overhead, e.g. head changes, advertisements etc.,which may diminish the gain in energy consumption. Finally, the protocol assumes thatall nodes begin with the same amount of energy capacity in each election round, assumingthat being a CH consumes approximately the same amount of energy for each node. Theprotocol should be extended to account for non-uniform energy nodes, i.e., use energy-basedthreshold. An extension to LEACH, LEACH with negotiation. The main theme of the 13
  22. 22. proposed extension is to precede data transfers with high-level negotiation using meta-datadescriptors as in the SPIN protocol discussed in the previous section. This ensures thatonly data that provides new information is transmitted to the cluster-heads before beingtransmitted to the base station. Figure 4.3: Comparison between SPIN, LEACH and Directed Diffusion.4.4 CTP : Collection Tree ProtocolCollecting information reliably and efficiently from the nodes in a sensor network is a chal-lenging problem, particularly due to the wireless dynamics. Multihop routing in a dynamicwireless environment requires that a protocol can adapt quickly to the changes in the network(agility) while the energy-constrains of sensor networks dictate that such mechanisms notrequire too much communication among the nodes (efficiency). CTP is a collection routingprotocol, that achieves both agility and efficiency, while offering highly reliable data deliveryin sensor networks.[5] 14
  23. 23. Figure 4.4: Multihop Wireless Routing Using CTP CTP has been used in research, teaching, and in commercial products. Experiences withCTP has also informed the design of the IPv6 Routing Protocol for Low power and LossyNetworks (RPL). CTP is a distance vector routing protocol designed for sensor networks.CTP computes the routes from each node in the network to the root (specified destinations)in the network. CTP uses these three mechanisms to overcome the challenges faced bydistance vector routing protocol in a highly dynamic wireless network: Agile and Accurate Link Quality Estimation: The links in a wireless network arehighly dynamic and exhibit bursty behavior over short time scales. This property of wirelesslinks suggests that a link quality must be agile for it to be accurate. The four-bit linkestimator used in CTP uses information from the physical, data link, and network layers toprovide accurate link quality estimates despite these challenges. Datapath Validation: In a dynamic wireless environment, a routing path that is reli-able at one point can become unreliable or even unavailable within a few seconds. Due tochanging link qualities, loops can form and cause network congestion and energy drain dueto looping packets. Thus, these problems in the routing path must be detected as quickly 15
  24. 24. as they occurr. CTP uses datapath validation to detect these problems at the timescaleof data packet transmission (a few tens of milliseconds). It does so by using data packetstransmissions and receptions as topology probes and quickly detecting the problem whenthe packets do not make progress towards the destination in the routing metric space. 16
  25. 25. Adaptive Beaconing: Routing protocols typically broadcast control packets at a fixedinterval (e.g., every 30 seconds). This interval poses a basic tradeoff. A small interval, i.e.,frequent beacons, makes the protocol more responsive to the changes in the network, butuses more bandwidth and energy. A large interval uses less bandwidth and energy but canlet topological problems persist for a long time. CTP uses adaptive beaconing to breakthis tradeoff. When the topology is inconsistent and has problems, it sends beacons faster.Otherwise, it decreases the beaconing rate exponentially. Thus, CTP can quickly respondto adverse wireless dynamics while incuring low control overhead in the long term.4.5 Greedy Perimeter Stateless Routing(GPSR) GPSR is a geographic routing for wireless sensor networks. Unlike traditional Internetrouting(DV, LS), each node keep states from immediate neighbors and uses only those statesfor data forwarding. The state is geographic position that all sensor nodes can self-configurethrough GPS devices or others. Source node propagates data with the position of destinationto wireless sensor network. In normal case, forwarding node runs greedy mode routing. Thegreedy routing firstly selects a node whose distance to a destination is less than distancefrom forwarding node to destination and shortest among all immediate neighbors. Then,data are forwarded to it. If there is no neighbor whose distance to destination is greaterthan distance from forwarding node to destination, forwarding node runs perimeter moderouting. The perimeter routing is based on planarized graphs such as Relative NeighborhoodGraph(RNG) or Gabriel Graph(GG). When each node receives position information fromimmediate nodes, it initially makes unit graph and then determine RNG or GG. If the nodereceives data and it cant perform greedy routing, it selects a node among immediate nodesby right-handed rule and sends data to the neighbor. However, the edge between sendingnode and receiving neighbor should not cross the edge between origin node and destination.During data forwarding in perimeter mode, if forwarding node run greedy routing, it returnsto perimeter mode into greedy mode[6].4.5.1 States of Neighbors ˆ Add and delete neighbor ˆ Update and look-up the state of neighbor ˆ Update RNG topology and GG topology ˆ Find shortest-path for greedy forward or clockwise-path for perimeter forward4.5.2 Beaconing ˆ Receive beacon packet and beacon solicit packet ˆ Periodically broadcast beacon packet to neighbor nodes ˆ Periodically check connections to neighbor nodes. 17
  26. 26. 4.5.3 Greedy Forwarding ˆ Receive greedy-mode data packet ˆ Send the pure application data except for GPSR protocol header to upper application if the destination of packet is same as the position of local node. ˆ Send the receiving whole packet to upper application if GPSR daemon runs on loosely- coupled mod. ˆ Forward the packet to shortest neighbor nodes if GPSR daemon runs on tightly-coupled mod.4.5.4 Perimeter Forwarding ˆ Receive perimeter-mode data packet ˆ Send the pure application data except for GPSR protocol header to upper application if the destination of packet is same as the position of local node. ˆ Send the receiving whole packet to upper application if GPSR daemon runs on loosely- coupled mod. ˆ Forward from on perimeter mode to on greedy mode if distance from local to destination is shorter than one from previous node to destination. ˆ Drop(send to application) the pure data except for protocol header if receiving packet is the previous sent packet to neighbor. ˆ Perform face change algorithm. ˆ Forward the packet to counterclockwise neighbor nodes.4.6 Power Efficient Gathering for Sensor Information Systems Power Efficient Gathering for Sensor Information Systems (PEGASIS) is a data-gatheringprotocol based on the assumption that all sensor nodes know the location of every other node,that is, the topology information is available to all nodes. Also,any node has the requiredtransmission range to reach the BS in one-hop, when it is select as a leader. The goals ofPEGASIS are as follows : ˆ Minimize the distance over which each node transmits. ˆ Minimize the broadcasting overhead. ˆ Minimize the number of messages that need to be sent to the BS. ˆ Distribute the energy consumption equally across all nodes. 18
  27. 27. Figure 4.5: Power Efficient Gathering for Sensor Information Systems A greedy algorithm is used to construct a chain of sensor nodes, starting from the nodefarthest from the BS. At each step, the nearest neighbor which has not been visited is addedto the chain. The chain is constructed a priory, before data transmission begins and isreconstructed when nodes die out. At every node, data fussion is carried out. so, that onlyone message is passed on from one node to next. A node which is designated as the leaderfinally transmits one message to BS. Leadership is transffered in sequential order and a token is passed. so that the nodesknow in which direction to pass messages in order to reach the leader. A possible chainformation is illustrated in figure. The delay involved in message reaching the BS is O(N),where N is the total number of nodes in the network[1].4.7 Binary Scheme This is also a chain-based scheme like PEGASIS, which classifies nodes into differentlevels. All nodes which recieve messages at one level rises to the next level[1]. 19
  28. 28. Step 1 :- S0 → S1 S2 → S3 S4 → S5 S6 → S7 Step 2 :- S1 → S3 S5 → S7 Step 3 :- S3 → S7 Step 4 :- S7 → BS The number of nodes is halved from one level to the next. For instance,consider a networkwith eight nodes labled from S0 to S7. In figure agreegated data reaches the BS in 4 stepswhich is O(log2 N ).where N is the number of nodes in the network.4.8 Chain Based Three level Scheme For non CDMA sensor nodes, a binary scheme is not applicable. The chain based threelevel scheme addresses this situation. In this scheme chain is constructed as in PEGASIS.The chain is devided into into number of groups to space out simulteneous transmission inorder to minimize interference. Within a group , nodes transmit one at a time[1]. One node out of each group agreegates data from all group members and rises to thenext level. The index of this leader node is decided priori. In the second level all nodes aredevided into two groups and the third level consist of a message exchange between one nodefrom each group of second level. Finally the leader transmits a single message to BS. Step 1 :- S0 → S1....S6 → S7 ← S8 ← S9 S10 → S11....S16 → S17 ← S18..........S97 ←S98 ← S99 Step 2 :- S7 → S17 ← S27 ← S37 ← S47 S57 → S67 ← S77 ← S87 ← S97 Step 3 :- S17 ← S67 Step 4 :- S67 → BS The working of this scheme is explain in above figure.Suppose Network has 100 nodesand the group size is 10 for the first level and 5 for second level. Three levels have beenfound to give the optimal energy X delay through simulation. 20
  29. 29. Chapter 5Simulation And Analysis we validate our analysis using simulations. We have also compared the performance ofdifferent protocols under same settings of the network parameters.5.1 Greedy Perimeter Stateless Routing(GPSR) The source node and destination node are assumed. The source node transmits thehello packet to all neighbourhood nodes through right hand flooding technique. The floodedpackets are tracked and a routing table is formed at the base station. Different path to deliverthepackets is found, data reachability is ensured and a routing table is formed with all thesuccessful routes. Once the routing table is formed, the optimal route is selected based onpacket delivery delay, less energy consumption and number of hops. We simulated the GPSRprotocol using Castalia Simulator. No of Nodes in Simulation is 100. Node deployment isUniform . For the simulation experiment, following parameter was used: 21
  30. 30. Figure 5.1: Energy Consumed By Each Node The Energy Consumption at every Node is shown in Figure: The GPSR routing protocol strives to address the unique requirements for sensor networkapplications. It provides a robust, energy-efficient routing protocol with the ability to routemessages from node to node and guarantees the delivery of packets under situations wherenon-uniform transmission ranges exist. A geographical routing protocol was developed andimplemented for successful data delivery to any destination within the network or to the basestation. The results of proposed optimal routing indicate that the energy consumption canbe systematically decreased by optimizing the clusters and head set size which also increasesthe efficiency of the network. The energy efficiency of the etwork is increased by ensuringthe data reachability using proper routing technique. If the path is being established fromsource to destination, the particular path might get loaded due to the traffic conditions. Iftraffic density is more, then an alternative path needs to be selected from the routing tablewith optimal energy conservation and shortest path with less traffic. This selection of pathwill further improve the routing technique by reducing the Packet Delivery Delay and energyconsumption.5.2 Collection Tree Protocol (CTP) We simulated the CTP cluster based routing protocol using Castalia Simulator. No ofNodes in Simulation is 100. Node deployment is Uniform and area of ”250x250”. For thesimulation experiment, following parameter was used: The Results of the simulation are shown in following figures.which shows the ApplicationLevel Latency , Packets recieved per Node , Recieved packet breakdown, Transmitted Packetsand Energy Consumed By each Node. 22
  31. 31. Figure 5.2: Energy Consumed By Each Node 23
  32. 32. Figure 5.3: Application Level Latency at Each Node Figure 5.4: Packets recieved per Node 24
  33. 33. Figure 5.5: CTP data per NodeFigure 5.6: Packets Transmitted per Node 25
  34. 34. 5.3 Low-Energy Adaptive Clustering Hierarchy (LEACH)Low-Energy Adaptive Clustering Hierarchy (LEACH) protocol for sensor networks is pro-posed by W. R. Heinzelman et. which minimizes energy dissipation in sensor networks. Itis very famous hierarchical routing algorithms for sensor networks which make clusters ofthe sensor nodes based on the received signal strength.The 5% of the total number of nodesbecomes the cluster head which act as router to the sink. Energy consumption is less astransmission will only be done by cluster head. We simulated the LEACH cluster based routing protocol using Castalia Simulator. Noof Nodes in Simulation is 100. Node deployment is Uniform and area of ”70x70”. For thesimulation experiment, following parameter was used: The Results of the simulation are shown in following figures.which shows the ApplicationLevel Latency , Packets recieved per Node , Recieved packet breakdown, Transmitted Packetsand Energy Consumed By each Node. 26
  35. 35. Figure 5.7: Energy Consumed By Each NodeFigure 5.8: Application Level Latency at Each Node 27
  36. 36. Figure 5.9: Packets recieved per Node Although LEACH is able to increase the network lifetime, there are still a number of issuesabout the assumptions used in this protocol. LEACH assumes a homogeneous distributionof sensor nodes in the given area. This scenario is not very realistic[7]. LEACH assumes thatall nodes can transmit with enough power to reach the BS if needed and that each node hascomputational power to support different MAC protocols. Therefore, it is not applicable tonetworks deployed in large regions. It also assumes that nodes always have data to send andnodes located close to each other have correlated data. It is not obvious how the number ofpredetermined Cluster Heads is going to be uniformly distributed throughout the network.Therefore, there is a possibility that the elected CHs will be concentrated in one part of thenetwork.The Hierarchical routing protocol LEACH is energy efficient for the sensor network.By varying the different no. of clusters heads/clusters in the network the performance ofnetwork changed in terms of lifetime, throughput and average energy dissipation. From theabove results we concluded that if the clusters in network or cluster heads in network arebelow or above 5 percentage of the total no. of nodes the performance of the network isdegraded in terms of energy, throughput and lifetime[7]. 28
  37. 37. Figure 5.10: Comparison of Routing Protocols in WSN 29
  38. 38. Chapter 6References 1. Ad Hoc Wireless Networks By,C.Shiva Ram Murthy and B.S.Manoj 2. sensor network Access on 20th June 2012 3. Routing Techniques in Wireless Sensor Networks: A Survey BY Jamal N. Al-Karaki AND Ahmed E. Kamal 4. A Review on Enhanced GPSR protocol For Wireless Sensor Networks by P.Pranitha,G.Swamy,Aaku Manjula. 5. Accessed on 28th October 2012 6. Greedy Perimeter Stateless Routing (GPSR) USER Specification By Ramesh Govidan 7. Energy and Throughput Analysis of Hierarchical Routing Protocol (LEACH) for Wire- less Sensor Network by prof.Vijay Ukani,Nirma University. 8. W. Heinzelman, A. Chandrakasan and H. Balakrishnan, ”Energy-Ecient Communica- tion Protocol for Wireless Mi- crosensor Networks,” Proceedings of the 33rd Hawaii International Conference on System Sciences (HICSS ’00), January 2000. 9. Y. Yao and J. Gehrke, The cougar approach to in-network query processing in sensor networks”, in SIGMOD Record, September 2002.10. Marc Greis tutorial For NS211. Castalia User Manual 30