38
LEACH Low Energy Adaptive Clustering Hierarchy Deparment of Computer Science Institute of System Architecture, Chair for Computer Network Dresden, 23 January 2007 Puneeth Kosaraju Miczard Riupassa

Leach routing protocol implementation in ns2

Embed Size (px)

DESCRIPTION

implementation of leach routing protocol in NS2

Citation preview

Page 1: Leach routing protocol implementation in ns2

LEACHLow Energy Adaptive Clustering Hierarchy

Deparment of Computer Science Institute of System Architecture, Chair for Computer Network

Dresden, 23 January 2007

Puneeth KosarajuMiczard Riupassa

Page 2: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

Outline

1. Preface.

2. Problem Definition.

3. LEACH Assumptions.

4. LEACH Protocol Architecture.

1. Determining Cluster Head nodes.

2. Set-up phase.

3. Steady State phase.

4. LEACH Protocol Variations (LEACH-C, LEACH-F).

5. Simulations of LEACH.

6. Conclusion.

7. References.

LEACH 2

Page 3: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

Basic fundamentals of Wireless Sensor Network

From book Protocol and Architecture for Wireless Sensor Network

1. Small2. Cheap 3. Efficient of Energy

LEACH 3

Page 4: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

Requirement Design of Wireless Sensor Network

From book Protocol and Architecture for Wireless Sensor Network

1. Type of Service2. Quality of Service3. Fault Tolerant4. Life Time5. Scalability6. Range of Density7. Programability8. Maintainability

LEACH 4

Page 5: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

Problem Definition in WSN

Ease of DeploymentSensor Network may contain hundreds untill thousands node

System Life TimeLong life time as possible.

Latency Data distribution is time sensitive

QualityReduce same redundant data between nodes

LEACH 5

Page 6: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

Why Use Microsensors?

1. Large number of Microsensors can be used to obtain desired accuracy

2. Relatively inexpensive

3. Low-power dissipation

4. Can be used to monitor machines for fault detection and diagnosis

LEACH 6

Page 7: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

Assumption

Radio characteristics

1. Same energy dissipation in transmit and receive circuitry

2. r2 Energy loss due to channel transmission

3. Radio channel is symmetric

Sensor Characteristics

4. Sensors are sensing environments at fixed rate

5. Sensors communicate among each other and to the base station

6. All sensors are homogenous and have energy-constraint

Base Station

7. Base station is fixed

8. Base station is located far from sensors

LEACH 7

Page 8: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

LEACH (Low-Energy Adaptive Clustering Hierarchy)

1. Self-Organizing, adaptive clustering protocol.

2. Even distribution of energy load among the sensors.

3. Dynamic cluster formation.

4. Randomized rotation of cluster heads after each round.

5. Cluster-heads communicate data with the base station.

6. Application-specific data processing, such as data aggregation.

LEACH 8

Page 9: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

LEACH – Architecture

LEACH 9

Page 10: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

Phase Life of Leach Protocol

Each Leach operation round consists of Set-up phase (clusters are organized).

Cluster Head Selection. Cluster Formation.

Steady state Phase (data transmission).

Timeline showing LEACH operation [6]

LEACH 10

Page 11: Leach routing protocol implementation in ns2

Setup phase

At the beginning of each round, each node advertises it probability, (depending upon its current energy level) to be the Cluster Head, to all other nodes.

Nodes (k for each round) with higher probabilities are chosen as the Cluster Heads.

Cluster Heads broadcasts an advertisement message (ADV) using CSMA MAC protocol.

Based on the received signal strength, each non-Cluster Head node determines its Cluster Head for this round (random selection with obstacle).

Each non-Cluster Head transmits a join-request message (Join-REQ) back to its chosen Cluster Head using a CSMA MAC protocol.

Cluster Head node sets up a TDMA schedule for data transmission coordination within the cluster.

TU Dresden, 23/01/2007 LEACH 11

Page 12: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

Flow graph for Setup phase[6]

LEACH 12

Page 13: Leach routing protocol implementation in ns2

Cluster Head Selection Algorithm[6]

Pi(t) is the probability with which node i elects itself to be Cluster Head at the beginning of the round r+1 (which starts at time t) such that expected number of cluster-head nodes for this round is k.

(1)

k = number of clusters during each round. N = number of nodes in the network.

TU Dresden, 23/01/2007 LEACH 13

Page 14: Leach routing protocol implementation in ns2

Cluster Head Selection Algorithm [6]

Each node will be Cluster Head once in N/k rounds.

Probability for each node i to be a cluster-head at time t

