Question 163433
<pre><font size = 4 color = "indigo"><b>
In the Gauss-Jordan elimination, you start with a system
of three equations and three unknowns:

{{{system(a[11]x+a[12]y+a[13]z=c[1],
          a[21]x+a[22]y+a[23]z=c[2],
          a[31]x+a[32]y+a[33]z=c[3])}}}  

Then you convert it to this matrix:

{{{(  matrix(3,5, a[11],a[12],a[13],"|",c[1],a[21],a[22],a[23],"|",c[2],a[31],a[32],a[33],"|",c[3] ) )}}}

Then you use row operations and end up with a matrix like this:

{{{(  matrix(3,5, b[11],b[12],b[13],"|",d[1],0,b[22],b[23],"|",d[2],0,0,b[33],"|",d[3] ) )}}}

That is, you get 0's in the lower left three elements.

Then you convert back to a system of equations:

{{{system(b[11]x+b[12]y+b[13]z=d[1],
          b[22]y+b[23]z=d[2],
          b[33]z=d[3])}}}   

Then you do what is called "back-substitution":

1. Solve the bottom equation for z.
2. Substitute that value of z in the middle equation, 
   and solve for y.
3. Substitute the values of y and z in the top equation
   and solve for x.  

----------

{{{(matrix(3,5,7,5,-3,"|",16,3,-5,2,"|",-8,5,3,-7,"|",0))}}}

To get a 0 where the 3 is on the middle row:

Multiply the top row by -3 and the middle row by 7, and
add them together:

{{{(matrix(2,5,-21,-15,9,"|",-48,21,-35,14,"|",-56))}}}
--------------
{{{(matrix(1,5,0,-50,23,"|",-104))}}}

Replace the second row by that, leaving the rest as is

{{{(matrix(3,5,7,5,-3,"|",16,0,-50,23,"|",-104,5,3,-7,"|",0))}}}

To get a 0 where the 5 is on the bottom row:

Multiply the top row by -5 and the bottom row by 7, and
add them together:

{{{(matrix(2,5,-35,-25,15,"|",-80,35,21,-49,"|",0))}}}
--------------
{{{(matrix(1,5,0,-4,-34,"|",-80))}}}

Notice that as it turns out, we can divide that through
by -2, so we might as well do that too, and get:

{{{(matrix(1,5,0,2,17,"|",40))}}}

We replace the bottom row by that, leaving the rest as is

{{{(matrix(3,5,7,5,-3,"|",16,0,-50,23,"|",-104,0,2,17,"|",40))}}}

To get a 0 where the 2 is on the bottom row:

Take the middle row as it is. Multiply the bottom row by 25, and
add them together:

{{{(matrix(2,5,0,-50,23,"|",-104,0,50,425,"|",1000))}}}
--------------
{{{(matrix(1,5,0,0,448,"|",896))}}}

Notice that as it turns out, we can divide that through
by 448, so we might as well do that too, and get:

{{{(matrix(1,5,0,0,1,"|",2))}}}

We replace the bottom row by that, leaving the rest as is

{{{(matrix(3,5,7,5,-3,"|",16,0,-50,23,"|",-104,0,0,1,"|",2))}}}

Then we convert that back to this system of equations:

{{{system(7x+5y-3z=16,0x-50y+23z=-104,0x+0y+z=2)}}}

or rather,

{{{system(7x+5y-3z=16,-50y+23z=-104,z=2)}}}

Now we do what is called "back-substitution":

The bottom equation is already solved for z.

Substitute {{{z=2}}} in the middle equation:

{{{-50y+23z=-104}}}
{{{-50y+23(2)=-104}}}
{{{-50y+46=-104}}}
{{{-50y=-150}}}
{{{y=3}}}

Substitute {{{z=2}}} and {{{y=3}}} in the top
equation:

{{{7x+5y-3z=16}}}
{{{7x+5(3)-3(2)=16}}}
{{{7x+15-6=16}}}
{{{7x+9=16}}}
{{{7x=7}}}
{{{x=1}}}

So the solution is {{{matrix(1,15,"(" ,x ,"," ,y ,"," ,z ,")" ,"=" ,"(" ,1 ,"," ,3 ,"," ,2 ,")")}}} 

Edwin</pre>