QKarma

Module 1 · Why Quantum + AI? · 20 min

What is a quantum computer?

You're reading a free preview lesson. Create an account and enroll to save progress, unlock every module and earn the certificate.

By the end of this lesson you will be able to

  • Contrast a classical bit with a qubit at an intuitive level
  • Explain why describing n qubits classically needs 2ⁿ numbers
  • Name the three quantum ingredients a quantum computer exploits — superposition, interference and entanglement
  • Correct the "it tries every answer in parallel" misconception

A quantum computer is a machine that processes information using the rules of quantum mechanics — the physics that governs atoms, electrons and photons. That sounds exotic, but the idea we will build on throughout this course is simple to state:

A quantum computer manipulates amplitudes — numbers that behave like probabilities but can be negative or even complex — and uses interference between them to make right answers likely and wrong answers unlikely.

This lesson gives you the big picture. Every idea here will be made precise, with full mathematics, in later modules.

Bits: the classical starting point

Every classical computer — your laptop, a phone, a GPU cluster — stores information in bits. A bit is always in exactly one of two states, which we label 0 and 1. Three bits are always in exactly one of 23=82^3 = 8 configurations, such as 101.

Even a random classical bit is simple to describe. A coin that is heads with probability pp and tails with probability 1−p1-p is fully described by the single number pp. For nn random bits, a full description is a probability for each of the 2n2^n configurations — but at any moment the physical bits are still in one configuration; the probabilities just describe our ignorance.

Qubits: the quantum version

A qubit (quantum bit) also has two special states, written ∣0⟩|0\rangle and ∣1⟩|1\rangle (read "ket zero" and "ket one"). But a qubit can also be in a superposition of them:

∣ψ⟩=α ∣0⟩+β ∣1⟩|\psi\rangle = \alpha\,|0\rangle + \beta\,|1\rangle

where α\alpha and β\beta are amplitudes. Two facts about amplitudes drive everything that follows:

  1. Measurement gives probabilities. When you measure the qubit you get 0 with probability ∣α∣2|\alpha|^2 and 1 with probability ∣β∣2|\beta|^2 (so ∣α∣2+∣β∣2=1|\alpha|^2 + |\beta|^2 = 1). This is the Born rule, which you will study in Module 3.
  2. Amplitudes can cancel. Unlike probabilities, amplitudes can be negative (or complex). When two computational paths lead to the same outcome, their amplitudes add — and a positive and a negative amplitude can cancel to zero. This is interference.

Why quantum states are expensive to describe

For nn qubits there is one amplitude for every nn-bit string, so a general state needs 2n2^n complex amplitudes:

∣ψ⟩=∑x∈{0,1}nαx ∣x⟩,∑x∣αx∣2=1.|\psi\rangle = \sum_{x \in \{0,1\}^n} \alpha_x\,|x\rangle, \qquad \sum_x |\alpha_x|^2 = 1.

Storing each amplitude as a double-precision complex number takes 16 bytes, so writing down the state of

QubitsAmplitudesMemory for the full state
101,02416 KB
30about 1.07 billion16 GiB
50about 1.13 × 10¹⁵16 PiB (about 18 PB)

Every additional qubit doubles the memory. This is the observation Feynman made in 1982: nature seems to "compute" with exponentially many amplitudes, so perhaps a computer built from quantum parts could simulate nature efficiently where classical computers cannot.

The "parallel universes" misconception

You will often read that a quantum computer "tries every possible answer at once". That is misleading. It is true that one operation can act on all 2n2^n amplitudes, but if you simply prepare an equal superposition of all answers and measure, you get a uniformly random answer — no better than guessing.

What a quantum algorithm actually does is:

  1. Prepare a superposition.
  2. Apply operations that make the amplitudes of wrong answers interfere destructively (cancel) and those of right answers interfere constructively (reinforce).
  3. Measure, obtaining a right answer with high probability.

This only works for problems with special structure that interference can exploit — which is why quantum computers are not faster at everything. The next lesson maps out where they help.

Knowledge check

Which statement best describes how a quantum algorithm gets its advantage?

Choose one answer

Three quantum ingredients

Throughout the course we will keep returning to three resources:

  • Superposition — a qubit's state is a combination of ∣0⟩|0\rangle and ∣1⟩|1\rangle with amplitudes.
  • Interference — amplitudes for the same outcome add, and can cancel or reinforce.
  • Entanglement — the joint state of several qubits can have correlations that cannot be described by giving each qubit its own state. You will meet entanglement properly in Module 5.

What the hardware looks like

A quantum computer is a physical device that holds qubits, applies controlled operations called gates to them, and measures them. Several technologies are competing, each with trade-offs:

TechnologyQubit is…Examples of companies
Superconducting circuitsa tiny electrical circuit cooled to about 10 millikelvinIBM, Google, Rigetti
Trapped ionsthe internal state of an individual charged atom held by electric fieldsQuantinuum, IonQ
Neutral atomsan atom held by focused laser beams ("optical tweezers")QuEra, Pasqal, Atom Computing
Photonicsproperties of individual particles of lightPsiQuantum, Xanadu
Spin qubitsthe spin of an electron in siliconIntel, Diraq

In this course you will run circuits on a simulator in your browser, on IBM's high-performance simulators, and on real IBM superconducting quantum processors.

Knowledge check

How many complex amplitudes are needed to describe a general state of 41 qubits?

Choose one answer

Summary

  • Classical bits are always in one definite configuration; qubits can be in superpositions described by amplitudes.
  • Measurement turns amplitudes into probabilities via the Born rule, P=∣amplitude∣2P = |\text{amplitude}|^2, and yields only one classical bit per qubit.
  • Describing nn qubits takes 2n2^n amplitudes, which is why quantum systems are hard to simulate classically.
  • Quantum algorithms win by interference, not by "trying everything" — so they help only for problems with the right structure.

References & further reading

  1. M. A. Nielsen & I. L. Chuang, Quantum Computation and Quantum Information, 10th Anniversary Ed., Cambridge University Press (2010) — Chapter 1 — the standard reference for this whole course
  2. R. P. Feynman, Simulating physics with computers, Int. J. Theor. Phys. 21, 467 (1982) — The original argument that quantum systems are hard to simulate classically
  3. S. Aaronson, The Limits of Quantum Computers, Scientific American 298(3), 62 (2008) — An accessible explanation of what quantum computers can and cannot do
  4. J. Preskill, Quantum Computing in the NISQ era and beyond, Quantum 2, 79 (2018)