Java Script Linear Algebra I
By Marcus Kazmierczak
|
|
What do you wish to calculate :
| |
|
Solution Matrix : | ||
The Mathematics Behind It
Let A represent our 3x3 Matrix.
| trace(A) | The trace of a matrix is simply the summation of its main diagonal. |
| det(A) | The determinant of a matrix is not quite as simple. For a n x n matrix the definition of the determinant is as follows :
In our 3x3 case it is a little easier, and boils down to :
|
| adj(A) | The adjoint of A is the matrix whose i, and jth element is the cofactor Aji of aji The cofactor of an element aij = (-1)i + j * det (A'). where A' is the matrix obtained from "omitting" the ith and jth rows. |
| inv(A) | The inverse of A is the matrix which when multiplied to A returns the identity matrix. The inverse was obtained using the Theorem : Aadj(A) = det(A)In Which when manipulated gives you : A-1 = (1 / det(A)) * adj(A) |
On To : Java Script Linear Algebra Page II
E-Mail : marcus@mkaz.com