Title: Corso di Reti mobili Reti ad hoc
1Corso di Reti mobili Reti ad hoc Reti di
Sensori
2Sensor Networks the network
- Ad Hoc Networks specialized for environmental
monitoring - Traditional approaches
- Manual deployment (small number of sensors)
- Fixed topology
- Sensed data gathered to a sink node
- Sinks issue requests/commands and receive
(preprocessed) sensed data - Sinks provide the user with an interface to the
network - Current trend
- Large number of sensors
- Connected as in a multihop ad hoc network
- High network density
- Autonomous when the sinks are disconnected
3Sensor Networks the network
User
Internet, Satellite Network, etc..
Sink
4Sensor Networks the sensors
- Each sensor
- Low power, low cost system
- Small
- Autonomous
- Sensors equipped with
- Processor
- Memory
- Radio Transceiver
- Sensing devices
- Acceleration, pressure, humidity, light,
acoustic, temperature, GPS, magnetic, - Battery, solar cells,
5Sensor Networks
- Differences with Ad Hoc Networks
- Number of sensor nodes can be several orders of
magnitude higher - Sensor nodes are strongly constrained in power,
computational capacities, and memory - Sensor network are denser and sensors are prone
to failures - The topology of a sensor network changes very
frequently due node failures (and mobility?) - Sensors may not have individual IDs
- Need tight integration with sensing tasks
6Sensor Networks
- Sensors are deployed in the Sensing Field
- Each sensors samples environmental parameters
- Produces a streams of data
- data stream can be pre-processed locally and then
forwarded to a sink - The sinks might be temporarily unavailable
- The network operates autonomously
- Pre-process and store sensed data
- Sensors may implement a database
7Sensor Networks Applications
- Environmental
- Tracking animals,
- Pollution control,
- Disaster recovery
- Monitor disaster areas,
- Fire/flooding detection,
- Meteorological research
- Security
- Nuclear, Biological and Chemical (NBC) attack
detection - Monitoring battlefield,
- Surveillance,
8Sensor Networks Applications
- Health
- Diagnostics
- Monitoring of physiological data,
- Support for disabled,
- Commercial
- Inventory management,
- Vehicle tracking,
- Toys,
- Domotics,
-
- Space exploration
9Sensor Networks
- Sensor networks issues
- Communication is expensive
- Routing is programmed by the sink node
- Programming is focused to specific applications
- Current research
- Point to point geographic routing
- Distributed Data Centric Storage
- Development of general purpose DBMS
- Desiderata
- Guaranteed storage/communication
- Security
- Mobility?
10Sensor Networks Motes
- Distributed by Crossbow INC. (http//www.xbow.com)
- Standard packages
- 8 processing/radio units
- 8 sensing units
- 1 serial programmer
- Operating System (tinyOS)
- Programming environment (nesC)
11Motes processing / radio
- CPU ATMEL 128L (8 bit, 8Mhz)
- Program memory 128 Kb
- Data memory 4 Kb 512 Kb (?)
- Radio 433 Mhz
12Motes sensing units
- MTS 300 CA
- Light
- Temperature
- Acoustic
- Sounder
- MTS 510 CA
- Light
- Accelerometer
- Acoustic
13Motes base station
- MIB 510 CA
- Serial interface
- Able to host MICA boards
- Externally powered
14Motes Software
- tinyOS
- Developed at UC Berkeley
- Event scheduler minimal C runtime
- Size lt 1 Kb
- Open Source (BSD Licence)
- Many modules (e.g. MAC layers, etc) freely
available - nesC
- Event driven language
- Components
- Commands (exported interface)
- Events (imported interface)
- Component-level concurrency
- Compiler for MOTES or emulator
- TinyOS NesC Tutorial
- http//www.tinyos.net/tinyos-1.x/doc/tutorial/
15Motes Software
- A simple nesC application
- BLINK
- Toggles the red led every second
- module BlinkM
-  provides    interface StdControlÂ
-  uses    interface Timer   interface
LedsÂ
implementation  command result_t
StdControl.init() Â Â Â call Leds.init()Â Â Â
return SUCCESSÂ Â command result_t
StdControl.start() Â Â Â return call
Timer.start(TIMER_REPEAT, 1000) Â Â command
result_t StdControl.stop() Â Â Â return call
Timer.stop()Â Â event result_t
Timer.fired()Â Â Â Â call Leds.redToggle()Â Â Â
return SUCCESSÂ
16Motes Software
- configuration Blink implementation Â
components Main, BlinkM, SingleTimer, LedsCÂ
Main.StdControl -gt BlinkM.StdControlÂ
Main.StdControl -gt SingleTimer.StdControlÂ
BlinkM.Timer -gt SingleTimer.Timer BlinkM.Leds
-gt LedsC.Leds -
17Sensor Networks Network Layer
- Important considerations
- Sensor networks are mostly data centric
- Attribute-based addressing and location awareness
- Data aggregation can be useful but it might
prevent collaborative effort - Energy efficiency is a key factor
- Traditional routing protocols are not practical
- Large routing tables
- Size of packet headers
- Node IDs are less meaningful than their
capabilities - From identity-based to data-driven routing
18Protocols for Sensor Networks
- Drawbacks of flooding-based data dissemination
- The implosion problem
- node A starts by flooding its data to all of its
neighbors. - Two copies of the data eventually arrive at node
D. - The system wastes resources in one unnecessary
send and receive.
- The overlap problem
- Two sensors cover an overlapping geographic
region. - The sensors flood their data
- Node C receives two copies of the data marked r.
- Resource blindness
- Sensors are not resource-aware they do not
adapt their activities based on their energy
19Protocols for Sensor Networks
4
2
7
6
3
5
8
6
6
9
8
4
7
8
9
2
Sink
Temperature lt 5
20Protocols for Sensor Networks
Area B
Area A
4
Area C
2
7
6
3
5
8
6
6
9
8
4
7
8
9
2
Sink
Temperature of the sensors in area C
21Sensor Protocol for Information via Negotiation
22SPIN
- Heinzelman et Al., MobiCom 99
- Negotiation
- Resource-adaptation
- Negotiation
- ensures that only useful information will be
transferred. - use of meta-data to describe data
- Resource adaptation
- Each sensor has a resource manager that monitors
energy consumption - Applications probe the resource manager before
transmitting/processing data
23SPIN
- SPIN Messages
- ADV When a sensor node has a new data, it
broadcasts (to its neighbors) an advertisement
(ADV) packet that describes the new data by using
meta data - REQ used by interested nodes to subscribe data
advertised with ADV - DATA to send the data to its subscribers
- Resource manager
- If the residual energy of a sensor is below a
given bound, the sensor does not partecipate to
the ADV-REQ-DATA protocol. - However, it will spend energy to receive the ADV
messages
ADV
REQ
Data
24SPIN
- Example of data propagation with SPIN
25SPIN
- Simulations SPIN VS
- Flooding
- Gossiping
- Nodes forward data to a random subset of
neighbors - Ideal
- With perfect knowledge of the network topology
and shortest paths - Simulation parameters
- 25 nodes
- Each node with 3 data items of 500 bytes each
- Each data item has a distinct name
26SPIN simulations
- Percent of total data acquired in the system over
time for each protocol (SPIN, Flooding,
gossiping, and ideal)
27SPIN simulations
- Total amount of energy dissipated in the system
for each protocol (SPIN, Flooding, gossiping, and
ideal)
28SPIN
- Drawbacks
- Energy management
- Nodes cannot turn off the radio to save energy
- Need for synchronization
- The same data travels along multiple paths
- Wastage of energy
- Assumes that all the sampled data should be
delivered to the sink - No mechanisms to let the sink request for
specific data - No local processing of sensed data
29Directed Diffusion
30Directed Diffusion
- Intanagonwiwat et Al., MobiCom 2OOO
- Coordination protocol to perform distributed
sensing of environmental phenomena - The sensor network is programmed to respond to
queries such as - "How many pedestrians do you observe in the
geographical region X - "Tell me in what direction that vehicle in region
Y is moving" - Directed diffusion is datacentric
- all communication is for named data
- Data generated by sensors is named by
attribute-value pairs. - A node requests data by sending interests for
named data.
31Directed Diffusion
- Basic elements of Directed Diffusion
- Data is named using attribute-value pairs.
- A sensing task is disseminated in the network as
an interest for named data. - The dissemination of interests sets up gradients
- gradients "draw" events (i.e., data matching the
interest). - Data matching the interest flow towards the sink
of interest along multiple paths. - The sink reinforces one, or a small number of
these paths.
32Directed Diffusion
- Interests are named by a sequence of
attribute-value pairs that describe the task. - Example of a simple animal tracking task
- type four-legged animal // detect animal
location - interval 20 ms // send back events every 20
ms - duration 10 seconds // .. for the next 10
seconds - rect -100, 100, 200, 400 // from sensors
within rectangle - Coordinate may refer to a GPS-based coordinate
system - The data sent in response to the interest is also
named using a similar naming scheme. - Example
- type four-legged animal // type of animal
seen - instance elephant // instance of this type
- location 125, 220 // node location
- intensity 0.6 // signal amplitude measure
- confidence 0.85 // confidence in the match
- timestamp 012040 // event generation time
33Directed Diffusion
- Interests are periodically generated by the sink
- The first broadcast is exploratory
- The next broadcasts are refreshes of the interest
- Necessary because dissemination of interests is
not reliable - Nodes receiving an interest may forward the
interest to a subset of neighbors - nodes must be assigned with a unique ID
- Directed diffusion works also in presence of
multiple sinks
34Directed Diffusion
- Nodes cache received interests
- Different interests with same time interval,
area, and type (but, for example, different
sampling rate) are aggregated - Interests in the cache expire when the duration
time is elapsed - Each interest in the cache is associated with a
gradient, i.e. the node from which it was
received - Gradients might be associated with different
sampling rate - Note that the same interest may be received from
different nodes
Interest propagation
Gradients set up
4
1
5
sink
2
3
6
35Directed Diffusion
- A gradient is a direction and a data rate
- Gradients are used to route data matching the
interest toward the sink whom originated the
interest - A data may be routed along multiple paths
- Data is routed along a single path if a preferred
gradient is used - Examples of data propagation
4
1
5
sink
2
3
6
36Directed Diffusion
- A sensor node which detects an event matching
with an interest in the cache - Start sampling the event at the largest sampling
rate of the corresponding gradients - The node sends sampled data to neighbors
interested in the event - This information is stored in the gradients
associated to the interest in the cache - If a gradient g has a lower rate then the others,
data along g is sent with lower rate - Neighbors forward the data only if a
corresponding interest (with a gradient) is still
in the cache - However if that data has already been sent it is
dropped
37Directed Diffusion
- Reinforcements
- Used when the sink start receiving data matching
an exploratory interest from node u - The sink reinforces node u to improve the quality
of received data - Exploratory interests use a low sampling rate
- Reinforces of interests specify an interest with
larger sampling rate - In turn, a node receiving a reinforce of an
interest reinforces one of its neighbors - Reinforces are propagated through the path along
which the data flows
38Directed Diffusion
- Drawbacks
- Assumes that the sink is permanently connected to
the network - the network does not operate autonomously
- Sensors do not process data (apart aggregation)
- The sensors just send the data matching the
interests to the sink - Does not exploit processing and storage
capabilities of the sensors - Flexible network design needs flexible routing
39Greedy Perimeter Stateless Routing(GPRS)
40Routing with GPS GPSR
- Karp Kung, MOBICOM 2OOO
- Assumptions
- The nodes are deployed on a two-dimensional space
- Nodes are aware of their position and of the
position of their neighbors - For example the nodes are equipped with GPS
- The source knows the coordinate of the
destination - Packet headers contain the destination coordinate
- The protocol is scalable
- No need for route discovery
- Few control packets
- Nodes maintain only local information
- Large route caches or routing table are not
necessary - Packet headers do not need to store routes
41GPSR
- GPRS comprises two modes
- Greedy forwarding
- Perimeter forwarding
- Greedy forwarding
- Consider a packet with destination D
- the forwarding node x select as next hop a
neighbor y such that - y is closer to D than x
- Among neighbors y is the closest to the
destination - Greedy forwarding fails if the packet encounters
a void
42GPSR
w
u
void
x
D
v
z
43GPSR
- Perimeter mode forwarding is executed when greedy
forwarding finds a void - Routes around the void
- Based on the right hand rule
- When arriving from y to x
- Selects as next edge the one sequentially
counterclockwise about x from edge (x,y) - Traverses the interior of a closed polygonal
region (face) in clockwise edge order - Intuitively it explores the polygon enclosing the
void to route around the void - In the previous example it would produce x w
u D
z
2
x
3
1
y
44GPSR
- However, graph G corresponding to the sensor
network is a non-planar embedding of a graph - Edges may cross
- the right hand rule may take a degenerate tour of
edges that does not trace the boundary of a
closed polygon - In the example, from x to v the right hand rule
produces the path - x v w u x
w
v
u
z
x
45GPSR graph planarization
- For this reason GPRS applies the perimeter mode
to a planar graph P obtained from G - Relative Neighborhood Graph of G
- Gabriel Graph of G
- Properties
- If G is connected then P is connected
- P is obtained from G by removing edges
- P is computed with a distributed algorithm
executed along with the perimeter mode packet
forwarding
46GPSR graph planarization
- Relative Neighborhood Graph (P) of G
- Edge (u,v)?P iff
- (u,v)?G
- d(u,v) ? Max(d(u,w),d(v,w)) for each w?N(u)?N(v)
- Consider the forwarding node u
- u considers each neighbor v?N(u)
- edge (u,v) is kept iff the above property is
satisfied
w
u
v
This area must be empty in order to include (u,v)
in P
47GPSR graph planarization
- Gabriel Graph (P) of G
- Edge (u,v)?P iff
- (u,v)?G
- d2(u,v) ? d2(u,w)d2 (v,w) for each w?N(u)?N(v)
- GG constructed with a distributed algorithm as
RNG - RNG is a subgraph of GG
- RNG has smaller link density
- RNG or GG are both suitable to GPRS
w
u
v
This area must be empty in order to include (u,v)
in P
48GPSR graph planarization
Full graph, Gabriel Graph and Relative
Neighborhood Graph
49GPSR perimeter mode
- Packet header in perimeter mode
- Let x be the node where the packet enters in
perimeter mode - Consider the line x-D
- GPSR forwards the packet on progressively closer
faces on the planar graph, each of which
intersects x-D
Field Function
D Destination Location
x Location where packet entered in perimeter mode
Lf Point on x-D where the packet entered current face
eo First edge traversed on current face
M Packet mode greedy or perimeter
50GPSR perimeter mode
- A planar graph has two types of faces
- Interior faces
- Closed polygonal regions bounded by the graph
edges - One exterior face
- The unbounded face outside the outer boundary of
the graph - On each face GPRS uses the right hand rule to
reach an edge which crosses x-D (and that is
closer to D than x) - At that edge GPRS moves to the adjacent face
crossed by x-D - Each time it enters a new face the packet
records - In Lf the point on the intersection between x-D
and the current edge - In eo the current edge
- GPRS returns to greedy mode if the current node
is closer to D than x - Perimeter mode is intended to recover from a
local maximum
51GPSR perimeter mode
Greedy mode
D
Perimeter mode
x-D
Lf
F2
F1
x
52GPSR perimeter mode
- If D is reachable from x (G is connected) then
GPRS always finds a route - if D is not reachable
- Either D lies inside an interior face Fi
- Or D lies in the exterior face Fe
- The packet will reach the face (either Fi or Fe)
- Then it will tour around the face until it
travels the edge eo for the second time - At that point the packet is discharged
53GPSR
- GPRS and mobility
- GPRS relies on updated information about the
position of the neighbors - It need a freshly planarized graph
- Using stale planarized graph may result in
performance degradation - Performing planarization at topology changes is
not sufficient - Nodes may move within a nodes transmission range
- Proactive approach nodes periodically (at each
beacon interval) communicate their position their
neighbors - This information is used to keep updated the list
of neighbors and to force planarization
54GPSR - simulation
- Decreasing the beaconing time the delivery rate
of GPRS - Routing overhead (beacon packets) is independent
of mobility - Beacons are proactive
Delivery rate
Routing overhead
55GPSR - simulation
- Path length nearly optimal if the network is
dense - 95 of packet delivered through the shortest path
VS 85 of DSR - Difference due to the caching of DSR, some paths
in the cache may be no longer optimal - Intuitively greedy routing approximates shortest
paths
56Data-Centric Storage (DCS) and Geographic Hash
Tables (GHT)
57DCS GHT
- Ratnasamy et Al., MONET 2003
- Focus
- The sensor network can operate in an unattended
mode - Samples and Records information about the
environment - Need for
- Data-dissemination techniques to extract data
- Data-centric storage
- Based on
- Geographic routing protocols
- Peer-to-peer lookup systems
58DCS GHT
- Data-centric storage
- Events are named (keys) and corresponding data
are stored by names in the network - Queries are directed to the node that stores
events of that key - Two operations supported by DCS
- Put(k,v) stores the observed data according to
its key k - Get(k,v) retrieves whatever value associated to
key k
59DCS GHT
- Design criteria of a DCS
- Node failures battery exhaustion, HW failures,
- Topology changes due to node mobility, failures,
- Scalability number of nodes, network density
- Energy constraints
- Persistence a stored pair (k,v) must remain
available despite failures and topology changes - Consistency a query for key k must reach the
node where pairs (k,v) are actually stored - Scaling in database size storage should not
overburden a node as the number of pairs (k,v)
increase
60DCS GHT
- Geographic hash table
- Hash(k) returns a pair of coordinates (x,y)
- (x,y) should be included in the network boundary,
it is assumed this information is known to each
node - (k,v) is stored by the node u which is the
closest to coordinates (x,y) - Queries related to key k are routed to (x,y)
- GHT built on top of the GPRS routing protocol
- Mobility or failure of u may result in
unavailability of stored value v - GHT uses a Perimeter Refresh Protocol (PRP) to
provide persistence and consistency - PRP selects one node as home node for key k
- PRP replicates v on the nodes in the perimeter
around (x,y)
61DCS GHT
source
Home Node
v
Produces value v with key k Hash(k) (x,y)
Home Perimeter
u
w
z
(x,y)
q
s
62DCS GHT
- Perimeter Refresh Protocol (PRP)
- Accomplish replication of key-value pairs
- GHT routes the packet (k,v) around the perimeter
enclosing (x,y) - Where (x,y)Hash(k)
- The perimeter is identified by GPSR
- (k,v) is stored in the home node
- Each node in the home perimeter stores a replica
- Nodes on the home perimeter are said replica
nodes
63DCS GHT
- Perimeter Refresh Protocol (PRP)
- The home node u of key k generates periodical
refresh packets which - Is sent to coordinate (x,y)Hash(k)
- Note that the home node might have moved
- Contains (k,v)
- Tours around the perimeter around (x,y)
- The refresh packets preserve consistency the
home node should be the closest to (x,y)
64DCS GHT
- Perimeter Refresh Protocol (PRP)
- If the refresh packet reaches a node v closer to
(x,y) than the old home node u - v generates a new refresh packet towards (x,y)
- It is egligible as a new home node for k
- Else v forwards the packet towards (x,y)
- When the refresh packet reaches its source v
- v becomes the home node for k
- Sets up a refresh timer for k
- Replicate (k,v) in the new perimeter
65DCS GHT
- Perimeter Refresh Protocol (PRP)
- However the home node may fail
- Need to enforce persistence
- Hence each replica node sets up a takeover timer
- The timer is reset when a refresh packet is
receved - When the timer expires the replica node generates
a refresh packet for (k,v) towards (x,y)
66DCS GHT
- Perimeter Refresh Protocol (PRP)
- Pairs (k,v) are not cached forever
- If a home (replica) node moves it might not be
associated to key k anymore - Discharging (k,v) should not affect availability
- Home and replica nodes use death timers
- Each pair expires after a death timeout
- The death timeout should be larger than the
refresh and takeover timeouts
67DCS GHT
- Perimeter Refresh Protocol (PRP)
v (replica)
r (replica)
u (home)
w (replica)
(x,y)
s (replica)
After takeover time w generates a refresh
q (home)
z (replica)
q becomes the new home node
68DCS GHT
- A home node for key k might be overburdened if
too many values with key k are produced - Structured replication (SR)
- uses a hierarchy (of depth d) of event names
- Hash(k) is the root of the hierarchy
- To each key k are associated a root and 4d-1
mirrors - A node stores the pair (k,v) to its closest
mirror of Hash(k) - Retrieval of a value involves queries to the root
and all mirrors - Trades storage overhead with communication
69DCS GHT
- An example of Structured Replication with d2
(0,100)
(100,100)
Root (3,3)
Level 1 Mirrors
Level 2 Mirrors
(0,0)
(100,0)
70DCS GHT
- Data Centric Storage based on Geographic Hash
Table - nodes should be aware of their coordinates
- Nodes should know the network boundary
- Built on top of GPRS
- Perimeter Refresh Protocol to enforce persistence
and consistency - Structured Replication to enforce scaling in
database size
71Physical and virtual Coordinates
72Geographic Routing and Localization
- Traditional routing protocols for ad hoc networks
are not practical - Large routing tables or path caches
- Size of packet headers
- Geographic routing appears to be the best option
- Coordinates are mandatory
- To support geographic routing
- Support the implementation of a data centric
storage (DCS with GHT) - Provide a relation between sensed data and
locations
73Sensor Coordinates
- Coordinates can be obtained by equipping nodes
with GPS - Additional cost
- Not always feasible (for example indoor)
- When no GPS system is available
- Either a few anchor nodes know their position
- other nodes compute coordinates with a variety of
methods - Or virtual coordinates are used
- typically they are hop-distances dependent
74Sensor Coordinates without GPS
- Approximate physical coordinates of the sensors
- A few nodes (anchors) know their exact position
- by means of special hardware (GPS)
- or because they are manually positioned in well
known locations - The anchors broadcast beacons
- The other nodes estimate their positions with
distributed protocols - Nodes may estimate their distance from the
anchors - Time of arrival techniques
- Signal strength
- Or they may estimate their position based on
triangulation - angle of arrival
75Range and Range-Free techniques
- Two basic techniques
- Using special Ranging hardware (e.g. signal
strength, T.O.A., etc). - Range Free Technique.
- Cost-Effective No special hardware for
ranging. - Topology based (Hop counting) techniques.
76Range techniques
- Drawbacks
- Need special antennas to estimate angle of
arrival - Signal strength or time of arrival techniques may
be affected by external perturbations - Interferences
- Humuidity
-
- Evaluation of the coordinate system accuracy
77Range-Free Techniques
- Virtual coordinates
- Unrelated to the physical coordinates of the
sensors - Typically based on hop distances
- Can support efficiently geographical routing
- With sparse networks might be better than
physical coordinates - Correspondence between virtual and physical
coordinates left to the sink node
78Sensor Coordinates without GPS
- Geographic routing without location information
(Rao et al.) MOBICOM 2003 - Investigates three cases
- Perimeter nodes are know they know their
location - Perimeter nodes know they are on the perimeter
but they dont know their location - Nodes know neither their location, nor whether
they are on the perimeter - For each case they give a protocol which assign
virtual coordinates
79Sensor Coordinates without GPS
- Perimeter nodes are known they know their
location - Given node i let
- Ni be the set of its neighbors
- xi its x-coordinate
- yi its y-coordinate
- Initially each node (except perimeter node) is
assigned coordinate (100,100) - Node i approximates its virtual coordinates
iteratively - xiSUM(xk k? Ni) / Ni
- yiSUM(yk k? Ni) / Ni
- The iteration is repeated d times
80Sensor Coordinates without GPS
- Perimeter nodes are known they know their
location - After d iterations evaluate
- success rate of greedy routing over the virtual
coordinates - Average path length
- Initial position of nodes
- After 10 iterations
- After 100 iterations
- After 1000 iterations
81Sensor Coordinates without GPS
- Perimeter nodes are known they know their
location - Simulation with d1000 (and 16 neighbors per
node) - Virtual coordinates
- Greedy routing success rate 99,3
- Average path length 17.1
- Physical coordinates
- Greedy routing success rate 98,9
- Average path length 16,8
- It is not necessary that all perimeter nodes
participate to the protocol - If only 8 perimeter nodes participate
- Greedy routing success rate 98,1
- Average path length 17.3
82Sensor Coordinates without GPS
- Only perimeter nodes are known
- Each perimeter node broadcasts an HELLO message
to the entire network - Each perimeter nodes knows its hop distance with
the other perimeter nodes - This vector distance is the perimeter vector
- Each perimeter node broadcasts its perimeter
vector to the entire network - Each perimeter node knows the hop distance
between any pair of perimeter nodes
83Sensor Coordinates without GPS
- Only perimeter nodes are known
- Each perimeter node computes a triangulation to
compute the virtual coordinates of the other
perimeter nodes - Such as to minimize
- SUM i,j in the perimeter (hop-dist(i,j)
dist(i,j))2 - Where dist(i,j) is the euclidean distance over
the assigned coordinates - Then the previous protocol is applied
- However the nodes can be assigned initial
coordinates taking into consideration the
information available from the previous steps
84Sensor Coordinates without GPS
- Only perimeter nodes are known
- With d10 (and 16 neighbors per node) achieve
same performance than previous protocol with
d1000 - Greedy routing success rate 99,2
- Average path length 17.2
- Due to a better initialization of non-perimeter
nodes
85Sensor Coordinates without GPS
- No Location Information
- Add a preliminary phase
- Two bootstrap nodes broadcast a beacon
- The nodes that, within two hops, are the farthest
from the bootstrap nodes are classified perimeter
node - Applies the same protocol as before
- With d10
- Greedy routing success rate 99,6
- Average path length 17.3
Example of virtual coordinates
86Sensor Coordinates without GPS
Success rate of greedy routing with virtual and
physical coordinates
87Sensor Coordinates without GPS
- The protocols are resilient to message losses
- Due to redundancy of information in the perimeter
vectors - The virtual coordinates can be mapped onto a
circle - Gives well defined area for implementing a
distributed hash table
88The Virtual Coordinate Assignment protocol
89Virtual Coordinate System
- A virtual coordinate system is defined by
electing three anchor nodes (X,Y,Z). - Each coordinate is a triplet (x,y,z), x is the
minimum hop distance between the node and the X
anchor. - The coordinates are virtual because they are not
related to the physical position of a node
(Euclidean coordinates). - Different nodes may have the same coordinates.
90Virtual Coordinate System
Y
(x,y,z)
Z
X
91Why three anchor?
Virtual Coordinate System
- A zone is a set of nodes sharing the same triplet
of coordinates - With less than three anchors a zone might be
split into two distinct regions.
92The zones
Virtual Coordinate System
- With the virtual coordinate system, the routing
protocol exploits geographic routing to reach the
destinations zone and proactive routing within
the zone. - Hence, in order to efficiently support routing,
the size of a zone must be small. - The size of the zones depends on the position of
the anchors and on the network density - We show that the zones are minimized if the
anchors are as far as possible from each other - The anchors must be close to the network border
93Virtual Coordinate Assignment Protocol
Virtual Coordinate System
- The sink node begins the VCap protocol
- It broadcasts a W_SET message containing an hop
counter to identify nodes on the network border - Nodes in the network use the hop counter in the
W_SET message to determine their hop distance
from the sink - Anchor X is elected by a broadcast-based
distributed protocol - Nodes with maximum hop distance from the sink (in
their local neighborhood) are eligible as X.
94Virtual Coordinate Assignment Protocol
Virtual Coordinate System
- The election of anchor X
- Among the nodes with maximum hop distance from
the sink, it is elected as X the node with
maximum ID. - The election of anchors Y and Z exploit a similar
protocol - Heuristics enforcing the property that X, Y and Z
are as far as possible from each other are used. - Example Z should be on the border and
equidistant from X and Y
95Virtual Coordinate Assignment Protocol
Virtual Coordinate System
- Feasible positions for anchor Z
96Hop Distance V.S. Euclidean distance
Virtual Coordinate System
- A node coordinate express the minimum hop
distance between the node and an anchor - Let ? be the network density, and r the
transmission range. - Let h and D be the minimum hop distance and
Euclidean distance between two nodes,
respectively. - Let l(h), u(h) such that l(h) D u(h).
- Assumption
97Bound to the size of a Zone
Virtual Coordinate System
- Feasible locations for an anchor, given two nodes
(a and b) in the same zone at distance d
r
a
b
a
d
b
d
a
a
d
b
b
98Bound to the size of a Zone
Virtual Coordinate System
- In a circular sensor network of diameter R, where
the anchors are placed on the vertexes of an
equilateral triangle inscribed in R. - The maximum distance d between nodes in the same
zone satisfy
99Simulative analysis of the zone size
- Maximum distance d between nodes in the same
zone in circular networks with R1 and r 0.05. - The figure plots the minimum, average and maximum
of dN in units of r with densities in the range
of 10 to 70. (min(dN)/r, E(dN)/r, max(dN)/r).
For low density the nodes of a zone are
dispersed. As density increases, d approaches
8/3r.
100VCAP Overhead
- Memory Overhead
- Each node stores only the values of the x,y, and
z coordinates. - Communication Overhead
- Step 1 (W_SET) is a simple network broadcast.
- Steps 2,3 and 4 (election of X,Y,Z) are also
based on broadcast. - The overhead of each step can be reduced trading
communication with latency. - A pragmatic approach exploits random delays of
the messages depending on the ID of the
forwarding node. - Large delays reduce the overhead but increase the
protocol latency.
101Coordinate Smoothing
- Coordinate smoothing
- Each coordinate is re-computed as the average of
the neighbors coordinate - Increases the resolution of the coordinate system
- By reducing the size of the zones
- Improves the performance of greedy routing
- Reduce the effect of errors (due to packet
losses) in the coordinate system
102Coordinate Smoothing
- Fraction of nodes which share the same coordinate
with at least another node
VCap
VCap one smoothing step
103Simulation of geographic routing over virtual
coordinates
- Simulation parameters
- Circular networks of radius R100 Transmission
Range r 8. Network Density (average neighbors
for node) ranges from 8 to 50. - Simulation of a greedy routing algorithm
- Statistics
- Degree of reachability (the possibility of
setting a source-dest path) - Average path lengths.
- Samples size of 1000.
104Effect of smoothing
Reachability with greedy geographic routing using
virtual coordinates.
105Reachability
Reachability with greedy geographic routing using
virtual (VCap), Eucledian (PHY), virtual one
smoothing step (SVC) coordinates
106Reachability
Reachability at low densities with greedy
geographic routing using virtual (VCap),
Eucledian (PHY), virtual 1 smoothing step
(SVC).
107Average path length
Average path length with greedy routing.
108Detours and greedy routing
Reachability with greedy routing and detours with
virtual coordinates and one smoothing step.
1092-hop lookup greedy routing
Reachability with 2-hop lookup greedy routing
with virtual coordinates and one smoothing step.
Circular domain with R 100, r 8
1102-hop lookup greedy routing
Average path length with 2-hop lookup greedy
routing with virtual coordinates and one
smoothing step.
111Packet overhead
Packet overhead per node (network with 300 nodes)
112Effect of packet loss
For each node, number of neighbors with at least
one coordinate error
113Simulation Outcomes
- The reachability approaches 100 as the network
density increases. - Reachability with virtual coordinates is
comparable to reachability with Euclidean
coordinates. - With very low density routing on virtual
coordinates performs better! - The average path length with virtual coordinate
is slightly larger.
114Conclusions and Future Works
- Goals achieved
- A distributed Virtual Coordinates Assignment
Protocol (VCap) for large scale sensor networks. - The resolution of VCap (the maximum diameter of a
zone) is independent of the network size. We
studied its relationship with network density. - Geographic routing over virtual coordinates has a
good degree of reachability compared to Euclidean
coordinates. Especially in dense networks. - Virtual Coordinates do not require GPS equipped
nodes. - Future Works
- Design of a geographic routing protocol with
guaranteed delivery over virtual coordinates. - Virtual coordinates with (low) mobility
115Data Management in Sensor NetworksThe MaD-WiSe
Aproach
116MaD-WiSe
- Aims
- Design a database for sensor networks
- The sensor network is programmed by high level
SQL queries - The queries are optimized and translated in a
query plan - The query plan assigns subqueries to individual
sensors - Eash sensor comprises a query processor which
executes its assigned query
117MaD-WiSe
- MaD-WiSe is implemented in NesC on TinyOS
- designed as a three layer software
- Network
- Transport (Stream System)
- Query Processor
118MaD-WiSe Network layer
- Based on the Virtual Coordinate assignment
protocol - Exploits a geographic greedy routing protocol
- Provides connection-less and connection-oriented
services - (planned) implementation of application-driven,
energy efficiency strategies
119MaD-WiSe Stream System
- Provides support to management of data streams in
the network - Streams can be
- Sensor streams (corresponding to a local
transducer) - Local streams (used to write/store processed
data) - Remote streams (used to access data
sensed/processed by remote sensors) - Implemeted over the connection-oriented services
of the network layer - Interface to the upper layers
- Open and Close streams
- Read and write from/to streams
120MaD-WiSe Query Processor
- Implements the operators of the algebra
- Such as join, select, average,
- Implemented over the Stream System