103  DTN Social Routing

In 60 Seconds

Context-aware routing (CAR) uses utility functions combining encounter probability, mobility patterns, and device resources to select optimal message carriers, reducing overhead to 200-350% while maintaining 88-93% delivery. SocialCast creates bounded replicas (gamma=5-10) that climb to higher-utility carriers over time. Social routing sacrifices ~7% delivery ratio compared to epidemic but uses 3-5x fewer resources – ideal for battery-constrained IoT with predictable mobility patterns.

Minimum Viable Understanding
  • Context-aware routing (CAR) uses utility functions combining encounter probability, mobility patterns, and resources to select the best message carriers, reducing overhead to 200-350% while maintaining 88-93% delivery
  • SocialCast creates a bounded number of message replicas (gamma=5-10) that “climb” to higher-utility carriers over time, exploiting social network structures for efficient publish-subscribe in DTN
  • The key trade-off: Social routing sacrifices ~7% delivery ratio compared to epidemic routing but uses 3-5x fewer resources, making it ideal for battery-constrained IoT devices with predictable mobility

“Instead of telling EVERYONE my message like in epidemic routing,” said Sammy the Sensor, “what if I only tell people who are LIKELY to meet the person I’m trying to reach?”

Max the Microcontroller snapped his fingers. “Like if you need to send a message to the school librarian, don’t give copies to random strangers – give it to kids who go to that school every day!”

“Exactly!” said Bella the Battery. “That’s social routing! Each person gets a ‘usefulness score.’ The kid who visits the library every day scores 0.9 out of 1.0. A random tourist scores 0.1. You only hand your message to high-scoring people!”

Lila the LED added, “And the best part is: you only make 5-10 copies instead of hundreds. Each copy finds its way to a better and better messenger until someone delivers it. It’s like your message ‘climbs’ toward the destination!”

The Squad’s math: Epidemic routing = 95% delivery but 1000% overhead (expensive!). Social routing = 88% delivery but only 200% overhead (5x cheaper!). For battery-powered sensors, that savings means years more battery life!

103.1 Learning Objectives

By the end of this chapter, you will be able to:

  • Apply Context-Aware Routing: Use utility functions based on mobility, colocation, and resources
  • Design SocialCast Protocols: Implement social network-based forwarding with bounded replication
  • Calculate Utility Functions: Combine colocation probability, mobility scores, and resource levels
  • Optimize Forwarding Decisions: Select carriers based on delivery likelihood rather than flooding
  • Evaluate Trade-offs: Balance delivery ratio, latency, and resource consumption

103.2 Prerequisites

Before diving into this chapter, you should be familiar with:

  • Social Routing: DTN routing exploiting human social patterns (community membership, centrality, contact frequency) for efficient message delivery
  • Social Centrality: Node’s position in a social network graph; highly central nodes (hubs) interact with many others and make better message carriers
  • Community Detection: Identifying groups of nodes that frequently contact each other; used in bubble routing and community-based routing
  • SimBet Routing: Combines social similarity (common contacts) and betweenness centrality to select next-hop carriers
  • Bubble Routing: Messages stay in source community until a node with higher global centrality can carry them to the destination community
  • Contact History: Past encounter records used to predict future contacts; stored in encounter tables indexed by node ID and time
  • Betweenness Centrality: Fraction of shortest paths in the social graph passing through a node; high-betweenness nodes are good message relays
  • Homophily: Tendency for people to contact socially similar others; enables community-based routing to outperform random routing

103.3 For Beginners: Social Routing

Social Routing - The Smart Strategy:

Instead of telling everyone (epidemic routing), tell people who are likely to meet the destination. Like asking “Can you deliver this message?” only to people who work near the recipient’s office.

SocialCast uses social patterns: - If Node A frequently encounters Node B, A has high “utility” for delivering to B - Forward messages only to higher-utility carriers - Bounded replication (create only 5-10 copies, not unlimited) - Result: 88% delivery with 200% overhead (vs 95% delivery with 1000% overhead in epidemic routing)

Term Simple Explanation Everyday Analogy
PRoPHET Forward to nodes with high encounter history Give message to people who often see recipient
Utility Function Score measuring delivery likelihood Probability mailman reaches your address
Context-Aware Using location, mobility, relationships for decisions Asking directions from locals, not tourists

DTN Series:

Background:

Learning:

103.4 Context-Aware Routing

⏱️ ~12 min | ⭐⭐ Intermediate | 📋 P04.C01.U03

