Computing Library › Quantum Logic Gates
Quantum Logic Gates

Controlled-Hadamard Gate (CH)

Conditionally places the target into an equal superposition, a controlled-U with U equal to the Hadamard.

Definition

The controlled-Hadamard gate CH applies the Hadamard H to the target when the control is |1⟩. Since H maps |0⟩ and |1⟩ to equal superpositions, CH lets a control decide whether the target becomes a superposition or stays in a basis state — useful for conditional branching of quantum walks and for preparing correlated superpositions.

Matrix

Kronos motion — thermal gate
CH (target block is H/√2)
10000100001/√21/√2001/√2-1/√2

Decomposition

Because H = RY(π/4)·Z·RY(-π/4) up to phase, CH can be written using the ABC pattern: CH = (I⊗RY(π/4))·CNOT·(I⊗RY(-π/4)), followed by suitable S/T corrections in some conventions. A common compilation uses two single-qubit rotations around one CNOT, since H is real.

python
import numpy as np
def ch():
    h = np.array([[1,1],[1,-1]])/np.sqrt(2)
    m = np.eye(4, dtype=complex)
    m[2:,2:] = h
    return m

Bell-state and W-state uses

CH appears in preparing certain multipartite entangled states. For example, W-state preparation on three qubits chains controlled rotations and CH-like conditional splits so that exactly one qubit is excited with balanced amplitudes.

As a member of the controlled-U family, CH is not a Clifford gate — H is Clifford, but conditioning it produces a non-Clifford two-qubit operation, so it must be synthesized from the native entangler and single-qubit rotations of the hardware.

See controlled-U for the general construction that produces CH as one instance.