# What is $\vert 0 \rangle \otimes \vert + \rangle$?

A simple question that I cannot seem to figure-out why I cannot achieve the correct result. When I evaluate $$\vert 0 \rangle \otimes \vert + \rangle,$$ I end up with $$\begin{bmatrix}1\\0\end{bmatrix} \otimes \begin{bmatrix}\tfrac{1}{\sqrt{2}}\\\tfrac{1}{\sqrt{2}}\end{bmatrix} = \begin{bmatrix}1\begin{bmatrix}\tfrac{1}{\sqrt{2}}\\\tfrac{1}{\sqrt{2}}\end{bmatrix}\\0\begin{bmatrix}\tfrac{1}{\sqrt{2}}\\\tfrac{1}{\sqrt{2}}\end{bmatrix}\end{bmatrix} = \begin{bmatrix}\tfrac{1}{\sqrt{2}}\\\tfrac{1}{\sqrt{2}}\\0\\0\end{bmatrix},$$

where $$\vert 00 \rangle$$, $$\vert 01 \rangle$$, $$\vert 10 \rangle$$, $$\vert 11 \rangle$$ have $$50\%$$, $$50\%$$, $$0\%$$, $$0\%$$ probability to be measured, respectively.

The trivial circuit (if you even consider it a circuit) on algassert suggests that the probabilities when measured are $$\vert 00 \rangle = 50\%$$, $$\vert 01 \rangle = 0\%$$, $$\vert 10 \rangle = 50\%$$, and $$\vert 11 \rangle = 0\%$$.

Why is my solution doesn't align with algassert?

• Just note, you used a tag entanglement. There is nothing about entanglement by definition because your state is described by tensor product. This means that both states are separable and not entangled. Therefore, I removed the tag. – Martin Vesely Apr 10 at 21:52
• So given $\vert \psi \rangle = \vert 0 \rangle \oplus \vert + \rangle$, $\psi$ is referred to as separable state because it is achieved by using the tensor product of two subsystems? An entangled qubit is the one that cannot be composed of smaller subsystems, an example is one of the EPR pairs? – M. Al Jumaily Apr 11 at 8:25
• Yes, tensor product describe separable systems. EPR pair are entangled qubits, so they cannot be described by tesnor product of two qubits. – Martin Vesely Apr 11 at 8:28
• @MartinVesely out of curiosity, are there any other entangled qubits other than EPR pair? – M. Al Jumaily Apr 11 at 8:34
• @M.Ai Jumaily: EPR pair is created with Hadamard gate and CNOT. Any time you use controlled gate, entangled state is prepared. So their is many types of entanglement based on controlled gate you use. – Martin Vesely Apr 11 at 11:50

Your calculation of $$|0\rangle \otimes |+\rangle$$ is right. For now, forget about calculation and use simple logic. In your setting first qubit is always in state $$|0\rangle$$ and the second one is in equally distributed superposition of $$|0\rangle$$ and $$|1\rangle$$. Hence when you take both qubits together, only states $$|00\rangle$$ and $$|01\rangle$$ are possible and both have a probability 50 %.

There can be a problem with qubits ordering. In $$|0\rangle \otimes |+\rangle$$ we assume that $$|0\rangle$$ is the most signigicant qubit, hence it is writen first. However, you can also use another convention when $$|0\rangle$$ is the least significant qubit, hence it is writen on second place. In this setting you will get results $$|00\rangle$$ and $$|10\rangle$$ with a probability 50 % and others with zero percent probability.

• Thank you for this comment! I would have never thought the convention they are using is being used practically. Would it be possible to change their convention to the one I am using? I might be looking for some "clever gate" where I apply it first before starting my circuit and it will achieve my desire? – M. Al Jumaily Apr 11 at 8:21
• @M.AlJumaily: You can apply swap gate to change the ordering. In case you have more qubits, apply swap gate on first and last qubit, then second and last but one qubit etc. – Martin Vesely Apr 11 at 8:26
• and your approach will not have any other consequences even with qubits in superposition? – M. Al Jumaily Apr 11 at 8:33
• there is a reverse gate in toolbox 2 that if you extend it to all the qubits, it will use the notation I used. Your approach did work as well! – M. Al Jumaily Apr 11 at 8:51
• It should be mentioned that it will swap the local wire states as well. So, use the reverse gate only when looking at the probability display. – M. Al Jumaily Apr 11 at 8:59

It appears to me that the algassert output actually agrees with your (correct) math, and that you're simply misreading it. If you read the "Final amplitudes" left to right, it says that you have $$50\%$$ each of getting $$\vert 00 \rangle$$ or $$\vert 01 \rangle$$, and $$0\%$$ of measuring $$\vert 10 \rangle$$ or $$\vert 11 \rangle$$.

• It still gives me 00 and 10. – M. Al Jumaily Apr 11 at 6:09
• But it's only a difference in convention. If you want to go with the convention used in algassert, just swap your qubits. (The way you have the circuit set up, you have $\vert + \rangle \otimes \vert 0 \rangle$ rather than $\vert 0 \rangle \otimes \vert + \rangle$. Your $\vert 0 \rangle$ is the most significant bit and should go on the lower wire.) – dlyongemallo Apr 11 at 11:54