WSN Data Aggregation Tree Animation

Trace leaf readings as cluster heads combine them before forwarding summaries to the sink.

animation
wsn
data-aggregation
convergecast
architecture
interactive
Interactive WSN data aggregation tree lab showing convergecast packet flow, cluster-head aggregation, sink-bound traffic reduction, completeness, latency, energy estimates, formulas, and trade-off caveats.
WSN Convergecast Aggregation Tree

WSN data aggregation tree

Watch sensor readings move up a collection tree, combine at cluster heads, and arrive at the sink as compact summaries. The live counters separate unavoidable leaf reporting from the sink-bound traffic that aggregation can reduce.

Sink-bound bytes 0% saved
Tree transmissions 0 saved
Completeness 100%
Current result AVG ready

Collection tree

Leaf sensors report locally; cluster heads forward one summary per group.

Stage 1 of 5
Wireless sensor network aggregation tree Sensor nodes at the lower part of the field send packets to cluster heads, then cluster heads forward aggregate packets to the sink node.
Deploy readings

Each sensor has a reading, a packet size, and a nearest cluster head. Step through the round to see where aggregation changes the traffic.

Forward every reading0 B
Aggregate at cluster heads0 B
1 Sense

Leaf nodes produce readings and choose a nearby cluster head.

2 Collect

Raw packets move over short links toward their cluster head.

3 Aggregate

Each cluster head computes the selected summary function.

4 Forward

Cluster heads send summary packets upstream to the sink.

5 Compare

The sink receives fewer packets, but latency and information loss must be checked.

Core idea

Aggregation is useful when many nearby sensors measure related phenomena and the sink needs a summary rather than every individual reading.

Traffic boundary

Leaf-to-cluster reporting still happens. The big reduction is in packets and bytes forwarded beyond the aggregation point.

Function choice

AVG is good for trends, MAX is safer for alarms, SUM fits totals, COUNT fits events, and RAW preserves detail when summaries are unsafe.

Design tradeoff

Waiting improves completeness, but increases latency. Packet loss and poorly chosen functions can make a compact summary misleading.

Technical accuracy notes

This lab models one collection round on a tree with one-hop sensor-to-cluster links and one-hop cluster-to-sink links. It compares a tree that forwards every received reading upstream against the same tree after cluster-head aggregation.

The model does not claim that aggregation removes all sensor transmissions. Sensors still send to their parent. The savings shown here apply to upstream forwarding after readings are combined.
Energy estimates use a simple byte-count radio model. Real WSN radio energy also depends on distance, transmit power, retransmissions, listening time, MAC overhead, sleep scheduling, and link quality.
Formulas and units
  • received_readings = count(packet_delivered_from_sensor_i)
  • clusters_with_data = count(cluster_j where received_readings_j is not zero)
  • sink_packets_without_aggregation = received_readings
  • sink_packets_with_aggregation = clusters_with_data
  • sink_bytes_without_aggregation = received_readings x reading_bytes
  • sink_bytes_with_aggregation = clusters_with_data x summary_bytes
  • sink_byte_savings_percent = (1 - sink_bytes_with_aggregation / sink_bytes_without_aggregation) x 100
  • tree_tx_without_aggregation = sensor_count + received_readings
  • tree_tx_with_aggregation = sensor_count + sink_packets_with_aggregation
  • tree_tx_savings_percent = (1 - tree_tx_with_aggregation / tree_tx_without_aggregation) x 100
  • daily_sink_bytes = sink_bytes_with_aggregation x samples_per_hour x 24
  • tree_radio_energy_uJ = tree_bytes_with_aggregation x 8 x energy_per_bit_nJ / 1000
  • completeness_percent = received_readings / sensor_count x 100
  • round_latency_ms = aggregation_wait_ms + upstream_airtime_ms
Aggregation function guide
  • AVG: Smooths spatial noise for slow environmental monitoring, but can hide one dangerous outlier.
  • MAX: Preserves the largest reading, so it is safer for fire, gas, vibration, and threshold alarms.
  • MIN: Preserves the smallest reading, useful for water tanks, battery reserves, and lowest pressure checks.
  • SUM: Preserves totals, such as rainfall accumulation, vehicle counts, power use, or event totals.
  • COUNT: Counts active detections or responsive nodes, useful for occupancy and density estimates.
  • RAW: Gives little or no compression, but keeps individual readings for debugging, regulation, or forensic review.
Design pitfalls
  • Do not use AVG for rare-event alarms when a single extreme reading must trigger action.
  • Do not report only a summary if the application must preserve identity, timestamp, or per-node evidence.
  • Do not ignore cluster-head energy burden. Aggregators receive, compute, and forward more than ordinary leaf nodes.
  • Do not wait forever for missing readings. Use timeouts and report completeness with the aggregate.
  • Do not treat byte savings as full battery savings without checking radio listening, retransmissions, and sleep duty cycle.
Practice prompts
  1. Set packet delivery to 80%. Which functions are most sensitive to missing readings?
  2. Switch Fire watch from MAX to AVG. What happens to the alarm signal?
  3. Increase cluster heads from 2 to 6. Why do sink bytes rise even though each cluster is smaller?
  4. Set RAW mode. Why might a system accept the higher traffic cost?
  5. Increase summary bytes. At what point does aggregation stop helping sink-bound byte volume?
Related resources