Difference between revisions of "Matrix multiplication"

From MathTank
Jump to navigation Jump to search
m
m
Line 1: Line 1:
We start with a simple example showing a practical use of multiplying a matrix by numbers (scalars). Below is an example of a distance matrix between three cities:
+
We start with a simple example showing a practical use of multiplying a matrix by numbers (scalars). Below is an example of a distance matrix between three cities in kilometers:
 
[[File:Distance matrix.png|alt=Distance matrix|thumb|Distance matrix]]
 
[[File:Distance matrix.png|alt=Distance matrix|thumb|Distance matrix]]
 +
 +
<math> A =\begin{bmatrix}
 +
0 & 340 & 360 \\
 +
340 & 0 & 450 \\
 +
360 & 450 & 360
 +
\end{bmatrix}
 +
 +
We can multiply this matrix by <math> 0.62 </math> to (approximately) convert it to distances in miles:
 +
 +
<math> B =0.62\cdot A \begin{bmatrix}
 +
0.62 \cdot 0 & 0.62\cdot 340 &  0.62 \dot 360 \\
 +
0.62 \cdot 340 & 0.62\cdot  0 & 0.62\cdot 450 \\
 +
0.62 \cdot 360 & 0.62\cdot 450 & 0.62\cdot 360
 +
\end{bmatrix} = \begin{bmatrix}
 +
0.62 \cdot 0 & 0.62\cdot 340 &  0.62 \dot 360 \\
 +
0.62 \cdot 340 & 0.62\cdot  0 & 0.62\cdot 450 \\
 +
0.62 \cdot 360 & 0.62\cdot 450 & 0.62\cdot 360
 +
\end{bmatrix}</math>

Revision as of 21:19, 27 November 2021

We start with a simple example showing a practical use of multiplying a matrix by numbers (scalars). Below is an example of a distance matrix between three cities in kilometers:

Distance matrix
Distance matrix

[math]\displaystyle{ A =\begin{bmatrix} 0 & 340 & 360 \\ 340 & 0 & 450 \\ 360 & 450 & 360 \end{bmatrix} We can multiply this matrix by \lt math\gt 0.62 }[/math] to (approximately) convert it to distances in miles:

[math]\displaystyle{ B =0.62\cdot A \begin{bmatrix} 0.62 \cdot 0 & 0.62\cdot 340 & 0.62 \dot 360 \\ 0.62 \cdot 340 & 0.62\cdot 0 & 0.62\cdot 450 \\ 0.62 \cdot 360 & 0.62\cdot 450 & 0.62\cdot 360 \end{bmatrix} = \begin{bmatrix} 0.62 \cdot 0 & 0.62\cdot 340 & 0.62 \dot 360 \\ 0.62 \cdot 340 & 0.62\cdot 0 & 0.62\cdot 450 \\ 0.62 \cdot 360 & 0.62\cdot 450 & 0.62\cdot 360 \end{bmatrix} }[/math]