본문으로 바로 이동 / Skip to content
Contents/Matrices

[aᵢⱼ] · Matrices

A box that moves many numbers as one body — the matrix.

A snack shop has a sales table for two branches and a price sheet per menu item. Could you multiply the two tables — whole?

Read matrix entries and operations while preserving the roles of their positions.

Start with table rows, columns and multiplication.

Every rotation on screen and the heart of every AI — one multiplication.

Open the immersive version →

Position matters as much as the number

Imagine two shops selling apples and pears. Let rows represent shops and columns represent fruit types. A small table holds the sales counts, and a number's position tells us its role.

A rectangular arrangement of numbers is called a matrix. Keeping row and column order lets us distinguish the first shop's apples from the second shop's pears.

2 ×12243648=
Scalar multiplication multiplies every entry by the same scalar. Matrix multiplication uses another rule.

Multiplying a matrix by 2 doubles each entry: this is scalar multiplication. Adding two matrices of the same dimensions also combines corresponding positions.

Matrix multiplication is different from multiplying matching positions. Multiply corresponding entries of a row of the left matrix and a column of the right, then add them. The inner dimensions must match.

For example, two apples at 1000 won and three pears at 2000 won cost 2×1000+3×2000=8000 won. Matrix multiplication can bundle this same calculation for several shops.

Rather than memorize a box of numbers, first ask what its rows and columns represent. After calculating, read the position and units of the result too.

Read these symbols together

aᵢⱼ
The entry in row i and column j.
m × n
Matrix dimensions: m rows and n columns.
AB
The matrix product is defined when the column count of A matches the row count of B.
Continue to the definitions and formulas ↓

Pause and try it yourself

Make a prediction first. Change one input at a time and compare what happens with what you expected.

Yesterday's sales

TteokbokkiGimbap
Branch A3020
Branch B2040

Price sheet per menu item

PriceCost
Tteokbokki3,0001,000
Gimbap2,5001,500

How would you find Branch A's revenue?

What becomes easier when numbers are grouped?

A matrix is not a box of numbers — it is a box holding a motion.

The four numbers [[0,−1],[1,0]] look like a plain table. But multiply them against a shape and they become the action 'rotate 90°'. Because what's written down is an action, not a quantity, the order of multiplication starts to matter.

Most of an AI's 'thinking' is multiply-and-add.

One layer of a neural network is the product of a weight box and an input. It is the same multiply-and-add as the snack shop's revenue, repeated billions of times. That is why the GPU, the machine best at this product, became the heart of the AI era.

Set out rows and columns before calculating

Written in the language of mathematics, the move you practiced — lay the row flat, stand the column up, multiply and add — looks like this.

The birth of one cell of a matrix product — paired with the snack shop tables

=

Definition of the matrix product

The cell in row i, column j of the result is the i-th row of the first matrix laid flat against the j-th column of the second, multiplied pairwise and added. That is exactly what each tap did in stage 1.

Compressing simultaneous equations

The two lines 2x+y=5 and x+3y=10 become the single line Ax=b. With a million unknowns, the notation stays exactly the same.

The 90° rotation box

Column 1, (0, 1), is where î=(1,0) lands; column 2, (−1, 0), is where ĵ=(0,1) lands. Read the columns and the box tells you what motion it is.

The law of order

Matrix multiplication generally cannot be reordered. This is why rotate-first and stretch-first produced different shapes in stage 2.

Make one more distinction

Like numbers, matrices satisfy AB = BA.

Swapping the order of a matrix product can change the result. In stage 2, rotate-first and stretch-first arrive at different shapes. A matrix is a box holding a motion, and motions care about order.

A matrix is just a table of numbers, not something you calculate with.

The power of a matrix is that boxes can be multiplied. The moment you multiply, a table becomes a revenue calculator, a machine that moves shapes, a layer of a neural network. Once multiplication is defined, a matrix is not a table — it is an extension of number itself.

Where else can this idea help?

Game and movie graphics

Every scene where a character turns, grows, or tilts is coordinates multiplied by a matrix. A 3D game performs this product hundreds of millions of times per second.

One layer of a neural network

A single layer of an AI is a weight matrix times an input. The sentence you send to a chatbot also becomes a box of numbers and passes through this product.

A photo is a matrix of numbers

A digital photo is a huge matrix of pixel brightnesses. Blur, sharpen, and every other filter are calculations done on that matrix.

GPU — the matrix multiplication machine

The GPU, once a chip for game graphics, became the key part of the AI era for one reason: graphics and neural networks both spend their time on giant matrix products.

Explain it in your own words

A has rows (1,2) and (3,4). What is a₂₁?
With quantities (2,3) and unit prices (1000,2000), what is the total?
Compare with one possible explanation

Positions distinguish objects and units. Mixing their roles can pair quantities and prices incorrectly.

Check the idea with practice problems (4)

Questions completed 0 / 4

1. One cell of a matrix product: lay the row (2, 3) flat, stand the column (5, 1) up, multiply and add. What do you get?

2. For two matrices A and B, the products AB and BA are…

3. Where does the 90° rotation box [[0, −1], [1, 0]] send the point (1, 0)?

4. Writing 2x+y=5, x+3y=10 as Ax=b, what is the box A?

The idea to take with you

A matrix preserves positional meaning; each operation has its own dimension and pairing rules.

Open a question in another setting →

What question comes next?

Previous concept

{ }

Simultaneous Equations

The moment people wanted to compress many equations into one line, the matrix was born.

← Simultaneous Equations lab

Leads to next

AI

Neural Network

One layer of a neural network is one matrix product — onward to the heart of AI.

Go to the Neural Network lab →

Related lab

v⃗

Vector

A matrix's columns are vectors — the eye that reads where the basis arrows go.

Go to the Vector lab →

Related lab

∇

Gradient Descent

How an AI studies: repeating this matrix computation tens of thousands of times.

Go to the Gradient Descent lab →
Worksheet for your own explanation →