A tale of two qubits: how quantum computers work

Just how do quantum computers work? It turns out that most of the magic of …

Quantum information is the physics of knowledge. To be more specific, the field of quantum information studies the implications that quantum mechanics has on the fundamental nature of information. By studying this relationship between quantum theory and information, it is possible to design a new type of computer—a quantum computer. A largescale, working quantum computer—the kind of quantum computer some scientists think we might see in 50 years—would be capable of performing some tasks impossibly quickly.

To date, the two most promising uses for such a device are quantum search and quantum factoring. To understand the power of a quantum search, consider classically searching a phonebook for the name which matches a particular phone number. If the phonebook has 10,000 entries, on average you'll need to look through about half of them—5,000 entries—before you get lucky. A quantum search algorithm only needs to guess 100 times. With 5,000 guesses a quantum computer could search through a phonebook with 25 million names.

Although quantum search is impressive, quantum factoring algorithms pose a legitimate, considerable threat to security. This is because the most common form of Internet security, public key cryptography, relies on certain math problems (like factoring numbers that are hundreds of digits long) being effectively impossible to solve. Quantum algorithms can perform this task exponentially faster than the best known classical strategies, rendering some forms of modern cryptography powerless to stop a quantum codebreaker.

Quantum computers are fundamentally different from classical computers because the physics of quantum information is also the physics of possibility. Classical computer memories are constrained to exist at any given time as a simple list of zeros and ones. In contrast, in a single quantum memory many such combinations—even all possible lists of zeros and ones—can all exist simultaneously. During a quantum algorithm, this symphony of possibilities split and merge, eventually coalescing around a single solution. The complexity of these large quantum states made of multiple possibilities make a complete description of quantum search or factoring a daunting task.

Rather than focusing on these large systems, therefore, the goal of this article is to describe the most fundamental, the most intriguing, and the most disturbing consequences of quantum information through an in-depth description of the smallest quantum systems. By learning how to think about the smallest quantum computers, it becomes possible to get a feeling for how and why larger quantum computers are so powerful. To that end, this article is divided into three parts:

Single qubits. The quantum bit, or qubit, is the simplest unit of quantum information. We look at how single qubits are described, how they are measured, how they change, and the classical assumptions about reality that they force us to abandon.

Pairs of qubits. The second section deals with two-qubit systems, and more importantly, describes what two-qubit systems make possible: entanglement. The crown jewel of quantum mechanics, the phenomenon of entanglement is inextricably bound to the power of quantum computers.

Quantum physics 101. The first two sections will focus on the question of how qubits work, avoiding the related question of why they work they way they do. Here we take a crash course in qualitative quantum theory, doing our best to get a look at the man behind the curtain. The only prerequisites for this course are a little courage and a healthy willingness to ignore common sense.

Single qubits

Bits, either classical or quantum, are the simplest possible units of information. They are oracle-like objects that, when asked a question (i.e., when measured), can respond in one of only two ways. Measuring a bit, either classical or quantum, will result in one of two possible outcomes. At first glance, this makes it sound like there is no difference between bits and qubits. In fact, the difference is not in the possible answers, but in the possible questions. For normal bits, only a single measurement is permitted, meaning that only a single question can be asked: Is this bit a zero or a one? In contrast, a qubit is a system which can be asked many, many different questions, but to each question, only one of two answers can be given.

This bizarre behavior is the very essence of quantum mechanics, and the goal of this section is to explain both the bounds that quantum theory places on such an object and the consequences that such bounds have for our classical assumptions. Given how counterintuitive this behavior seems, I will first explain in some detail how polarized light provides the perfect example of a qubit. Using a little light, some polarized sunglasses, and a 3D screening of "Avatar," I'll use that specific example to describe how all single-qubit states can be thought of as points on or inside a sphere, and finally how the fundamental operations of quantum measurement, rotation, and decoherence can be visualized and understood using that sphere.

Before continuing, I should define a word that I'll be using frequently: state. A system's state is a complete description of that system; every system (including a single qubit) is in a particular state, and any systems that would behave completely identically are said to have the same state. Classical bits, therefore, are always in one of exactly two states, "zero" or "one."

With that out of the way, our first step is to find an object which always gives one of exactly two answers, but which can be measured in many different ways. Here's where you're going to need those polarized sunglasses. Polarized sunglasses are different from normal sunglasses because they are designed to block the glare from horizontal surfaces, like a long stretch of desert highway or the surface of a lake on a sunny day.

How do they work? Light is in fact made of photons—the smallest indivisible unit of light—and every photon creates a tiny, oscillating electric field as it travels. Light from the sun (and most other sources of light) is composed of photons oscillating in all sorts of directions. However, light which is reflected off a horizontal surface (like glare off a lake) will become horizontally polarized. When the light reaches the sunglasses, the photons are either transmitted or absorbed. If a photon's electric field oscillates horizontally, polarized sunglasses absorb it. If it oscillates vertically, it will pass right through the same sunglasses.

