# Clarification on Matrix Representation of a Quantum Gate

I came across a matrix representation in my quantum computing studies and I'm seeking clarification on its interpretation. The matrix I encountered is:

$$\left[\begin{matrix} 1 - i & 0 & 0 & 0\\ 0 & 1 + i & 0 & 0\\ 0 & 0 & 1 + i & 0\\ 0 & 0 & 0 & -1 - i \end{matrix}\right]$$

I suspect it might represent a controlled-Z gate, but I'm uncertain due to the presence of complex terms. Can someone confirm whether this matrix indeed corresponds to a controlled-Z gate? If not, what gate does it represent and how does it differ from the controlled-Z gate?

• Indeed a controlled-$Z$ seems a good starting point, just compute which other transformation you then still need! Commented Feb 29 at 12:58
• In particular following up on @JosBergervoet, (1) it's not normalized - what normalization factor would you need? (2) in the computational basis the CZ gate only has entries from $\{-1,0,1\}$ - so after normalization of your matrix can you divide out by a global phase? (3) after normalizing and mod'ing out by the global phase, does the action of your matrix leave $|00\rangle$ invariant (as the CZ matrix does) or does it still give a phase shift? Commented Feb 29 at 13:26
• If you factor out $1+i$, which can be ignored as it is a global phase, you are left almost with CZ gate. A problem is a phase change for state $|00\rangle$. Commented Feb 29 at 14:06