Saturday, December 05, 2015

Quantum entanglement does not work like that

Whenever the topic of quantum entanglement -- which Einstein decried as "spooky action at a distance" -- comes up in online conversation, somebody will always ask whether this phenomenon can be used for instantaneous communication. And this is a very reasonable question because although the answer is definitively No, it's far from intuitively obvious why this is so, not least because it depends on details of quantum behavior usually omitted from non-technical explanations -- details that are critical to understanding the phenomenon.

I originally wrote the explanation below in response to a post on Gizmodo. Several people said it was helpful, so I decided to preserve it online for when the question inevitably comes up again.

The Very, Very Short Version

Entanglement allows you to infer what result somebody else's experiment will get; but it doesn't allow you to influence what result they will get.

The long version:

First, entangle your electrons

Suppose you “entangle” two electrons (there are lots of ways to do this; we'll take it as given). What this means is that they are paired in such a way that certain of their properties are reflections of each other. (In technical language we would say they have a "shared state".) In particular, we are interested in the so-called "spin". So you send me one electron and keep the other. Now you measure yours to see if it's spin is pointed up or down; if you find yours is up, you’ll know that if I do the same experiment, mine is pointed down; and vice versa. (The entangled electrons are always opposite, like two sides of a coin). 

Importantly, you won’t know whether you’ll get up or down until you do the experiment -- it’s a coin toss. The only way to tell which is the Up electron and which is the Down, by definition, is to do the measurement. 

Anyway: so far, so normal. Up to this point, it's really no more surprising than if you had split a coin down the middle and sent one half to me. It's no surprise that if you kept the heads side, I got the tails side.

But note the really important part here: I can't use this to send you a signal. The typical misunderstanding at this point is to think that since the electrons are always opposite, if I somehow force my electron into the Up position before measuring, yours will instantaneously be in the Down position, and from there with enough entangled electrons I can easily construct a binary code. And the simple fact is, entanglement does not work like that. Although the electrons are opposite to begin with, anything I do to change the state of my electron does not change the state of yours; instead it just breaks the entanglement. I can no more flip your electron by flipping mine than I can turn your half of the coin from heads to tails.

Let's get spooky

But now it gets quantum. Unlike a coin, there are lots of ways you can measure spin: in fact you can choose any axis you want to measure it along. You don’t have to measure whether your electron is pointing up or down like this: |. You could measure whether it is pointing left or right, like this --. Or along any in-between axis, like / or \. 

Now here's the critical part: electron spin is quantized. This means that whatever axis you measure spin on, the answer will always be precisely "+1" or "-1" units of spin (using the units that physicists typically choose), regardless of what state you thought the electron was previously in; in other words, either clockwise or counterclockwise. Yes, even if you think your equipment only generates up and down electrons, if you choose to measure it on the left-right axis, its spin will definitely be measured as either one unit of left or right spin. Oh, and of course if I measure mine on the same axis, it is pointing the other way. Or you could measure it on any orientation in between, and if I measure it on the same orientation, I get the opposite.

There is no analogy in the macroscopic world for this behavior that I can think of. If you had, say, a spinning basketball and you measured it's spin as "+1" in the up/down axis, it's spin on the left/right axis would be 0, and its spin in the / or \ directions would be somewhere between 0 and 1. This is a crucial difference between the quantum world and the familiar classical world.

One of the things this tells us is that, unlike basketballs and other classical objects, electrons don't have a definite spin until you measure it (and even then, that spin is only good until you measure it again on a different axis).

It gets worse (or maybe better)

Now, we’re not done. Up to now we've always measured our electrons on the same axis. It gets even spookier if you and I choose to measure our electrons along different orientations. 

Suppose you measure on the | axis and, say, get Up; but I choose to measure on the -- axis. Now two things I said above seem to be in conflict: 
  • entangled spins are always opposite, so mine must be Down; but 
  • if I measure left/right I must get precisely left or right. 
So what happens? Well, in fact I get left or right, and with an equal chance of each. It’s as if my electron was pointing Down after your experiment, and randomly chose which of left or right to flip to when I measured it.

Notice, by the way, that when I do my measurement, nothing now happens to your electron. If you were to subsequently measure your electron on the -- axis, your result would be completely random. The moment you measured your electron the first time, the entanglement was over. So no amount of cleverness with repeated measurements will let me send a signal either.

The really hard part

Now I do something even more interesting: instead of measuring --, I set my equipment at an angle to yours, lets say at /. If we think of a clock face with Up/Down at 12 o’clock / 6 o’clock, I set mine at 1 o’clock / 7 o’clock. Now what happens? 

What I find is that when your result is Up (12), I’ll get 7 most of the time and 1 some of the time (the exact proportions can be predicted, and have been demonstrated experimentally literally billions of times). And if your result was Down (6), I get the opposite results; mostly 1, some 7. Somehow, my electron “knows” what axis you measured along and what result you got -- even though the orientation was not fixed at the beginning before the electrons separated. In fact, even the orientations of our measurements can be chosen long after the electrons have separated, yet the entanglement still occurs. 

So maybe there's something here that can be used to communicate? Maybe you can send a signal with the way you choose the axis you measure on, since that influences the distribution of my measurements on a different axis? 

Unfortunately, no. And the reason is this:

Remember that when you measure on your end, you always get a random result, either up or down. You can’t force your electron to Up, and thereby influence my distribution; you can only discover whether it is Up or Down (and then infer what I am seeing). You can choose the axis you measure on, but not the outcome you get. (You can't even "separate out" the Up electrons from the Down: the only way to know which is which is to measure them, which destroys the entanglement.) And since you are getting 12 or 6 at random, to me it looks like I'm getting 7 or 1 at random too.

One last throw of the dice?

So perhaps there is one last loophole. If being entangled affects the measurements I get, maybe there is some way I can tell whether our electrons are still entangled? Since entanglement breaking is also instantaneous, maybe that in itself can be used to send a message? But no. Even while our electrons are still entangled, your stream of results looks completely random to you. Similarly on the other end, whatever I measure looks completely random to me: 1 or 7, 7 or 1, with no pattern. It’s only when we bring our results together that we see that whenever you got 12 I was more likely to get 7, and whenever you got 6 I was more likely to get 1, thereby proving that our electrons were entangled.

This is what physicists mean when they say our results are correlated, and the degree of correlation (as mentioned above) is precisely predictable, and has been tested in the lab. But it's only by bringing our results together that we see the correlation -- in isolation, each of us appears to get a random series of results. And bringing our results together to compare requires conventional slower than light communication.

(By the way, this is the basis of quantum cryptography, but that's a long story for another time.)

So in summary...

A lot of the confusion here comes from non-technical explanations being loose in their language when they say that one electron "influences" the other. This is true in the sense explained above -- the result I measure is linked at a distance (yes OK, Albert, "spookily") to the result you measure. But it's not true in the sense that you could change your electron and instantaneously cause a change in my electron. Any change you make to your electron in an attempt to change mine simply breaks the entanglement, and our results are no longer connected in any way.

Thursday, September 24, 2015

Experimental theology: religious football

Somewhere between one third and one half of Americans believe that God / Jesus cares enough about the outcome of sports contests to intervene, typically in favor of those who pray most fervently. I propose to put this belief to the test with the new game of Religious Football.

The game is very simple. It is played on a conventional American football field with a standard ball. The game begins with the ball at midfield on a tee, and two teams of eleven prayers line up on opposite sides of the field, five yards from the 50 yard line. Each team prays as hard as it can for the ball to move towards the opponents' end zone. Prayers can be spoken or silent, according to each team's ecclesiastical tradition.

If a team manages to pray the ball across the line, they score a point, the ball is re-centered, and the process begins again. After 60 minutes, the game ends and the team with the most points win.

This is a game where the "twelfth man" is exceptionally important. Supporters are allowed, even encouraged, to pray along with their team to help move the ball. (Conversely, the 13th man will be hung from the goalposts at half time).

There are a few other rules and penalties, to maintain order. The major ones include:
  • Offsides: The players must maintain five yards from the ball at all times, so if one team's prayers cause the ball to move, it can advance and the other team must retreat. Approaching closer than that incurs a five yard penalty.
  • Illegal touching: touching the ball in any way, or causing it to move with anything other than the power of prayer, is a ten yard penalty. 
  • Out of bounds: any reference to an opponent's mother, sister, or other female relative is completely out of bounds and will be penalized ten yards.
  • Roughing the pastor: any contact with the opponent's spiritual leader on the sidelines results in a 15 yard penalty. 
 I propose that we launch this game in Texas where, I'm told, both Jesus and football are popular.

Thursday, July 09, 2015

What we really talk about when we talk about transgendered people

A confession: back in my early-20s, there was a guy who worked in my office who disappeared for a few weeks then returned as a woman who worked in my office. For narrative purposes I'll call her Helen (not her real name). In retrospect, apparently I was among the few who didn't know this was going to happen, but in my defense we rarely intersected professionally and didn't move in the same social circles, despite being about the same age and at similar points on our career arcs.

And also in my defense, in my early-20s I was largely oblivious to and indifferent about anything that didn't directly impact me personally. But that's a long story for another day.

Anyway, this was my first conscious experience with a transgendered individual. While it's certainly possible that I'd known transgendered people before without even realizing it -- see above re. obliviousness -- Helen was the first person I actually knew before she became, well, Helen. It didn't bother me at all that she made this change -- again see above re. obliviousness -- but one thing did strike me as odd: the way she acted.

When Helen still had the body of a man, she was almost stereotypically male: very loud, pushy, assertive, what modern Americans might call a "bro", the British a "lad". If the boys were going to a pub or to crash a party or to get drunk and walk noisily down the middle of the street singing rugby songs, she would be right in the middle of it. In the office she would talk over people in meetings, push to the front at presentations, and if a sexist email joke was doing the rounds (yes, we still did that back in those days), she'd be in on it.

And afterwards, when she returned to work with long hair and makeup and skirts... she behaved exactly the same. And I remember thinking to myself: why doesn't she act more like a woman? But I shrugged -- it wasn't my problem -- and got on with life.

Shortly after that, I left the company in question for a better opportunity and never really thought about Helen again. It was only about a decade later that it suddenly dawned on me: perhaps the problem wasn't with how Helen acted. Perhaps the problem was with how I expected men and women to act.

Thursday, June 25, 2015

I Hate Birthdays

The thing I hate most about birthdays in the Web era is the absurdly insincere birthday greetings in email and on FB from corporations that happen to have my birthday in their database. What am I supposed to think about "good wishes" that don't emanate from any actual person? At best, it's an attempt to co-opt the natural human reaction of reciprocity; at worst, it's a crude sales pitch (who doesn't want a new weed trimmer on their birthday, right?).

If I wanted to read meaningless, empty, formulaic wishes that don't genuinely emanate from any real person with real feelings, I would go stand and stare in front of the birthday card rack at Hallmark for an hour.

 At least, that's what I used to do before the restraining order.

Tuesday, June 23, 2015

Some Thoughts On Jurassic World

Oh, and SPOILERS, obviously.

Here's a couple of thoughts about Jurassic World that I haven't seen mentioned elsewhere.

1. Owen (Chris Pratt) is actually responsible for hundreds of deaths. If instead of trying to escape from the Indominus Rex compound he had heroically accepted his fate and sacrificed his own life so that the others could escape without releasing the dinosaur, nobody else would have died. Also, the movie would have been over much more quickly.

2. Everybody online is complaining about Claire (Bryce Dallas Howard) running around the woods in her high heels and never once sinking in, losing a shoe, or breaking a heel. I think the director missed a great opportunity to capitalize on that. When Owen is pinned down by a pterosaur and Claire saves him, instead of shooting the pterosaur she should have spiked it in the head in the head with her heel.

And then she and Chris could have exchanged some witty banter about how he's sorry for mocking her footwear, while all around them people continue to be dragged to their horrible deaths, all because Owen didn't sacrifice himself in the first act (see point 1 above).

3. As an aside, Claire is obviously not from New York or she would have a pair of sneakers in her purse that she changes into when it's time to run for the train.

4. I don't think I've ever seen such gratuitous product placement in a movie ostensibly about the evils of over-commercialization. Even in actual Mercedes commercials the camera doesn't caress the bodywork so lovingly before coming to rest on such a prominent shot of the emblem. The director of this movie either has the most profound sense of irony on the planet, or none at all. I'm not sure which.

Tuesday, May 19, 2015

How to win bar bets with Wikipedia

Step 1: Edit Wikipedia to insert a fake "fact". Choose your fact carefully: it needs to be unlikely enough that your mark will bet against it, but not so crazy that it will provoke obvious incredulity ("Prince Philip, the Duke of Edinburgh, is a Furry"), causing the mark to doubt the veracity of Wikipedia. You also need to be sure that your edit won't get quickly reverted, so stay away from entries that are closely watched, controversial, or recently in the news ("in 2014, more goats were killed in rail accidents in the US than people").

Step 2: Choose your mark and place your bet.

Step 3: "Prove" your claim by looking it up on Wikipedia. Collect your winnings and leave before the mark checks other sources or your Wikipedia edit gets reverted.

Wednesday, April 15, 2015

Physics Problem: barometers and building height

There's a physics problem that typically gets presented to children when they learn about pressure (air, water, and often mercury) and barometers. And it seems to me that the problem is broken. The question is: how could you use an ordinary barometer to measure the height of a tall building? And the expected answer is to measure the air pressure at the top and bottom, and then knowing the weight of air, compute the elevation change.

But let's check the feasibility of this with a quick back-of-the-envelope calculation. For any realistic earthbound circumstance, we can assume that the pressure drops linearly with altitude; see the chart below. For reference, Denver, Colorado is at about 1600m, and the highest town in Great Britain is under 500m; we won't find much in the way of tall buildings above an altitude of 4000m.

("Atmospheric Pressure vs. Altitude" by Geek.not.nerd - Own work. Licensed under CC0 via Wikimedia Commons)

So what would our barometer tell us? Since we're just investigating the feasibility here, we're going to round things a little to make the math easy. Don't worry, no truths were harmed during the making of this calculation:
  • For every 1000m of altitude gained, the pressure drops ~10kPa, the chart tells us (at least, over the range we are concerned with).
  • Thus for each meter, the pressure drops ~10Pa; that's 0.1hPa. (1 hectopascal or 1hPa = 100Pa, and is the modern unit equivalent to millibars, commonly used in meteorology.)
A typical household digital barometer can detect a change of +/- 0.5hPa (50Pa), and an analog "certified precision" $600 aneroid barometer is only accurate to 1hPa (100Pa). So with one of these instruments, we can hope to measure building height to, at best, an accuracy of 5 to 10m -- maybe good enough to estimate the number of stories, but not the height.

Fortunately there are two other possible ways to use a barometer to determine a building's height:
  1. Drop the barometer off the top of the building and time how long it takes to hit the ground below. For a building in the range of 100m to 200m, timing accurate to 0.01s would give a precision of around 0.5m, so we will probably want to use some kind of electronic timing device rather than a hand-operated stopwatch. (With manual timing we could reasonably only count on a timing accuracy of 1/10s, which by coincidence converts to about the same height accuracy as the digital barometer.) For example, we could have synchronized clocks at top and bottom, an electromagnet release that records the start time and a sound-activated circuit to record the stop time. For a heavy barometer, we can ignore air resistance.
  2. Find the building custodian and say to him "If you can tell me how tall this building is, I will give you this lovely barometer". This is definitely my favorite solution.
NOTE TO STUDENTS: do not use this answer in any test unless you are very sure about the sense of humor of your teacher.

Monday, April 13, 2015

The American problem

The fundamental tension in America is that the red states want to be Sparta and the blue states want to be Athens, and the only thing that unites them in common cause is fear of Persia.

Friday, April 10, 2015

On the intractability of free will

[Author's note: the thoughts here originated as a Letter to the Editors at New Scientist, in response to a somewhat throwaway remark, in an article about randomness, that chance may be essential to the existence of free will. I felt that the point deserved delving into in more depth. New Scientist did publish the letter, but as is typical edited it down for publication -- in particular, many of my adverbs did not survive. Consequently, I wanted to share the full text here.]

Randomness may be necessary to "admit free will" in an otherwise-mechanical universe ("Chance", New Scientist 14 March 2015, p.28ff) but by itself it is not sufficient. It's hard to argue scientifically about the existence of free will in the absence of a rigorous definition of what it is, but we can say something about what it does. And at a minimum, it's existence requires that the outputs of my brain -- my actions -- are not completely determined by the inputs plus initial state. This is, of course, an astonishing proposition that is contrary to any other known physical system or law. Even if we introduce randomness, we merely allow a range of outcomes distributed probabilistically, but we still have no element of intentionality or purpose, the other essential ingredient in free will. Randomness alone would make us no more free than tumbling dice.

One intriguing possibility, however, is that whatever free will actually is, randomness provides a means for it to influence the brain without apparently violating known physical law; a curtain behind which it can hide. Imagine that free will is able to influence apparently-random outcomes deep in the brain, to achieve a desired output, but is also constrained by the need to appear random over the long term. The brain would be like a rigged casino where the roulette wheel comes up red or black at the casino's own choosing, but it must still ensure that the two come up equally over the long term if it is not to be caught breaking the rules. Correspondingly, we might speculate that free will rigs the brain game by influencing individual apparently-random quantum outcomes, which chaotic systems in turn amplify to macroscopic scale, but is limited in the long run because the overall outcomes must match our probabilistic quantum expectations.

Intriguingly, existing psychological experiments are consistent with this model of free will. For example, we know that behaviors that are usually considered exercises of free will such as "paying attention" or "resistance to temptation" are limited and can be exhausted, requiring time to recharge, even though they don't seem to be associated with anything as obvious as depletion of specific neurotransmitters or saturation of synapses. Yet this is exactly what we expect if free will can only influence a limited number of outcomes while staying hidden within known physical laws.

Whatever free will turns out to be -- assuming it exists at all -- understanding it will take at least as great a conceptual leap as that from classical mechanics to quantum theory. And perhaps it is only the reality of chance that connects these three views of reality into a consistent, scientifically explicable universe.

Wednesday, April 01, 2015

Athens and Sparta: A Parable About Open and Closed Source Software

Among all the city-states of Classical Greece, the most famous are certainly Athens and Sparta. Sometimes allies, often enemies, despite their shared language and culture, these two could not have been more different. So in the rivalry between Athens and Sparta, who ultimately emerged the winner?

In the 5th century BCE, the dominant city-state was Sparta. It was hierarchical, authoritarian and ruled by tyrannical kings and aristocrats. It’s greatest cultural values were discipline and conformity, and the kings of this highly militaristic state were also its generals. Sparta was incredibly effective at concentrating its resources to conquer a chosen goal – the phrase “the tip of the spear” could have been invented for them. As a result, Spartans were feared in battle across the Greek world, and Sparta was able to impose its military will on its neighbors.

But then, Athens began to rise to prominence and oppose the hegemony of Sparta. It became a famous center of creativity in the arts, learning and philosophy, home to Plato's Academy and Aristotle's Lyceum. Athens also gave the ancient world Socrates, Pericles, Sophocles and many more philosophers, writers and politicians. Its schools and forums were often lively, open-air marketplaces for competing ideas. It thrived on chaos. Even more remarkable were its experiments in democracy that included a unique combination of direct and representative democracy: everybody was expected to participate in and contribute to Athenian civic life. In stark contrast to Sparta’s general-kings, Athens elected its generals according to the needs of each war.

For a century, Athens and Sparta were in almost constant conflict for dominance of the Greek world, pausing occasionally and briefly to unite against a common enemy. Finally, in 404BCE, Athens was defeated for good and fell under Spartan rule. So did this mean that Sparta had won? Not exactly: Sparta’s dominance was short-lived. Neither Athens nor Sparta ever fully recovered from the costs and destruction of their wars, which impoverished most of the Greek world and ushered in the end of Greek pre-eminence.

So if both Sparta and Athens lost, who won? While Sparta and Athens were exhausting themselves in civil war, far to the west a small village called Rome was growing into a regional power. Rome was something strange and new: it borrowed many ideas from the Greeks, but had no real artistic culture of it’s own. Its sculpture, painting and poetry were second-rate derivations, sometimes even direct copies, of the works of the Greeks. It contributed no significant advances in mathematics or science, and barely anything to philosophy. Even the gods that the Romans claimed to worship were obvious imitations of the Greek pantheon. And yet, the Romans were exceptional engineers, great builders and implementers of others’ ideas. While the Greeks declined, Rome conquered a vast empire, convincing native populations almost everywhere that it was in their best interests to assimilate into Roman ways.

In the end, neither Sparta nor Athens won: both lost to Rome.

Friday, March 27, 2015


My three step plan for de-cluttering my house:
  1. Rent a storage locker
  2. Fill it with all the junk that I never use and / or really don't need
  3. Default on the rent

Wednesday, March 25, 2015


A friend of mine who is big into "natural foods" told me never to eat anything I couldn't pronounce, which is why I don't eat quinoa or acai.

Thursday, March 19, 2015

What would Jesus do?

A church in San Francisco has promised to remove controversial sprinklers it installed to deter rough sleepers, reports the BBC. "After an outcry, the city's archdiocese admitted it had been "ill-conceived" for St Mary's Cathedral to treat homeless people in this way", it goes on.

The new policy replaces the sprinklers with landmines and automatic machine guns.

Saturday, March 14, 2015

Understanding Fifty Shades

So if I understand current pop-culture correctly, "Fifty Shades" is a "Twilight" fanfic written by a middle-aged Mary Sue mom with actual sex scenes. Do I have that right?

Jeremy Clarkson is a git

The Jeremy Clarkson controversy isn't about the fact that he's a misogynistic, homophobic, pompous prick and the poster child [sic] for old white bigots hiding behind a facade of man-of-the-people "ordinary bloke". It's about integrity in automotive journalism.