🏠 Home 📘 Track 1: Quantum Basics L22 — Your First Circuit L23 — Reading the Results L24 — Everything Connects
L23 §4 · Build Something Real ~12 min

Reading the Results —
Statistics & Measurement

A quantum circuit runs once and gives you exactly one classical bit string. That single result is almost useless. Run the same circuit N times and a histogram builds up — converging on the true probability distribution hidden in the quantum state. This lesson teaches you to read that histogram.

✦ One Idea Running a circuit N times builds a histogram that approximates the true probability distribution. The more shots you run, the closer the histogram converges to the theoretical probabilities — and reading that histogram is how you extract classical answers from a quantum computer.
measurement shots histogram Born Rule statistical convergence reset gate classical bits
Section 01
① Hook

The Gap Between Quantum and Classical

📊
Think about what running a circuit means
You have run the Bell pair circuit in L22. Now think carefully about what you got.

You run the Bell pair circuit exactly once and measure both qubits. You get the result $|00\rangle$. What can you conclude from this single run?

Here is the fundamental tension in quantum computing. The power of a quantum computer lives in its quantum state — in the superpositions and entanglements inside a running circuit. But the output of every quantum computation is classical. It is a string of 0s and 1s. Nothing quantum emerges from the measurement.

That classical output is also random. Run the Bell pair circuit once: you get $|00\rangle$ or $|11\rangle$, you cannot predict which. Run it twice: maybe $|00\rangle$, then $|11\rangle$. Run it ten times: some pattern starts to emerge. Run it a thousand times: a clear histogram takes shape, converging on the true probability distribution.

The quantum state is not directly observable. What you observe is a collection of classical measurement outcomes. Reading those outcomes correctly — understanding what the histogram is telling you and what it is not — is the essential skill for working with any quantum computer.

🔑
Why this lesson merges L25 and L26
The original curriculum split "measuring circuits" and "reading results" into two lessons. But they are one continuous topic: you cannot understand what a histogram is without understanding why you need multiple shots, and you cannot understand shots without understanding what measurement does. This merged lesson treats them as they actually are — one coherent idea.
Section 02
② Intuition

Frequency Becomes Probability

Before any quantum notation, here is the classical version of the idea.

🪙 The Coin Flip Analogy
You have a coin. You suspect it might be fair (50% heads). But you cannot look inside the coin to check. You can only flip it and record the result.

One flip tells you almost nothing. Heads. Could be a fair coin. Could be a 70% heads coin. Could be a 99% heads coin.

Ten flips: 7 heads. Starting to look biased, but still noisy.

100 flips: 51 heads. Now you are fairly confident it is close to fair.

10,000 flips: 4,998 heads. The frequency has converged to the true probability: 50%.

A quantum circuit is exactly this. The quantum state determines the probabilities. Measurement samples from that distribution. Each run is one flip. The histogram you build up over many runs approximates the true distribution — and that approximation gets better as you add more runs.

The mathematical fact behind this is called the Law of Large Numbers: as the number of independent, identical trials grows, the observed frequency converges to the true probability. For a quantum circuit, "trials" are shots — individual runs of the circuit followed by measurement. Each shot is independent: the circuit is reset to $|0\rangle$ before every run.

Key Insight
A quantum probability is not directly observable. What is observable is a frequency — the fraction of shots that gave a particular outcome. That frequency is your estimate of the probability. The more shots you run, the better the estimate. This is how every quantum computer in the world operates: not one run, but thousands.
Section 03
③ Framework

What Measurement Actually Does

The three things measurement does

When you measure a qubit — or any quantum system — three things happen simultaneously:

⚡ The Three Effects of Measurement
1. Collapse. The quantum state is projected onto one of the measurement basis states ($|0\rangle$ or $|1\rangle$ for a standard computational measurement). The superposition ends. Before: a quantum state with complex amplitudes. After: a definite classical value.

2. Classical output. The result is a classical bit — 0 or 1. This is the number that appears in your terminal, your screen, your histogram. It is no longer quantum in any sense.

3. Irreversibility. Measurement cannot be undone. Unlike quantum gates, which are all reversible, measurement is a one-way street. The quantum information encoded in the superposition is lost. Only the classical result survives.

The circuit notation: double lines

In a quantum circuit diagram, measurement is shown as a box with a meter symbol inside. After the measurement box, the wire splits into a double line — the notation for classical information. Single lines carry quantum states (qubits). Double lines carry classical bits after collapse.

Measurement notation — quantum wire becomes classical wire
quantum wire (qubit) measure classical wire (bit: 0 or 1) 0/1

The Born Rule — connecting amplitudes to probabilities

The probability of getting a particular measurement outcome is given by the Born Rule: the probability equals the squared magnitude of the amplitude for that outcome.

