Tuesday, December 18, 2012

Our brains are radios

Ok, our brains are not actually radios, sorry for the provocative title. But as I will explain shortly, there are some interesting parallels. When I teach about wireless radios in my networking classes, I talk about this connection, and this always perks my students up. The connection stems from the fact that both radios and brains are signal processing systems. The concepts behind how radio receivers work explain some of the mysterious phenomena in our brains, particularly the hearing of phantom tunes.

This is how radios work

Most people have an incorrect model of how radios and wireless radio communication work. The layman thinks radios are simple. The transmitter does all the heavy lifting, and puts the signal on the air. Before the signal fades away completely, if the receiver device is in communication range, it will pick up the signal by listening. This naive understanding suggests that the receiver is a passive device, as listening is perceived mostly as a passive activity. But, nothing can be further from the truth. The receiver spends considerable energy to power its radio and amplify the signal in order to receive it.

When the receiver powers its radio to amplify signals, it is also amplifying noise. The signal to noise ratio (SNR) determines successful reception: if the signal has not faded, it will get amplified more, stand out, and decoded correctly. This gives raise to an interesting question: When there is no signal in the channel, what does the receiver radio hear? The answer is the receiver radio hears amplified noise. But the receiver radio does not have a way to know that this is noise. It picks up the signal as 0 and 1 bits, and passes this to the higher layer, MAC layer, which can have more context to differentiate between valid message and noise/junk message.

A peculiarity of the radios

In 2004, I was doing some MAC layer hacking on the wireless sensor nodes. For one experiment I bypassed the MAC layer on the node to listen/record the radio at the link layer. The lone node was recording bits, 0s, 1s, and so forth. I was surprised. I double-checked that there was no node transmitting in the vicinity, I tried again, and yes the receiver was still picking up phantom messages from thin air. This is because, the receiver radio is powered up and it is amplifying noise and receiving it as a phantom message. The reason this is not a problem in normal operation of the motes is because the MAC layer does the filtering of the phantom messages. To this end, the MAC layer imposes a preamble check (for at least a couple bytes) before recording a reception of a message. If the initial part of a stream of bits matches the preamble pattern (say 010101010101010101010101) than the rest of the message is recorded and delivered to the application layer. Otherwise, this is just noise, and should be ignored. Another important detail here is that if the preamble length is chosen too short (say 1 byte long), sooner or later the random noise stream will match the preamble pattern and a phantom (random noise) message will be received and passed to the application layer.

A peculiarity of our brains

This finally brings me to the brain and phantom tune connection. When you are lying in a dark room, deprived of any visual and audio stimulation, do you sometimes start hearing a tune (a phantom tune)? Tell me I am not the only one. It sometimes sounds very vivid, and you almost think you are actually hearing it play. (Sensory deprivation tanks is a good place to experience this. People who lost hearing also experience these in more intensity as reported in these articles.) This phantom tune is your brain lying to you, like the radio picking up phantom messages from thin air. This is because your brain is a signal processing machine and it is trying to latch on to some signals by boosting them. When there is no outside stimuli to latch on to, the noise gets amplified. In this case, the noise is the random firings of your neurons, which happens incessantly. And if it happens that a sequence of random firings of neurons matches the initial sequence (preamble!) of an old tune stored in your memory, your brain latches on to that signal and fills the rest of the signal playing from your memory, and you feel like you are vividly hearing that music again.

A related Kurt Vonnegut story from TimeQuake

I will of course not miss this opportunity to include a short piece on this theme from my favorite writer Kurt Vonnegut. This story appears in the TimeQuake book.
For the record: Dr. Fleon Sunoco at the NIH, who is independently rich, hires grave robbers tovbring him the brains of deceased members of Mensa, a nationwide club for persons with high Intelligence Quotients, or IQs, as determined by standardized tests of verbal and nonverbal skills, tests which pit the testees against the Joe and Jane Sixpacks, against the Lumpenproletariat.
His ghouls also bring him brains of people who died in really stupid accidents, crossing busy streets against the light, starting charcoal fires at cookouts with gasoline, and so on, for comparison. So as not to arouse suspicion, they deliver the fresh brains one at a time in buckets stolen from a nearby Kentucky Fried Chicken franchise. Needless to say, Sunoco's supervisors have no idea what he's really doing when he works late night after night.
They do notice how much he likes fried chicken, apparently, ordering it by the bucket, and that he never offers anybody else some. They also wonder how he stays so skinny. During regular working hours, he does what he is paid to do, which is develop a birth control pill that takes all the pleasure out of sex, so teenagers won't copulate.
At night, though, with nobody around, he slices up high-IQ brains, looking for little radios. He doesn't think Mensa members had them inserted surgically. He thinks they were born with them, so the receivers have to be made of meat. Sunoco has written in his secret journal: "There is no way an unassisted human brain, which is nothing more than a dog's breakfast, three and a half pounds of blood-soaked sponge, could have written 'Stardust,' let alone Beethoven's Ninth Symphony."
One night he finds an unexplained little snot-colored bump, no larger than a mustard seed, in the inner ear of a Mensa member, who as a junior high schooler had won spelling bee after spelling bee. Eureka!
He reexamines the inner ear of a moron who was killed when, she was grabbing door handles of fast-moving vehicles while wearing Rollerblades. Neither of her inner ears has a snot-colored bump. Eureka!
Sunoco examines fifty more brains, half from people so stupid you couldn't believe it, half from people so smart you couldn't believe it. Only the inner ears of the rocket scientists, so to speak, have bumps. The bumps have to have been the reason the smarties were so good at taking IQ tests. An extra piece of tissue that little, and as nothing but tissue, couldn't possibly have been much more help than a pimple. It has to be a radio! And radios like that have to be feeding correct answers to questions, no matter how recondite, to Mensas and Phi Beta Kappas, and to quiz show contestants.
This is a Nobel Prize-type discovery! So, even before he has published, Fleon Sunoco goes out and buys himself a suit of tails for Stockholm.
Trout said: "Fleon Sunoco jumped to his death into the National Institutes of Health parking lot. He was wearing his new suit of tails, which would never get to Stockholm. "He realized that his discovery proved that he didn't deserve credit for making it. He was hoist by his own petard! Anybody who did anything as wonderful as what he had done couldn't possibly have done it with just a human brain, with nothing but the dog's breakfast in his braincase. He could have done it only with outside help."