Table of Contents

CCRy gate (Controlled-Controlled-RY)

CCRy applies Y rotation by $\theta$ to the target if both controls are $|1\rangle$. Parametric doubly-controlled rotation for variational algorithms.

Action: $|c_1 c_2 t\rangle \to |c_1 c_2 (R_Y(\theta)|t\rangle)\rangle$ where rotation is applied only when both controls are $|1\rangle$.

$$\text{CCRy}(\theta) = \begin{pmatrix} 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 1 & 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 1 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 0 & \cos(\theta/2) & -\sin(\theta/2) & 0 & 0 \\ 0 & 0 & 0 & 0 & \sin(\theta/2) & \cos(\theta/2) & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 0 & \cos(\theta/2) & -\sin(\theta/2) \\ 0 & 0 & 0 & 0 & 0 & 0 & \sin(\theta/2) & \cos(\theta/2) \end{pmatrix}$$

Properties

Uses

Decomposition

CCRy can be decomposed using CX and single-qubit rotations:

$$\text{CCRy}(\theta) = (I \otimes I \otimes R_Y(\theta/2)) \text{CNOT}_{12} \text{CNOT}_{02} (I \otimes I \otimes R_Y(\theta/2))$$

More efficient decompositions exist using fewer gates.

Implementation

Relations