What's the Frequency, Flik?

The internet is pretty slick. Every attached computer has a unique address sort of like a phone number. (Sometimes, entire sub-networks lurk behind a single address through the miracles of IP and routing and such, just as entire switchboards of phones may lie behind the phone number of a main switchboard, but that's another story.)

Thanks to Transmission Control Protocol (TCP), files can be sent from one address to another with amazing efficiency. The brilliance of TCP's design lies in this: the rate at which stuff is sent automatically throttles up or down in response to network latency as measured by response time!

The Office – S5/E9: The Surplus from Vimeo.

Let's break it down. TCP is cool because "transmission control" sounds like "mission control" and that sounds like something NASA would have. But TCP is also cool because of how it works. Grossly simplified, it works like this:

  • You want to send that document requesting a pony to someone who has sent you a blind solicitation.
  • The networky stuff in your computer breaks the document into a bunch of "packets". Just like real parcels sent through UPS or Fedex or that other service, each packet is wrapped with a label explaining where it came from, where it's going, and so forth.
  • The packets follow various routes to their destination. As they arrive, the recipient (i.e., networky stuff on the other guy's computer) sends a receipt (called an "ack") to the sender. Meanwhile, the recipient uses the wrapper info to figure out whether all the packets have arrived, to put them in their correct order, and finally to reassemble the document. Transmission Accomplished!
  • The best part is the flow control. The sender starts by spraying out some packets and timing how long it takes to get a receipt for them. If the receipts come quickly, the sender sends more packets at a time. If the receipts come slowly, the sender sends fewer packets at a time (even stopping cold, if necessary). And since there's an ongoing flow of shipments and receipts and timing, the sender can avoid flooding the network but can also avoid letting bandwidth go to waste! Faster and faster! Slower and slower! No, faster! Slower! Strike that! Reverse it!
Flik, from Pixar's A Bug's Life
Flik, from Pixar's A Bug's Life

Now, here's the trippy science factoid du jour: researchers at Leland Stanford Junior University have discovered that Harvester Ants (including, apparently, the most venemous insect in the world) have been using TCP all along… behind Vint Cerf's and Bob Kahn's backs! Says the press release:

the rate at which harvester ants – which forage for seeds as individuals – leave the nest to search for food corresponds to food availability.

A forager won't return to the nest until it finds food. If seeds are plentiful, foragers return faster, and more ants leave the nest to forage. If, however, ants begin returning empty handed, the search is slowed, and perhaps called off.

They also found that the ants followed two other phases of TCP. One phase is known as slow start, which describes how a source sends out a large wave of packets at the beginning of a transmission to gauge bandwidth; similarly, when the harvester ants begin foraging, they send out foragers to scope out food availability before scaling up or down the rate of outgoing foragers.

Another protocol, called time-out, occurs when a data transfer link breaks or is disrupted, and the source stops sending packets. Similarly, when foragers are prevented from returning to the nest for more than 20 minutes, no more foragers leave the nest.

Further research into what these critters might teach us will be undertaken at the newly funded FourmiLab. Meanwhile, I leave you with a meditation on Proverbs 6:6 by e. e. cummings: go(perpe)go from his 1935 manuscript No Thanks (in George James Firmage, ed., E. E. Cummings: Complete Poems, 1904-1962, Revised, NY: Norton, 1994, p. 403 or thereabouts).

go(perpe)go, e. e. cummings, No Thanks, #20, 1935
go(perpe)go, e. e. cummings, No Thanks, #20, 1935


Leave a Reply