if the matrix is a 3 x 3 it there is a simple way to solve...
a b c
D= d e f = aei + dhc +gbf - ceg-fha- idb. at least i think that's it^_^
g h i
please note this in only for a 3X3 matrix
dan
1 0 0 K1
0 1 0 k2
0 0 1 k3
3.) x - 3y -7z = 6
4x + y = 7
2x + 3y +z = 9
4.) 3x - 5z = -1
2x + 7y = 6
x + y + z = 5
... Help T_T this is trial & error probs ... so many, so complicated ... kindly teach me some tips in solving matrices?
No, for a larger matrix you use elementary row operations to row reduce it to echelon form. The complexity of this algorithm is , the complexity of using the determinant becomes larger not exactly sure.
What I am trying to say, is that for larger matrices using the determinant is not the most efficient way to do it.
To example, to find the inverse matrix using Gaussian elimination takes steps. To find the inverse using transposes and determinants takes ways thus for the first values we have,
1,8,27,64,125...
1,2,6,24,120,...
You can see it is more efficient using Gaussian elimination for matrices of dimension 5.
ive got an example in our discussion:
2x - y + 3z = 9
3x + y + +2z = 11
x - y + z = 2
A
( Add 2nd row to the 1st row)
2 -1 3 9
3 1 2 11
1 -1 1 2
B
(5 0 5 20) 1/5
3 1 2 11
1 -1 1 2
C
(Add row 2 by row 3)
1 0 1 4
3 1 2 11
1 -1 1 2
D
(Add 2nd row by 1st row)
(1 0 1 4) -2
3 1 2 11
4 0 3 13
E
( Add 3rd row by 1st row)
(1 0 1 4) -3
-1 1 0 3
4 0 3 13
F
(Add 3rd row by 1st row)
1 0 1 4
1 1 0 3
(1 0 0 1) -1
G
(Add 2nd row by 3rd row)
0 0 1 3
1 1 0 3
(1 0 0 1)-1
H
0 0 1 3
0 1 0 2
1 0 0 1
I
1 0 0 1 where x = 1
0 1 0 2 where y = 2
0 0 1 3 where z = 3
looks simple but complicated
Let me do it my way.
As I said, all you need is to reach a triangluar matrix. (A matrix with the bottom numbers zeros below the diagnol).
The augmented matrix is
[2 -1 3 | 9]
[3 1 2 | 11]
[1 -1 1 | 2]
Thus,
[1 -1 1 | 2]
[2 -1 3 | 9]
[3 1 2 | 11]
Thus,
[1 -1 1 |2]
[0 1 1 |5 ]
[0 4 -1| 5 ]
Thus,
[1 -1 1|2]
[0 1 1|5 ]
[0 0 -5| -15]
Thus,
[1 -1 1|2]
[0 1 1|5]
[0 0 1|3]
And stop right here, why? You will see, first note you got a triangular matrix.
The bottom line says,
z=3
The middle line says
y+z=5 thus y+3=5 thus y=2
The top line says,
x-y+z=2 thus x-2+3=2 thus x+1=2 thus x=1.
Finished!
You see how each line leads to a simple equation.
Doing it like this would say half your time.
This is my 24th post!!!
Stopping when the matrix is upper-triangular and then using back substitution
is fine if we just have the one equation to solve. But if we have a number of
right-hand sides (as we get if we are using Gaussian elimination to numerically
invert a matrix) it may be more efficient to go all the way and reduce the left-
hand side to an identity matrix.
It may be that this exercises is intended to illustrate the technique for
subsequent application in this manner, so if the original poster has been
asker to reduce the left-hand side to the identity matrix we should respect
that.
RonL