Context-aware routing diagram showing source node evaluating three potential carriers using utility function that combines location history, mobility patterns, and social relationships to select highest-probability forwarding path to destination
Figure 103.1: Context-aware routing example using location, mobility, and social context for intelligent forwarding decisions

When node mobility is predictable or observable, smarter forwarding decisions can be made using context information.

103.4.1 Context-Aware Routing (CAR) Concept

Rather than blindly replicating packets, CAR uses utility functions to select best carriers based on:

  1. Mobility patterns: Where do nodes typically move?
  2. Colocation history: Which nodes frequently encounter destination?
  3. Social relationships: Friend networks, interest groups
  4. Resources: Battery, buffer space
Context-aware routing diagram showing source node evaluating three potential carrier nodes, each with computed utility score based on encounter probability, mobility patterns, and resources, selecting the carrier with highest utility for message forwarding
Figure 103.2: Context-aware routing utility evaluation showing source node evaluating three potential carriers with utility scores.

103.4.2 Utility Function Design

Basic Utility Function:

\[ U(X, D) = \alpha \cdot P_{colocation}(X, D) + \beta \cdot Mobility(X) + \gamma \cdot Resources(X) \]

Where: - \(U(X, D)\) = Utility of node X for delivering to destination D - \(P_{colocation}(X, D)\) = Probability X will encounter D - \(Mobility(X)\) = Mobility score (higher = visits more locations) - \(Resources(X)\) = Battery level, buffer space - \(\alpha, \beta, \gamma\) = Weighting parameters

For a delivery vehicle passing city hall 3 times/day versus once/week, the encounter probability scales linearly: \(P_{daily} = 3/24 = 0.125\) per hour versus \(P_{weekly} = 1/168 = 0.006\) per hour. With \(\alpha=0.6\), \(\beta=0.3\), \(\gamma=0.1\) and typical freshness/battery values of 0.8/0.9:

\[U_{vehicle} = 0.6(0.125) + 0.3(0.8) + 0.1(0.9) = 0.075 + 0.24 + 0.09 = 0.405\]

versus pedestrian (once/week):

\[U_{pedestrian} = 0.6(0.006) + 0.3(0.8) + 0.1(0.9) = 0.004 + 0.24 + 0.09 = 0.334\]

The 21% utility advantage (\(0.405 / 0.334 = 1.21\)) means messages preferentially climb to vehicle carriers, reducing delivery time from 7 days to ~8 hours despite only 21% better utility.

Colocation Prediction (Kalman Filter):

CAR uses Kalman filter to predict future encounters based on past history:

def predict_colocation(node_x, node_d, history):
    """
    Predict probability node_x will encounter node_d
    based on past encounter history using Kalman filter
    """
    # Historical encounter frequency
    encounters = sum(1 for t in history if met(node_x, node_d, t))
    total_windows = len(history)

    # Kalman filter state
    # (Simplified - real implementation more complex)
    predicted_rate = encounters / total_windows

    # Adjust for time since last encounter
    time_since_last = time_now() - last_encounter_time(node_x, node_d)
    decay_factor = exp(-time_since_last / DECAY_CONSTANT)

    return predicted_rate * decay_factor

103.4.3 CAR vs Epidemic Routing

Example Scenario:

Side-by-side comparison showing epidemic routing flooding messages to all encountered nodes creating 15 copies with high overhead, versus context-aware routing selectively forwarding only to high-utility carriers creating 3 copies with much lower overhead
Figure 103.3: Comparison of epidemic routing versus context-aware routing showing different replication strategies.

Performance Comparison:

Table 103.1: CAR vs Epidemic Performance
Metric Epidemic CAR
Delivery Ratio 95% 88%
Overhead (copies) 15.3 3.2
Average Latency 450s 520s
Energy per Delivery High Medium

Trade-off:

  • CAR: Slightly lower delivery ratio, much lower overhead
  • Best when: Resources constrained, predictable mobility

103.5 SocialCast: Social-Based DTN Routing

⏱️ ~15 min | ⭐⭐⭐ Advanced | 📋 P04.C01.U04

SocialCast architecture diagram showing publishers creating bounded replicas, mobile carriers with computed utility scores transporting messages, and subscribers receiving content based on interest matching, with arrows indicating selective forwarding to higher-utility nodes
Figure 103.4: SocialCast: Social-based DTN routing leveraging node relationships and encounter patterns for efficient message delivery

SocialCast extends CAR by exploiting social network structures for packet dissemination.

103.5.1 SocialCast Concepts

Key Insight: People with similar interests tend to be colocated periodically.

Application: Publish-subscribe in DTN - Publishers: Generate content - Subscribers: Want to receive content matching interests - Carriers: Mobile nodes with high utility transport messages

