Matrix MultiplicationCalculator
Matrix A size: x
Matrix B size: x
Answer
How to use this Matrix Multiplication Calculator 🤔
Follow these steps to perform Matrix Multiplication for the given matrices.
- Enter the matrix size for matrix A, and matrix B.
- Based on the given matrix size, a matrix of input fields appears. Enter the matrix elements.
- As and when you complete entering the matrix elements, Matrix Multiplication is calculated, and displayed in the answer section.
Matrix Multiplication
Matrix multiplication is the process of multiplying two matrices by taking the dot product of rows and columns. This operation is only possible when the number of columns in the first matrix is equal to the number of rows in the second matrix.
Given two matrices A and B, their product C = A * B is computed as:
C[i][j] = \sum_{k=1}^{n} A[i][k] * B[k][j]
where 1 ≤ i ≤ m, 1 ≤ j ≤ p, and n is the number of columns in A and rows in B.
Example 1
Let's multiply the following two matrices:
\( A = \begin{bmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{bmatrix} \)
\( B = \begin{bmatrix} 7 & 8 \\ 9 & 10 \\ 11 & 12 \end{bmatrix} \)
The product of A and B is:
\( C = A * B = \begin{bmatrix} 1*7 + 2*9 + 3*11 & 1*8 + 2*10 + 3*12 \\ 4*7 + 5*9 + 6*11 & 4*8 + 5*10 + 6*12 \end{bmatrix} = \begin{bmatrix} 58 & 64 \\ 139 & 154 \end{bmatrix} \)
Example 2
Consider another example with different matrices:
\( A = \begin{bmatrix} 2 & 4 \\ 6 & 8 \end{bmatrix} \)
\( B = \begin{bmatrix} 1 & 3 \\ 5 & 7 \end{bmatrix} \)
The product of A and B is:
\( C = A * B = \begin{bmatrix} 2*1 + 4*5 & 2*3 + 4*7 \\ 6*1 + 8*5 & 6*3 + 8*7 \end{bmatrix} = \begin{bmatrix} 22 & 34 \\ 46 & 74 \end{bmatrix} \)
These examples demonstrate the basic process of matrix multiplication by taking the dot product of rows and columns to get the resultant matrix.