How to Build A Quantum Lie Detector with Quantum Computers

Qiskit
Qiskit
Published in
7 min readApr 25, 2022

--

By Maria Violaris, PhD student at the University of Oxford

“Entanglement.” “Nonlocality.” “Spooky action at a distance.” Each of these terms has been used to describe the counterintuitive behavior of quantum particles that become correlated after some physical interaction. We can separate those particles by the length of a room, or put them on opposite sides of the galaxy. No matter how great the distance, when we measure them, they will still be correlated beyond all classical expectation. Theorists still debate exactly how this happens, but thanks to a clever quantum thought experiment known as Hardy’s paradox, we’ve been able to rule out at least one strong possibility.

Thought experiments have always played a vital role in quantum theory, helping physicists grapple with some of the field’s many challenging and seemingly paradoxical concepts. Earlier this year, we debuted our Quantum Paradoxes video series, which presents famous thought experiments from the history of the field, and offers a new perspective on those thought experiments by showing you how to encode them as quantum circuits. In that first video, we helped viewers gain a new perspective on quantum superposition by teaching them how to build a quantum bomb tester. For our second installment of the series, we’ll see how adding a quantum lie detector to our arsenal can help deepen our understanding of quantum entanglement.

Proving Einstein Wrong

Today, we mostly take it for granted that entanglement is a fundamental element of quantum mechanics — just like quantum superposition or interference. However, Einstein and many of his contemporaries believed the existence of this “spooky” quantum phenomenon was a hint that something important was missing from quantum theory. Quantum theory indicated that particles could maintain entanglement across vast distances, but researchers of the day were reluctant to take those observations at face value. Surely, they argued, the mathematics of early quantum theory had failed to account for some “local hidden variable” that was causing the correlation in measurement outcomes between entangled particles.

Local hidden-variable theories were appealing because, on the one hand, they allowed physicists to maintain their understanding of classical locality — e.g., that interaction cannot occur between particles separated in space, and that information cannot travel faster than the speed of light. On the other hand, they also allowed physicists to reconcile the idea of classical locality with the then-nascent theory quantum realism, which essentially states that quantum theory describes what is really happening on the quantum scale, no matter how counterintuitive it may seem.

A local hidden-variable theory of quantum mechanics effectively gave physicists the ability to say that many aspects ofquantum theory that didn’t seem to make sense could be explained by some “hidden variable” that had not yet been discovered. There was just one problem: In 1964, nearly a decade after Einstein’s death, physicist John Steward Bell proved that local hidden variable theories were fundamentally incompatible with quantum physics.

Bell’s theorem showed that if local hidden variables were responsible for the phenomenon of entanglement, then there should be a statistical bound — later dubbed “Bell’s inequality” — on the correlations observed between entangled particles. Crucially, he also showed that quantum physics predicts many correlations that violate Bell’s inequality, and those predictions were soon validated across multiple experiments. This meant the only way that hidden variables could explain the existence of entanglement is if they were associated with both halves of an entangled pair and able to transmit some sort of influence between the particles instantaneously, regardless of how great the distance separating them. In other words, hidden variables only work if they are “nonlocal” (see the Qiskit textbook for more information on Bell inequalities).

This proved that quantum mechanics really is as weird as it seems, and shifted scientists’ conception of the fundamental properties of the reality that quantum theory describes. The phenomenon of nonlocality became a cornerstone example of the unusual behaviour of quantum systems, and furthermore became central to the advanced quantum information processing techniques we use in quantum computing today.

Building A Better Test

Bell’s theorem gained widespread acceptance and quickly became one of the most important results in the history of quantum theory. However, some physicists were understandably dissatisfied with the fact that it could only be demonstrated by violating the statistical bound described by Bell’s inequality. What if some fluke of probability distorted the conclusions we drew from violating the bound? What if researchers could only perform a small number of runs of an experiment, leading to unreliable statistical outcomes? Bell’s original theorem did nothing to address these concerns.

In 1990, a team of quantum physicists proposed a different test of whether reality can be described by a model that includes local hidden variables. This test required entangling three particles — rather than the two used for prior Bell’s theorem experiments, in what we call a GHZ (Greenberger-Horne-Zailinger) state —such that the three particles are maximally entangled. Using this set-up, we can show the violation of the local hidden-variables theory deterministically with a single message — no need to violate any statistical bound.