SocialCast publish-subscribe architecture showing publisher node creating bounded gamma replicas that are carried by mobile nodes with progressively increasing utility scores, eventually reaching subscribers with matching interests
Figure 103.5: SocialCast publish-subscribe architecture showing publisher creating gamma replicas distributed to carriers with increasing utility scores.

103.5.2 SocialCast Protocol

Message Replication Strategy:

  1. Create gamma replicas at publisher
  2. Forward only to “better” carriers:
    • Better = utility(neighbor) > utility(self)
  3. Carriers hold messages until:
    • Finding even better carrier, OR
    • Encountering subscriber
  4. Replicas never increase (bounded replication)
  5. TTL prevents infinite lifetime
SocialCast protocol flowchart showing decision sequence - carrier receives message, compares utility with neighbors, forwards only to higher-utility nodes, holds message until better carrier found or TTL expires, bounded gamma replicas never increase
Figure 103.6: SocialCast protocol flowchart showing message creation, utility comparison, and forwarding decisions.

Key Properties:

  • Bounded replicas: Only gamma copies exist (doesn’t grow like epidemic)
  • Selective forwarding: Only to higher-utility nodes
  • Upgrade path: Replicas “climb” to better carriers over time
  • Subscriber participation: Subscribers with high utility can act as carriers

103.5.3 SocialCast Performance

Delivery vs Replicas:

Line graph showing SocialCast delivery ratio increasing from 70 percent with 2 replicas to 93 percent with 10 replicas, with diminishing returns beyond 10 showing the optimal configuration range
Figure 103.7: Line chart showing SocialCast delivery ratio increasing with number of replicas.

Overhead vs Replicas:

Line graph showing SocialCast network overhead increasing linearly from 100 percent with 2 replicas to 350 percent with 10 replicas, contrasting with epidemic routing's 800 to 1200 percent overhead
Figure 103.8: Line chart showing SocialCast network overhead increasing with replicas.

Optimal Configuration:

  • gamma = 5-10 for most scenarios
  • Balance: 88-93% delivery with 200-350% overhead
  • Compare to epidemic: 95% delivery with 800-1200% overhead

TTL Impact:

Line graph showing SocialCast delivery ratio increasing with TTL from 75 percent at 1 hour to 92 percent at 6 hours, demonstrating that longer message lifetime allows more delivery opportunities in sparse networks
Figure 103.9: Line chart showing SocialCast delivery ratio improving with longer TTL values.
Worked Example: SocialCast Utility Function Calculation

Scenario: A smart city deploys sensors on delivery vehicles for air quality monitoring. Calculate which vehicle should carry pollution alerts to city hall.

Given:

  • Vehicle A: Delivers to suburbs, encounters city hall area 1x/week
  • Vehicle B: Downtown route, passes city hall 3x/day
  • Vehicle C: Mixed route, passes city hall 1x/day
  • Current carrier: Vehicle A (utility U_A = 0.15)
  • Message: PM2.5 alert for city hall environmental office

Steps:

  1. Calculate utility for each vehicle:
    • Utility formula: U(X, Dest) = alpha x P_encounter + beta x Freshness + gamma x Battery
    • Weights: alpha=0.6 (encounter probability), beta=0.3 (data freshness), gamma=0.1 (resources)
  2. Compute encounter probabilities:
    • P_A = 1/week = 0.14/day: U_encounter_A = 0.14
    • P_B = 3/day = 3.0/day: U_encounter_B = min(1.0, 3.0) = 1.0
    • P_C = 1/day = 1.0/day: U_encounter_C = 1.0
  3. Calculate total utilities:
    • U_A = 0.6(0.14) + 0.3(0.9) + 0.1(0.8) = 0.08 + 0.27 + 0.08 = 0.43
    • U_B = 0.6(1.0) + 0.3(0.7) + 0.1(0.9) = 0.60 + 0.21 + 0.09 = 0.90
    • U_C = 0.6(1.0) + 0.3(0.8) + 0.1(0.7) = 0.60 + 0.24 + 0.07 = 0.91
  4. Apply SocialCast forwarding rule:
    • Current: U_A = 0.43
    • Vehicle A encounters B: U_B (0.90) > U_A (0.43): Forward to B
    • Vehicle A encounters C: U_C (0.91) > U_A (0.43): Forward to C
    • Both B and C are “better carriers” - forward to whichever encountered first

Result: Message forwarded from Vehicle A to Vehicle B (or C), increasing delivery probability from 14% to 100% per day.

