Basic operations on matrices
1Introduction
A
2Terms and definitions
A matrix is a rectangular array of numbers arranged in
For example,
is a matrix. A
3Strategy
For matrix operations, first check the size. Sums and differences are defined only for matrices of the same size, while scalar multiplication is defined for matrices of any size.
data/lecture/math/linear-algebra/vector-operations.lecture.n.md4Intuitive explanation
Adding matrices means adding entries in the same position. Like matching the same seat in two seating charts, only entries with the same row number and column number are paired.
Therefore matrices of different sizes do not have matching positions everywhere. This is why the operation is not defined.
5Addition and scalar multiplication
Let and be matrices of the same size . Then
For a scalar ,
Two matrices are equal only when they have the same size and all corresponding entries are equal.
6Worked example
Let
Then
A matrix and a matrix cannot be added because their positions do not correspond.
7Proof checkpoint: why same size is required
The entry is defined by pairing the entry of with the entry of . If one matrix lacks that position, the rule has no value to assign. The restriction is therefore part of the definition, not a cosmetic convention.
8Common misunderstandings
- Do not add matrices of different sizes because their entries look similar.
- A
row vector and a行 ぎょう ベクトルcolumn vector with the same number of components still have different sizes.列 れつ ベクトル - Square matrices are not the only matrices used in linear algebra; rectangular matrices are central for maps .
9Scope
Addition and scalar multiplication are entrywise. Matrix multiplication is not entrywise and needs its own definition.