fa55cbba85206eb4c738063c80f989eba3712947,cirq/ops/common_gates.py,,rx,#Any#,1329

Before Change



def rx(rads: value.TParamVal) -> XPowGate:
    Returns a gate with the matrix e^{-i X rads / 2}.
    pi = sympy.pi if protocols.is_parameterized(rads) else np.pi
    return XPowGate(exponent=rads / pi, global_shift=-0.5)


def ry(rads: value.TParamVal) -> YPowGate:

After Change



def rx(rads: value.TParamVal) -> Rx:
    Returns a gate with the matrix e^{-i X rads / 2}.
    return Rx(rads=rads)


def ry(rads: value.TParamVal) -> Ry:
    Returns a gate with the matrix e^{-i Y rads / 2}.
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: quantumlib/Cirq
Commit Name: fa55cbba85206eb4c738063c80f989eba3712947
Time: 2021-03-18
Author: tanujkhattar@google.com
File Name: cirq/ops/common_gates.py
Class Name:
Method Name: rx


Project Name: quantumlib/Cirq
Commit Name: fa55cbba85206eb4c738063c80f989eba3712947
Time: 2021-03-18
Author: tanujkhattar@google.com
File Name: cirq/ops/common_gates.py
Class Name:
Method Name: rz


Project Name: quantumlib/Cirq
Commit Name: fa55cbba85206eb4c738063c80f989eba3712947
Time: 2021-03-18
Author: tanujkhattar@google.com
File Name: cirq/ops/common_gates.py
Class Name:
Method Name: ry