this is the question I am referring to
I am sorry to ask such a question, can someone explain how are we able to make the new form of the operator A.
Thank you, any help would be great!
Quantum Computing Stack Exchange is a question and answer site for engineers, scientists, programmers, and computing professionals interested in quantum computing. It only takes a minute to sign up.
Sign up to join this communitythis is the question I am referring to
I am sorry to ask such a question, can someone explain how are we able to make the new form of the operator A.
Thank you, any help would be great!
If you mean how does the answer immediately state that $A=|1\rangle \langle 0|+|0\rangle \langle 1|$, the reason is because in the question, it tells us that $A|0\rangle = |1\rangle$ and $A|1\rangle = |0\rangle$
So we can see that we need two operators that perform these mappings:
$|1\rangle \langle 0|0\rangle = |1\rangle$ and $|0\rangle \langle 1|1\rangle=|0\rangle$
A far easier way, however, is simply taking what we know about the behaviour of A, and using the Identity operator along with the inner product function:
$$IAI=\sum_{i}|i\rangle \langle i|A\sum_{j}|j\rangle \langle j|=\sum_{i,j}|i\rangle \langle j|\langle i|A|j\rangle$$
This way, you can calculate the entries of A based on it's actions on the input and output states, along with the associated operator.