This is an old revision of the document!
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/syntax/header.php on line 56
Warning: Undefined array key "do" in /home/levene/public_html/w/mst10030/lib/plugins/revealjs/action.php on line 14
Table of Contents
Operations on matrices
We want to define operations on matrices: some (useful) ways of taking two matrices and making a new matrix.
Before we begin, a remark about $1\times 1$ matrices. These are of the form $[a_{11}]$ where $a_{11}$ is just a number. The square brackets $[\,]$ don't really matter here; they just keep the inside of a matrix in one place. So really: a $1\times 1$ matrix is just a number. This means that special cases of the operations we define will be operations on ordinary numbers. You should check that in the special case when all the matrices involved are $1\times 1$ matrices, the operations become the ordinary operations on numbers, so we are generalising the familiar operations (addition, subtraction, multiplication and so on) from numbers to matrices.
Matrix addition and subtraction
Definition of matrix addition
If $A$ and $B$ are matrices of the same size, then $A+B$ is defined to be the matrix with the same size as $A$ and $B$ so that the $(i,j)$ entry of $A+B$ is $a_{ij}+b_{ij}$, for every $i,j$.
If $A$ and $B$ are matrices of different sizes, then $A+B$ is undefined.
Example
\[ \begin{bmatrix}1&2&-2\\3&0&5\end{bmatrix}+\begin{bmatrix}-2&2&0\\1&1&1\end{bmatrix}=\begin{bmatrix}-1&4&-2\\4&1&6\end{bmatrix}.\]
Example
\[ \begin{bmatrix}1&2&-2\\3&0&5\end{bmatrix}+\begin{bmatrix}-2&2\\1&1\end{bmatrix}\text{ is undefined.}\]
Remarks
- For any matrices $A$ and $B$ with the same size: $A+B=B+A$. We say that matrix addition is commutative.
- For any matrices $A$, $B$ and $C$ with the same size: $(A+B)+C=A+(B+C)$. We say that matrix addition is associative.
Definition of the zero matrix
The $n\times m$ zero matrix is the $n\times m$ matrix so that every entry is $0$. We write this as $0_{n\times m}$. So \[ 0_{n\times m}=\begin{bmatrix} 0&0&\dots&0\\ 0&0&\dots&0\\ \vdots&\vdots&&\vdots\\ 0&0&\dots&0\end{bmatrix}\] where this matrix has $n$ rows and $m$ columns.
Exercise
Show that if $A$ is any $n\times m$ matrix, then \[ 0_{n\times m}+A=A=A+0_{n\times m}.\] Remember that when checking that matrices are equal, you have to check that they have the same size, and that all the entries are the same.
Definition of matrix subtraction
If $A$ and $B$ are matrices of the same size, then $A-B$ is defined to be the matrix with the same size as $A$ and $B$ so that the $(i,j)$ entry of $A-B$ is $a_{ij}-b_{ij}$, for every $i,j$.
If $A$ and $B$ are matrices of different sizes, then $A-B$ is undefined.
Example
\[ \begin{bmatrix}1&2&-2\\3&0&5\end{bmatrix}-\begin{bmatrix}-2&2&0\\1&1&1\end{bmatrix}=\begin{bmatrix}3&0&-2\\2&-1&4\end{bmatrix}.\]
Example
\[ \begin{bmatrix}1&2&-2\\3&0&5\end{bmatrix}-\begin{bmatrix}-2&2\\1&1\end{bmatrix}\text{ is undefined.}\]
Scalar multiplication
Definition of a scalar
In linear algebra, a scalar is just a fancy name for a number (in this course: a real number). The reason is that numbers are often used for scaling things up or down; for example, the scalar $3$ is often used to scale things up by a factor of $3$ (by multiplying by $3$).
Definition of scalar multiplication of matrices
If $c$ is a real number and $A$ is an $n\times m$ matrix, then we define the matrix $cA$ to be the $n\times m$ matrix given by multiplying every entry of $A$ by $c$. In other words, the $(i,j)$ entry of $cA$ is $ca_{i,j}$.
Example
If $A=\begin{bmatrix}1&0&-3\\3&-4&1\end{bmatrix}$, then $3A=\begin{bmatrix}3&0&-9\\9&-12&3\end{bmatrix}$. In other words, \[ 3\begin{bmatrix}1&0&-3\\3&-4&1\end{bmatrix}=\begin{bmatrix}3&0&-9\\9&-12&3\end{bmatrix}.\]
The negative of a matrix
We write $-A$ as a shorthand for $-1A$; so the $(i,j)$ entry of $-A$ is $-a_{ij}$. For example, \[ -\begin{bmatrix}-1&0&3\\3&-4&1\end{bmatrix}=\begin{bmatrix}1&0&-3\\-3&4&-1\end{bmatrix}.\]
Exercise
Prove that $A-B=A+(-B)$ for any matrices $A$ and $B$ of the same size.
Row-column multiplication
Definition of row-column multiplication
If $a=\begin{bmatrix}a_1&a_2&\dots&a_n\end{bmatrix}$ is a $1\times n$ row vector and $b=\begin{bmatrix}b_1\\b_2\\\vdots\\b_n\end{bmatrix}$ is an $n\times 1$ column vector, then the row-column product, or simply the product of $a$ and $b$ is defined to be \[ ab=\begin{bmatrix}a_1&a_2&\dots&a_n\end{bmatrix}\begin{bmatrix}b_1\\b_2\\\vdots\\b_n\end{bmatrix}=a_1b_1+a_2b_2+\dots+a_nb_n.\]
If we want to emphasize that we are multiplying in this way, we sometimes write $a\cdot b$ instead of $ab$.
The product $ab$ of a $1\times m$ row vector $a$ with an $n\times 1$ column vector $b$ is undefined if $m\ne n$.
Example
\[ \begin{bmatrix}1&2\end{bmatrix}\begin{bmatrix}3&-1\end{bmatrix}=1\cdots 3+2\cdot(-1)=3+(-2)=1.\]