These polarized lenses provide our first example of a quantum measurement, as they show a way to distinguish between horizontally polarized and vertically polarized photons (based on which gets transmitted and which gets absorbed). They can, of course, be used to ask a different question (make a different measurement) if they are tilted. By tilting your head 90 degrees, you make a measurement which is the opposite of the first, as the sunglasses transmit all of the glare you were trying to avoid. By tilting your head 45 degrees to one side (diagonally) or the other side (antidiagonally), they will transmit only half the glare.

Does this mean that the types of questions you can ask are limited to the angles at which you can tilt your head? That may seem reasonable, but if you went to see the 3D showing of Avatar, you might have guessed that this isn't true. In order to create the illusion of three-dimensional objects on a two-dimensional screen, movie theaters need to control exactly which photons go to each of your eyes. For decades, this was done using color. (Remember the 3D glasses with one red lens and one blue lens?)

To get full-color 3D, we need another way to control which photons go in which eye. Once again there are only two answers—absorbed or transmitted—so we need new questions. You don't want the entire movie to change when you tilt your head, so using horizontally and vertically polarized lenses is out. Likewise, diagonally and antidiagonally polarized lenses won't work. (Test this out in a 3D movie—tilting your head won't ruin the effect.)

The solution is something completely different, called circular polarization. The two lenses in modern 3D glasses each ask the question, is an incoming photon right-circularly polarized or left-circularly polarized? Each lens transmits only one of these two types of light (one of the two answers to the question), allowing special projectors (which transmit the same types of light) to control what image is seen by each of your eyes, thereby creating the illusion of electric blue warriors riding extra-terrestrial pterodactyls flying off the screen.

If the polarization of a photon is the perfect example of a quantum bit, what can the following three questions/measurments tell us about it?

Is the polarization horizontal or vertical?

Is the polarization diagonal or anti-diagonal? (In other
words, will it pass through my polarized sunglasses when I
tilt my head forty-five degrees to the left or to the right of
vertical?)

Is the polarization right-circularly or left-circularly
polarized? (In other words, does it pass through the right or
left lens of a pair of 3D glasses?)

If we performed the measurements that these three questions represent on the horizontally polarized photons generated by highway glare, we would learn that each photon always passes through a horizontal polarizer (question 1), but has only a 50% chance of passing through diagonal (question 2) or right-circular polarizers (question 3).

Great article, I wish it had existed 10 years ago when I was first learning the technical details of QM and QC as an undergrad. A piece like this to help the intuition would have gone a long way when slogging through the parts of Nielsen and Chuang I just wasn't ready to handle conceptually.

Oh come on, it wasn't that hard. Just defocus your eyes, click 'next' five times, and nod knowingly at the witty last sentence. It worked for me.

This looks like a really good article, but my reading instructions are a little too close to the truth for me to know for sure. Especially when it got to the math section. I think I have a grasp on the concept of local realism and most of the single qubit section, so that's a personal victory.

Excellent piece. Handily the most technical thing I've read on Ars to date, but quite nice to read about the computing aspects of quantum mechanics. My brain is definitely going to be stuck on the entanglement of quantum measurements, though. Hmmmm.

Great read BTW. Thanks for explaining it, but wow quantum computers are complicated, I never knew it was that complicated. I mean I knew that the measurements changed the state of a quantum computer, but wow, I had no idea about the other properties. Mind blowing!

A question for you, if you don't mind, because this "spooky actions at a distance" thing still intrigues the hell out of me.

I understand that states need to be entangled between two particles at some point when they are together, but there is something that myself and some friends disagree on in our understanding.

Basically, let's say we create a stream of entangled particles (say photons) and split them at our location, and then buffer a local stream whilst transmitting the other stream a long distance... *If* we then maintain absolute parity in measurement at both locations, and ensure against outside influences prematurely observing these particles. Could we actually transmit information over large distances *instantaneously* by "observing" according to an agreed protocol that would allow us to expect certain results and then perceive error or success in those "observations" at the "receiving" location as the form of the data?

You don't want the entire movie to change when you tilt your head, so using horizontally and vertically polarized lenses is out. Likewise, diagonally and anti-diagonally polarized lenses won't work. (Test this out in a 3D movie—tilting your head won't ruin the effect.)

Actually, when I went to see Avatar in 3D, I could hold the left lenses of two pairs of glasses together and they would let through light, but if I tilted one of them 90 degrees all of the light would be blocked. The reverse would happen if I held a left lens and a right lens together. Doesn't that mean they were, in fact, horizontally and vertically polarized? Or am I missing something here?

This was a rather hard slog, though I think I got most of it. Probably only about half of the last part. That could've used some more/better clarification.

Regarding Figure 11, how can you describe every possible state as a combination of |L> and |R> when |L> and |R> are two endpoints of a single axis? Doesn't that only let you describe the points along that axis?

For the quantum equations, it would've been helpful to have defined the conceptual meaning of the mathematical operations between states ahead of time. By the end it became clear what they meant -- effectively addition is union, or "either this state exists or that state exists", and multiplication is intersection, or "both of these states exist", so |a>|b> + |c>|d> means "either both a and b are the case, or both c and d are the case" -- but when you just started throwing equations out there I was just like, "what?". I /still/ don't get the whole thing with phases. Intuitively multiplication-by-number would indicate weighting, or in this case probability, but they actually mean phases and pulsing and all that, so I don't think that's right (plus, the numbers are complex...). (As an aside, mathematically what kind of value is a quantum state? Is it a vector of three numbers, corresponding to the three axes? Or does entanglement mean it's something weirder?)

Also, at the part where you go to define |H> and |V> in terms of |R> and |L>, it's sort of odd that you do it the way you do -- usually, when you define something in terms of other things, you do it by putting it on one side of an equation by itself, not inside of the equation. Why this way? And what are all the 1/sqrt(2) factors for? (Intuitively I would assume it's to normalize things, so that the sum of probabilities remains 1, but if multiplication-by-number doesn't actually have to do with probability weighting but with... pulsing... then I have no clue.)

Last, does this measuring-is-entangling idea bear any relation to the many worlds idea? E.g., that every time a quantum event happens, the universe forks itself in two, with the event going one way in one of them and the other way in the other, so that in the end there are endless parallel universes for every possible reality. Does this measuring-is-entangling idea imply effectively the same thing formulated differently, as "all possible realities exist simultaneously in an entangled quantum state" (rather than in parallel universes), or are they two different things? What's the difference?

I once knew, and understood (at least I have vague memories of understanding) all of the basic QM represented here - and even for me, it's a bit too much. It took me a quarter of grad school to begin to wrap my head around the stuff, I think this is a level of detail that's not appropriate for general public consumption.

I don't think the reason he went on to discuss the quantum measurement problem was to not deprive of us critical information.

I think it was so he could get in the riff on stacked up turtles!

BTW, I'm almost certain the turtles quote much predates Pratchett's use of it; Wikipedia has a sheaf of possible attributions for its origin. I believe I saw it in something from the late 19th or early 20th century (Alan Quatermain??), though my brain cells are currently heavily entangled and probably not reliable on this.

Let's say we create a stream of entangled particles (say photons) and split them at our location, and then buffer a local stream whilst transmitting the other stream a long distance ...Could we actually transmit information over large distances *instantaneously* by "observing" according to an agreed protocol that would allow us to expect certain results and then perceive error or success in those "observations" at the "receiving" location as the form of the data?

This is a great question, and one of the most commonly misunderstood aspects of "spooky action at a distance". Entanglement cannot be used to communicate faster than light.

The reason is that while measurement results on entangled particles are always perfectly correlated, as you point out, they are also totally *random*. The scheme you describe will result in two parties instantaneously sharing a string of *random* bits. Although one can think of that information as being transmitted instantly, neither of the two parties has any control over what information is measured, making it impossible to use this effect to send a message. (Note, however, that this is *exactly* how <a href="http://en.wikipedia.org/wiki/Quantum_cryptography">quantum key distribution</a> works).

Let's say we create a stream of entangled particles (say photons) and split them at our location, and then buffer a local stream whilst transmitting the other stream a long distance ...Could we actually transmit information over large distances *instantaneously* by "observing" according to an agreed protocol that would allow us to expect certain results and then perceive error or success in those "observations" at the "receiving" location as the form of the data?

The scheme you describe will result in two parties instantaneously sharing a string of *random* bits.

Thanks for your reply. The bit I quote from you is where I always get stuck on this. Let's forget the impossibilities of the logistics of all this for a moment. What I thought was that if "observing" is synchronised and you are "observing" the same particles then you can get predictable opposite results based on what you choose to "observe"?

I am most definitely over simplifying there! ( I must say that I love how ridiculous all these statements sound! )

Is there really no way to create that situation, even theoretically? Because if there isn't I need to go read the article again as I have misunderstood something fundamental! :-)

An excellent article really. I've read upwards of half a dozen articles regarding quantum computers and this is the first time, I can say, I understood its principles on at least a basic level. This also served, to bring my knowledge and comprehension of quantum entanglement, to a level beyond that of starter Quantum Mechanics university classes.

Regarding Figure 11, how can you describe every possible state as a combination of |L> and |R> when |L> and |R> are two endpoints of a single axis? Doesn't that only let you describe the points along that axis?

Good question. Figure 11 shows how to describe any point on the *surface* of the sphere as a combination of |L> and |R>. Said another way, it shows how to describe any point on the surface of the sphere in reference to |L> and |R>, by noting the latitude (theta) and longitude (phi) of a point relative to those two poles. To also describe the points inside the sphere, you have to add a third decoherence parameter. Because the equations were already getting confusing, I decided to leave this out.

quote:

(As an aside, mathematically what kind of value is a quantum state? Is it a vector of three numbers, corresponding to the three axes? Or does entanglement mean it's something weirder?)

Quantum states are represented in different ways, depending on your assumptions. For the most part, you can describe an N-qubit quantum state which has not been subjected to decoherence as a column vector with 2^N entries. If you want to describe states which have been partially decohered, you need to use a more general mathematical object: a square matrix with 2^N columns and 2^N rows. In either case, every entry in the vector/matrix is complex, that is, it has a real and an imaginary component.

quote:

And what are all the 1/sqrt(2) factors for? (Intuitively I would assume it's to normalize things ...)

Your intuition is correct. To find the probability of measuring any one quantum state in a sum of quantum states, you square the magnitude of that state's coefficient (that coefficient is called an amplitude). The square of 1/sqrt(2) is 1/2, meaning that any term with a 1/sqrt(2) in front of it has a 50% chance of being detected in that state.

quote:

Last, does this measuring-is-entangling idea bear any relation to the many worlds idea? E.g., that every time a quantum event happens, the universe forks itself in two, with the event going one way in one of them and the other way in the other, so that in the end there are endless parallel universes for every possible reality. Does this measuring-is-entangling idea imply effectively the same thing formulated differently, as "all possible realities exist simultaneously in an entangled quantum state" (rather than in parallel universes), or are they two different things? What's the difference?

As you point out, the many worlds interpretation posits that every time a quantum measurement happens, the universe splits. If at some point quantum measurement becomes irreversible (a collapse to classical physics), these multiple universes would be forever separate and unrelated. If the turtles really do go all the way down, they are part of a giant entangled state, and as such can continue to *interfere* with each other, continuously merging and splitting forever. (Note that here I'm using the technical quantum mechanical meaning of <a href="http://en.wikipedia.org/wiki/Interference_%28wave_propagation%29>interference</a>.)

Is there really no way to create that situation, even theoretically? Because if there isn't I need to go read the article again as I have misunderstood something fundamental! :-)

Regarding trying to use entanglement to communicate faster than light, it really is impossible, even theoretically. To follow the analogy of the article, let's say you set up a measurement for the hero/villain pairs. You're going to ask them both the same question about Love or War. Although you know they'll always disagree, you have no idea which will answer "Love" and which will answer "War".

If you'd like to break the system and design an FTL communication scheme, imagine you have two magic coins that when simultaneously flipped will always give totally random but always opposite results. So regardless of the distance between them when one comes up heads, the other comes up tails, but it's impossible to predict which will be which. If you can use these coins to communicate faster than light, then you can use entanglement to communicate faster than light. (HINT: You can't.)

So, at the IMAX3D movies, tilting your head will ruin the effect, and you should be able to take two pair of glasses and rotate their lenses with respect to each other and see them get light and dark as you match and unmatch the polarization.

The Real3D lenses should always be dark when paired against the oppositely polarized lens, regardless of how you rotate them.

I always figured the action at a distance was tied to the wave function of particles. I was taught that the probability function extended to infinity. That allows the possibility of "tunneling" between two arbitrary locations.

Your intuition is correct. To find the probability of measuring any one quantum state in a sum of quantum states, you square the magnitude of that state's coefficient (that coefficient is called an amplitude). The square of 1/sqrt(2) is 1/2, meaning that any term with a 1/sqrt(2) in front of it has a 50% chance of being detected in that state.

Hmm, I see. I'm still having trouble reconciling "amplitude" and "heartbeat", but I'll keep trying.

Would turtles all the way down also imply that if a friend of yours sent you a letter from many thousands of miles away, which world you're in -- what's in the letter -- would only be determined for you (the split would only happen) at the point where you actually open the letter and look at it? And until you do, the entire rest of the world, from your perspective, is in a quantum superposition of all possible realities corresponding to all of the possible contents the letter could have? (And that, until you open the door, the person who knocked really could be anyone). (I was actually thinking about this earlier today, completely independent of this article, so the article is pretty fortuitous; at the time it seemed like a pretty radical new view (for me) of life, the universe, & everything, and hours later it turns it might be "mainstream".)