(2)

Ci(t) = it determines whether node i has been a Cluster Head in most recent (r mod(N/k)) rounds.

TU Dresden, 23/01/2007 LEACH 14

Page 15: Leach routing protocol implementation in ns2

Cluster Head Selection Algorithm[6]

(3)

= total no. of nodes eligible to be a cluster-head at time t.

This ensures energy at each node to be approx. equal after every N/k rounds.

Using (2) and (3), expected no of Cluster Heads per round is,

(4)

TU Dresden, 23/01/2007 LEACH 15

Page 16: Leach routing protocol implementation in ns2

Cluster Formation Algorithm [2]

Cluster Heads broadcasts an advertisement message (ADV) using CSMA MAC protocol. ADV = node’s ID + distinguishable header.

Based on the received signal strength of ADV message, each non-Cluster Head node determines its Cluster Head for this round (random selection with obstacle).

Each non-Cluster Head transmits a join-request message (Join-REQ) back to its chosen Cluster Head using a CSMA MAC protocol. Join-REQ = node’s ID + cluster-head ID + header.

Cluster Head node sets up a TDMA schedule for data transmission coordination within the cluster.

TDMA Schedule Prevents collision among data messages. Energy conservation in non cluster-head nodes.

TU Dresden, 23/01/2007 LEACH 16

Page 17: Leach routing protocol implementation in ns2

Dynamic Cluster Formation

TU Dresden, 23/01/2007Clusters at time t

Clusters at time t+dLEACH 17

Page 18: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

TDMA schedule is used to send data from node to head cluster. Head Cluster aggregates the data received from node cluster’s. Communication is via direct-sequence spread spectrum (DSSS) and each

cluster uses a unique spreading code to reduce inter-cluster interference. Data is sent from the cluster head nodes to the BS using a fixed spreading

code and CSMA.

Steady-State Phase

Timeline showing LEACH operation [6]

LEACH 18

Page 19: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

Assumptions Nodes are all time synchronized and start the setup phase at same time.

BS sends out synchronized pulses to the nodes. Cluster Head must be awake all the time.

To reduce inter-cluster interference, each cluster in LEACH communicates using direct-sequence spread spectrum (DSSS).

Data is sent from the cluster head nodes to the BS using a fixed spreading code and CSMA.

Steady-State Phase

Timeline showing LEACH operation [6]

LEACH 19

Page 20: Leach routing protocol implementation in ns2

Flow Chart for Steady Phase[6]

TU Dresden, 23/01/2007 LEACH 20

Page 21: Leach routing protocol implementation in ns2

Sensor Data Aggregation

Data aggregation is performed on all the uncompressed data at cluster head. Performing local data aggregation requires less energy than sending all the

unprocessed data to the BS.

» L:1 data compression.» EDA : energy dissipation per bit for data

aggregation.» ETX : energy dissipation per bit to transmit to BS.

TU Dresden, 23/01/2007 LEACH 21

Page 22: Leach routing protocol implementation in ns2

Sensor Data Aggregation [6]

L = 20, BS is 100m away, cost of commn. to BS = 1.05 X 10-6 J /bit . Result: when energy to perform DA < 1.05 X 10-6 J, total energy

dissipation of the system is less using data aggregation.

TU Dresden, 23/01/2007 LEACH 22

Page 23: Leach routing protocol implementation in ns2

LEACH-C: BS Cluster Formation

LEACH doesn’t guarantee cluster head spread in the network. Centralized clustering algorithm for cluster formation. Uniform distribution of Cluster Heads through out the network. Uses same steady-state protocol as LEACH. Set-up phase

Each node specifies its location(using GPS) and energy level to the BS. BS runs an optimization algorithm to determine the cluster’s for that

round. BS determines optimal clusters and broadcasts a message containing

cluster head ID for each node.

TU Dresden, 23/01/2007 LEACH 23

Page 24: Leach routing protocol implementation in ns2

LEACH-F: Fixed Cluster, Rotating Cluster Head

Clusters are formed once using centralized cluster formation algorithm(LEACH-C) and are fixed.

Cluster Head position rotates among the nodes in the cluster. BS determines optimal clusters and broadcasts a message containing cluster

head ID for each node. First node listed in the cluster becomes Cluster Head for first round. Steady-state protocol is identical to LEACH protocol. Advantage: No setup overhead at the beginning of each round. Disadvantages

Requires more transmit power from nodes. Increases energy dissipation of non CH node and inter-cluster

interference. Not practical for dynamic system. Doesn’t handle node mobility.