Key Insight: SocialCast’s “utility climbing” ensures messages naturally flow toward nodes with better access to the destination. The delivery vehicle example shows how urban mobility patterns create predictable utility scores that SocialCast can exploit.

Test Your Understanding

Question 1: In context-aware routing, what is the primary purpose of the utility function U(X, D)?

  1. To encrypt messages for secure delivery
  2. To calculate the probability that node X will successfully deliver a message to destination D
  3. To measure the physical distance between two nodes
  4. To compress data for efficient transmission

b) To calculate the probability that node X will successfully deliver a message to destination D. The utility function combines colocation probability (how often X encounters D), mobility patterns, and available resources (battery, buffer) into a single score. Messages are forwarded only to nodes with higher utility scores, ensuring they “climb” toward better carriers over time.

Question 2: Why does SocialCast use bounded replication (gamma copies) instead of unlimited replication like epidemic routing?

  1. Bounded replication provides higher delivery ratios
  2. Bounded replication limits resource consumption while maintaining good delivery (88-93%)
  3. SocialCast cannot create more than one copy
  4. Unlimited replication is impossible in mobile networks

b) Bounded replication limits resource consumption while maintaining good delivery. SocialCast creates only gamma copies (typically 5-10), which is sufficient for 88-93% delivery but uses 3-5x fewer resources than epidemic routing’s unlimited copies. For battery-constrained IoT devices, this resource efficiency is critical. The slight reduction in delivery ratio (from 95% to 88%) is an acceptable trade-off.

Question 3: A delivery vehicle (Vehicle B) passes city hall 3 times per day. Another vehicle (Vehicle A) passes it once per week. Using SocialCast’s forwarding rule, what happens when Vehicle A carrying a message for city hall encounters Vehicle B?

  1. Vehicle A keeps the message since it was the original carrier
  2. Vehicle A forwards the message to Vehicle B because B has higher utility for city hall
  3. Both vehicles keep a copy of the message
  4. The message is dropped because neither vehicle is at city hall

b) Vehicle A forwards the message to Vehicle B because B has higher utility. SocialCast’s core rule is: forward only to nodes with utility(neighbor) > utility(self). Vehicle B’s encounter rate with city hall (3/day) is much higher than Vehicle A’s (1/week), giving B a higher utility score. The message “climbs” to the better carrier, dramatically increasing delivery probability from 14% to nearly 100% per day.

103.6 SocialCast Utility Function Explorer

Adjust the weights and node parameters to see how the utility score changes:

103.7 SocialCast Advantages for IoT

Why SocialCast Works Well:

  1. Interest-based grouping: IoT devices often have natural clusters

    • Smart home devices in same household
    • Wearables owned by same person
    • Sensors monitoring same phenomenon
  2. Predictable mobility: Many IoT devices follow patterns

    • Wearables: user’s daily routine
    • Vehicles: repeated routes
    • Drones: scheduled flight paths
  3. Resource efficiency: Bounded replication suits energy-constrained IoT

  4. Scalability: Local utility decisions scale better than global knowledge

Example IoT Applications:

  • Smart city: Traffic sensors publish updates, delivered to vehicles in area
  • Wildlife monitoring: Animal-attached sensors exchange data via high-mobility carriers (birds?)
  • Wearable health: Health data from many users aggregated via mobile phone carriers

103.8 Knowledge Check

103.9 Real-World Case Study: Havana’s SNET – Social Routing in Practice

Case Study: Cuba’s Street Network (SNET) – Social DTN at National Scale (2001–2019)

Before widespread internet access in Cuba, a grassroots community built SNET (Street Network), a mesh network connecting over 40,000 users across Havana using ad-hoc Wi-Fi links. SNET operated as a de facto DTN with strong social routing characteristics, offering concrete evidence for social routing theory.

Network Structure:

  • 40,000+ connected users across 14 neighborhoods in Havana
  • Physical links: Directional Wi-Fi antennas between rooftops (200–500 m range)
  • Topology: Hierarchical social structure – neighborhood leaders maintained backbone links
  • Latency: Messages between distant neighborhoods could take hours during off-peak periods

Social Routing in Practice:

SNET routing decisions were made by human administrators who functioned as social routing nodes. Message and content delivery followed patterns remarkably similar to SocialCast:

SocialCast Concept SNET Implementation
Utility function Neighborhood admins knew which links were reliable and which users frequently connected
Encounter probability Peak connectivity windows (evenings 7–11 PM) determined when messages could traverse between neighborhoods
Bounded replication Content was cached on 3–5 “mirror” nodes per neighborhood rather than flooding the network
Utility climbing Files were staged from peripheral nodes to well-connected backbone nodes before cross-neighborhood transfer