Two years later, in 1992, theoretical physicist Lucien Hardy devised a thought experiment which strikes the perfect balance between the original Bell test and GHZ test: Hardy’s paradox. Like Bell’s theorem and the GHZ experiment that preceded him, Hardy’s thought experiment also demonstrates that quantum physics does not support the existence of local hidden variables. However, unlike the GHZ test, Hardy’s experiment only requires two particles, and unlike the Bell test, we don’t have to violate any statistical bound to do it.

Quantum Gamifying Hardy’s Paradox

To show you how this works, I have re-framed Hardy’s thought experiment as a game of Two Truths & A Lie between our good friends, Alice, Bob and Carol. We’ll be able to check the results of the game using a quantum lie detector I’ve built withQiskit.

To start, let me explain the paradox:

We begin by representing our particles as two entangled qubits. Their overall state can be written in the following three ways, in terms of z-basis (|0⟩, |1⟩) and x-basis (|+⟩, |-⟩) states:

Now, consider what happens when Alice measures the first qubit and Bob measures the second qubit. From the overall state, Carol can draw some conclusions about their measurement outcomes. Two are true, and one is a lie!

[A] From (1), if Alice and Bob both measure their qubits in the z-basis, then at least one of them will measure 0, so the outcome 11 is forbidden.

[B] From (2), if Alice measures her qubit in the z-basis and gets 0, then Bob’s qubit will be in the |+⟩ state. If Bob measured it in the x-basis, he will get 0 (where an x-basis measurement of |+⟩ corresponds to an outcome 0, and of |-⟩ corresponds to an outcome 1). This means the outcome 01 is forbidden. Similarly from (3), if Bob measures his qubit in the z-basis and gets 0, and then Alice measures her qubit in the x-basis, she will also get 0, so 10 is forbidden.

“So,” Carol reasons, “at least one person — either Alice or Bob — will get 0 if they both measure in the z-basis, and if one of them gets 0 in the z-basis, then the other will be certain to get 0 in the x-basis.” Hence, it is natural to conclude that if bothAlice and Bob measure in the x-basis, at least one of them will get 0. Therefore, we can say the following:

[C] From [A] and [B], the outcome where Alice gets 1 and Bob gets 1 in the x-basis should be forbidden.

Now let’s write out the state of Alice and Bob’s qubits entirely in the x-basis:

We see there is a finite | — — ⟩ term, which will give the forbidden 11 outcome if it is measured!

The Logic Behind The Quantum Lies

My quantum lie detector prepares the state |Ψ⟩, performs x- and/or z-measurements on the two qubits, then checks to see if a certain outcome is forbidden. With this method, the lie detector reveals that statements [A] and [B] are true, but statement [C] is false. So where did classical Carol’s reasoning go wrong?

Carol assumed that Alice’s choice of measuring her qubit in the x-basis or z-basis can have no effect on the outcomes Bob will get when he measures his qubit, so she can combine conclusions about what Alice will get when measuring in either x- or z- bases. The paradox can be resolved by accepting that the relation between Alice and Bob’s qubits cannot be described using a local hidden variable.

One interpretation of this is that Alice’s choice of measurement basis does affect Bob’s measurement outcome, even though the qubits are spatially separated. This means there is nonlocality between Alice and Bob’s qubits.

Despite being proposed in 1992, the interpretation of Hardy’s paradox and nonlocality more generally is still under debate. There are arguments demonstrating that there need not be any “spooky action at a distance” between particles after all,since the existence of local hidden variables is not the only way for quantum theory to be local. An alternative is that quantum systems contain locally inaccessible information, which cannot be retrieved even if we perform measurements on an unlimited number of copies of the system (see Deutsch 2000 and Bedard 2021). Additionally, nonlocality is related to contextuality, which has been proposed to provide the elusive magic behind quantum computation.

Check out my latest video on the Qiskit YouTube channel to find out more about Hardy’s paradox, including the original thought experiment about interfering particles and antiparticles, and how to code your own quantum lie detector! The code is all available in this Jupyter Notebook.

--

--

Qiskit
Qiskit

An open source quantum computing framework for writing quantum experiments and applications