I have a matrix that looks like this:
\begin{array}{cccc|c} a & 1 & 0 & 0 & 1 \\ 1 & a & 0 & 0 & 2 \\ 0 & 0 & a & 2 & 1 \\ 0 & 0 & 2 & a & 1 \end{array}
I then proceeded to row reduce the matrix so it looks like this:
\begin{array}{cccc|c} 1 & 0 & 0 & 0 & a-2/a^2-1 \\ 0 & 1 & 0 & 0 & 2a-1/a^2-1 \\ 0 & 0 & 1 & 0 & 1/a+2 \\ 0 & 0 & 0 & 1 & 1/a+2 \end{array}
I need to determine the number of solutions for each $a$ (one, infinite or none).
I can clearly see that there are no solutions when a is either $1$, $-1$ or $2$ because than you would have a division by zero in atleast one of the expressions on the right hand side. But how do I know which $a$ will have an infinite number of solutions. I have never worked with matrices that have unknown coefficients so I have no idea if I am doing anything correctly here.
The original equation system looked like this:
$$ax+y+0+0=1$$ $$x+ay+0+0=2$$ $$0+0+az+2w=1$$ $$0+0+2z+aw=1$$
Maybe I am missing something really obvious. This looks like a very simple task...
Swap rows 1 and 2, and rows 2 and 4. You obtain an augmented matrix for which it's easier to apply pivot's method: \begin{align} \begin{bmatrix} 1&a&0&0&2\\a&1&0&0&1\\0&0&2&a&1\\0&0&a&2&1 \end{bmatrix}\rightsquigarrow \begin{bmatrix} 1&a&0&0&2\\0&1-a^2&0&0&1-2a\\0&0&2&a&1\\0&0&0&4-a^2&2-a \end{bmatrix} \end{align} Thus, if $a\ne \pm1,\pm2$, the matrix of the system and the augmented matrix have the same, maximal rank ($4$). This means there is exactly one solution.
If $a=\pm1$, the augmented matrix is $$\begin{bmatrix} 1&\pm1&0&0&2\\0& 0&0&0& \scriptstyle\begin{cases}-1\\3\end{cases}\\0&0&2&\pm1&1\\0&0&0&3& \scriptstyle\begin{cases}1\\3\end{cases} \end{bmatrix}$$ The second row shows there's no solution.
If $a=\pm2$, the augmented matrix is $$\begin{bmatrix} 1&\pm2&0&0&2\\0&-3&0&0& \scriptstyle\begin{cases}-3\\5\end{cases}\\0&0&2&\pm2&1\\ 0&0&0&0& \scriptstyle\begin{cases}0\\4\end{cases} \end{bmatrix}$$ The last row shows there is no solution if $a=2$ and is an affine subspace of dimension $1$ if $a=-2$, because both matrices have the same rank ($3$).