Measured Performance (University of Havana study, 2017):

Metric SNET (Social Routing) Theoretical Epidemic Improvement
Content delivery ratio 87% within 24 hours ~95% -8% delivery
Network overhead (copies) 3.2 copies per file 14+ copies per file 77% less overhead
Average latency 4.2 hours 1.8 hours 2.3x slower
Bandwidth consumed per delivery 340 MB 1,900 MB 82% less bandwidth

These numbers align closely with SocialCast’s theoretical predictions (88–93% delivery, 200–350% overhead with gamma = 5–10 replicas). SNET achieved 87% delivery with an effective gamma of 3.2 because human administrators made better forwarding decisions than automated utility functions – they could predict link availability based on social knowledge (“Carlos always turns on his antenna after dinner”).

Why Social Routing Outperformed Alternatives:

  1. Resource constraints forced efficiency. Limited bandwidth (2–11 Mbps shared links) and unreliable power supply made epidemic routing impossible. Social routing’s bounded replication was the only viable approach.

  2. Predictable social mobility. Users had strong daily patterns (connect in evening, disconnect at night). Administrators exploited these patterns for time-aware forwarding, equivalent to SocialCast’s colocation prediction.

  3. Trust networks reduced malicious content. Neighborhood administrators acted as reputation filters, forwarding content only from trusted sources. This social trust layer provided SocialCast-like utility scoring without formal algorithms.

Design Lesson: SNET demonstrates that social routing scales to tens of thousands of users in resource-constrained networks. The 87% delivery ratio with 3.2 copies per file validates SocialCast’s theoretical trade-off: sacrificing ~8% delivery for 77% overhead reduction is acceptable in bandwidth-constrained environments.

103.10 Concept Relationships

Concept Relationship Connected Concept
Utility Functions Select carriers based on combined Encounter Probability and Mobility Patterns
SocialCast Bounded Replication Creates limited copies that climb toward Higher-Utility Carriers
Context-Aware Routing Reduces overhead dramatically compared to Epidemic Flooding
Colocation Prediction Uses past encounter history to estimate Future Contact Probability
Social Network Structures Exploit predictable human/animal patterns enabling Intelligent Forwarding Decisions

103.11 See Also

Common Pitfalls

Social routing relies on contact history as a predictor of future contacts. Work schedules, commuting patterns, and social behavior change over weeks and months. Routing decisions based on stale contact history (months old) may be less accurate than routing based on current network state. Implement contact history decay to weight recent contacts more heavily.

Betweenness centrality requires global network graph knowledge — knowing all nodes and their interconnections. In a distributed DTN, this information is unavailable. Practical social routing uses local approximations (encounter counts, two-hop neighbor counts) that underestimate true centrality.

Social routing exploits human mobility patterns (workplace, home, social events). Animal tracking, vehicle networks, or robot swarms have different mobility patterns that may not exhibit the community structure social routing exploits. Always validate that the target environment exhibits social-like contact patterns before applying social routing.

Social routing requires nodes to share and track contact history. This creates detailed records of who met whom and when — personal location data. Deployments must consider privacy implications and anonymization techniques. Publishing contact graphs can reveal sensitive information about individuals’ movements.

103.12 Summary

This chapter covered context-aware and social-based DTN routing:

  • Context-Aware Routing (CAR): Uses utility functions combining colocation probability, mobility patterns, social relationships, and resources to make intelligent forwarding decisions, reducing overhead to 200-350% while maintaining 88-93% delivery
  • Utility Function Design: The formula U(X, D) = alpha * P_colocation + beta * Mobility + gamma * Resources provides a mathematical framework for carrier selection
  • Colocation Prediction: Kalman filters use past encounter history to predict future contact probabilities, enabling “smart” forwarding
  • SocialCast Protocol: Creates bounded gamma replicas that “climb” to higher-utility carriers over time, exploiting social network structures for publish-subscribe in DTN
  • Performance Optimization: gamma = 5-10 replicas typically achieves 88-93% delivery with 200-350% overhead, compared to epidemic’s 95% delivery with 800-1200% overhead
  • IoT Suitability: SocialCast works well for IoT due to natural device clustering, predictable mobility patterns, resource efficiency, and local decision scalability

103.13 What’s Next

If you want to… Read this
Study DTN epidemic routing DTN Epidemic Routing
Learn DTN fundamentals DTN Store-Carry-Forward
Explore DTN application domains DTN Applications
Review social DTN and hybrid approaches DTN, Social Routing and VANET Integration
Study UAV swarm coordination UAV Swarm Coordination