[ 1 4 7 ] [ 4 2 -5 ] [ 7 -5 3 ]
[ 0 2 -9 ] [ -2 0 -7 ] [ 9 7 0 ]
[ 2 4 ] [ 1 3 ] [ 3 7 ] [ 5 6 ] + [ 2 2 ] = [ 7 8 ]
[ 5 8 ] [ 3 2 ] [ 2 6 ] [ 9 7 ] - [ 4 3 ] = [ 5 4 ]
2 * [ 1 3 ] = [ 2 6 ] [ 4 5 ] [ 8 10 ]
Matrix multiplication is performed by multiplying corresponding elements and then summing them up.
The number of columns in the first matrix should be equal to the number of rows in the second matrix.
Example:
[ 2 3 ] [ 1 3 4 ] [ 7 15 20 ] [ 4 1 ] * [ 2 -1 1 ] = [ 10 5 6 ] [ 3 2 3 ]
The product of two matrices is not commutative, i.e., AB ≠ BA in general.
The product matrix has dimensions equal to the number of rows in the first matrix and the number of columns in the second matrix.
det(A) = a(ei - fh) - b(di - fg) + c(dh - eg)
A^(-1) = (1/det(A)) * adj(A)
where adj(A) is the adjugate matrix[ 2 3 ] [ 1 3 ] [ 7 12 ] [ 4 1 ] * [ 2 2 ] = [ 12 6 ]
[ 0 2 ] [ 3 -1 ] [ 0 -6 ] [ -2 0 ] * [ 2 4 ] = [ 6 0 ]
A = [ 5 1 ] [ 1 3 ] The eigenvalues are λ₁ = 6 and λ₂ = 2. The eigenvectors are v₁ = [ 1 ] and v₂ = [ -1 ]. Thus, A can be diagonalized as A = PDP^(-1) = [ 1 -1 ][ 6 0 ][ 1 -1 ]^(-1) [ 1 1 ][ 0 2 ][ 1 1 ]
x₁ = det(A₁) / det(A), x₂ = det(A₂) / det(A), ... xₙ = det(Aₙ) / det(A)
where A₁, A₂, …, Aₙ are matrices obtained by replacing the corresponding column in A with b.