jcmgray / quimb

A python library for quantum information and many-body calculations including tensor networks.
http://quimb.readthedocs.io
Other
467 stars 107 forks source link

typo in Zsqrt #71

Closed trevor-vincent closed 3 years ago

trevor-vincent commented 3 years ago

In quimb/gen/operators.py we have a small typo:

def Zsqrt(**qu_opts):
    r"""Rz(pi / 2).
    .. math::
        Z^{\frac{1}{2}} =
        \frac{1}{\sqrt{2}}
        \begin{bmatrix}
        1 - i & 0 \\
        0 & 1 + i
        \end{bmatrix}
    """
    return Ry(math.pi / 2, **qu_opts)

Ry should be Rz here.

jcmgray commented 3 years ago

Well spotted! Thanks - fixed by 05ffb1a6.