# proof that the gate U is equivalent to the given circuit mathematically

I have solved this question by this, but can't able to get my mistake in it.

• Please do not post screenshots and photos, use LaTeX. – Martin Vesely Feb 6 at 8:22

To start with, you only know that $$e^{i\theta A/2}=\cos\frac{\theta}{2} I+i\sin\frac{\theta}{2} A$$ if $$A^2=I$$. Since your $$A^2\neq I$$, that doesn't work. (It does, however, work on the central $$2\times 2$$ block.) So, in your final matrix, you should end up with the top-left and bottom-right matrix elements being 1.
In fact, I'm pretty confident that what you've been asked to prove is not correct. I've convinced myself of this by working backwards -- supplying $$|00\rangle$$ to the output of both. $$U^\dagger(\theta)|00\rangle=|00\rangle$$ because $$|00\rangle$$ is an eigenstate of $$XY-YX$$. For the circuit, however, cNOT takes $$|00\rangle$$ to $$|00\rangle$$, and then the single-qubit unitaries convert it to $$|1\rangle(R_Y(-\theta)|0\rangle)$$, which is certainly not $$|00\rangle$$!