A matrix
is simply a grid of numbers. That's all. If you've ever used a
spreadsheet program, you've already met matrices in one form (matrices
is just the plural of matrix).
For example, here's a 3×3 matrix consisting of a few random
numbers that I just made up on the spot:
The above is an example of a square matrix,
that is, a matrix containing the same number of rows as columns. But
this doesn't have to be the case. For example, a 1×3 matrix
(that's 1 row, 3 columns) looks like the following:
(12, 64.1, 64)
Have you read the section on vectors
yet? If so, you might have noticed that the above, single row matrix,
looks just like a typical 3-dimensional vector. Guess what? It is a vector. Vectors are just single row
matrices!
(The above vector is written horizontally - that's generally how
vectors are written. But you can also write vectors vertically, as
single column matrices, in which case they're called column vectors.
The vector above is a row vector.)
What about a 1×1 matrix?
(6)
In this case, the brackets are unnecessary (the whole point of having
the brackets there is to group multiple numbers together - there's no
risk of a single number falling apart) and you can just write this as
6. Readers over the age of 2 months old will note that this looks just
like an ordinary number (a scalar,
if you've read the fundamentals
section). That's because it is!
So, you see, matrices are just a logical extension of the ordinary
scalar numbers you met when you first learned to count. Just as a
vector is a scalar extended into multiple dimensions, a matrix is a scalar extended
into multiple dimensions of multiple dimensions!