Skip to content

Commit

Permalink
added RX90 native gate and modified R method
Browse files Browse the repository at this point in the history
  • Loading branch information
ElStabilini committed Nov 20, 2024
1 parent eca774d commit 6a55047
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/qibolab/_core/native.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@ class SingleQubitNatives(NativeContainer):

RX: Optional[Native] = None
"""Pulse to drive the qubit from state 0 to state 1."""
RX90: Optional[Native] = None
"""Pulse to drive the qubit from state 0 to state +"""
RX12: Optional[Native] = None
"""Pulse to drive to qubit from state 1 to state 2."""
MZ: Optional[Native] = None
Expand All @@ -78,8 +80,11 @@ def R(self, theta: float = np.pi, phi: float = 0.0) -> PulseSequence:
``theta`` will be the angle of the rotation, while ``phi`` the angle that the rotation axis forms with x axis.
"""
assert self.RX is not None
return rotation(self.RX, theta, phi)
if self.RX90 != None:
return rotation(self.RX, 2 * theta, phi)
else:
assert self.RX is not None
return rotation(self.RX, theta, phi)


class TwoQubitNatives(NativeContainer):
Expand Down

0 comments on commit 6a55047

Please sign in to comment.