Intersection of 3 planes along a line I have three planes:
\begin{align*}
\pi_1: x+y+z&=2\\
\pi_2: x+ay+2z&=3\\
\pi_3: x+a^2y+4z&=3+a
\end{align*}
I want to determine a such that the three planes intersect along a line. I do this by setting up the system of equations:
$$
\begin{cases}
\begin{align*}
x+y+z&=2\\
x+ay+2z&=3\\
x+a^2y+4z&=3+a
\end{align*}
\end{cases}
$$
and solve for x, y and z. I subtract the first row from the second and third
$$
\begin{cases}
\begin{align*}
x+y+z&=2\\
(a-1)y+z&=1\\
(a^2-1)y+3z&=1+a.
\end{align*}
\end{cases}
$$
I subtract $(a+1)*\textrm{row}_1$ from the third row:
$$
\begin{cases}
\begin{align*}
x+y+z&=2\\
(a-1)y+z&=1\\
(2-a)z&=1+a.
\end{align*}
\end{cases}
$$
I think I am supposed to find an $a$ such that $0=0$ in the third row, but obviously there isn't any such $a$. Do I have the right idea about how to solve this? If so, where is my mistake?
 A: You mean subtract $(a+1)$ times the second row from the third row.
After that the system become 
$$x+y+z=2$$
$$(a-1)y+z=1$$
$$(2-a)z=0$$
If $a=2$, then we have $y+z=1$ and $x=1$ which is  a line.
If $a \ne 2$, then $z=0$, hence we have $(a-1)y=1$ and $x+y=2$, to be consistent, clearly $a \ne 1$, and we can solve for $y$ and $x$ uniquely.
Summary, $a=2$ for the solution to be a line.
A: You had the right idea. 
Of yourse, in this case, there was only one parameter, and even that appeared in the form of simple expressions ($a$ and $a^2$). With more complicated problems, I suggest you start in a different way. 
Compute the determinant of the matrix of coeeficients on the LHS: 
$$\det\begin{pmatrix} 1 & 1 & 1 \\ 1 & a & 2 \\ 1 & a^2 & 4 \\  \end{pmatrix} = 4a+2+a^2-2a^2-4-a= -a^2+3a-2$$
This is zero iff $a=2$ or $a=1$. These are the only values to check: if the determinant is nonzero, then the system has a unique solution, so the planes intersect in a single point.
A: Hint
See, that from your system of equations you can obtain two lines:
$$l_1:\begin{cases}x=(a-2)t+1\\y=t\\z=(1-a)t+1\end{cases}$$
$$l_2:\begin{cases}x=\frac{5-a}{3}+\frac{a^2-4}{3}t\\y=t\\z=\frac{a+1}{3}+\frac{1-a^2}{3}t\end{cases}$$
