-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmatrices.html
More file actions
80 lines (76 loc) · 3.09 KB
/
matrices.html
File metadata and controls
80 lines (76 loc) · 3.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
<html style="height: 100%;"><head>
<title>Matrices</title>
<body style="position: relative; min-height: 100%; top: 0px;">
<h1 align="center"><font color="red">Matrices</font></h1>
<p>A Matrix is an array of numbers.</p>
<p>There are many things we can do with them ...</p>
<h2>Adding</h2>
<p>To add two matrices: add the numbers in the matching positions:</p>
<p align="center"><img src="matrix-addition.gif" alt="Matrix Addition" width="384" height="119"></p>
<div class="simple">
<div align="center">These are the calculations: </div>
<table align="center">
<tbody><tr align="center">
<td>3+4=7</td>
<td>8+0=8</td>
</tr>
<tr align="center">
<td>4+1=5</td>
<td>6-9=-3</td>
</tr>
</tbody></table>
</div>
<p>The two matrices must be the same size, i.e. the rows must match in size, and the columns must match in size.</p>
<div class="example">
<p>Example: a matrix with <b>3 rows</b> and <b>5 columns</b> can be added to another matrix of <b>3 rows</b> and <b>5 columns</b>. But it could not be added to a matrix with <b>3 rows</b> and <b>4 columns</b> (the columns don't match in size)</p>
</div>
<h2>Negative</h2>
<p>The negative of a matrix is also simple:</p>
<p align="center"><img src="matrix-negative.gif" alt="Matrix Negative" width="279" height="111"></p>
<div class="simple">
<div align="center">These are the calculations: </div>
<table align="center">
<tbody><tr align="center">
<td>-(2)=-2</td>
<td>-(-4)=+4</td>
</tr>
<tr align="center">
<td>-(7)=-7</td>
<td>-(10)=-10</td>
</tr>
</tbody></table>
</div>
<h2>Subtracting</h2>
<p>To subtract two matrices: subtract the numbers in the matching positions:</p>
<p align="center"><img src="matrix-subtraction.gif" alt="Matrix Subtraction" width="383" height="115"></p>
<div class="simple">
<div align="center">These are the calculations: </div>
<table align="center">
<tbody><tr align="center">
<td>3-4=-1</td>
<td>8-0=8</td>
</tr>
<tr align="center">
<td>4-1=3</td>
<td>6-(-9)=15</td>
</tr>
</tbody></table>
</div>
<p align="center"><i>Note: subtracting is actually defined as the <b>addition</b> of a negative matrix: A + (-B)</i></p>
<h2>Multiply by a Constant</h2>
<p>We can multiply a matrix by some value:</p>
<p align="center"><img src="matrix-multiply-constant.gif" alt="Matrix Multiply Constant" width="304" height="116"></p>
<div class="simple">
<div align="center">These are the calculations: </div>
<table align="center">
<tbody><tr align="center">
<td>2×4=8</td>
<td>2×0=0</td>
</tr>
<tr align="center">
<td>2×1=2</td>
<td>2×-9=-18</td>
</tr>
</tbody></table>
</div>
<p>We call the constant a <b>scalar</b>, so officially this is called <span class="large">"scalar multiplication"</span>. </p>