What is a Quantum Circuit?
Track: Quantum Gates & Circuits · Difficulty: Beginner · Est: 12 min
What is a Quantum Circuit?
Overview
A quantum gate is a single state transformation. A quantum circuit is how we turn gates into a computation:
- a sequence of gates applied over time,
- followed by measurement that produces classical outputs.
This page is essential because it formalizes “doing computation” without jumping into any particular algorithm. Once you understand circuits as structured composition, you can reason about any quantum program.
Intuition
Think of the computation as happening in stages:
- Initialize qubits in a known state (often for each qubit).
- Evolve the joint state using gates (single- and multi-qubit).
- Measure some qubits to obtain classical results.
A circuit is just a clear way to describe step (2).
The most important intuition is that a circuit is not “many little measurements.” It is one coherent evolution made of smaller pieces. Until you measure, the state stays quantum and can include superposition and entanglement.
You can think of the state as a vector that changes step-by-step:
Each is a gate (more precisely, a unitary operator) acting on one or more qubits.
Formal Description
A quantum circuit on qubits is a finite list of gates
where each is a unitary operator acting on the -dimensional state space (often by acting non-trivially on only a few qubits and as identity on the rest).
Composition order (what changes to the state)
If the initial state is , then applying the circuit produces
Explanation of the notation:
- is the starting joint state of all qubits.
- acts first, producing .
- acts next, and so on.
- The gate written closest to the state acts first.
This “rightmost gate acts first” convention is standard in linear algebra.
Circuit vs gate
- A gate is one operator ().
- A circuit is a composition of many operators ().
So a circuit itself corresponds to one overall operator:
Measurement is then applied to to produce classical outcomes.
Worked Example
Consider a 2-qubit computation:
- Start with
- Apply H to the first qubit:
- Apply CNOT with the first qubit as control and second as target:
Interpretation:
- The circuit took a simple initial product state and produced an entangled Bell state.
- Nothing was measured yet; the whole process is coherent evolution.
If you measure both qubits in the computational basis at the end, you see correlated outcomes (00 or 11 with probability 1/2 each).
Turtle Tip
When reading a circuit, don’t try to “guess the final answer” immediately. Track the state step-by-step: apply one gate, simplify, then move on.
Common Pitfalls
- Don’t confuse the order of gates in algebra vs diagrams: algebra often reads right-to-left, while diagrams are usually drawn left-to-right in time.
- Don’t assume a circuit “does something classical” before measurement. Intermediate steps are quantum state evolution.
Quick Check
- In the expression , which gate acts first?
- In one sentence: what is the difference between a gate and a circuit?
What’s Next
Now that you know what a circuit is, we need a visual language to draw them. Next we introduce circuit diagrams and notation: wires, gate symbols, controlled gates, and measurement symbols (conceptually).
