Level 1, Curious

Computational basis

These are the two states a usual measurement is built to distinguish, the state certain to read 0 and the state certain to read 1. The puzzles finish on this pair, and a Hadamard before the click turns the reading into one along the x axis.

The computational basis is the pair of states labelled 0 and 1 that a measurement is usually built to distinguish. Other arrangements exist, and a Hadamard placed before the measurement is the everyday way to read along the x axis of the Bloch sphere, between |+⟩ and |−⟩.

Keith calls this pair the normal way, as if the others were dialects. Malcolm calls it one arrangement among several, and then uses it for the puzzles, because a puzzle needs a finish line everyone can see.

An example

Every state of one qubit is an amount of |0⟩ plus an amount of |1⟩. The amounts are the amplitudes, and a reading in this basis gives each label with a chance equal to the square of its amount.

Two qubits have four labels, |00⟩, |01⟩, |10⟩ and |11⟩, with wire 1 as the left digit. Three have eight, and ten have 1,024, one for every bit pattern the wires could print.

Now put |−⟩ on wire 1 and |+⟩ on wire 2. The amplitudes for 00, 01, 10 and 11 are 0.5, 0.5, −0.5 and −0.5. Each square is 0.25, so in this basis the pair is as random as two wires can be. Read 400 copies and expect about 100 of each.

Press H on both wires before the click. H turns |−⟩ into |1⟩ and |+⟩ into |0⟩, so every copy reads 10. The same pair is a blur in one basis and a certainty in another.

That H and click together is a reading in a second basis. A 0 means the wire was found as |+⟩, and a 1 means |−⟩. The chip still only tells 0 from 1, and the gate turns the question round to face it.

What it is not

It is not where the qubit secretly lives. A qubit in |+⟩ is not hiding a 0 or a 1. It gives a certain answer in one basis and a fair toss in this one.

Nor is it where the work happens. Gates mix the labels all through a circuit. This basis is where the input goes in and the answer comes out.

And it is not base 2. The labels are written in binary, so |101⟩ can be read as the number 5, but basis here means a set of states that can be told apart perfectly and that every other state is built from.

A reading in this basis is a measurement, and each label is written as a ket. The second basis is the |+⟩ state and the |−⟩ state, reached with the Hadamard gate. Which Measurement asks you to pick the right basis for a job.

Used in

Longer explanation: How to learn quantum computing

All the words