Quantum Mechanics Primer

Essential quantum mechanics for understanding quantum reservoir computing: states, gates, measurement, density matrices, and open-system dynamics.

#Introduction

This primer covers the quantum mechanics you need before reading the QRC essay. It does not assume any prior physics background beyond basic linear algebra (vectors, matrices, complex numbers).

The goal is not a full quantum mechanics course. It is the minimum viable quantum toolkit for understanding how quantum systems serve as reservoirs: how states encode information, how dynamics process it, and how measurement extracts it.

Concepts Path
States & QubitsGates & CircuitsMeasurementOpen Dynamics

Each section builds on the last. Review cards appear after related sections to reinforce definitions and key equations.

#Classical vs Quantum

A classical bit is either 0 or 1. A qubit generalizes this: its state is a unit vector in a two-dimensional complex vector space.

ψ=α0+β1,α2+β2=1|\psi\rangle = \alpha|0\rangle + \beta|1\rangle, \qquad |\alpha|^2 + |\beta|^2 = 1

The notation |\cdot\rangle is called a “ket” in Dirac notation. The computational basis states are:

0=(10),1=(01)|0\rangle = \begin{pmatrix}1\\0\end{pmatrix}, \qquad |1\rangle = \begin{pmatrix}0\\1\end{pmatrix}

The complex coefficients α\alpha and β\beta are called probability amplitudes. They carry both magnitude (which determines measurement probabilities) and phase (which determines interference behavior).

A “bra” ψ\langle\psi| is the conjugate transpose of the ket. The inner product ϕψ\langle\phi|\psi\rangle gives the overlap between two states.

#The Bloch Sphere

Any single-qubit pure state can be parameterized as:

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

This maps to a point on the unit sphere in three dimensions. The angles θ\theta (polar) and ϕ\phi (azimuthal) have direct physical meaning: θ\theta controls how “close” the state is to 0|0\rangle vs 1|1\rangle, while ϕ\phi is the relative phase between the two components.

The Bloch SphereEvery pure single-qubit state maps to a point on the unit sphere.
|0⟩|1⟩xyz|ψ⟩θφ

Quantum gates correspond to rotations on the Bloch sphere. This geometric picture is the main intuition tool for understanding single-qubit transformations.

#Quantum Gates

Quantum gates are unitary matrices acting on qubit states. Unitarity (UU=IU^\dagger U = I) ensures that gates are reversible and preserve probability normalization.

#Pauli Gates

The three Pauli matrices are the fundamental single-qubit operations:

X=(0110),Y=(0ii0),Z=(1001)X = \begin{pmatrix}0&1\\1&0\end{pmatrix}, \quad Y = \begin{pmatrix}0&-i\\i&0\end{pmatrix}, \quad Z = \begin{pmatrix}1&0\\0&-1\end{pmatrix}

X is a bit flip, Z is a phase flip, and Y combines both. On the Bloch sphere, each Pauli gate is a 180° rotation about the corresponding axis. The Pauli operators also serve as observables for measurement, which is directly relevant to QRC feature extraction.

#Hadamard and Rotations

The Hadamard gate creates equal superpositions:

H=12(1111)H = \frac{1}{\sqrt{2}}\begin{pmatrix}1&1\\1&-1\end{pmatrix}

General single-qubit rotations about axis n^\hat{n} by angle θ\theta have the form:

Rn^(θ)=eiθn^σ/2=cosθ2Iisinθ2(n^σ)R_{\hat{n}}(\theta) = e^{-i\theta\hat{n}\cdot\vec{\sigma}/2} = \cos\frac{\theta}{2}\,I - i\sin\frac{\theta}{2}\,(\hat{n}\cdot\vec{\sigma})

where σ=(X,Y,Z)\vec{\sigma} = (X, Y, Z) is the vector of Pauli matrices. In QRC, rotation angles are often the control parameters modulated by classical input signals.

#Multi-Qubit Gates

The controlled-NOT (CNOT) gate flips the target qubit only when the control qubit is 1|1\rangle:

CNOT=00I+11X\text{CNOT} = |0\rangle\langle 0| \otimes I + |1\rangle\langle 1| \otimes X

Together with arbitrary single-qubit rotations, CNOT forms a universal gate set: any unitary on n qubits can be decomposed into single-qubit gates and CNOTs. This is a cornerstone result in quantum computing.

