Skip to content
What is a Qubit?

What is a Qubit?

January 1, 2025

A qubit (quantum bit) is the basic unit of quantum information. It generalizes the classical bit by allowing states that are not merely 0 or 1, but normalized vectors in a two-dimensional complex Hilbert space.

Classical bit vs quantum bit

A classical bit is in one of two definite states: 0 or 1. You can copy it arbitrarily and read it without disturbing it.

A qubit can be prepared in a superposition of 0\lvert 0 \rangle and 1\lvert 1 \rangle. You still obtain a classical outcome (0 or 1) when you measure in the computational basis, but the pre-measurement state carries more information in the amplitudes.

The no-cloning theorem means unknown qubit states cannot be copied perfectly. This is a structural difference from classical bits.

Mathematical representation (Dirac notation)

We write an arbitrary single-qubit pure state as a ket:

ψ=α0+β1,α,βC,α2+β2=1. \lvert \psi \rangle = \alpha \lvert 0 \rangle + \beta \lvert 1 \rangle, \quad \alpha, \beta \in \mathbb{C}, \quad \lvert \alpha \rvert^2 + \lvert \beta \rvert^2 = 1.

The bra ψ\langle \psi \rvert is the conjugate-transpose row vector. Inner products use the braket ϕψ\langle \phi \vert \psi \rangle.

Superposition

Superposition means α\alpha and β\beta can both be non-zero. A measurement in the computational basis yields:

  • outcome 0 with probability α2\lvert \alpha \rvert^2
  • outcome 1 with probability β2\lvert \beta \rvert^2

Even though only one outcome is observed, the quantum description before measurement is the full normalized vector ψ\lvert \psi \rangle.

Bloch sphere (introduction)

Up to a global phase, any pure single-qubit state can be written as

ψ=cosθ20+eiϕsinθ21, \lvert \psi \rangle = \cos\frac{\theta}{2}\,\lvert 0 \rangle + e^{i\phi}\sin\frac{\theta}{2}\,\lvert 1 \rangle,

with 0θπ0 \le \theta \le \pi and 0ϕ<2π0 \le \phi < 2\pi. The pair (θ,ϕ)(\theta, \phi) maps to a point on the Bloch sphere: a geometric picture of single-qubit pure states as points on a unit sphere.

The Bloch sphere is strictly a picture for one qubit in a pure state. Multi-qubit systems require higher-dimensional state spaces; you cannot represent an arbitrary two-qubit state on a single sphere.

Python / Qiskit example

The snippet below prepares a superposition with a Hadamard gate and prints the statevector (ideal noise-free simulation).

from qiskit import QuantumCircuit
from qiskit.quantum_info import Statevector

qc = QuantumCircuit(1)
qc.h(0)

psi = Statevector(qc)
print(psi)

You should obtain amplitudes consistent with +=12(0+1)\lvert + \rangle = \frac{1}{\sqrt{2}}(\lvert 0 \rangle + \lvert 1 \rangle) up to numerical formatting. To see random 0/1 outcomes from measurement, run the circuit on a simulator or device with shots after you add a measurement instruction.

If you are new to Qiskit, follow Install Qiskit first so your environment matches the imports used in later lessons.

Exercise

Thought question: Suppose you are given many copies of an unknown qubit state ψ\lvert \psi \rangle. Why is it impossible to learn α\alpha and β\beta perfectly from a single measurement on one copy? What kind of repeated experiment would let you estimate α2\lvert \alpha \rvert^2 and β2\lvert \beta \rvert^2?

Next

Continue with Superposition for more intuition before you formalize gates as matrices.