Entangling Feature Maps

IQP Encoding

Instantaneous Quantum Polynomial circuits with provable classical hardness for sampling.

Qubits

4

Depth

6

Total Gates

52

Simulability

Not simulable

Mathematical Formulation

ψ(x)=[Hn(i,j)ZZ(xixj)iRZ(2xi)]reps+n|\psi(\mathbf{x})\rangle = \left[ H^{\otimes n} \cdot \prod_{(i,j)} ZZ(x_i x_j) \cdot \prod_i RZ(2x_i) \right]^{\text{reps}} |+\rangle^{\otimes n}

Description

IQP (Instantaneous Quantum Polynomial) encoding creates quantum states through cycles of Hadamard gates, single-qubit RZ phase gates, and two-qubit ZZ interaction gates. The circuit structure — diagonal unitaries sandwiched between Hadamard layers — is provably hard to simulate classically under standard complexity-theoretic assumptions.

Each layer applies three stages: (1) Hadamard gates create equal superposition, (2) single-qubit RZ(2x_i) gates encode individual features as phases, and (3) ZZ(x_i · x_j) gates encode pairwise feature interactions. The resulting state has equal amplitudes across all basis states but feature-dependent phases, making the quantum kernel k(x,x') = |⟨ψ(x)|ψ(x')⟩|² classically intractable to compute.

The entanglement topology (full, linear, or circular) controls the trade-off between expressibility and circuit cost. Full entanglement captures all O(n²) pairwise interactions but requires O(n²) CNOT gates per layer, while linear entanglement uses only O(n) gates.

Circuit Diagram

Property Radar

Properties

Qubits
4
Circuit Depth
6
Total Gates
52
Single-Qubit Gates
28
Two-Qubit Gates
24
Parameters
20
Entangling
Yes
Simulability
Not Simulable
Expressibility
Entanglement Capability
Trainability
0.70
Noise Resilience

Resource Scaling

How resource requirements grow with the number of input features.

FeaturesQubitsDepthGates2Q Gates
226144
4465224
886200112
16166784480

Code Examples

IQP encoding with PennyLane using full entanglement and 2 reps.

python
from encoding_atlas import IQPEncoding
import pennylane as qml
import numpy as np

enc = IQPEncoding(n_features=4, reps=2, entanglement="full")
dev = qml.device("default.qubit", wires=enc.n_qubits)

@qml.qnode(dev)
def circuit(x):
    enc.get_circuit(x, backend="pennylane")
    return qml.state()

x = np.array([0.1, 0.5, 1.2, 2.3])
state = circuit(x)

When to Use This Encoding

  • Quantum kernel methods (QSVM) with provable classical hardness
  • Quantum advantage benchmarking and demonstrations
  • Feature interaction modeling (captures pairwise x_i·x_j terms)
  • Variational quantum classifiers requiring expressive feature maps
  • Quantum reservoir computing

Pros & Cons

Advantages

  • Provably hard to simulate classically (polynomial hierarchy collapse argument)
  • High expressibility with entangled, phase-modulated states
  • Captures both individual and pairwise feature interactions
  • Flexible entanglement topologies (full, linear, circular)
  • Well-studied theoretical properties

Limitations

  • Full entanglement requires O(n²) CNOT gates per layer
  • Barren plateaus risk increases with repetitions
  • Not NISQ-friendly for large feature counts with full entanglement
  • Feature count limited to ~12 for practical use
  • Phase-only encoding — all basis states have equal amplitude

References

  1. [1]Havlíček, V., et al. (2019). Supervised learning with quantum-enhanced feature spaces. Nature, 567(7747), 209–212.
  2. [2]Bremner, M.J., Montanaro, A., & Shepherd, D.J. (2016). Average-case complexity versus approximate simulation of commuting quantum computations. Physical Review Letters, 117(8), 080501.
  3. [3]Shepherd, D. & Bremner, M.J. (2009). Temporally unstructured quantum computation. Proceedings of the Royal Society A, 465(2105), 1413–1439.