- Fundamentals
- Also: parameterized quantum circuit
- Also: PQC
- Also: variational circuit
- Also: ansatz circuit
Parametric Circuit
A quantum circuit containing free parameters (typically rotation angles) that can be set or optimized at runtime, forming the basis of variational quantum algorithms and quantum machine learning.
A parametric circuit (also called a parameterized quantum circuit or PQC) is a quantum circuit in which some gate parameters, typically rotation angles, are left as free variables rather than fixed values. These parameters are adjusted by a classical optimizer to minimize a cost function, making parametric circuits the quantum component of all variational quantum algorithms. They serve the same role in quantum computing that neural network architectures serve in classical machine learning: a flexible function family whose parameters are trained to solve a specific problem.
Structure of a parametric circuit
A parametric circuit depends on a parameter vector . The circuit typically alternates between:
- Parameterized rotation layers: Single-qubit rotation gates (, , ) whose angles are the trainable parameters.
- Entangling layers: Fixed two-qubit gates (CNOT, CZ) that create entanglement between qubits.
A simple example on 3 qubits with one layer:
q0: ──Ry(θ₁)──●─────────
│
q1: ──Ry(θ₂)──X──●──────
│
q2: ──Ry(θ₃)─────X──────
Stacking multiple such layers increases the expressibility of the circuit (the range of quantum states it can produce) at the cost of increased circuit depth and more parameters to optimize.
The variational quantum algorithm pattern
Parametric circuits are the quantum ingredient in the variational quantum eigensolver (VQE), QAOA, and quantum machine learning models. The general workflow is:
- Prepare: Apply to an initial state to produce .
- Measure: Estimate the expectation value of a cost operator : .
- Optimize: A classical optimizer (COBYLA, L-BFGS-B, SPSA, Adam) updates to minimize .
- Repeat until convergence.
The quantum processor evaluates the cost function, and the classical computer navigates the parameter landscape. This hybrid approach is designed to extract value from NISQ devices that cannot run deep circuits reliably.
Gradient computation: the parameter shift rule
Computing gradients of quantum expectation values with respect to circuit parameters is essential for gradient-based optimization. The parameter shift rule provides an exact formula for gates of the form where has eigenvalues (which includes all Pauli rotation gates):
Each partial derivative requires two circuit evaluations with the parameter shifted by . For parameters, a full gradient costs circuit evaluations. This is analogous to numerical finite differences but gives exact gradients (up to shot noise) rather than approximations.
For gates with different eigenvalue spectra, generalized parameter shift rules exist with more shift terms.
Expressibility and trainability
Two key properties of parametric circuit design:
Expressibility: How much of the Hilbert space can the circuit access as parameters vary? A highly expressible circuit can approximate a wider range of quantum states. Random parametric circuits with sufficient depth become approximately 2-designs, meaning they can approximate the distribution of Haar-random unitaries. However, more expressibility is not always better; overly expressive circuits are harder to train.
Trainability: How easy is it to find good parameters? The barren plateau phenomenon poses a fundamental challenge: for sufficiently deep random parametric circuits on many qubits, the gradient of the cost function vanishes exponentially with the number of qubits. Specifically, for qubits, meaning the cost landscape becomes exponentially flat. This makes gradient-based optimization impractical for large, unstructured circuits.
Strategies to avoid barren plateaus include:
- Using shallow circuits with problem-specific structure (hardware-efficient ansatze, UCCSD for chemistry)
- Initializing parameters near a classically computed solution
- Using local cost functions rather than global ones
- Layer-wise training (training one layer at a time)
Common parametric circuit architectures
- Hardware-efficient ansatz: Alternating layers of arbitrary single-qubit rotations and entangling gates matching the hardware’s native connectivity. Easy to implement but prone to barren plateaus.
- UCCSD (Unitary Coupled Cluster): Chemistry-inspired ansatz used in VQE. Each parameter corresponds to a physically meaningful excitation operator. More structured, fewer barren plateau issues, but deeper circuits.
- QAOA ansatz: Alternating layers of problem Hamiltonian evolution and mixer evolution . Parameters are for layers.
Why it matters for learners
Parametric circuits are the workhorse of near-term quantum computing. Nearly every proposed NISQ application, from quantum chemistry to optimization to machine learning, uses parameterized circuits as its core computational primitive. Understanding their structure, how gradients are computed, and the barren plateau challenge is essential for anyone working with current quantum hardware. The interplay between circuit design (expressibility) and optimization landscape (trainability) is one of the central open problems in quantum computing research.