Get AI summaries of any video or article — Sign up free
How Does a Quantum Computer Work? thumbnail

How Does a Quantum Computer Work?

Veritasium·
4 min read

Based on Veritasium's video on YouTube. If you like this content, support the original creators by watching, liking and subscribing to their content.

TL;DR

Qubits can exist in superposition, holding combinations of “0” and “1” until measurement.

Briefing

Quantum computers derive their potential advantage from qubits that can exist in superposition—being in combinations of “zero” and “one” at the same time—rather than committing to a single value like classical bits. That superposition, when multiple qubits interact, creates a state space that grows exponentially with the number of qubits, giving quantum systems access to an enormous number of possible configurations simultaneously. The payoff matters because it explains why quantum computing can outperform classical computing for certain problem types, even though it doesn’t make every task faster.

A concrete example comes from how qubits can be physically realized. Researchers have used the outermost electron in phosphorus as a qubit. Electrons behave like tiny bar magnets because they carry a property called spin, which can align with or oppose an external magnetic field. The “spin down” alignment corresponds to the lower-energy state (often treated as the zero state), while “spin up” is the higher-energy state (the one state), which requires energy to flip. Before measurement, however, the electron need not settle into either spin direction; quantum mechanics allows it to exist in a quantum superposition described by coefficients that encode the relative probabilities of measuring spin up or spin down.

The advantage becomes clearer when two qubits are considered. A classical two-bit system can represent four possible states—00, 01, 10, 11—but specifying which one you have requires only two bits of information. In contrast, a two-qubit quantum system can be placed into a superposition spanning all four basis states at once. Describing that quantum state requires four coefficients, reflecting the larger information content of the quantum state space. With three qubits, the number of basis states—and the number of coefficients needed to specify the state—grows to eight, following the rule that N qubits correspond to 2^N classical bits of equivalent information.

There’s a crucial catch: measurement collapses the superposition. When the qubits are measured, the system yields one of the basis states, and the detailed information about the pre-measurement superposition is lost. That means quantum algorithms must be engineered so that the computation’s intermediate superpositions evolve toward a final outcome that is both measurable and useful—typically a specific basis state such as a particular pattern of spins (e.g., down/down/up/up).

Finally, quantum computers aren’t universal speed boosters. Individual quantum operations may be slower than classical operations, and the benefit doesn’t come from faster per-step computation. Instead, quantum speedups come from reducing the total number of operations needed for specific algorithms by exploiting superposition and quantum “parallelism.” For tasks like watching high-definition video, browsing the internet, or doing routine documentation work, quantum hardware doesn’t automatically deliver improvements because those problems don’t map onto the special algorithmic structures that quantum mechanics accelerates.

Cornell Notes

Qubits differ from classical bits because they can exist in superposition, meaning they hold a combination of “0” and “1” until measurement. Using spin as an example, an electron in a magnetic field can be in spin down or spin up, but before measurement it can be in a superposition described by probability coefficients. With multiple qubits, the number of basis states—and the information needed to specify the quantum state—grows exponentially (N qubits correspond to 2^N classical bits of equivalent information). The catch is that measurement collapses the superposition, so quantum algorithms must be designed to steer the system toward a single, measurable basis state. Quantum computers therefore speed up only certain calculations, not every task.

Why does a qubit offer more than a classical bit?

A classical bit is either 0 or 1. A qubit can be in a quantum superposition of both states at once, represented by coefficients that determine the probabilities of measuring 0 (e.g., spin down) or 1 (spin up). This superposition is what enlarges the computational state space.

How can an electron’s spin act as a qubit?

Electrons have spin, which behaves like a tiny bar magnet aligning with an external magnetic field. In the lowest-energy alignment (“spin down”), the qubit corresponds to the zero state. Flipping to the higher-energy alignment (“spin up”) requires energy. Before measurement, the electron can exist in a superposition of spin up and spin down rather than choosing one.

What changes when two qubits are used instead of two classical bits?

A classical two-bit system has four possible states (00, 01, 10, 11), but identifying which one you have requires only two bits. A two-qubit quantum system can be in a superposition spanning all four basis states simultaneously, and specifying that quantum state requires four coefficients—reflecting a larger information capacity in the quantum state.

Why doesn’t superposition automatically make measurement reveal all the information?

Measurement collapses the superposition into one basis state. After measuring, only one outcome (like down/down or up/down patterns) is obtained, and the detailed pre-measurement superpositional information is lost. Quantum algorithms must therefore amplify the probability of the correct basis state while suppressing others.

Why aren’t quantum computers universally faster than classical computers?

Quantum speedups don’t come from making every operation faster; individual operations can be slower. The advantage is that certain algorithms require exponentially fewer total operations by leveraging superposition and quantum parallelism. For everyday tasks like video playback or web browsing, there’s no inherent quantum advantage because those problems don’t exploit the same algorithmic structure.

Review Questions

  1. How does the exponential growth of possible states with N qubits relate to the number of coefficients needed to describe a quantum state?
  2. What role does measurement collapse play in shaping how quantum algorithms must be designed?
  3. Why can a quantum computer reduce the total number of operations for some problems while still not being faster for every task?

Key Points

  1. 1

    Qubits can exist in superposition, holding combinations of “0” and “1” until measurement.

  2. 2

    Electron spin in a magnetic field can represent qubit states, with spin down as the lower-energy (zero) state and spin up as the higher-energy (one) state.

  3. 3

    The number of basis states for N qubits grows as 2^N, corresponding to an exponential increase in the information content of the quantum state.

  4. 4

    Measurement collapses superposition into a single basis state, destroying most of the pre-measurement information.

  5. 5

    Quantum algorithms must be engineered so that the final measurable outcome is a specific basis state rather than an unmeasurable superposition.

  6. 6

    Quantum computers are not universally faster; they can outperform classical systems only for particular algorithm classes where superposition reduces the total operation count.

Highlights

Spin-based qubits work because electrons align with or oppose a magnetic field, creating two energy states (spin down and spin up) that can be combined in superposition before measurement.
Two qubits can occupy a superposition of all four classical two-bit states, but describing that quantum state requires four coefficients rather than two bits.
The exponential information growth of N qubits (2^N) is real only in the pre-measurement state; measurement collapses it to one outcome.
Quantum speedups come from fewer total operations for specific problems, not from making every individual operation faster.
Quantum computers are best viewed as specialized accelerators for certain calculations, not replacements for classical computers.

Topics

  • Qubits and Superposition
  • Spin-Based Qubits
  • Quantum State Space
  • Measurement Collapse
  • Quantum Algorithm Speedups