TinyTools

Matrix Calculator

Matrix A (Row-Major)
Rows: 3
Cols: 3
OPERATIONS
Matrix B (Row-Major)
Rows: 3
Cols: 3

Calculation Result

2
0
0
0
2
0
0
0
2

Matrices & Notation

Matrix: A rectangular array of numbers arranged in rows and columns. Matrices are fundamental in linear algebra, physics, and computer graphics.

Standard (Row-Major): Data is stored and accessed row by row. This is the common convention in mathematics and most programming languages (C, Python).

OpenGL (Column-Major): Data is stored and accessed column by column. This convention is widely used in graphics APIs like OpenGL and WebGL for easier hardware optimization of transformations.

Operations & Theory

Addition & Subtraction

Performed entry-wise. Matrix A and B must have the exact same dimensions. Result = A[i,j] ± B[i,j].

Multiplication

The number of columns in A must equal the number of rows in B. The result is calculated by taking the dot product of rows from A and columns from B.

Determinant

A scalar value that can be computed from the elements of a square matrix. It indicates if a matrix is invertible (det ≠ 0).

Inverse

Available only for square matrices where Determinant ≠ 0. If A is inverse of B, then A × B = I (Identity Matrix).

Transpose

Flipping the matrix over its diagonal; the rows become columns and columns become rows.

Rank

The number of linearly independent rows or columns. It represents the dimension of the vector space spanned by its rows or columns.