Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Self-stabilization and Sensor Networks
M Potop Butucaru, F Petit, S Tixeuil
UPMC Sorbonne Universités [email protected]
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Outline
Sensor Networks and Self-stabilization Model(s)
Cached Sensornet Self-stabilizing Unison TDMA
Motivation Algorithm stack Clustering
Density
Self-stabilizing Clustering Simulation Results Conclusion
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Sensor Networks
Iprocessor + sensors + radio
I2 AA batteries, on/off switch
I3 LEDs for debugging
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Sensor Networks
While (batteries supply power)
ICollect, aggregate and reduce data
Ilog into memory
In spite of numerous fault modes
IPermanent sensor failures, node failures
Irestarts, radio failures
Itransient faults, reconfigurations
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Distributed Systems
Definition (Classical System,
a.k.a.Non stabilizing)
Starting from aparticularinitial configuration, the system immediatelyexhibits correct behavior.
Definition (Self-stabilizing System)
Starting fromanyinitial configuration, the system eventuallyreaches a configuration from with its behavior is correct.ISelf-stabilization permits to recover from transient failures
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Distributed Systems
Definition (Classical System,
a.k.a.Non stabilizing)
Starting from aparticularinitial configuration, the system immediatelyexhibits correct behavior.
Definition (Self-stabilizing System)
Starting fromanyinitial configuration, the system eventuallyreaches a configuration from with its behavior is correct.ISelf-stabilization permits to recover from transient failures
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Self-stabilization
“Correct”
Time Configurations
Stabilization Time
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Complexity Criteria
Maximize useful lifetime of system
I“maximise useful”: correct quickly from illegitimate state
ISelf-stabilization, scalability
I“maximise lifetime”: use minimal energy to preserve batteries
Ilocal vs. global preserving
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
System Specifics
Ionly one radio frequency Ino collision detect Iaccess technique: CSMA/CA Iuse CRC to detect collision Ino directional send/receive Imsg. are small (30 bytes) Iradio range about 1 meter Inumber of neighbors < 10 Icould be large number of nodes (perhaps > 100000)
Iunique node IDs (probably) Icost a fewU(someday) Islow processor (4 MHz) Ilimited memory (4 KB RAM) Iitem nodes have real-time
clocks⌘drift between 1 msec and 100 msec per second
Iseveral power modes available
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
The Model(s)
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
The Model(s)
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
The Model(s)
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
The Model(s)
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
a b
c d
e
f h g
i j
k l
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
The Model(s)
Self-stabilizing model
IRead neighborhood state,
Icompute and update local state
Sensor Network model
IRead local state,
Icompute and broadcast to neighborhood
ICollisions may appear
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Self-stabilization in Sensor Networks
Transform (i.e. Simulate) the self-stabilizing model into the sensor networks model
IPros: reuse existing SS algorithms
ICons: potentially inefficient, overhead
I[Herman 03]Cached Sensornet Transform
Design self-stabilizing algorithms for the sensor networks model
IPros: potentially efficient
ICons: ignore previous SS work
I[Herman 03]Unison with collisions
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Self-stabilization in Sensor Networks
Transform (i.e. Simulate) the self-stabilizing model into the sensor networks model
IPros: reuse existing SS algorithms
ICons: potentially inefficient, overhead
I[Herman 03]Cached Sensornet Transform
Design self-stabilizing algorithms for the sensor networks model
IPros: potentially efficient
ICons: ignore previous SS work
I[Herman 03]Unison with collisions
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Self-stabilization in Sensor Networks
Transform (i.e. Simulate) the self-stabilizing model into the sensor networks model
IPros: reuse existing SS algorithms
ICons: potentially inefficient, overhead
I[Herman 03]Cached Sensornet Transform
Design self-stabilizing algorithms for the sensor networks model
IPros: potentially efficient
ICons: ignore previous SS work
I[Herman 03]Unison with collisions
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Cached Sensornet Transform
Basic Algorithm
IEach nodephas a variablevp IEach neighborqofphas a variablecqvp
Icqvpis the cached value ofvpatq
IWheneverpassignsvp,palso broadcasts the new value to the neighborhood
IWhenever a neighborqofpreceivesvp,qupdatescqvp
accordingly
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Cached Sensornet Transform
Definition (Cache coherence)
For all neighborspandq,cqvp=vpLemma (Closure)
If started from a cache coherent state, and without collisions, the self-stabilizing model is simulated by replacing all occurrences of cqvpby vp
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Lemma (Closure)
If started from a cache coherent state, and without collisions, the self-stabilizing model is simulated by replacing all occurrences of cqvpby vp
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Lemma (Closure)
If started from a cache coherent state, and without collisions, the self-stabilizing model is simulated by replacing all occurrences of cqvpby vp
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Lemma (Closure)
If started from a cache coherent state, and without collisions, the self-stabilizing model is simulated by replacing all occurrences of cqvpby vp
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Cached Sensornet Transform
Periodic retransmit
IEach nodepperiodically broadcastsvpto its neighborhood
Lemma (Convergence)
If started from an arbitrary state, and without collisions, a cache coherent state is eventually reached
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Lemma (Convergence)
If started from an arbitrary state, and without collisions, a cache coherent state is eventually reached
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Lemma (Convergence)
If started from an arbitrary state, and without collisions, a cache coherent state is eventually reached
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Lemma (Convergence)
If started from an arbitrary state, and without collisions, a cache coherent state is eventually reached
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Lemma (Convergence)
If started from an arbitrary state, and without collisions, a cache coherent state is eventually reached
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Lemma (Convergence)
If started from an arbitrary state, and without collisions, a cache coherent state is eventually reached
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Cached Sensornet Transform
Message Corruption
IEach neighborqofphas a Boolean variablebqvp IIfqreceivesvpcorrectly,bqvpbecomes true
IG!Abecomes
for all neighborsqofp,bpvqandG! A; for all neighborsqofp,bpvqbecomes false
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
IIfqreceivesvpcorrectly,bqvpbecomes true
IG!Abecomes
for all neighborsqofp,bpvqandG! A; for all neighborsqofp,bpvqbecomes false
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
IIfqreceivesvpcorrectly,bqvpbecomes true
IG!Abecomes
for all neighborsqofp,bpvqandG! A; for all neighborsqofp,bpvqbecomes false
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
IIfqreceivesvpcorrectly,bqvpbecomes true
IG!Abecomes
for all neighborsqofp,bpvqandG! A; for all neighborsqofp,bpvqbecomes false
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
IIfqreceivesvpcorrectly,bqvpbecomes true
IG!Abecomes
for all neighborsqofp,bpvqandG! A; for all neighborsqofp,bpvqbecomes false
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
IIfqreceivesvpcorrectly,bqvpbecomes true
IG!Abecomes
for all neighborsqofp,bpvqandG! A; for all neighborsqofp,bpvqbecomes false
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
IIfqreceivesvpcorrectly,bqvpbecomes true
IG!Abecomes
for all neighborsqofp,bpvqandG! A; for all neighborsqofp,bpvqbecomes false
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
IIfqreceivesvpcorrectly,bqvpbecomes true
IG!Abecomes
for all neighborsqofp,bpvqandG! A; for all neighborsqofp,bpvqbecomes false
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
IIfqreceivesvpcorrectly,bqvpbecomes true
IG!Abecomes
for all neighborsqofp,bpvqandG! A; for all neighborsqofp,bpvqbecomes false
a b
c cbva
cavb
ccva
cavc
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Cached Sensornet Transform
Periodic Retransmit Message Corruption Lemma (Self-stabilization)
If started from an arbitrary state, the self-stabilizing model is eventually simulated
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Self-stabilizing Unison
Specification
IEach nodephas a clock variablevp IFor every neighborspandq,|vp-vq|61
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Self-stabilizing Unison
Specification
IEach nodephas a clock variablevp IFor every neighborspandq,|vp-vq|61
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 2 0 8 1 1
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 2 0 8 2 1
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 2 1 8 2 1
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 2 2 8 2 1
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 2 2 8 2 2
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 2 2 8 2 3
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 3 3 8 3 3
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 4 4 8 4 4
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 5 5 8 5 5
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 6 6 8 6 6
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
7 7 6 8 7 7
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
8 7 6 8 8 8
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
8 7 7 8 9 8
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
Self-stabilizing Unison
Ifor every neighborq,vq>vp!vp:=vp+1
non activatable activatable legitimate
8 8 7 8 9 9
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Unison with Collisions
Specification
IEach nodephas a clock variablevp IFor every neighborspandq,|vp-vq|61
Self-stabilizing Unison
with Collisions
Ifor every neighborq,vq>vp!vp:=vp+1
Ifor every neighborq,cpvq>vp!vp:=vp+1
IOnly correctly received messages update cached variables
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Unison with Collisions
Specification
IEach nodephas a clock variablevp IFor every neighborspandq,|vp-vq|61
Self-stabilizing Unison
with CollisionsIfor every neighborq,cpvq>vp!vp:=vp+1
IOnly correctly received messages update cached variables
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Unison with Collisions
Specification
IEach nodephas a clock variablevp IFor every neighborspandq,|vp-vq|61
Self-stabilizing Unison
with CollisionsIfor every neighborq,cpvq>vp!vp:=vp+1
IOnly correctly received messages update cached variables
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
non activatable activatable legitimate lower than value strictly greater
2 2
1 4
1 2
0
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
non activatable activatable legitimate lower than value strictly greater
2 3
2 4
1 2
0
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
non activatable activatable legitimate lower than value strictly greater
2 4
3 4
1 2
0
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
non activatable activatable legitimate lower than value strictly greater
2 4
3 2
1 2
0
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
non activatable activatable legitimate lower than value strictly greater
2 4
3 2
4 2
0
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
non activatable activatable legitimate lower than value strictly greater
2 4
3 2
4 2
0
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
non activatable activatable legitimate lower than value strictly greater
2 4
3 2
4 2
3
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
non activatable activatable legitimate lower than value strictly greater
3 4
3 3
4 3
3
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Example
non activatable activatable legitimate lower than value strictly greater
4 4
3 4
4 4
3
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Unison with Collisions
Cache coherence weakening
IFor every neighborspandq,cpvq6vq
Self-stabilizing Unison with collisions
IUnison and Weak cache coherence are preserved by program executions
IUnison and Weak cache coherence eventually hold
ISome extra work is expected to get bounded clock values
Sensor Networks and Self-stabilization TDMA Clustering Conclusion
Self-stabilization in Sensor Networks
Transform (i.e. Simulate) the self-stabilizing model into the sensor networks model
I[Herman 03]Cached Sensornet Transform
IOverhead is not upper bounded
Design self-stabilizing algorithms for the sensor networks model
I[Herman 03]Unison with collisions
IProof in the model is specific to the problem