I am stuck in this problem and I want to know if there's anything wrong in the approach. Along with the correct solution, kindly point out what is wrong in my approach!
Show that there are two values of k for which the equations, $$\begin{align} kx+3y+2z & =1 \\ x+(k-1)y& = 4 \\ 10y+3z& =-2\\ 2x-ky-z& =5 \end{align}$$ are consistent. Find their common solution for that value of k which is an integer.
My attempt
Writing the given system of equations in matrix form, \begin{align} \begin{bmatrix} k &3 &2 \\ 1 &k-1 &0 \\ 0 & 10 & 3\\ 2 & -k &-1 \end{bmatrix}\begin{bmatrix} x\\ y\\ z \end{bmatrix}& = \begin{bmatrix} 1\\ 4\\ -2\\ 5 \end{bmatrix} \\\\i.e., AX & = B \end{align}
Now we'll construct the augmented matrix A|B and reduce it to echelon form (to comapre rank later): \begin{align} \therefore A|B & = \begin{bmatrix} k &3 &2 &|1\\ 1 &k-1 &0 &|4\\ 0 & 10 & 3&|-2\\ 2 & -k &-1 &|5 \end{bmatrix} \\ \\R_{2} \mapsto R_{2}-\frac{R_{1}}{k} & = \begin{bmatrix} k &3 &2 &|1\\ 0 &k-1-\frac{3}{k} &\frac{-2}{k} &|4-\frac{1}{k}\\ 0 & 10 & 3&|-2\\ 2 & -k &-1 &|5 \end{bmatrix}= \begin{bmatrix} k &3 &2 &|1\\ 0 &\frac{k^{2}-k-3}{k} &\frac{-2}{k} &|\frac{4k-1}{k}\\ 0 & 10 & 3&|-2\\ 2 & -k &-1 &|5 \end{bmatrix} \\ \\R_{3} \mapsto R_{3}-\frac{10kR_{2}}{k^{2}-k-3} & = \begin{bmatrix} k &3 &2 &|1\\ 0 &\frac{k^{2}-k-3}{k} &\frac{-2}{k} &|\frac{4k-1}{k}\\ 0 & 0 & \frac{3k^{2}-3k+11}{k^{2}-k-3}&|\frac{-2k^{2}-38k+16}{k^{3}-k^2-3k}\\ 2 & -k &-1 &|5 \end{bmatrix} \\ \\R_{4} \mapsto R_{4}-\frac{2R_{1}}{k} & = \begin{bmatrix} k &3 &2 &|1\\ 0 &\frac{k^{2}-k-3}{k} &\frac{-2}{k} &|\frac{4k-1}{k}\\ 0 & 0 & \frac{3k^{2}-3k+11}{k^{2}-k-3}&|\frac{-2k^{2}-38k+16}{k^{3}-k^2-3k}\\ 0 & \frac{-k^{2}-6}{k} &\frac{-k-4}{k} &|\frac{5k-2}{k} \end{bmatrix} \end{align}
Now, how do I proceed from here. I want to check the condition that rank of A|B = rank of A for consistency. But even before that, for the matrix to be in echelon form, all the terms of last row have to be zero which is not possible for any k.
Correct answer is $k=3$ or $\frac{-1}{25}$
Source: This book.
As @xbh pointed out, the procedure needs to be continued two steps further and then equate the very last entry to 0. Unfortunately this leads to be a polynomial of k in 4th degree and there's probably a slip somewhere in the calculations.
Alternately, a necessary (although not sufficient) condition for consistency would be,
$$\begin{align*}\left |A|B \right | = 0 \\ \\ \begin{vmatrix} k & 3 & 2 & 1\\ 1 & k-1 & 0 & 4\\ 0 & 10 & 3 & -2\\ 2 & -k & -1 & 5 \end{vmatrix} = 0 \\ \\ 25k^{2}-74k-3 = 0 \\ \\ \therefore k = 3 \ \ or \ \ \frac{-1}{25} \end{align*} $$
We have to now put back each of these k in the system of equations to check that they're consistent indeed.
For the integer value of $k=3$, we get $x=2, y=1, z=-4$