# Does a fidelity of $\mathcal{F}(U_1|0\rangle, U_2|0\rangle)=1$ imply that $U_1=U_2$?

I'm now studying quantum ML and now studying about fidelity ($$\mathcal{F}$$).

To my knowledge, fidelity means the distance between two quantum states, $$\textit{i.e.,}$$ if $$\mathcal{F} ==1$$, then the two quantum states are identical.

From this, suppose initial quantum states $$|0\rangle$$ goes on arbitrary two unitary gates $$U_1$$ and $$U_2$$ ; and $$\mathcal{F}$$ of two outputs equals 1, $$\mathcal{F}(U_1|0\rangle, U_2|0\rangle)=1$$.

Then, can I tell $$U_1 =U_2$$? IF not, can I make it true with finite requiements?

I think you mean that if $$\mathcal{F}=1$$, the two states are identical.
Now to your question: is it true that $$\mathcal{F}(U_1|0\rangle,U_2|0\rangle)=0\implies U_1=U_2.$$ This is not true. You need more conditions! As a simply counter example, consider $$U_1=\left(\begin{array}{cc} 1 & 0 \\ 0 & 1 \end{array}\right),\qquad U_2=\left(\begin{array}{cc} 1 & 0 \\ 0 & -1 \end{array}\right).$$ These two unitaries have the same effect on the basis state $$|0\rangle$$. Thus, you also need to add to your list of requirements that you can make a similar statement for a complete basis of states. Even then it might not be enough: in my previous example, if you also tried the $$|1\rangle$$ state, you would also conclude that the outputs have fidelity 1, because fidelity doesn't see a global phase. In this case, you'd have to also test something like a $$|+\rangle$$ state.
In the case of a single qubit, it is sufficient to test two states which are neither parallel nor orthogonal. For a larger Hilbert space dimension ($$d$$), off the top of my head, you should require $$d$$ vectors, but you have to be careful with your choice of states to capture enough relative phase information. It is sufficient to select $$d-1$$ orthonormal vectors (this checks that, up to a relative phase, all but one of the columns of the unitaries are the same with respect to a particular orthonormal basis), and then a final one which has some support on all the previous ones and yet also completes the basis (checking the final column is correct, and the relative phases of the previous columns).
• Oh! In my experiment, I define identical unitaries $U_1, U_2$ and want to check the relativeness/closeness of these unitaries. I want to make $U_1$ and $U_2$ go far away although they are the same at the first time. Sep 2, 2022 at 1:28