Born Rule
$$\text{For state } |\psi\rangle = \alpha|0\rangle + \beta|1\rangle:$$ $$P(\text{measure } 0) = |\alpha|^2 \qquad P(\text{measure } 1) = |\beta|^2$$ $$|\alpha|^2 + |\beta|^2 = 1 \quad \text{(normalisation — probabilities sum to 1)}$$
Every symbol defined: $\alpha$ and $\beta$ are the complex amplitudes of $|0\rangle$ and $|1\rangle$ respectively. $|\alpha|^2$ means the squared magnitude of $\alpha$ — for real-valued amplitudes, $|\alpha|^2 = \alpha^2$. The normalisation condition ensures the probabilities are valid (they sum to 1). The Born Rule is one of the postulates of quantum mechanics — it cannot be derived from more fundamental principles. It is the bridge between the quantum state and experimental outcomes.

Notice what the Born Rule does not say: it does not tell you which outcome you will get on any single run. It gives probabilities — which are only meaningful as long-run frequencies. A single measurement outcome tells you nothing about whether the Born Rule is satisfied. Ten thousand measurements give you a reliable estimate.

TermDefinitionUnit
shotOne complete run of a circuit: prepare → apply gates → measure → record result. Also called a "sample" or "trial."
countsThe number of shots that gave a particular outcome. Example: 503 shots gave |00⟩ out of 1000 total shots.integer
frequencyThe fraction of shots giving an outcome. counts ÷ total shots. Converges to the true probability for large N.0–1
histogramA bar chart showing counts or frequencies for each possible outcome. The visual representation of repeated measurement.
shot noiseStatistical fluctuation in a histogram due to finite sample size. Scales as 1/√N: double the shots, halve the relative noise.
Section 04
④ Theory

Reset: Reusing Qubits Between Shots

Every shot of a circuit starts from the same initial state: all qubits in $|0\rangle$. But after measurement, a qubit is in a definite classical state — either $|0\rangle$ or $|1\rangle$, depending on the outcome. To run the next shot, you need to bring all qubits back to $|0\rangle$.

This is the job of the Reset gate, sometimes written $\mathsf{Reset}$ or $|0\rangle$ in a circuit diagram. It is a non-unitary, non-reversible operation that unconditionally puts a qubit into $|0\rangle$ — regardless of what state it was in before.

Reset gate — any input → |0⟩
|1⟩ Reset |0⟩
(|0⟩+|1⟩)/√2 Reset |0⟩
Reset unconditionally sets the qubit to |0⟩. It does not matter if the qubit is in |1⟩, in superposition, or in an entangled state. After Reset, the qubit is always |0⟩.

This is why Reset is not a unitary gate — it is not reversible. It destroys quantum information. But that is exactly what you need between shots: a clean slate.

In practice, "Reset" in software often just means re-preparing the qubit in its ground state — either by applying an X gate if the measurement gave $|1\rangle$, or by the hardware's natural relaxation to $|0\rangle$. On real quantum hardware, qubits slowly lose energy and naturally decay toward $|0\rangle$ — this physical relaxation is the hardware implementation of reset.

🔁
Reset makes circuit re-execution possible
Without Reset, after one shot the qubits are in whatever state the measurement collapsed them to. Running the circuit again on those states would give wrong results. Reset guarantees that every shot starts identically — from $|0\rangle^{\otimes n}$ — so that the shots are independent, identical trials. This independence is the statistical requirement for the histogram to correctly estimate the probability distribution.
🚫
Reset is not the same as "undo the measurement"
Measurement is irreversible — you cannot recover the pre-measurement quantum state after collapse. Reset does not undo measurement; it prepares a fresh $|0\rangle$ state. The quantum information that existed before the measurement is permanently gone. Reset creates a new starting point, not a return to the previous state.
Section 05
⑤ Interactive

Live Histogram Builder

Choose a circuit, choose how many shots to run, then press Run. Watch the histogram build live. See how more shots produces a smoother, more reliable estimate of the underlying probabilities. Then reset and try a different circuit.

📊 Live Histogram Builder
Run N shots → watch frequencies converge to probabilities
INTERACTIVE
1 — Choose circuit
2 — Choose number of shots
N =
Total shots 0
Dominant outcome
Shot noise ≈ 1/√N
Convergence
Choose a circuit, choose N shots, then press ▶ Run. Watch the histogram converge as you add more shots.

Things to observe: start with the H gate circuit and run 1 shot at a time — the histogram jumps unpredictably. Run 10 shots: rough shape appears. Run 100: close to 50/50. Run 1000: very close. The shot noise (uncertainty) scales as $1/\sqrt{N}$ — to halve the error, you need four times the shots.

Section 06
③ Framework