Quantum Circuit: Bell State PreparationA Hadamard gate followed by CNOT creates maximal entanglement from |00⟩.
|0⟩|0⟩H(|00⟩ + |11⟩) / √2

#Measurement

Measurement is the bridge from quantum to classical information. For a qubit in state ψ=α0+β1|\psi\rangle = \alpha|0\rangle + \beta|1\rangle, measuring in the computational basis yields:

P(0)=α2,P(1)=β2P(0) = |\alpha|^2, \qquad P(1) = |\beta|^2

This is the Born rule. After measurement, the state collapses to the observed outcome. The process is irreversible and probabilistic.

Measurement and CollapseA superposition state collapses to a definite outcome with Born-rule probabilities.
α|0⟩ + β|1⟩superpositionMeasurein Z basis|0⟩prob |α|²|1⟩prob |β|²

For a general observable O^\hat{O} (a Hermitian operator), the expectation value is:

O^=ψO^ψ\langle\hat{O}\rangle = \langle\psi|\hat{O}|\psi\rangle

In QRC, observables like the Pauli operators are measured on the reservoir state, and their expectation values become the classical feature vector fed to the readout layer.

#Density Matrices

A pure state ψ|\psi\rangle can also be written as a density matrix: ρ=ψψ\rho = |\psi\rangle\langle\psi|. But density matrices can also represent mixed states, which arise from:

  • Statistical ensembles (classical uncertainty about which state was prepared)
  • Tracing out part of an entangled system (the reduced state of a subsystem)
  • Decoherence from environmental interaction

A valid density matrix satisfies ρ0\rho \geq 0 (positive semi-definite) and Tr(ρ)=1\text{Tr}(\rho) = 1. Purity is measured by Tr(ρ2)\text{Tr}(\rho^2): equal to 1 for pure states, less than 1 for mixed.

ρpure=ψψ,Tr(ρpure2)=1\rho_{\text{pure}} = |\psi\rangle\langle\psi|, \quad \text{Tr}(\rho_{\text{pure}}^2) = 1
ρmixed=kpkψkψk,Tr(ρmixed2)<1\rho_{\text{mixed}} = \sum_k p_k |\psi_k\rangle\langle\psi_k|, \quad \text{Tr}(\rho_{\text{mixed}}^2) < 1

The expectation value formula generalizes naturally:

O^=Tr(O^ρ)\langle\hat{O}\rangle = \text{Tr}(\hat{O}\rho)

This is the central formula in QRC for extracting features from the quantum reservoir state. The partial trace operation, ρA=TrB(ρAB)\rho_A = \text{Tr}_B(\rho_{AB}), gives the reduced state of subsystem A, which is generally mixed even if the global state is pure.

Review: test your understanding
0/6 cards
Question
What is superposition, and how does it differ from a classical bit?
Question
What do the symbols |0⟩ and |1⟩ represent in Dirac notation?
Question
What does the Bloch sphere represent, and where do |0⟩ and |1⟩ sit on it?
Question
What do the Pauli X, Y, and Z gates do to a qubit?
Question
What does the Hadamard gate do, and why is it important?
Question
State the Born rule for a qubit in state |ψ⟩ = α|0⟩ + β|1⟩.

#Entanglement

A multi-qubit state is formed by the tensor product of individual qubit spaces. For two qubits, the basis is {00,01,10,11}\{|00\rangle, |01\rangle, |10\rangle, |11\rangle\}, spanning a four-dimensional Hilbert space.

A state is entangled if it cannot be written as a product of individual qubit states. The canonical examples are the Bell states:

Φ+=12(00+11)|\Phi^+\rangle = \frac{1}{\sqrt{2}}(|00\rangle + |11\rangle)
Φ=12(0011)|\Phi^-\rangle = \frac{1}{\sqrt{2}}(|00\rangle - |11\rangle)
Ψ+=12(01+10)|\Psi^+\rangle = \frac{1}{\sqrt{2}}(|01\rangle + |10\rangle)
Ψ=12(0110)|\Psi^-\rangle = \frac{1}{\sqrt{2}}(|01\rangle - |10\rangle)

In an entangled state, measuring one qubit instantly constrains the possible outcomes of the other. This is non-classical: no local hidden variable model can reproduce the correlations.

