Gaussian elimination with back substitution

kristopher0123

New member
Joined
Sep 11, 2009
Messages
19
So...I don't even know where to start. I don't know what it is. Is there any chance anyone could give a step by step example? Here's an equation for it if you think you can help...

2x + 6y = 16
2x + 3y = 17

and (in case there's a difference between sizes of matrices)

x + y + z = -1
3x + 5y + 4z = 2
3x + 6y + 5z = 0

Thank you all so much!
 
Well, I don't know how to make a matrix in tex, nor can I figure it out! But here I'll try to explain:

So take your two equations

\(\displaystyle 2x + 6y = 16\)
\(\displaystyle 2x + 3y = 12\)

And make them into a matrix:

\(\displaystyle 2 \ \ 6 \ \ 16\)
\(\displaystyle 2 \ \ 3 \ \ 12\)

Now, multiply the first line by -1:

\(\displaystyle [2 \ \ 6 \ \ 16]*-1\)
\(\displaystyle 2 \ \ 3 \ \ 12\)

And add it to the second row:

\(\displaystyle 2 \ \ \ \ 6 \ \ \ \ 16\)
\(\displaystyle 0 \ \ -3 \ \ -4\)

Now, put your coefficients back in:

\(\displaystyle 2x + 6y = 16\)
\(\displaystyle -3y = -4\)

Now you see you can solve for y with the second equation, then use that value of y to solve for x in the first.

This same thing works for the 3 x 3, although with a bit more work. Try it out!

Hope this helps
 
Alright I got how to do it, but i cant seem to get the 3x4 matrix right. Every time I try, I get different answers for x and y. Here, I'll show you my work so far.

x + y + z = -1...................1 1 1 -1
3x + 5y + 4z = 2 --->...........3 5 4 2
3x + 6y + 5z = 0................3 6 5 0

R2-R3 (R=row) --->...........1 1 1 -1
.................................3 5 4 2
.................................0 -1 -1 2

3R1-R2--->.....................1 1 1 -1
..................................0 -2 -1 -5
..................................0 -1 -1 2

R2-2R3.........................1 1 1 -1
.................................0 -2 -1 -5
.................................0 0 1 -9 (z=-9)

R2+R1...........................1 -1 0 -6
..................................0 -2 -1 -5
..................................0 0 1 -9


-2y-1(-9)=-5
-2y+9=-5
-2y=-14
y=7

x+y+z=-1
x+7-9=-1
x-2=-1
x=3

unfortunately, this doesn't check out with the other equations. I've tried going through the matrices like...at least four different times, getting different answers each time, with none of them being correct. If you could show me my mistake, I would GREATLY apprectiate it. Thanks so much again, and sorry about any formatting issues...I have no idea how to make it all nice and neat like you guys lol...
 
Never mind. I'm an idiot...I mean, x-2=-1 definitly means x=3...not 1...wow hahahah. Alright I got it. Thanks again!
 
Top