WEBVTT
1
00:00:00.000 --> 00:00:09.720
This calculator skill C14, this is doing arithmetic with matrices that would be adding and subtracting
2
00:00:09.720 --> 00:00:12.080
and multiplying.
3
00:00:12.080 --> 00:00:15.960
So here I got a couple examples, here's two matrices being added together, here's the
4
00:00:15.960 --> 00:00:18.760
same two matrices being subtracted.
5
00:00:18.760 --> 00:00:25.440
You should already know that when you subtract or add matrices, you're doing it element by
6
00:00:25.440 --> 00:00:31.280
element. So it's element in the first row, first column, plus the element in the first
7
00:00:31.280 --> 00:00:33.000
row, first column of the other one.
8
00:00:33.000 --> 00:00:36.440
So 2 plus 9 equals 11, and so on.
9
00:00:36.440 --> 00:00:40.640
Or in this case, 2 minus 9 equals minus 7.
10
00:00:40.640 --> 00:00:49.080
So I've got my calculator pre-programmed with those two matrices.
11
00:00:49.080 --> 00:00:52.680
For example, in the previous video I showed you how to put them out on the home screens,
12
00:00:52.680 --> 00:00:55.200
I'm going to show you that they're actually there.
13
00:00:55.200 --> 00:00:59.800
So second matrix, and they're in C and D is where I loaded them in.
14
00:00:59.800 --> 00:01:07.200
So C, if I press enter, there's the 1, and if I do second matrix again, if I go down
15
00:01:07.200 --> 00:01:12.400
and I press D, then there is the other.
16
00:01:12.400 --> 00:01:13.400
Okay?
17
00:01:13.400 --> 00:01:18.200
So to do this addition, then it's as simple as doing what?
18
00:01:18.200 --> 00:01:29.000
Second matrix C, which is number 3, minus second matrix 4, which is D.
19
00:01:29.000 --> 00:01:32.440
If I want to do the subtraction problem, for example.
20
00:01:32.440 --> 00:01:39.680
And now if I compare that answer to what they had, I can see that it's completely identical
21
00:01:39.680 --> 00:01:40.680
to their answer.
22
00:01:40.680 --> 00:01:43.640
Now let's do the one up above the addition one.
23
00:01:43.640 --> 00:01:48.760
So I'm going to be a clever here, I'm going to do second entry, and then I'm going to scroll
24
00:01:48.760 --> 00:01:54.560
back and change my negative to a positive instead of having to go through that keystrokes
25
00:01:54.560 --> 00:01:55.640
for the matrix.
26
00:01:55.640 --> 00:02:02.000
And if I press enter, now I get my other answer for addition.
27
00:02:02.000 --> 00:02:05.200
So that's adding two matrices together.
28
00:02:05.200 --> 00:02:10.800
Of course, if I try to add two matrices that are not the same dimensions, like for example,
29
00:02:10.800 --> 00:02:17.480
my matrix in A second matrix is 3 by 4, right?
30
00:02:17.480 --> 00:02:19.000
3 by 4.
31
00:02:19.000 --> 00:02:29.000
So for example, if I come back here to my home screen, now I do second entry, and I try
32
00:02:29.000 --> 00:02:38.040
to add to this, I'll get rid of that, and instead I'll try to add matrix A to it.
33
00:02:38.040 --> 00:02:43.760
That's going to tell me there's a domain mismatch, or excuse me, dimension mismatch,
34
00:02:43.760 --> 00:02:45.680
dim stands for dimension.
35
00:02:45.680 --> 00:02:50.000
So it knows when you're trying to do something that's not possible, which is add matrices
36
00:02:50.000 --> 00:02:57.960
together that are not the same dimensions.
37
00:02:57.960 --> 00:03:04.360
There as you should know by now, there are two different kinds of multiplication in matrices.
38
00:03:04.360 --> 00:03:10.280
There's multiplication called scalar multiplication in which you multiply one number time the matrix.
39
00:03:10.280 --> 00:03:14.600
And when you do that, what actually you're doing is multiplying the same number times
40
00:03:14.600 --> 00:03:17.120
every element in the matrix.
41
00:03:17.120 --> 00:03:26.480
So for example, if I bring back up my matrix C, for example, so that's number three, and
42
00:03:26.480 --> 00:03:27.960
I look and see there.
43
00:03:27.960 --> 00:03:32.600
Now if I want to do scalar multiplication of two, then all these elements should be two
44
00:03:32.600 --> 00:03:35.360
times what you see here.
45
00:03:35.360 --> 00:03:44.840
So two times second matrix, and then C, which is three.
46
00:03:44.840 --> 00:03:48.160
And you can see here that all the entries are then been doubled.
47
00:03:48.160 --> 00:03:52.640
So that's scalar multiplication, scalar multiplication.
48
00:03:52.640 --> 00:04:00.320
Finally, we have matrix multiplication, where we're multiplying a matrix times a matrix.
49
00:04:00.320 --> 00:04:05.240
And of all the ones that I have loaded in here, you should already be able to tell which
50
00:04:05.240 --> 00:04:07.960
ones it is possible to multiply together.
51
00:04:07.960 --> 00:04:15.160
For example, if I want to multiply matrix a, followed by matrix b, it's not possible.
52
00:04:15.160 --> 00:04:22.400
If the way you have to think of this is the column of the first one has to match the row
53
00:04:22.400 --> 00:04:23.960
of the second one.
54
00:04:23.960 --> 00:04:25.440
So four does not match three.
55
00:04:25.440 --> 00:04:31.760
So I couldn't follow a by b, but I could multiply b, followed by a, because that would be this
56
00:04:31.760 --> 00:04:35.760
three with this three, and I'd end up with a three by four.
57
00:04:35.760 --> 00:04:36.760
Okay?
58
00:04:36.760 --> 00:04:40.760
So let me multiply a times b, and b times a, and you'll see one of them doesn't work, and
59
00:04:40.760 --> 00:04:46.200
the other one gives me a three by four matrix.
60
00:04:46.200 --> 00:04:49.240
So I'm going to go back to my home screen here.
61
00:04:49.240 --> 00:05:03.240
And I'm going to do second matrix a times second matrix b.
62
00:05:03.240 --> 00:05:05.480
Now was that the one that's going to work?
63
00:05:05.480 --> 00:05:07.680
No, that's not the one that's going to work.
64
00:05:07.680 --> 00:05:14.200
Remember that dimensions of the columns of the first and the row of the second matrix
65
00:05:14.200 --> 00:05:15.760
did not match.
66
00:05:15.760 --> 00:05:19.520
So it's going to tell you that you can't do it.
67
00:05:19.520 --> 00:05:30.040
But if I go to the other way, so let's see, I'll clear out, I'll clear this out here,
68
00:05:30.040 --> 00:05:31.560
and I'll do it the other way.
69
00:05:31.560 --> 00:05:44.720
Second matrix b times second matrix a.
70
00:05:44.720 --> 00:05:48.640
And now you see it turns out, because the dimensions match.
71
00:05:48.640 --> 00:05:53.320
And I'm not going to describe how matrix multiplication is done.
72
00:05:53.320 --> 00:05:56.200
That's for not a calculator skill.
73
00:05:56.200 --> 00:05:58.640
That's something that you should know how to do.
74
00:05:58.640 --> 00:06:02.760
What I'm showing you is how to do that matrix multiplication in the calculator.
75
00:06:02.760 --> 00:06:04.920
And indeed, ended up being a three by four.
76
00:06:04.920 --> 00:06:08.400
Remember, it was supposed to be a three by four matrix.
77
00:06:08.400 --> 00:06:13.680
And by the way, you don't actually need the multiplication in here.
78
00:06:13.680 --> 00:06:19.320
So for example, if I delete that, it's still going to work just fine.
79
00:06:19.320 --> 00:06:21.880
So that's matrix multiplication.
80
00:06:21.880 --> 00:06:27.720
And you must have the column of the first matrix, must match the rows of the second or the
81
00:06:27.720 --> 00:06:32.200
following matrix in order for matrix multiplication to work correctly.
82
00:06:32.200 --> 00:06:33.200
That's it.
83
00:06:33.200 --> 00:06:41.800
That's all the essential arithmetic of matrices, adding, subtracting, scalar multiplication
84
00:06:41.800 --> 00:06:43.840
and multiplication.
85
00:06:43.840 --> 00:06:45.720
In matrices, we don't do division.
86
00:06:45.720 --> 00:06:48.560
We do something called multiplying by the inverse.
87
00:06:48.560 --> 00:07:18.520
And that is for another video.