Let $P_1 = \lbrace I, -I, iI, -iI, X, -X, iX, -iX, Y, -Y, iY, -iY, Z, -Z, iZ, -iZ\rbrace$. Let $P_n$ be the $n$-tensor fold of $P_1$. It is said that two operators either commute if $AB = BA$ or anti-commute if $AB = -BA$ for all $A,B \in P_n$.
Let us have $n=1$ and $A=I$ and $B=Y$, then we have:
\begin{align*} IY &\stackrel{\text{true}}{=} YI,\\ IY &\stackrel{\text{true}}{=} -YI. \end{align*}
In other words, $I$ and $Y$ both commute and anti-commute. I have also added a matlab code snippet for completeness.
I = [1 0; 0 1];
Y = [0 -i;i 0];
if isequal(I*Y,Y*I)
disp('commute')
end
if isequal(I*Y,-Y*I)
disp('ANTI-commute')
end
I am referring to Daniel Gottesman's PhD thesis.
What am I missing?
Edit: My Matlab code should run only one of the if statements (not both). It seems that my machine was caching the answers from previously. A restart of the program has fixed the issue.