Interactive Calculator · Quantum Foundations
CHSH Bell Test Calculator
Pick four measurement angles, set how noisy your entangled source is, and see whether your correlations break the classical limit.
How much of the ideal entangled state survives. 100% is a perfect singlet, lower values add white noise.
Trials are split evenly across the four setting pairs.
CHSH value |S|
2.687
Classical limit 2, quantum limit 2.828
Game win probability
83.59%
Classical best 75%, quantum best 85.36%
Correlators E(x, y) = −V cos(x − y)
Bars show magnitudes. Purple means negative, blue means positive.
Bell inequality violated
S = 2.687 exceeds 2, so no local hidden-variable model can reproduce these correlations. With 100,000 trials the statistical error is about ±0.0094, a 73.3σ violation.Trials needed for a 5σ violation at these settings: about 466.
Maximum S versus visibility (optimal settings)
The curve crosses the classical limit at V = 1/√2 ≈ 70.7%, the minimum visibility that can show a violation.
Compute the CHSH value S for an entangled pair, compare it with the classical bound of 2 and the quantum bound of 2.83, find the game win probability, and estimate how many trials a convincing Bell test needs.
What this calculator does
The CHSH inequality, named after Clauser, Horne, Shimony, and Holt, is the most widely used test of whether two distant measurements are correlated in a way that no classical theory can explain. Alice and Bob each choose between two measurement settings, record one-bit outcomes, and combine four measured correlations into a single number S. If the world obeys local hidden variables, then S can never exceed 2 in magnitude. Quantum mechanics predicts that an entangled pair can reach 2√2, about 2.83, which is called the Tsirelson bound.
This calculator uses the textbook model of a singlet state measured along directions in one plane, with an adjustable visibility that stands in for noise in the source and detectors. You choose the four angles and the visibility, and it returns the four correlators, the S value, whether the inequality is violated, the winning probability in the equivalent CHSH game, and the statistical significance you would get from a chosen number of trials.
How to use it
Start with the preset called Optimal Bell settings, which uses angles 0°, 90° for Alice and 45°, 135° for Bob. With perfect visibility you get S = 2.828 and a game win probability of 85.36 percent. Then lower the visibility slider and watch S fall in proportion. Where the curve in the chart crosses 2, you lose the violation. That crossing is at 70.7 percent visibility, and it is the minimum quality an entangled source needs for a Bell test to work with these settings.
Next, try moving the angles. The preset called All angles equal shows that without a difference between the settings there is nothing for entanglement to exploit, so the four correlators cancel. Then change one angle at a time and see which choices keep S high. You will find that the best arrangement has neighboring settings separated by 45 degrees, which makes sense because the correlation falls off as a cosine of the angle difference.
Finally, use the trials slider. A real experiment has finite statistics, so each correlator is only known to within a statistical error. The calculator splits your trials evenly across the four setting pairs and estimates the standard error of S, then tells you how many standard deviations above 2 your result sits. The text under the callout reports how many trials are needed for a five-sigma violation at the current settings.
Reading the result
A value of S above 2 means no local hidden-variable model can reproduce the statistics, provided the experiment closes the usual loopholes. A value between 0 and 2 is consistent with classical explanations. The game win probability is a different way of expressing the same number. In the CHSH game, referees give Alice and Bob random bits and they must output bits whose parity matches the product of the referee bits, without communicating. Classical players can win at most 75 percent of rounds, while players sharing entanglement can win up to 85.36 percent.
Be careful about what a violation does and does not prove. It shows that the correlations cannot come from pre-agreed local instructions. It does not allow messages to travel faster than light, and it does not by itself prove that a system is useful for computing. In practice, laboratories also have to guarantee that detectors catch enough of the particles and that the settings are chosen too late for any signal to travel between the two sites. The loophole-free experiments of 2015 did both.
Assumptions and limits
The calculator assumes an ideal two-qubit singlet state mixed with white noise, perfect detection, and measurements in a single plane. Real photon experiments use polarization angles that are half the Bloch-sphere angles used here, so a 45 degree Bloch angle corresponds to 22.5 degrees of polarizer rotation. Real systems also suffer from accidental coincidences, unbalanced detectors, drifts, and sometimes loophole-opening choices, none of which are modeled. The statistical formula treats trials as independent and identically distributed, which is the usual idealization.
The formulas behind it
Correlator
E(x, y) = −V cos(x − y)
For a singlet state measured along directions x and y in one plane, with visibility V.
CHSH value
S = E(a, b) − E(a, b′) + E(a′, b) + E(a′, b′)
Any local hidden-variable theory gives |S| ≤ 2. Quantum mechanics allows up to 2√2.
Game win probability
P(win) = 1/2 + |S|/8
Classical strategies reach 75 percent, entangled strategies up to about 85.36 percent.
Minimum visibility
V_min = 1/√2 ≈ 0.707
With optimal settings, S = 2√2·V exceeds 2 only above this visibility.
Statistical error
σ(S) = √( Σᵢ (1 − Eᵢ²) / nᵢ ), nᵢ = N/4
Standard error of S when N trials are split evenly across the four setting pairs.
Worked examples
Ideal source with optimal angles
- Set a = 0°, a′ = 90°, b = 45°, b′ = 135° and V = 100%.
- The four correlators are −0.707, +0.707, −0.707, and −0.707.
- S = −0.707 − 0.707 − 0.707 − 0.707 = −2.828.
Result|S| = 2.828, which is the Tsirelson bound, and the game win probability is 85.36 percent.
A realistic lab source
- Keep the optimal angles but set V = 95%.
- Each correlator has magnitude 0.95 × 0.707 = 0.672, so |S| = 2.687.
- The win probability is 1/2 + 2.687/8 = 83.6 percent.
- Σ(1 − E²) = 4 × (1 − 0.4516) = 2.194, so a 5σ violation needs N ≈ 25 × 2.194 × 4 / (0.687)² ≈ 465 trials.
ResultA 95 percent source violates the inequality by 0.687 and needs only a few hundred ideal trials for five sigma.
A source that is too noisy
- Set V = 65% with the optimal angles.
- |S| = 2.828 × 0.65 = 1.838.
ResultS is below 2, so these correlations can be explained classically even though the underlying state is still entangled.
Frequently asked questions
Why is the classical limit exactly 2?
Because if each particle carries pre-agreed answers for both settings, the four correlators combine in a way that can add up to at most 2, as Clauser, Horne, Shimony, and Holt showed in 1969.
Is a Bell violation proof of faster-than-light influence?
No. The correlations cannot be used to send information, and the violation only rules out the combination of locality and pre-existing values.
Why does a visibility below 70.7 percent hide the violation?
Because noise shrinks all correlators by the same factor, and 2√2 times 0.707 equals exactly 2.
References
- Bell, J. S. (1964). On the Einstein Podolsky Rosen paradox. Physics Physique Fizika, 1, 195-200.
- Clauser, J. F., Horne, M. A., Shimony, A., & Holt, R. A. (1969). Proposed experiment to test local hidden-variable theories. Physical Review Letters, 23, 880-884.
- Tsirelson, B. S. (1980). Quantum generalizations of Bell's inequality. Letters in Mathematical Physics, 4, 93-100.
- Aspect, A., Dalibard, J., & Roger, G. (1982). Experimental test of Bell's inequalities using time-varying analyzers. Physical Review Letters, 49, 1804-1807.
- Hensen, B., et al. (2015). Loophole-free Bell inequality violation using electron spins separated by 1.3 kilometres. Nature, 526, 682-686.
- Brunner, N., Cavalcanti, D., Pironio, S., Scarani, V., & Wehner, S. (2014). Bell nonlocality. Reviews of Modern Physics, 86, 419-478.
- Cleve, R., Høyer, P., Toner, B., & Watrous, J. (2004). Consequences and limits of nonlocal strategies. Proceedings of the 19th IEEE Conference on Computational Complexity, 236-249.
Keep exploring
- Paper: Loophole-Free Bell Inequality Violation Using Electron Spins Separated by 1.3 Kilometres
- Term: Bell Inequality
- Term: Entanglement
- Myth: Entanglement is just ordinary correlation, and hidden variables can explain it
- Myth: Entanglement lets you send messages faster than light
These calculators use simplified, published models for education and planning. Real devices and systems differ, so treat results as estimates. They are not engineering, investment, legal, or security advice.