Reading the Histogram Correctly

What converges and what does not

As you ran more shots in the interactive, you saw two kinds of bars: some that gradually settled near their theoretical values, and some (like $|01\rangle$ and $|10\rangle$ in the Bell pair circuit) that stayed exactly at zero.

These are fundamentally different. The fluctuating bars converge statistically — they carry shot noise that shrinks as $1/\sqrt{N}$. The zero bars converge mathematically — they are exactly zero because the quantum state has zero amplitude for those outcomes. No matter how many shots you run, the Bell pair will never produce $|01\rangle$. This is not statistical. It is structural.

N=10
Rough shape.
~30% error.
±16%
N=100
Good shape.
~10% error.
±5%
N=1K
Near true.
~3% error.
±1.6%
N=10K
Very precise.
~1% error.
±0.5%

The shot noise formula

Shot noise — uncertainty in frequency estimate
$$\text{Standard error of frequency} \approx \frac{1}{2\sqrt{N}}$$ $$\text{Example: } N=100 \Rightarrow \text{error} \approx 5\% \qquad N=1000 \Rightarrow \text{error} \approx 1.6\%$$
This comes from the standard error of a binomial proportion: $\sqrt{p(1-p)/N} \leq 1/(2\sqrt{N})$ (the worst case being $p=0.5$). For the H gate circuit with 100 shots, you expect the 0 count to be within about ±5 shots of 50. For 1000 shots, within ±16 shots of 500. To achieve 0.5% precision, you need N ≈ 10,000 shots. This is why real quantum computers run circuits thousands or millions of times.

What a histogram is and is not

A histogram is an estimate of the probability distribution, not the distribution itself. The true distribution is determined by the quantum state and the Born Rule — it is exact. The histogram is a finite-sample approximation of that exact distribution, with statistical noise.

🖥️
How IBM Quantum counts shots
When you run a circuit on IBM Quantum hardware, the default is 4,096 shots (2¹² — a power of 2 for convenient binary processing). More shots mean more reliable statistics but longer total execution time. For a circuit where each shot takes ~100 microseconds, 4,096 shots takes about 0.4 seconds of circuit execution time, plus queue waiting time. Researchers running many circuits often use 1,024 shots as a balance between speed and precision. For precise amplitude estimation, up to 8,192 or 16,384 shots are used.
Reading Rule
When reading a histogram: bars near theoretical values tell you about probabilities — subject to shot noise. Bars at exactly zero tell you about structure — which outcomes are forbidden by the quantum state. Both kinds of information matter. Distinguish them.
Lesson Summary

What You Now Know About Reading Quantum Results

  • 📊
    One shot gives one classical bit string — almost useless on its own
    A single measurement collapses the quantum state to one outcome. You cannot determine the probability distribution from a single result. You need many shots — typically hundreds to thousands — to build a reliable histogram.
  • 📈
    A histogram of N shots estimates the true probability distribution
    The frequency of each outcome (count ÷ N) converges to the true Born Rule probability as N increases. Shot noise scales as $1/\sqrt{N}$: 100 shots gives ~5% precision, 10,000 shots gives ~0.5% precision.
  • Measurement collapses the state, produces a classical bit, and is irreversible
    Three simultaneous effects: wavefunction collapse (superposition ends), classical output (0 or 1), and destruction of quantum information. Unlike gates, measurement cannot be undone. The Born Rule gives the probabilities: $P(\text{outcome}) = |\text{amplitude}|^2$.
  • 🔁
    Reset brings qubits back to |0⟩ before each new shot
    Without Reset, each shot would start from a different (post-measurement) state. Reset unconditionally sets a qubit to $|0\rangle$ regardless of its previous state. It is non-unitary and non-reversible — it destroys quantum information. But it is essential for reliable, independent, repeated measurement.
  • 🔍
    Two kinds of bars: statistical and structural
    Bars near their theoretical value have shot noise — they fluctuate and converge. Bars at exactly zero are structurally forbidden — their amplitudes are zero by the quantum state's construction. The Bell pair's $|01\rangle$ and $|10\rangle$ bars will never appear regardless of shot count. That structural zero is more informative than any non-zero bar.
Section 4 Retrieval Check

These three questions span L19–L23. They test whether the core ideas of Section 4 have stuck — gates, entanglement, circuits, and reading results. You need solid circuit knowledge before the Section 5 synthesis.

Quick Check
How clearly does reading quantum results click for you?

You have built circuits, created entanglement,
and now learned to read the results.
Section 4 is complete.
Next: everything connects. The full picture of quantum computing,
from qubit to algorithm.

→ Everything Connects — L24 · §5 begins
Sources & Further Reading
← Previous
Your First Circuit
L22 — Bell pair circuit, entanglement in data