Quantum Mechanics Primer (for Computing)
Quantum Mechanics Primer (for Computing)
Section titled “Quantum Mechanics Primer (for Computing)”Summary
Section titled “Summary”Quantum computing is mostly linear algebra + probability, with a few quantum-specific rules. This note is the “minimum viable QM” you need for circuits, algorithms, and error correction.
States are vectors (kets)
Section titled “States are vectors (kets)”- A pure state is a normalized vector often written as a “ket” like
|ψ⟩in a complex Hilbert space. - For one qubit, a common basis is
|0⟩, |1⟩. - For
nqubits, the space dimension is2^n.
Superposition is linear combination
Section titled “Superposition is linear combination”You can write a state as
|ψ⟩ = Σ_x α_x |x⟩ with Σ_x |α_x|^2 = 1.
The α_x are amplitudes; probabilities come from squared magnitudes.
Global phase doesn’t matter (relative phase does)
Section titled “Global phase doesn’t matter (relative phase does)”|ψ⟩ande^{iθ}|ψ⟩represent the same physical state.- But phases between components (relative phase) affect interference.
Evolution (closed systems) is unitary
Section titled “Evolution (closed systems) is unitary”- Quantum gates are represented by unitary matrices
UwhereU† U = I. - Applying a gate updates the state:
|ψ'⟩ = U|ψ⟩.
Measurement = probabilities + state update
Section titled “Measurement = probabilities + state update”Measuring in the computational basis |0⟩, |1⟩:
- Outcome
0occurs with probability|⟨0|ψ⟩|^2 - Outcome
1occurs with probability|⟨1|ψ⟩|^2
After measurement, the post-measurement state is the normalized projection onto the observed outcome’s subspace.
Composite systems: tensor products
Section titled “Composite systems: tensor products”- Two qubits:
|ψ⟩ ⊗ |φ⟩(often written|ψ⟩|φ⟩). - Basis states:
|00⟩, |01⟩, |10⟩, |11⟩.
Entanglement
Section titled “Entanglement”A state is entangled if it cannot be written as a simple product state.
Example Bell state:
|Φ⁺⟩ = (|00⟩ + |11⟩) / √2
Measuring one qubit gives a correlated result in the other; importantly, this correlation can’t be reproduced by classical shared randomness for all measurement choices.
Interference
Section titled “Interference”Because amplitudes add, paths can cancel.
- If two computational paths lead to the same basis state with opposite phase, their amplitudes can cancel.
- Most quantum algorithms are “interference engines”: design (U) so the amplitude mass concentrates on good outcomes.
Mixed states and density matrices (why you care)
Section titled “Mixed states and density matrices (why you care)”Real devices interact with the environment → noise → you can’t assume a pure state.
- A mixed state is represented by a density matrix
ρ. - Pure state:
ρ = |ψ⟩⟨ψ| - Noise and measurement can be expressed as quantum channels (CPTP maps).
You’ll revisit this for error correction and benchmarking.
No-cloning (practically important)
Section titled “No-cloning (practically important)”There is no universal operation that takes an unknown |ψ⟩ and outputs |ψ⟩|ψ⟩ for all |ψ⟩. This is why:
- quantum “backup copies” don’t exist
- many classical fault-tolerance intuitions don’t transfer directly
References
Section titled “References”04-qubits-and-measurement.md(Bloch sphere + measurement intuition)