TITLE: Why is this method for solving linear equations systems using determinants works?
QUESTION [5 upvotes]: I'm new here and english is not my native language but I'll try to explain my question the best I can.
While studying methods for solving systems of linear equations I came across a method so called "Gauss algorithm" for which I doubt if it is it's real name or not, but I can't understand WHY it works.
I would really appreciate a proper explanation or maybe a hint for what is happening inside the method process that accounts for the logic behind it.
The process in question is the following and involves determinants:
Suppose we have the following system of linear equations, for instance
\begin{cases}
\ x+2y-z=-5 \\2x-1y+2z=8 \\3x+3y+4z=5 \
\end{cases}
Then the result of appliying the method continues as follow
\begin{array}{ccc|c}
x & y & z & i.t. \\
\hline
1 & 2 & -1 & -5 \\
2 & -1 & 2 & 8 \\
3 & 3 & 4 & 5 \\
\hline
 & -5 & 4 & 18 \\
 & -3 & 7 & 20 \\
\hline
 &  & -23 & -46 \\
\end{array}
Where for example the coefficients $-5$ and $4$, and the independent term $18$, of the first row of the reduced system has been computed with the follow determinants:
\begin{equation}
 \begin{vmatrix}
    1 & 2  \\
    2 & -1  \\
    \end{vmatrix}=-5
\hspace{1cm}
\begin{vmatrix}
    1 & -1  \\
    2 & 2  \\
    \end{vmatrix}=4
\hspace{1cm}
\begin{vmatrix}
    1 & -5  \\
    2 & 8  \\
    \end{vmatrix}=18
\end{equation}
Where those determinants were computed using the first and the second row of the system of equations matrix. Then the other coefficients -3 and 7 and the independant term 20 were found by computing the respective determinants as above but using the first and third row of the system of equations matrix.
Appliying this method and if the system is compatible, then as above you can see that \begin{equation} -23z = -46\\
z=2\end{equation}
and then by substitution in the subsequent former equations the other variables can be found.
Well that's the method I was studying and will appreciate to know more about it, it's a pity I don't know the name of it but maybe you can help.
Thanks in advance!

REPLY [4 votes]: The method is called Gauss elimination.
It works like this.
Consider some equations, and we only record some of the coefficients of them.
... [A] ... B ... | E
...  C  ... D ... | F

There are further lines not shown, and the data above sorresponds to something like
$$
\begin{aligned}
\dots +\boxed{a}x+\dots+bz &=e\ ,\\
\dots +cx+\dots+dz &=f\ ,
\end{aligned}
$$
Now we declare a value $a\ne 0$ under the coefficients to be the "pivot", and put it in a box.
The pivot line is divided imaginary by the pivot $a$, thus getting $\dots +x+\dots+(b/a)z =(e/a)$, and then used to eliminate all coefficients below (and in a total elimination also above) the pivot. So multiply the above equation by $-c$, and add this to the one involving $cx$ to eliminate $c$. One obtains, in the formal description, in the "next elimination block":
... [A] ...     B    ... |     E
...  0  ... D - BC/A ... | F - EC/A

and note that $D-BC/A$ is the determinant $AD-BC$ divided by the pivot $A$. This is the native Gauss elimination. Numerically, 
people tend to chose $A$ with maximal absolute value.
The above scheme uses a variation, all new rows are multiplied by the pivot.
So:
... [A] ...      B  ... |      E
...  0  ... AD - BC ... | AF - EC

This is it!

In our case, also always copying the pivot line:
$$
\begin{array}{ccc|c}
x & y & z & i.t. \\
\hline
\boxed1 & 2 & -1 & -5 \\
2 & -1 & 2 & 8 \\
3 & 3 & 4 & 5 \\
\hline
1 & 2 & -1 & -5 \\
 & \boxed{-5} & 4 & 18 \\
 & -3 & 7 & 20 \\
\hline
1 & 2 & -1 & -5 \\
 & -5 & 4 & 18 \\
 &  & \boxed{-23} & -46 \\
\end{array}
$$