Skip to content

Added Rz gate (#290, QAE-1152)

Explanation of changes

Implemented Rz gate

  1. Added an Rz class in the gate_library.
    This is essentially a copy of the Rxy gate, except that instead of two parameters, theta and phi, there is only one theta. I also added a Z and Z90 class to the gate library which is an Rz where theta is fixed to 180 and 90.
  2. Added a pulse factory called phase_shift to generate a pulse_library.ShiftClockPhase object.
    This is the Rz gate in a transmon qubit.
  3. Added Rz referring to the phase_shift pulse factory in the config of a BasicTransmonElement.

Motivation of changes

The changes address issue #290 (closed), which stresses that there is no Hadamard gate in the gate library. In a transmon qubit, the Hadamard gate is a combination of two operations, a Y90 followed by a Z. However, there is no way to have a Hadamard gate that contains two sub-gates or operations within it. A pulse operation can have a list of pulses, but this is not true for a gate.

I implemented the Rz gate since it is useful in any case, and now it enables the user to combine the Y90 gate and the Z gate to implement a Hadamard on a transmon qubit.

Closes #290 (closed)


Merge checklist

See also merge request guidelines

  • Merge request has been reviewed (in-depth by a knowledgeable contributor), and is approved by a project maintainer.
  • New code is covered by unit tests (or N/A).
  • New code is documented and docstrings use numpydoc format (or N/A).
  • New functionality: considered making private instead of extending public API (or N/A).
  • Public API changed: added @deprecated (or N/A).
  • Tested on hardware (or N/A).
  • CHANGELOG.md and AUTHORS.md have been updated (or N/A).
  • Windows tests in CI pipeline pass (manually triggered by maintainers before merging).
    • Maintainers do not hit Auto-merge, we need to actively check as manual tests do not block pipeline

For reference, the issues workflow is described in the contribution guidelines.

Edited by Edgar Reehuis

Merge request reports

Loading