Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

delete erroneous note in XXMinusYY documentation (backport #13837) #13840

Merged
merged 1 commit into from
Feb 13, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 0 additions & 30 deletions qiskit/circuit/library/standard_gates/xx_minus_yy.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,36 +63,6 @@ class XXMinusYYGate(Gate):
0 & 0 & 1 & 0 \\
-i\sin\left(\rotationangle\right)e^{i\beta} & 0 & 0 & \cos\left(\rotationangle\right)
\end{pmatrix}

.. note::

In Qiskit's convention, higher qubit indices are more significant
(little endian convention). In the above example we apply the gate
on (q_0, q_1) which results in adding the (optional) phase defined
by :math:`\beta` on q_1. Instead, if we apply it on (q_1, q_0), the
phase is added on q_0. If :math:`\beta` is set to its default value
of :math:`0`, the gate is equivalent in big and little endian.

.. code-block:: text

┌───────────────┐
q_0: ┤1 ├
│ (XX-YY)(θ,β) │
q_1: ┤0 ├
└───────────────┘

.. math::

\newcommand{\rotationangle}{\frac{\theta}{2}}

R_{XX-YY}(\theta, \beta) q_1, q_0 =
RZ_0(\beta) \cdot \exp\left(-i \frac{\theta}{2} \frac{XX-YY}{2}\right) \cdot RZ_0(-\beta) =
\begin{pmatrix}
\cos\left(\rotationangle\right) & 0 & 0 & -i\sin\left(\rotationangle\right)e^{i\beta} \\
0 & 1 & 0 & 0 \\
0 & 0 & 1 & 0 \\
-i\sin\left(\rotationangle\right)e^{-i\beta} & 0 & 0 & \cos\left(\rotationangle\right)
\end{pmatrix}
"""

_standard_gate = StandardGate.XXMinusYYGate
Expand Down