![]() |
Returns a Cirq TwoQubitDiagonalGate for pyQuil's CPHASE10 gate.
cirq_rigetti.quil_input.cphase10(
phi: float
) -> TwoQubitDiagonalGate
In pyQuil, CPHASE10(phi) = diag(1, 1, [exp(1j * phi), 1]), and in Cirq, a TwoQubitDiagonalGate is specified by its diagonal in radians, which would be [0, 0, phi, 0].
Args | |
---|---|
phi
|
Gate parameter (in radians). |
Returns | |
---|---|
A TwoQubitDiagonalGate equivalent to a CPHASE10 gate of given angle. |