📝 Worksheet← Lesson
BitWithBite
Linear Algebra · Quick Reference

Matrix Operations Cheat Sheet

Linear Algebra · Lesson 2/7
In one line: beyond simple addition, matrices can be multiplied together and even 'divided' through inverses — operations that power everything from computer graphics to solving systems of equations.

Key Ideas

1Matrix Multiplication Rule. To multiply A (m x n) by B (n x p), the number of columns in A must equal the number of rows in B; the result is an m x p matrix.
2How to Multiply Matrices. Each entry in the result is the sum of products of a row from A and a column from B (the 'dot product' of that row and column).
3Matrix Multiplication is NOT Commutative. In general, A*B does not equal B*A — order matters, unlike with ordinary numbers.
4Inverse of a Matrix (A^-1). A matrix that 'undoes' A, so that A * A^-1 = I (the identity matrix). Only square matrices with nonzero determinant have an inverse.
5Inverse of a 2x2 Matrix. For A=[[a,b],[c,d]], A^-1 = (1/det(A)) * [[d,-b],[-c,a]], where det(A) = ad-bc.

Worked Examples

Multiply [[1,2],[3,4]] by [[5,6],[7,8]].
[[19,22],[43,50]]
Find the inverse of [[2,1],[1,1]].
[[1,-1],[-1,2]]
Can the matrices [[1,2,3]] (1x3) and [[4,5]] (1x2) be multiplied as A*B?
No, this multiplication is not defined

Formulas

(A*B)_ij = sum over k of A_ik * B_kj
For A=[[a,b],[c,d]]: A^-1 = (1/(ad-bc)) * [[d,-b],[-c,a]]

Practice Yourself

Multiply [[1,0],[0,1]] by [[3,4],[5,6]].
[[3,4],[5,6]] (multiplying by identity leaves it unchanged)
Find the inverse of [[1,2],[3,4]].
det=-2, A^-1=[[-2,1],[1.5,-0.5]]
Is matrix multiplication commutative in general?
No