Free to Learn
Quantum link lab

Can two boxes beat the rulebook?

Give Alice and Bob a box each. Each box sees its own input, 0 or 1, and gives one answer. They win if their answers match, except when both inputs are 1. Then they must disagree. The boxes can agree on rules before the game and cannot talk during it.

Try to win all four cases

Start with four zero answers. If Bob flips his answer for input 1, which pair of inputs will lose?

Alice’s answers
Bob’s answers
  • 00MatchWin
  • 01MatchWin
  • 10MatchWin
  • 11DifferLoss
3 of 4 cases won. Loss on 11.
Why does the loss move?

A win on 00 ties Alice’s first answer to Bob’s first. A win on 01 ties it to Bob’s second answer too. Now a win on 10 forces Alice’s second answer to match all the others. That leaves 11 with identical answers when it needs different ones. Picking a random rulebook each round mixes strategies with the same ceiling. With independent, equally likely inputs, their best average is 75%.

Now try a pair of qubits.

A qubit is a physical system you can measure to get one bit. An entangled pair shares a state. Here the input selects how each box measures its half. Each answer on its own looks like a fair coin. Compare the answers afterward and a pattern appears: with the right measurement angles the pair wins about 85 times in 100 on average.

Your project is a Python tool that tells those cases apart. First you’ll score a round. Then you’ll try to fool your scorekeeper. Finally you’ll use it on measurements from two electron spins in labs 1.3 km apart.

Build your Bell-test reporter

You’ll need Python 3.10+ and enough Python to edit a function. On a computer, clone the public project and run the reporter. You can also try the two experiments here.

git clone https://github.com/itsHabib/free-to-learn.git
cd free-to-learn
git switch --detach 09e1d847be38ad5ce4a00c3f28a522a85887c7fa
cd courses/quantum-link-lab
python3 lab.py demo
  1. Score a single round. Write the win rule in your own reporter and catch the four-input bug.
  2. Break your metric. A box with a fixed answer scores 97%. Figure out how it did that.
  3. Inspect the Delft run. Combine four correlations, report uncertainty and diagnose a new dataset.

Open the project on GitHub · Reference implementation · Learner starter · Where the six books fit

A healthy pair. A broken receiver.

Alice’s 0 and 1 both make it to Bob. A caller says the link still loses information. Which state would you send to reproduce the fault?

Try the receiver bench · Repair it in Python · Take the night shift

Watch the experiments on YouTube

The fourth card

Predict which input pair will lose when Bob changes one answer. Watch on YouTube

196 wins in Delft

Two scoreboards both say 80%. Decide whether you trust them equally. Watch on YouTube

Fix the scorekeeper

Watch one wrong line fail four tests. Then find the catch in a 97% win rate. Watch on YouTube

The receiver that passed

Pick a probe, follow Alice’s two-bit message and watch the failed delivery replay after the fix. Watch on YouTube