For QRC, entanglement is what makes n qubits produce correlations across a 2n-dimensional space. It enables richer feature dynamics than n independent qubits would provide.

#Quantum Dynamics

Closed quantum systems evolve according to the Schrödinger equation:

iddtψ(t)=H^(t)ψ(t)i\hbar\frac{d}{dt}|\psi(t)\rangle = \hat{H}(t)|\psi(t)\rangle

The Hamiltonian H^\hat{H} is a Hermitian operator that encodes the energy structure and interactions of the system. For a time-independent Hamiltonian, the solution is:

ψ(t)=eiH^t/ψ(0)=U(t)ψ(0)|\psi(t)\rangle = e^{-i\hat{H}t/\hbar}|\psi(0)\rangle = U(t)|\psi(0)\rangle

The evolution operator U(t)=eiH^t/U(t) = e^{-i\hat{H}t/\hbar} is unitary, so it preserves the norm of the state vector and is invertible. In density-matrix form:

ρ(t)=U(t)ρ(0)U(t)\rho(t) = U(t)\rho(0)U^\dagger(t)

In QRC, the Hamiltonian is the reservoir itself. Its structure determines what dynamical features the reservoir can produce. The time-dependent case H^(t)\hat{H}(t) is common in QRC, since classical inputs modulate Hamiltonian parameters at each time step.

#Open Quantum Systems

Real quantum hardware is never perfectly isolated. Environmental interactions cause decoherence (loss of quantum coherence) and dissipation (energy exchange with surroundings). The Lindblad master equation governs these processes:

dρdt=i[H^,ρ]+kγk(LkρLk12{LkLk,ρ})\frac{d\rho}{dt} = -\frac{i}{\hbar}[\hat{H}, \rho] + \sum_k \gamma_k \left( L_k \rho L_k^\dagger - \frac{1}{2}\{L_k^\dagger L_k, \rho\}\right)

The first term is coherent (Hamiltonian) evolution. The sum is the dissipator, where each LkL_k is a Lindblad (jump) operator describing a specific noise channel, and γk\gamma_k is its rate.

Common noise channels include:

  • Amplitude damping (L=γ01L = \sqrt{\gamma}\,|0\rangle\langle 1|) — energy relaxation
  • Dephasing (L=γ/2ZL = \sqrt{\gamma/2}\,Z) — loss of phase coherence
  • Depolarizing — uniform contraction toward the maximally mixed state
Open Quantum SystemThe system evolves under both coherent Hamiltonian dynamics and incoherent environment coupling.
System ρĤ drives unitary partEnvironment(thermal, photon loss...)LₖĤ(t)dρ/dt = −i[Ĥ,ρ] + Σₖ dissipator(Lₖ)Moderate noise → fading memory (useful for RC)

In QRC, noise is not purely destructive. Moderate decoherence can implement fading memory, helping the reservoir forget old inputs at a controlled rate. Too much noise destroys useful structure; too little can cause the reservoir to retain information indefinitely, violating the fading-memory property needed for temporal processing.

#Bridge to Reservoir Computing

Every concept in this primer maps directly to a QRC component:

  • The density matrix ρ\rho is the reservoir state, evolving in a 2n-dimensional space for n qubits.
  • The Hamiltonian H^(t)\hat{H}(t) drives the reservoir dynamics, with classical inputs modulating its parameters at each time step.
  • Lindblad operators LkL_k model hardware noise, which can serve as a natural fading-memory mechanism.
  • Expectation values Tr(O^kρ)\text{Tr}(\hat{O}_k\rho) extract classical features for the linear readout layer.

The exponentially large Hilbert space is the key resource: a few qubits can produce feature vectors of dimension far exceeding the physical qubit count, potentially enriching the readout's discrimination power.

With this foundation in place, you are ready to read the main QRC essay, where these quantum ingredients combine with the reservoir computing paradigm.

Review: test your understanding
0/8 cards
Question
What is a density matrix, and when is it needed instead of a ket?
Question
How do you compute an expectation value from a density matrix?
Question
What is a tensor product, and how does it relate to multi-qubit states?
Question
What are Bell states, and what makes them special?
Question
Write the time-dependent Schrödinger equation and explain each term.
Question
What is unitary evolution, and what property does it preserve?
Question
What is the Lindblad master equation, and when does it apply?
Question
How do the quantum concepts in this primer map to QRC components?