Having Problem With Kronecker and Outer Product

430 Views Asked by At

I'm having an issue with some outer & Kronecker products where I am doing two different processes which should result in the same answer, but I'm getting a different answer for each. Can anyone tell me where I'm going wrong?

I have the following:

$A = \begin{bmatrix}1\\0\end{bmatrix}$
$B = \begin{bmatrix}1\\0\end{bmatrix}$
$H = \begin{bmatrix}1&1\\1&-1\end{bmatrix}*\frac{1}{\sqrt{2}}$


The first process is: $Vec((H*A)\otimes B)$

$H*A = \begin{bmatrix}\frac{1}{\sqrt{2}}\\\frac{1}{\sqrt{2}}\end{bmatrix}$

Taking the outer product with the $B$ vector:

$\begin{bmatrix}\frac{1}{\sqrt{2}}\\\frac{1}{\sqrt{2}}\end{bmatrix} * \begin{bmatrix}1&0\end{bmatrix} = \begin{bmatrix}\frac{1}{\sqrt{2}}&0\\\frac{1}{\sqrt{2}}&0\end{bmatrix}$

Vectorizing that, we get:

$\begin{bmatrix}\frac{1}{\sqrt{2}}\\\frac{1}{\sqrt{2}}\\0\\0\end{bmatrix}$


The second process is: $(H\otimes I)*Vec(A\otimes B)$

$H\otimes I = \begin{bmatrix}1&0&1&0\\0&1&0&1\\1&0&-1&0\\0&1&0&-1\end{bmatrix}*\frac{1}{\sqrt{2}}$

$Vec(A\otimes B) = \begin{bmatrix}1\\0\\0\\0\end{bmatrix}$

Multiplying them together we get:

$\begin{bmatrix}\frac{1}{\sqrt{2}}\\0\\\frac{1}{\sqrt{2}}\\0\end{bmatrix}$

Can anyone see where I've mis-stepped? I'm pretty sure the second process comes up with the correct answer and that the first process is somehow incorrect.

I'm trying to do the first step to making a Bell state to give some context. The next step would be the CNOT gate.

Thanks!!

EDIT: It turns out that I'm having the same problem as this person was: Kronecker product and outer product confusion

1

There are 1 best solutions below

4
On BEST ANSWER

You said:

Taking the outer product with the B vector: $\begin{bmatrix}\frac{1}{\sqrt{2}}\\\frac{1}{\sqrt{2}}\end{bmatrix} \otimes \begin{bmatrix}1&0\end{bmatrix} = \begin{bmatrix}\frac{1}{\sqrt{2}}&0\\\frac{1}{\sqrt{2}}&0\end{bmatrix}$

But in your case $B=\begin{bmatrix}1\\ 0\end{bmatrix},$ so it should have been

$$\begin{bmatrix}\frac{1}{\sqrt{2}}\\\frac{1}{\sqrt{2}}\end{bmatrix} \otimes \begin{bmatrix}1\\ 0\end{bmatrix} = \begin{bmatrix}\frac{1}{\sqrt{2}}\\0\\\frac{1}{\sqrt{2}}\\0\end{bmatrix}.$$

Vectorization converts matrix to colum vector, but in your case $(H*A)\otimes B$ is already a vector, hence $Vec((H*A)\otimes B)=(H*A)\otimes B.$