qml.ops.qubit.attributes.composable_rotations¶
-
composable_rotations
= {'CRX', 'CRY', 'CRZ', 'ControlledPhaseShift', 'IsingXX', 'IsingYY', 'IsingZZ', 'PhaseShift', 'RX', 'RY', 'RZ', 'Rot'}¶ Operations for which composing multiple copies of the operation results in an addition (or alternative accumulation) of parameters.
For example,
qml.RZ
is a composable rotation. Applyingqml.RZ(0.1, wires=0)
followed byqml.RZ(0.2, wires=0)
is equivalent to performing a single rotationqml.RZ(0.3, wires=0)
.An example for an alternative accumulation is the
qml.Rot
gate: although the three angles it takes do not fulfil the composable property, the gate implements a rotation around an axis by an effective angle which does.- Type
code/api/pennylane.ops.qubit.attributes.composable_rotations
Download Python script
Download Notebook
View on GitHub