liveBook · Manning

Quantum state

As explained in Quantum Programming in Depth

A quantum state is a mathematical representation of the physical condition of a quantum system, including the probabilities of measurement outcomes.

A quantum state is a mathematical description of a quantum system. In an n-qubit system, it can be written as |ψₙ⟩ = Σⱼ₌₀^(2ⁿ−1) aⱼ|j⟩ₙ, where each amplitude aⱼ describes a computational-basis component. The amplitudes must be normalized so that the total probability is one; state-preparation routines can also normalize supplied amplitudes. section 2.5 section 2.3

Working with quantum states requires keeping three representations aligned:

  • Basis states may be written with bit strings or integer labels. The conversion depends on endian convention, so array indexes and measurement results must use the same interpretation. section 2.3
  • Integer-based Dirac notation is compact for multiqubit states, but the number of qubits must remain explicit: |0⟩ may otherwise be ambiguous. section 2.5
  • Measurement returns a basis state, with each outcome occurring according to the square of its amplitude; it therefore reveals limited information about the complete state. section 4.9

Preparing and inspecting a two-qubit state

Start with two qubits in |00⟩ and an amplitude array [a₀, a₁, a₂, a₃]. A preparation routine targets |ψ₂⟩ = a₀|0⟩ + a₁|1⟩ + a₂|2⟩ + a₃|3⟩, normalizing the inputs when necessary. Implement the routine in Qiskit or Q#, run it repeatedly, and compare measured frequencies with the squared amplitudes. For deeper inspection, use multiple copies for quantum state tomography; use joint measurements when the goal is information about correlations rather than individual qubits. section 2.3 section 4.9 section 1.5

How Quantum Programming in Depth covers it

How deep it goes
Develops amplitude notation, normalization, encoding conventions, measurement probabilities, tomography, and joint measurements without deriving full physical foundations.
Examples
Demonstrates two-qubit and arbitrary n-qubit amplitude arrays, endian conversion, repeated measurements, tomography, and correlation-preserving joint measurements.
What you can do after
Builds quantum-state preparation routines and evaluates their measurement distributions in Qiskit or Q#.
How it connects
Connects quantum states to amplitudes, basis states, superposition, measurement, quantum state tomography, and joint measurements.

Also explained in

Compare how 2 books explain quantum state →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Quantum Programming in Depth. The section links point to the parts of the book it draws on.