TU Dresden, 23/01/2007 LEACH 24

Page 25: Leach routing protocol implementation in ns2

LEACH Simulation [6]

TU Dresden, 23/01/2007 LEACH 25

100 node random test network

Page 26: Leach routing protocol implementation in ns2

LEACH Simulation

tround = 0.08 seconds * (Estart / 9 mJ)

Estart : initial energy of the nodes.

tround : time after which cluster-heads and associated clusters

should be rotated

TU Dresden, 23/01/2007 LEACH 26

Page 27: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

LEACH – Simulation Result

Energy dissipation System Lifetime

LEACH 27

Page 28: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

LEACH - System Life TimeAfter 1200 rounds

Live nodes (circled)

Dead nodes (dotted)

LEACH 28

Page 29: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

LEACH – Results

1. Factor of 7 reduction in energy dissipation as compared to Direct Communication

2. Uniform distribution of energy-usage in the network3. Doubles the system lifetime compared to other methods4. Nodes die essentially in random fashion, thus maintain the network

coverage

LEACH 29

Page 30: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

LEACH-Centralized (Leach-C ): Base Station Cluster Formation

Mechanism• Send data about position and energy level to the Base Station• Base Station are calculating Energy consume that needed• Base Station define cluster head and cluster node with the ID

number and also cluster area.

In fact ..LEACH-C delivers 40% more data per unit energy than LEACH

LEACH 30

Page 31: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

LEACH-C : Simulation Result

Total amount of data received at the BS over time.

Number of nodes alive per amount of data sent to the BS

LEACH 31

Page 32: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

LEACH – Pros

Pros

1. As Hierarchical Topology, LEACH is fundamental algorithm design.

2. Theoretical analysis go well with the simulation results.

3. Better energy utilization and system life time.

4. The algorithm provides prolonged network coverage ( low latency ).

LEACH 32

Page 33: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

LEACH –Cons

Cons

1. The simulations are still to be performed using the Network simulator

2. Fault-tolerance issues – when nodes fail or behave unexpectedly

3. The paper assumes all the nodes begin with same energy – this assumption may not be realistic

LEACH 33

Page 34: Leach routing protocol implementation in ns2

TU Dresden, 23/01/2007

Reference1. Heinzelman Wendi Rabiner, Chandrakasan Anantha, and Balakrishnan Hari. Energy-Efficient

Communication Protocol for Wireless Microsensor Networks. In IEEE. Published in the Proceedings of the Hawaii International Conference on System Sciences, January 4-7, 2000, Maui, Hawaii.

2. Heinzelman Wendi Rabiner, Chandrakasan Anantha, and Balakrishnan Hari. An Application-Specific Protocol Architecture for Wireless Microsensor Networks. IEEE Transactions On Wireless Communication, Vol. 1, No. 4, October 2002.

3. Handy. M. J, Haase. M, Timmermann. D. Low Energy Adaptive Clustering Hierarchy with Deterministic Cluster-Head Selection. IEEE International Conference on Mobile and Wireless Communications Networks, 2002, Stockholm.

4. Yrjölä Juhana. Summary of Energy-Efficient Communication Protocol for Wireless Microsensor Networks, 13th March 2005.

5. Karl Holger, Willig Andreas. Protocol and Architecture for Wireless Sensor Network, John Willey and Sons Ltd, 2005.

6. W. Heinzelman, “Application-specific protocol architectures for wireless networks,” Ph.D. dissertstion, Mass. Inst. Technol., Cambridge, 2000.

LEACH 34

Page 35: Leach routing protocol implementation in ns2

Acknowledgements

Some of the slides are inspired from following presentations

Tuteja Mukul. Presentation of Energy-Efficient Communication Protocol for Wireless Microsensor Networks.

Saket Das, Presentation on LEACH protocol, University of Nebraska-Lincoln.

TU Dresden, 23/01/2007 LEACH 35

Page 36: Leach routing protocol implementation in ns2

Questions &

Comments

TU Dresden, 23/01/2007 LEACH 36

Page 37: Leach routing protocol implementation in ns2

Optimal percentage of cluster heads

If number of cluster-heads is less than k, some nodes have to transmit very far to reach the cluster head, large global energy.

If number of cluster-heads is more than k, distance does not reduce substantially, more cluster heads have to transmit the long haul distances to the base station, hence compression is less.

TU Dresden, 23/01/2007 LEACH 37

Page 38: Leach routing protocol implementation in ns2

LEACH Simulation

TU Dresden, 23/01/2007 LEACH 38