This note is part of [[quantum/Practical Quantum Information System]].
> [!info] Course code
> Use the companion repository for this lecture's runnable lab, helper functions, and regression checks:
> - [notebooks/by_concept/bells_inequality_and_chsh.ipynb](https://github.com/montekkundan/quantum-code/blob/main/notebooks/by_concept/bells_inequality_and_chsh.ipynb)
> - [qcourse/protocols.py](https://github.com/montekkundan/quantum-code/blob/main/qcourse/protocols.py)
> - [tests/test_protocols_algorithms_qec.py](https://github.com/montekkundan/quantum-code/blob/main/tests/test_protocols_algorithms_qec.py)
[TODO: add video - Bell's Inequality and CHSH]
## What This Concept Is
Suppose two distant parties produce correlated outcomes. Are those correlations just the result of shared hidden information prepared in advance, or are they genuinely incompatible with any local hidden-variable explanation? Bell's inequality is the mathematical tool that turns that philosophical question into an experimentally testable one.
The CHSH game is the operational version that many students find easier to remember. It converts Bell's inequality into a simple score-based task. Classical strategies are bounded. Entangled quantum strategies can do better. That performance gap is one of the clearest early demonstrations that [[quantum/Glossary#Local realism|local realism]] fails.
## Foundation Terms You Need First
[[quantum/Glossary#Bell inequality|Bell inequalities]] are constraints obeyed by local hidden-variable models. The [[quantum/Glossary#CHSH game|CHSH game]] is a two-player nonlocal game that expresses one such constraint operationally. [[quantum/Glossary#Locality|Locality]] means no faster-than-light signalling. [[quantum/Glossary#Local realism|Local realism]] is the stronger classical package that Bell tests rule out.
That distinction is essential: Bell violation attacks local realism, not the no-signalling structure of relativity.
## How The Idea Actually Works
In a Bell test, two parties choose measurement settings independently and compare their outcomes afterward. If the results can be explained by a shared classical hidden variable fixed in advance, then certain statistical inequalities must hold. Bell derived one family of such inequalities. CHSH is the most widely taught modern form.
The quantum strategy uses an entangled state, usually a Bell pair, and carefully chosen measurement bases. The resulting correlations exceed the best classical hidden-variable bound. This does not happen because the parties communicate during the game. It happens because the shared entangled state supports correlations that cannot be reproduced by any model that is both local and realist in the Bell sense.
The important caution is that Bell violation does not enable signalling. Each party's local statistics still look compatible with ordinary probability theory until the data are compared afterward. That is why the phenomenon is so striking: the correlations are stronger than classical local realism permits, yet they still respect the no-signalling structure of relativistic causality.
This note is one of the places where the course's conceptual layers lock together cleanly. Entanglement, basis choice, measurement, and hidden-variable reasoning all meet here in a single experimentally meaningful statement.
## Worked Example: CHSH As A Winning Game
Alice receives a bit $x$, Bob receives a bit $y$, and they output bits $a$ and $b$. They win when
$
a\oplus b=x\land y.
$
A deterministic classical strategy fixes Alice's two possible answers and Bob's two possible answers in advance. The four input pairs demand three equalities of the form $a=b$ and one inequality of the form $a\ne b$. No fixed assignment can satisfy all four at once, so the best classical strategy wins at most $3/4$ of the time. Shared randomness only chooses among deterministic strategies, so it cannot improve the bound.
The standard quantum strategy uses a Bell pair and rotated measurement bases. Its winning probability is
$
\cos^2(\pi/8)\approx0.854.
$
This gap is the operational Bell violation. It is not a signalling protocol: Alice's local outcome distribution remains balanced regardless of Bob's input.
## Why It Matters
- It is the cleanest operational test that entanglement is more than classical correlation.
- It separates locality from local realism in a precise way.
- It lays the groundwork for nonlocal games and certified randomness.
## Source Reading Lens
Use `qclec.pdf` Lectures 13-14 for the path from hidden variables to CHSH, then to nonlocal games and Tsirelson's inequality. Read this with [[concepts/Nonlocal Games]] and [[concepts/Einstein-Certified Randomness]] so Bell violation is not treated as only a philosophy result.
> [!question] What does the Tsirelson bound add beyond "quantum beats classical"?
>> [!answer] It shows that quantum correlations are stronger than local hidden-variable correlations but still limited. Quantum mechanics does not allow arbitrary no-signalling correlations; it has its own precise ceiling.
> [!question] Why is Bell violation useful for certified randomness?
>> [!answer] If separated devices violate a Bell inequality under the right assumptions, their outputs cannot be explained as fully predetermined local hidden-variable data. That gives a route to certifying randomness from observed correlations rather than trusting the internal device implementation.
## Additional Study Notes
**Check yourself: shared randomness is still classical** In CHSH, allowing Alice and Bob to share classical random bits does not beat the classical $3/4$ winning bound. Shared randomness only randomizes among deterministic local strategies.
**Check yourself: the quantum CHSH ceiling is known** It is not open whether standard quantum mechanics can beat $\cos^2(\pi/8)$ in CHSH. Tsirelson's bound gives the quantum optimum.
**Key fact: Bell violation does not signal** Entanglement can improve CHSH correlations, but Alice cannot choose her input or measurement to send a controllable message to Bob through the shared state alone.
**Question: What is the difference between breaking a Bell inequality and breaking relativity?** Bell violation rules out local hidden-variable explanations for the correlations. It does not give either party a local measurement distribution that depends on the other party's chosen input in a usable signalling way.
## Study Checks
Use these after the explanation, not before it.
### Quick Checks
- MCQ: What does Bell violation rule out under standard assumptions? A. Relativity B. All randomness C. Local hidden-variable explanations D. Measurement itself **Answer:** C. Local hidden-variable explanations.
- What is the classical CHSH winning bound? **Answer:** 3/4.
- MCQ: What is the optimal quantum CHSH winning probability? A. 1/2 B. 3/4 C. $\cos^2(\pi/8)$ D. 1 **Answer:** C. cos^2(pi/8).
- Why does Bell violation not imply faster-than-light signalling? **Answer:** The local marginal distribution for either party does not depend on the other party's input; the stronger-than-classical structure appears only in the compared correlations.
- MCQ: What does Tsirelson's bound show? A. Quantum correlations are unlimited B. Quantum correlations beat classical local bounds but still have a finite ceiling C. Classical strategies can always match quantum strategies D. Bell pairs are unnecessary **Answer:** B. Quantum correlations beat classical local bounds but still have a finite ceiling.
### Oral Exam Anchors
> [!question] Oral exam anchor
> Derive the classical CHSH bound and compare it to the quantum value.
A good answer should say:
In the CHSH game, Alice receives x, Bob receives y, and they output a and b. They win when
a xor b = x and y.
A deterministic classical strategy fixes Alice's answers for x=0,1 and Bob's answers for y=0,1 in advance. The four input pairs require three parity constraints with a xor b = 0 and one parity constraint with a xor b = 1. Multiplying or xoring all four constraints creates a contradiction, so no deterministic local strategy can satisfy all four inputs.
The best deterministic strategy wins three out of four cases, so the classical winning probability is at most 3/4. Shared randomness only randomizes among deterministic strategies, so it cannot exceed 3/4.
The quantum strategy using a Bell pair and appropriate measurement bases wins with probability
cos^2(pi/8) approximately 0.854.
This violates the classical local hidden-variable bound, but it does not enable signalling because each party's local marginal distribution remains independent of the other party's input.
## Practical Lab
Run the CHSH game explicitly so Bell violation becomes a visible performance gap.
- Implement the best classical CHSH strategy and record its winning rate.
- Implement the Bell-state quantum strategy and estimate its winning rate from measurement shots.
- Compare both against the classical bound and summarize the gap in plain language.
## Homework
Use the homework to connect the observed violation to the hidden-variable question.
- State the CHSH classical winning bound clearly.
- Explain why violating that bound rules out local hidden-variable explanations of the observed correlations.
- Explain why Bell violation still does not allow signalling faster than light.
## References
- Scott Aaronson, [Introduction to Quantum Information Science](https://www.scottaaronson.com/qclec.pdf), Lectures 13 and 14.
- Scott Aaronson, *Quantum Computing since Democritus*, Chapter 12.
- IBM Quantum Learning, [learning portal](https://quantum.cloud.ibm.com/learning/en).
- Qiskit documentation, [main docs](https://qiskit.org/documentation/).