WEBVTT

00:00:00.000 --> 00:00:05.335 align:middle line:84%
[SQUEAKING]
[RUSTLING] [CLICKING]

00:00:05.335 --> 00:00:12.607 align:middle line:90%


00:00:12.607 --> 00:00:14.440 align:middle line:84%
PETER SHOR: But the
first thing I want to do

00:00:14.440 --> 00:00:19.120 align:middle line:84%
is explain the
Cayley tree theorem.

00:00:19.120 --> 00:00:45.160 align:middle line:84%
And so the question is, how
many labelings of a tree on n

00:00:45.160 --> 00:00:47.440 align:middle line:90%
vertices?

00:00:47.440 --> 00:00:50.840 align:middle line:84%
And what I want to do
is I want to give you

00:00:50.840 --> 00:00:53.240 align:middle line:84%
the first few elements--
the first few numbers

00:00:53.240 --> 00:00:58.280 align:middle line:84%
in this sequence and let
you guess the answer.

00:00:58.280 --> 00:01:03.270 align:middle line:84%
So the first one is a
tree on two vertices.

00:01:03.270 --> 00:01:11.090 align:middle line:84%
And if you want to
label it with 1 and 2,

00:01:11.090 --> 00:01:14.630 align:middle line:84%
there's only really one way
of doing it, which is that.

00:01:14.630 --> 00:01:22.558 align:middle line:84%
And so that's n equals
2, n equals 3, 1, 2,

00:01:22.558 --> 00:01:33.230 align:middle line:84%
3, which is clearly the same as
1, 3, 2, because these trees--

00:01:33.230 --> 00:01:43.950 align:middle line:90%
actually, 2, 1, 3, and 3, 1, 2.

00:01:43.950 --> 00:01:49.310 align:middle line:84%
So there's one way of doing
this, three ways of doing this.

00:01:49.310 --> 00:01:50.490 align:middle line:90%
N equals 4.

00:01:50.490 --> 00:01:54.790 align:middle line:90%


00:01:54.790 --> 00:01:59.890 align:middle line:84%
OK, this time I'm not going to
list them all out because there

00:01:59.890 --> 00:02:01.030 align:middle line:90%
are too many to count.

00:02:01.030 --> 00:02:10.190 align:middle line:84%
But I'm going to list them
in the form of the tree.

00:02:10.190 --> 00:02:13.130 align:middle line:84%
So how many ways
are they doing it?

00:02:13.130 --> 00:02:16.090 align:middle line:84%
Are there labeling a
tree which is a path?

00:02:16.090 --> 00:02:17.190 align:middle line:90%
Can anyone tell me?

00:02:17.190 --> 00:02:23.770 align:middle line:90%


00:02:23.770 --> 00:02:25.690 align:middle line:90%
Yeah?

00:02:25.690 --> 00:02:28.350 align:middle line:84%
AUDIENCE: Maybe like 4 choose 2
to choose the two middle ones.

00:02:28.350 --> 00:02:30.530 align:middle line:90%
And then 2 times 2.

00:02:30.530 --> 00:02:32.910 align:middle line:84%
PETER SHOR: Yeah,
4 choose 2 times 2,

00:02:32.910 --> 00:02:37.010 align:middle line:84%
which is 12, because
you get to choose

00:02:37.010 --> 00:02:39.450 align:middle line:90%
which two are the middle ones.

00:02:39.450 --> 00:02:47.570 align:middle line:84%
And then there are two
ways of completing that.

00:02:47.570 --> 00:02:52.890 align:middle line:84%
And how about a tree
that looks like this?

00:02:52.890 --> 00:02:58.960 align:middle line:84%
Wait, I drew one too
many leaves on that.

00:02:58.960 --> 00:03:00.740 align:middle line:84%
How many ways are
there of doing this?

00:03:00.740 --> 00:03:08.640 align:middle line:90%


00:03:08.640 --> 00:03:11.200 align:middle line:84%
4, because the only thing that
matters is the middle one.

00:03:11.200 --> 00:03:15.320 align:middle line:90%
So 4 and this becomes 16.

00:03:15.320 --> 00:03:19.520 align:middle line:90%
And let's do n equals 5.

00:03:19.520 --> 00:03:23.960 align:middle line:90%
And there's one of these--

00:03:23.960 --> 00:03:27.120 align:middle line:84%
oops, I drew an extra
leaf on that one, too.

00:03:27.120 --> 00:03:28.160 align:middle line:90%
Sorry.

00:03:28.160 --> 00:03:31.080 align:middle line:90%
There are five of these.

00:03:31.080 --> 00:03:41.600 align:middle line:84%
And there are 5
factorial over 2 ways,

00:03:41.600 --> 00:03:45.680 align:middle line:84%
because there are 5 factorial
ways of labeling the vertices

00:03:45.680 --> 00:03:47.010 align:middle line:90%
from left to right.

00:03:47.010 --> 00:03:50.600 align:middle line:90%


00:03:50.600 --> 00:03:54.040 align:middle line:84%
But this tree is symmetric
in left and right,

00:03:54.040 --> 00:03:59.500 align:middle line:84%
so you're double counting
if you do that, which is 60.

00:03:59.500 --> 00:04:06.300 align:middle line:84%
And then there are
again 5 factorial over 2

00:04:06.300 --> 00:04:17.579 align:middle line:84%
because you can label
these 1, 3, 2, 4, 5.

00:04:17.579 --> 00:04:20.579 align:middle line:84%
But you can swap 5 and
4 and get the same tree.

00:04:20.579 --> 00:04:23.140 align:middle line:90%
So there's an extra factor of 2.

00:04:23.140 --> 00:04:26.620 align:middle line:90%
And this is 60.

00:04:26.620 --> 00:04:30.100 align:middle line:84%
And you add these
up, you get 125.

00:04:30.100 --> 00:04:31.790 align:middle line:90%
So does anybody see a pattern?

00:04:31.790 --> 00:04:39.300 align:middle line:90%


00:04:39.300 --> 00:04:40.540 align:middle line:90%
Yeah.

00:04:40.540 --> 00:04:44.780 align:middle line:84%
AUDIENCE: Like you multiply
by 3 then by 4 then by 5.

00:04:44.780 --> 00:04:47.592 align:middle line:84%
Like I guess within
the sequence.

00:04:47.592 --> 00:04:48.300 align:middle line:90%
PETER SHOR: Yeah.

00:04:48.300 --> 00:04:50.260 align:middle line:90%
Well, I mean yes.

00:04:50.260 --> 00:04:52.210 align:middle line:84%
That's essentially
the right idea.

00:04:52.210 --> 00:04:55.050 align:middle line:90%
This is 3 to the 1.

00:04:55.050 --> 00:04:56.890 align:middle line:90%
This is 2 to the 0.

00:04:56.890 --> 00:04:59.250 align:middle line:90%
This is 4 squared.

00:04:59.250 --> 00:05:03.330 align:middle line:90%
And this one is 5 cubed.

00:05:03.330 --> 00:05:06.970 align:middle line:84%
So the Cayley tree
theorem says there

00:05:06.970 --> 00:05:10.070 align:middle line:84%
are n to the n minus
2 ways of doing this.

00:05:10.070 --> 00:05:20.570 align:middle line:90%


00:05:20.570 --> 00:05:24.650 align:middle line:84%
So that's the statement of
the Cayley tree theorem.

00:05:24.650 --> 00:05:29.250 align:middle line:84%
And there are lots
and lots of proofs.

00:05:29.250 --> 00:05:32.530 align:middle line:84%
So one way you might
think of proving

00:05:32.530 --> 00:05:36.250 align:middle line:84%
it is to find a bijection
between labeled trees

00:05:36.250 --> 00:05:42.090 align:middle line:84%
and sequences of the numbers 1
through n of length n minus 2.

00:05:42.090 --> 00:05:43.550 align:middle line:90%
And you can do it that way.

00:05:43.550 --> 00:05:47.250 align:middle line:84%
But this bijection is really
incredibly complicated

00:05:47.250 --> 00:05:50.150 align:middle line:90%
and completely non-intuitive.

00:05:50.150 --> 00:05:53.270 align:middle line:84%
So that's not really
the right way to do it.

00:05:53.270 --> 00:05:58.070 align:middle line:84%
So what I'm going to
do is try to explain

00:05:58.070 --> 00:06:03.190 align:middle line:84%
a way of doing this by counting
these certain objects twice,

00:06:03.190 --> 00:06:06.150 align:middle line:84%
or certain object in
two different ways.

00:06:06.150 --> 00:06:07.820 align:middle line:90%
And how do we do this?

00:06:07.820 --> 00:06:10.350 align:middle line:90%


00:06:10.350 --> 00:06:23.320 align:middle line:84%
So let T sub n be number of
labeled trees on n vertices.

00:06:23.320 --> 00:06:30.470 align:middle line:90%


00:06:30.470 --> 00:06:32.150 align:middle line:84%
And the first thing
we're going to do

00:06:32.150 --> 00:06:39.430 align:middle line:84%
is change the thing to number
of labeled rooted trees

00:06:39.430 --> 00:06:40.240 align:middle line:90%
on n vertices.

00:06:40.240 --> 00:06:55.700 align:middle line:90%


00:06:55.700 --> 00:07:00.260 align:middle line:84%
OK, so what do you do
to get a rooted tree?

00:07:00.260 --> 00:07:09.940 align:middle line:90%


00:07:09.940 --> 00:07:20.080 align:middle line:84%
Is a tree with a specified
vertex, called the root.

00:07:20.080 --> 00:07:34.220 align:middle line:90%


00:07:34.220 --> 00:07:43.220 align:middle line:84%
OK, so if T sub n is the
number of labeled trees

00:07:43.220 --> 00:07:46.480 align:middle line:84%
on n vertices, what is
the number of labeled

00:07:46.480 --> 00:07:47.990 align:middle line:90%
rooted trees on n vertices?

00:07:47.990 --> 00:07:56.520 align:middle line:90%


00:07:56.520 --> 00:08:00.720 align:middle line:84%
OK, well, what you do is
you start with a tree.

00:08:00.720 --> 00:08:04.960 align:middle line:90%
Let's do this tree, 1, 3, 2.

00:08:04.960 --> 00:08:09.720 align:middle line:84%
And now you pick a
vertex to call the root.

00:08:09.720 --> 00:08:16.880 align:middle line:84%
So in this case, you
can do this is the root.

00:08:16.880 --> 00:08:21.720 align:middle line:90%
And 3, 1, 2, this is the root.

00:08:21.720 --> 00:08:27.960 align:middle line:84%
Or you could do 2, 3,
1, and this is the root.

00:08:27.960 --> 00:08:32.280 align:middle line:84%
So to go from a labeled tree
to a rooted tree, labeled

00:08:32.280 --> 00:08:35.120 align:middle line:84%
rooted tree, we just
pick one vertex.

00:08:35.120 --> 00:08:39.419 align:middle line:84%
And so there are n
times T sub n of these.

00:08:39.419 --> 00:08:44.270 align:middle line:90%


00:08:44.270 --> 00:08:55.600 align:middle line:84%
And now what we're
going to count--

00:08:55.600 --> 00:08:59.350 align:middle line:90%


00:08:59.350 --> 00:09:11.550 align:middle line:84%
what we count in two ways
is labeled rooted trees

00:09:11.550 --> 00:09:16.820 align:middle line:90%
with ordered edges.

00:09:16.820 --> 00:09:23.110 align:middle line:90%


00:09:23.110 --> 00:09:31.930 align:middle line:84%
So let's pick the middle
one there, 1, 3, 2.

00:09:31.930 --> 00:09:34.790 align:middle line:90%


00:09:34.790 --> 00:09:36.730 align:middle line:90%
So we need to order the edges.

00:09:36.730 --> 00:09:40.230 align:middle line:84%
And we can either order this
one and then this one, and then

00:09:40.230 --> 00:09:42.210 align:middle line:90%
this one and then this one.

00:09:42.210 --> 00:09:45.490 align:middle line:84%
So I'm going to use
letters to order

00:09:45.490 --> 00:09:49.010 align:middle line:84%
the edges because otherwise we
have too many numbers floating

00:09:49.010 --> 00:10:03.610 align:middle line:84%
around and it gets
confusing, so 3, 2, 1, A, B.

00:10:03.610 --> 00:10:08.170 align:middle line:90%
So how many labeled trees--

00:10:08.170 --> 00:10:12.530 align:middle line:84%
in terms of T sub n, the
number of labeled trees,

00:10:12.530 --> 00:10:14.210 align:middle line:84%
how many labeled
rooted trees would

00:10:14.210 --> 00:10:15.910 align:middle line:84%
ordered edges are
there going to be?

00:10:15.910 --> 00:10:20.730 align:middle line:90%


00:10:20.730 --> 00:10:22.550 align:middle line:90%
So there are n minus 1 edges.

00:10:22.550 --> 00:10:25.230 align:middle line:84%
How many ways are there of
ordering n minus 1 edges?

00:10:25.230 --> 00:10:28.955 align:middle line:90%


00:10:28.955 --> 00:10:30.590 align:middle line:90%
n minus 1 factorial.

00:10:30.590 --> 00:10:31.690 align:middle line:90%
Very good.

00:10:31.690 --> 00:10:39.930 align:middle line:84%
So this is T sub n times n
times n minus 1 factorial.

00:10:39.930 --> 00:10:42.355 align:middle line:90%
OK.

00:10:42.355 --> 00:10:49.920 align:middle line:84%
So if we can count this
in a way that tells us

00:10:49.920 --> 00:10:55.240 align:middle line:84%
the answer is n to the n
minus 2 times n times n

00:10:55.240 --> 00:10:59.390 align:middle line:84%
minus 1 factorial, then we
have proven the theorem.

00:10:59.390 --> 00:11:06.297 align:middle line:90%


00:11:06.297 --> 00:11:06.797 align:middle line:90%
OK.

00:11:06.797 --> 00:11:10.576 align:middle line:90%


00:11:10.576 --> 00:11:19.040 align:middle line:84%
So the second way
of counting, lemma,

00:11:19.040 --> 00:11:35.440 align:middle line:84%
there are n to the n minus 2 n
factorial labeled rooted trees

00:11:35.440 --> 00:11:36.270 align:middle line:90%
with ordered edges.

00:11:36.270 --> 00:11:54.460 align:middle line:90%


00:11:54.460 --> 00:11:56.700 align:middle line:90%
Good?

00:11:56.700 --> 00:11:58.210 align:middle line:90%
So how do we prove this lemma?

00:11:58.210 --> 00:12:00.780 align:middle line:90%


00:12:00.780 --> 00:12:03.860 align:middle line:90%
What we will do--

00:12:03.860 --> 00:12:04.570 align:middle line:90%
proof method.

00:12:04.570 --> 00:12:12.340 align:middle line:90%


00:12:12.340 --> 00:12:24.020 align:middle line:84%
Construct a labeled
rooted tree, I'm

00:12:24.020 --> 00:12:36.770 align:middle line:84%
going to say, via
labeled rooted forests,

00:12:36.770 --> 00:12:38.470 align:middle line:90%
by adding one edge at a time.

00:12:38.470 --> 00:12:55.170 align:middle line:90%


00:12:55.170 --> 00:13:01.330 align:middle line:84%
So back here, we have this
n minus 1 factorial, which

00:13:01.330 --> 00:13:03.050 align:middle line:90%
is the order of the edges.

00:13:03.050 --> 00:13:05.010 align:middle line:84%
And this order of
the edges is just

00:13:05.010 --> 00:13:06.730 align:middle line:84%
going to be the
order that we add

00:13:06.730 --> 00:13:15.490 align:middle line:84%
the edges to get to labeled
rooted forests to get

00:13:15.490 --> 00:13:16.990 align:middle line:90%
to the label rooted tree.

00:13:16.990 --> 00:13:24.998 align:middle line:90%


00:13:24.998 --> 00:13:27.190 align:middle line:84%
And I'm going to
do it by example.

00:13:27.190 --> 00:13:31.450 align:middle line:84%
But-- well, basically
because it's much easier

00:13:31.450 --> 00:13:33.530 align:middle line:84%
to see by example than
if I try to describe

00:13:33.530 --> 00:13:35.710 align:middle line:90%
the process in words.

00:13:35.710 --> 00:13:42.750 align:middle line:90%
So we start with a forest.

00:13:42.750 --> 00:13:44.570 align:middle line:84%
I never told you
what a forest is.

00:13:44.570 --> 00:13:47.630 align:middle line:84%
A forest is a
collection of trees,

00:13:47.630 --> 00:13:55.110 align:middle line:84%
which I'm going to say that
this makes perfect sense.

00:13:55.110 --> 00:14:06.650 align:middle line:84%
So start with a forest with
n trees with one vertex each.

00:14:06.650 --> 00:14:20.710 align:middle line:90%


00:14:20.710 --> 00:14:23.720 align:middle line:90%
1, 2, 3, 4, 5, 6.

00:14:23.720 --> 00:14:28.630 align:middle line:90%


00:14:28.630 --> 00:14:32.000 align:middle line:90%
Choose one of these trees.

00:14:32.000 --> 00:14:41.140 align:middle line:90%


00:14:41.140 --> 00:14:42.980 align:middle line:84%
And what we're
going to do is we're

00:14:42.980 --> 00:14:54.620 align:middle line:84%
going to add it to a
vertex and add it on top

00:14:54.620 --> 00:15:03.250 align:middle line:90%
of a vertex in another tree.

00:15:03.250 --> 00:15:08.900 align:middle line:90%


00:15:08.900 --> 00:15:09.960 align:middle line:90%
And let's see--

00:15:09.960 --> 00:15:45.720 align:middle line:90%


00:15:45.720 --> 00:15:59.600 align:middle line:84%
So let's take one of
these trees and stick it

00:15:59.600 --> 00:16:02.900 align:middle line:84%
on top of a vertex
in another tree.

00:16:02.900 --> 00:16:05.640 align:middle line:90%


00:16:05.640 --> 00:16:18.840 align:middle line:84%
So this gives us
1, 2, 4, 5, 3, 6.

00:16:18.840 --> 00:16:22.440 align:middle line:84%
And we want to label
this with the letter A

00:16:22.440 --> 00:16:25.720 align:middle line:84%
because it was the
first thing we did.

00:16:25.720 --> 00:16:34.150 align:middle line:84%
Now let's take a different
tree and stick it

00:16:34.150 --> 00:16:40.270 align:middle line:84%
on top of another
vertex in a tree.

00:16:40.270 --> 00:16:51.150 align:middle line:90%
And we get 1, 4, 5, 6, 2.

00:16:51.150 --> 00:16:53.470 align:middle line:90%
And here this was 3.

00:16:53.470 --> 00:16:55.630 align:middle line:90%
And this was a first step.

00:16:55.630 --> 00:16:59.150 align:middle line:90%
And this was our second step.

00:16:59.150 --> 00:17:01.510 align:middle line:90%
And we keep on doing this.

00:17:01.510 --> 00:17:07.109 align:middle line:84%
And maybe the next step
is we pick this tree

00:17:07.109 --> 00:17:12.790 align:middle line:84%
and stick it on
top of this vertex.

00:17:12.790 --> 00:17:31.850 align:middle line:84%
And we have 1, 4, 5, 6,
2, 3, and B, A, and C.

00:17:31.850 --> 00:17:35.050 align:middle line:84%
And we keep on doing
this until we get--

00:17:35.050 --> 00:17:38.670 align:middle line:84%
until we used up all
the trees except one.

00:17:38.670 --> 00:17:41.490 align:middle line:84%
And we have a
labeled rooted tree

00:17:41.490 --> 00:17:42.920 align:middle line:90%
with an ordering on the edges.

00:17:42.920 --> 00:17:47.090 align:middle line:90%


00:17:47.090 --> 00:18:13.550 align:middle line:84%
So how many ways are
there of doing this?

00:18:13.550 --> 00:18:22.450 align:middle line:90%


00:18:22.450 --> 00:18:23.650 align:middle line:90%
Oh gosh.

00:18:23.650 --> 00:18:29.630 align:middle line:84%
This is one of these
hard to erase chunks.

00:18:29.630 --> 00:18:37.580 align:middle line:90%


00:18:37.580 --> 00:18:38.080 align:middle line:90%
OK.

00:18:38.080 --> 00:18:40.760 align:middle line:90%


00:18:40.760 --> 00:18:45.940 align:middle line:84%
Well, how many configurations
are there to start with?

00:18:45.940 --> 00:19:01.360 align:middle line:90%


00:19:01.360 --> 00:19:03.560 align:middle line:90%
Anybody?

00:19:03.560 --> 00:19:10.760 align:middle line:84%
How many labeled-- how many
labeled forests with n tree

00:19:10.760 --> 00:19:12.580 align:middle line:90%
with one vertex each are there?

00:19:12.580 --> 00:19:17.440 align:middle line:90%


00:19:17.440 --> 00:19:19.840 align:middle line:84%
I can see nobody's answering
it because this question is

00:19:19.840 --> 00:19:22.560 align:middle line:90%
too easy.

00:19:22.560 --> 00:19:24.550 align:middle line:90%
There's only one of them.

00:19:24.550 --> 00:19:27.630 align:middle line:90%
There are n vertices.

00:19:27.630 --> 00:19:29.790 align:middle line:84%
And they have the
labels 1 through n.

00:19:29.790 --> 00:19:40.350 align:middle line:84%
And since order doesn't matter,
there's one of them, so one

00:19:40.350 --> 00:19:48.970 align:middle line:90%
after K steps have--

00:19:48.970 --> 00:19:51.750 align:middle line:90%


00:19:51.750 --> 00:19:58.790 align:middle line:90%
well, each step we have n--

00:19:58.790 --> 00:20:02.950 align:middle line:90%
each step we reduce one tree.

00:20:02.950 --> 00:20:07.500 align:middle line:90%
So we have n minus k trees.

00:20:07.500 --> 00:20:16.110 align:middle line:90%


00:20:16.110 --> 00:20:17.980 align:middle line:90%
Take one node.

00:20:17.980 --> 00:20:24.130 align:middle line:90%


00:20:24.130 --> 00:20:26.900 align:middle line:90%
Add a different tree.

00:20:26.900 --> 00:20:31.930 align:middle line:90%


00:20:31.930 --> 00:20:32.950 align:middle line:90%
We take one node.

00:20:32.950 --> 00:20:35.420 align:middle line:84%
We add a different
tree on that node--

00:20:35.420 --> 00:20:39.050 align:middle line:90%


00:20:39.050 --> 00:20:40.280 align:middle line:90%
to that node.

00:20:40.280 --> 00:20:43.250 align:middle line:90%


00:20:43.250 --> 00:20:57.290 align:middle line:84%
So, for example, here,
we chose node number 5.

00:20:57.290 --> 00:21:01.050 align:middle line:84%
And we added the fourth
tree to that node.

00:21:01.050 --> 00:21:03.200 align:middle line:84%
So how many ways are
there of doing this step?

00:21:03.200 --> 00:21:13.370 align:middle line:90%


00:21:13.370 --> 00:21:16.010 align:middle line:84%
How many ways are there
of choosing a node?

00:21:16.010 --> 00:21:16.650 align:middle line:90%
Anybody?

00:21:16.650 --> 00:21:24.230 align:middle line:90%


00:21:24.230 --> 00:21:24.730 align:middle line:90%
Yes.

00:21:24.730 --> 00:21:30.000 align:middle line:90%


00:21:30.000 --> 00:21:32.800 align:middle line:90%
How many nodes are there?

00:21:32.800 --> 00:21:33.640 align:middle line:90%
n.

00:21:33.640 --> 00:21:35.480 align:middle line:84%
And we can choose
any one of them.

00:21:35.480 --> 00:21:38.360 align:middle line:84%
So there are n ways
of choosing the node.

00:21:38.360 --> 00:21:42.520 align:middle line:90%
And now we have n minus k trees.

00:21:42.520 --> 00:21:45.080 align:middle line:84%
And we want to choose
a different tree

00:21:45.080 --> 00:21:47.040 align:middle line:90%
to add on top of the node.

00:21:47.040 --> 00:21:51.940 align:middle line:84%
So there are n minus k
minus 1 trees we can add.

00:21:51.940 --> 00:21:55.600 align:middle line:90%


00:21:55.600 --> 00:22:04.860 align:middle line:84%
So there's n times n minus
k minus 1 ways to do this.

00:22:04.860 --> 00:22:09.720 align:middle line:90%


00:22:09.720 --> 00:22:12.030 align:middle line:90%
So number of--

00:22:12.030 --> 00:22:15.560 align:middle line:90%


00:22:15.560 --> 00:22:17.200 align:middle line:90%
OK, what was it?

00:22:17.200 --> 00:22:33.060 align:middle line:84%
Labeled rooted trees-- labeled
rooted trees with edge ordering

00:22:33.060 --> 00:22:35.900 align:middle line:90%
is the product.

00:22:35.900 --> 00:22:40.600 align:middle line:90%
Well, so after k steps--

00:22:40.600 --> 00:22:44.320 align:middle line:84%
we want to start with how many
ways there are after 0 steps.

00:22:44.320 --> 00:22:50.840 align:middle line:84%
So 0 to-- well, there are
n minus 1 steps altogether.

00:22:50.840 --> 00:22:53.080 align:middle line:90%
So n minus 2, I believe.

00:22:53.080 --> 00:22:57.596 align:middle line:90%


00:22:57.596 --> 00:23:03.520 align:middle line:90%
n, n minus k minus 1.

00:23:03.520 --> 00:23:22.770 align:middle line:90%


00:23:22.770 --> 00:23:30.890 align:middle line:84%
So this is equal to
pi from k equals 0

00:23:30.890 --> 00:23:38.770 align:middle line:84%
to n minus 2 n times pi
from k equals 0 to n minus 2

00:23:38.770 --> 00:23:45.290 align:middle line:84%
of n minus k minus 1,
which is equal to--

00:23:45.290 --> 00:23:46.630 align:middle line:90%
well, there are n--

00:23:46.630 --> 00:23:54.210 align:middle line:90%


00:23:54.210 --> 00:23:57.130 align:middle line:90%
there are n minus 1 steps.

00:23:57.130 --> 00:23:58.950 align:middle line:84%
And each of these, you
have a factor of n.

00:23:58.950 --> 00:24:02.130 align:middle line:84%
So this is just n
times n minus 1.

00:24:02.130 --> 00:24:17.450 align:middle line:84%
And this should be n
minus 1 factorial, which--

00:24:17.450 --> 00:24:20.190 align:middle line:90%


00:24:20.190 --> 00:24:21.810 align:middle line:90%
if I haven't erased it--

00:24:21.810 --> 00:24:24.470 align:middle line:90%


00:24:24.470 --> 00:24:28.830 align:middle line:84%
yeah, we want to show that
there are n to the n minus 2n

00:24:28.830 --> 00:24:29.570 align:middle line:90%
factorial.

00:24:29.570 --> 00:24:32.070 align:middle line:84%
But that's the same as
n to the n minus 1 times

00:24:32.070 --> 00:24:33.990 align:middle line:90%
n minus 1 factorial.

00:24:33.990 --> 00:24:38.470 align:middle line:84%
So this is the number
of labeled rooted trees

00:24:38.470 --> 00:24:41.110 align:middle line:90%
with an edge ordering.

00:24:41.110 --> 00:24:46.790 align:middle line:84%
So this implies
that T sub n times

00:24:46.790 --> 00:24:58.310 align:middle line:90%
n times n minus 1 factorial--

00:24:58.310 --> 00:25:02.670 align:middle line:84%
so this is the number of
labeled rooted trees on n node.

00:25:02.670 --> 00:25:05.910 align:middle line:84%
And this is the number
of edge orderings--

00:25:05.910 --> 00:25:10.310 align:middle line:84%
is equal to n to the
n minus 1 times n

00:25:10.310 --> 00:25:19.580 align:middle line:84%
minus 1 factorial, which shows
you that T sub n equals minus 2

00:25:19.580 --> 00:25:20.980 align:middle line:90%
to the n--

00:25:20.980 --> 00:25:38.240 align:middle line:84%
n to the n minus 2, sorry, which
is what we wanted to prove.

00:25:38.240 --> 00:25:50.780 align:middle line:90%


00:25:50.780 --> 00:25:52.260 align:middle line:90%
OK.

00:25:52.260 --> 00:25:54.420 align:middle line:90%
Yes?

00:25:54.420 --> 00:25:58.340 align:middle line:84%
AUDIENCE: When you do the n
times n minus k minus 1 thing

00:25:58.340 --> 00:26:00.900 align:middle line:84%
is if you pick a node and
then isn't the second one just

00:26:00.900 --> 00:26:05.298 align:middle line:84%
picking a tree that's not
one of the trees you picked?

00:26:05.298 --> 00:26:06.340 align:middle line:90%
PETER SHOR: That's right.

00:26:06.340 --> 00:26:08.382 align:middle line:90%
Well, it's picking a tree--

00:26:08.382 --> 00:26:10.840 align:middle line:84%
no, because you can pick a tree
that you've already picked.

00:26:10.840 --> 00:26:12.600 align:middle line:90%
You just cannot pick a tree--

00:26:12.600 --> 00:26:15.440 align:middle line:84%
you cannot pick the
tree that node is in.

00:26:15.440 --> 00:26:17.320 align:middle line:90%
Yeah.

00:26:17.320 --> 00:26:22.600 align:middle line:84%
So we pick a node here, and
then we pick a different tree

00:26:22.600 --> 00:26:24.080 align:middle line:90%
to put on top of it.

00:26:24.080 --> 00:26:26.310 align:middle line:90%
And that's 5, 6, 2.

00:26:26.310 --> 00:26:29.880 align:middle line:84%
AUDIENCE: But doesn't it
matter how you connect them

00:26:29.880 --> 00:26:30.882 align:middle line:90%
with the other tree?

00:26:30.882 --> 00:26:32.840 align:middle line:84%
Because you're just
picking like another tree--

00:26:32.840 --> 00:26:34.257 align:middle line:84%
PETER SHOR: Oh,
we're always going

00:26:34.257 --> 00:26:38.960 align:middle line:84%
to put the root of this
tree on top of this node.

00:26:38.960 --> 00:26:43.880 align:middle line:84%
And you can see
that the process can

00:26:43.880 --> 00:26:48.080 align:middle line:84%
be undone because if we
have A, B, C, the way

00:26:48.080 --> 00:26:51.560 align:middle line:84%
we undo this step is
we find the last edge.

00:26:51.560 --> 00:26:53.360 align:middle line:90%
And we cut it.

00:26:53.360 --> 00:26:57.240 align:middle line:84%
And we have a tree
on top of that edge.

00:26:57.240 --> 00:27:01.440 align:middle line:84%
And we have the tree that's
left when you remove this edge.

00:27:01.440 --> 00:27:04.240 align:middle line:90%
So that undoes the step.

00:27:04.240 --> 00:27:07.920 align:middle line:84%
So the whole process
is, I want to say

00:27:07.920 --> 00:27:20.990 align:middle line:84%
that there is a this function
that takes you from trees on k--

00:27:20.990 --> 00:27:23.590 align:middle line:90%
n minus k nodes to trees--

00:27:23.590 --> 00:27:27.670 align:middle line:84%
or to forests of n minus
k trees to forests of n

00:27:27.670 --> 00:27:30.050 align:middle line:84%
minus k minus 1
trees is reversible.

00:27:30.050 --> 00:27:32.920 align:middle line:90%
So it's a bijection.

00:27:32.920 --> 00:27:34.420 align:middle line:84%
But, yeah, that was
a good question.

00:27:34.420 --> 00:27:52.910 align:middle line:90%


00:27:52.910 --> 00:27:59.270 align:middle line:84%
And last year, we
actually used this theorem

00:27:59.270 --> 00:28:03.790 align:middle line:84%
for one of our term
paper projects.

00:28:03.790 --> 00:28:07.530 align:middle line:90%
This year we're not.

00:28:07.530 --> 00:28:10.670 align:middle line:84%
I wanted to tell you this at
the beginning of the class,

00:28:10.670 --> 00:28:11.510 align:middle line:90%
but I forgot.

00:28:11.510 --> 00:28:15.630 align:middle line:84%
So what we're going to do is
tonight, assuming all goes well,

00:28:15.630 --> 00:28:20.050 align:middle line:84%
I will put up the term paper
projects and their assignments

00:28:20.050 --> 00:28:21.250 align:middle line:90%
to students.

00:28:21.250 --> 00:28:31.610 align:middle line:84%
And tomorrow in recitation,
the recitation leaders

00:28:31.610 --> 00:28:35.250 align:middle line:84%
will discuss them a little bit,
although most of the recitation

00:28:35.250 --> 00:28:39.130 align:middle line:84%
tomorrow is going to
be devoted to writing.

00:28:39.130 --> 00:28:46.720 align:middle line:84%
So the term paper projects are
hopefully coming out tonight.

00:28:46.720 --> 00:28:51.210 align:middle line:90%


00:28:51.210 --> 00:28:57.170 align:middle line:84%
So now, we are going
to switch topics and go

00:28:57.170 --> 00:28:59.150 align:middle line:90%
to generating functions.

00:28:59.150 --> 00:29:03.870 align:middle line:90%


00:29:03.870 --> 00:29:04.370 align:middle line:90%
OK.

00:29:04.370 --> 00:29:25.800 align:middle line:90%


00:29:25.800 --> 00:29:29.640 align:middle line:84%
And generating functions
are a very useful concept

00:29:29.640 --> 00:29:31.080 align:middle line:90%
in mathematics.

00:29:31.080 --> 00:29:33.230 align:middle line:84%
And you can use them
to count things.

00:29:33.230 --> 00:29:35.840 align:middle line:90%


00:29:35.840 --> 00:29:38.360 align:middle line:84%
I mean, there are proofs
of the Cayley tree theorem

00:29:38.360 --> 00:29:40.080 align:middle line:90%
that use generating functions.

00:29:40.080 --> 00:29:45.280 align:middle line:84%
And there are proofs of
probably nearly everything we've

00:29:45.280 --> 00:29:48.440 align:middle line:84%
discussed in terms of counting
that use generating functions,

00:29:48.440 --> 00:29:51.560 align:middle line:84%
although often, the
generating functions proofs

00:29:51.560 --> 00:29:55.383 align:middle line:84%
are more difficult than the
non-generating functions proofs.

00:29:55.383 --> 00:29:56.800 align:middle line:84%
On the other hand,
there are cases

00:29:56.800 --> 00:30:00.720 align:middle line:84%
where generating functions are
really the only way to do it.

00:30:00.720 --> 00:30:02.680 align:middle line:84%
And the other advantage
of generating functions

00:30:02.680 --> 00:30:04.180 align:middle line:90%
is that they're mechanical.

00:30:04.180 --> 00:30:09.300 align:middle line:84%
So given, say, combinatorial
identity and you look at it

00:30:09.300 --> 00:30:15.060 align:middle line:84%
and you say, what things can
I count in two different ways

00:30:15.060 --> 00:30:20.440 align:middle line:84%
to prove it, or something
else, well, it's--

00:30:20.440 --> 00:30:23.300 align:middle line:90%


00:30:23.300 --> 00:30:26.460 align:middle line:84%
you know, you have to use
some creativity to find this.

00:30:26.460 --> 00:30:32.860 align:middle line:84%
But if you have a generating
combinatorial identity

00:30:32.860 --> 00:30:36.260 align:middle line:84%
with generating
functions, often it's

00:30:36.260 --> 00:30:39.520 align:middle line:84%
fairly straightforward to prove
it using generating functions,

00:30:39.520 --> 00:30:43.600 align:middle line:84%
although it involves
actual algebra.

00:30:43.600 --> 00:30:51.000 align:middle line:84%
So it's maybe more
difficult. So why am I?

00:30:51.000 --> 00:31:00.700 align:middle line:90%


00:31:00.700 --> 00:31:07.570 align:middle line:84%
Let a1-- well, a0,
a1, a2, et cetera,

00:31:07.570 --> 00:31:08.660 align:middle line:90%
be a sequence of numbers.

00:31:08.660 --> 00:31:21.850 align:middle line:90%


00:31:21.850 --> 00:31:44.210 align:middle line:84%
The generating function
associated with the sequence

00:31:44.210 --> 00:31:56.930 align:middle line:84%
is F of x is equal to
sum a sub i x to the i, i

00:31:56.930 --> 00:31:59.030 align:middle line:90%
equals 0 to infinity.

00:31:59.030 --> 00:32:12.350 align:middle line:90%


00:32:12.350 --> 00:32:18.210 align:middle line:84%
So this is an
algebraic function.

00:32:18.210 --> 00:32:22.830 align:middle line:84%
And that means you can use all
the tools of algebraic functions

00:32:22.830 --> 00:32:24.550 align:middle line:90%
to manipulate it.

00:32:24.550 --> 00:32:28.630 align:middle line:84%
And this, we will find, is
going to be very useful.

00:32:28.630 --> 00:32:34.750 align:middle line:84%
Now, you can ask what
does x mean here?

00:32:34.750 --> 00:32:36.770 align:middle line:84%
And x doesn't really
mean anything.

00:32:36.770 --> 00:32:44.350 align:middle line:84%
It's just a tool for
keeping track of what

00:32:44.350 --> 00:32:48.310 align:middle line:90%
the i is on ai x to the i.

00:32:48.310 --> 00:32:58.500 align:middle line:84%
So it's a way of
keeping the i-th ai

00:32:58.500 --> 00:33:02.740 align:middle line:90%
distinct from the j-th ai.

00:33:02.740 --> 00:33:05.090 align:middle line:84%
So it usually doesn't
really mean anything.

00:33:05.090 --> 00:33:11.580 align:middle line:90%


00:33:11.580 --> 00:33:24.300 align:middle line:84%
So the example--
well, one example--

00:33:24.300 --> 00:33:28.520 align:middle line:84%
is we'll take the sequence
of binomial coefficients.

00:33:28.520 --> 00:33:32.020 align:middle line:90%


00:33:32.020 --> 00:33:33.620 align:middle line:90%
So what is this?

00:33:33.620 --> 00:33:36.640 align:middle line:90%
f sub n-- oh, right--

00:33:36.640 --> 00:33:46.340 align:middle line:90%


00:33:46.340 --> 00:33:50.120 align:middle line:90%
a sub n is equal to k choose n.

00:33:50.120 --> 00:33:53.660 align:middle line:90%


00:33:53.660 --> 00:34:02.840 align:middle line:84%
So the generating function for
this, F of x is equal to sum.

00:34:02.840 --> 00:34:04.880 align:middle line:84%
And here n is what
we're summing over.

00:34:04.880 --> 00:34:08.400 align:middle line:90%
n equals 0 through infinity.

00:34:08.400 --> 00:34:13.739 align:middle line:84%
And-- no, this is 0
if n is bigger than k.

00:34:13.739 --> 00:34:26.520 align:middle line:84%
So that's sum n equals 0
through K, a k choose n.

00:34:26.520 --> 00:34:34.719 align:middle line:84%
But let me write an x to the
n, k n choose n, x to the n.

00:34:34.719 --> 00:34:37.780 align:middle line:84%
And you should
know what this is.

00:34:37.780 --> 00:34:40.400 align:middle line:90%


00:34:40.400 --> 00:34:42.199 align:middle line:90%
This is the binomial theorem.

00:34:42.199 --> 00:34:46.620 align:middle line:90%
And it's just 1 plus x to the k.

00:34:46.620 --> 00:34:49.719 align:middle line:90%


00:34:49.719 --> 00:34:52.120 align:middle line:84%
And one way of
thinking about this

00:34:52.120 --> 00:35:05.140 align:middle line:84%
is F of x equals 1 plus
x, 1 plus x, and 1 plus x.

00:35:05.140 --> 00:35:09.402 align:middle line:90%


00:35:09.402 --> 00:35:10.980 align:middle line:90%
So for the k-th term--

00:35:10.980 --> 00:35:18.830 align:middle line:90%


00:35:18.830 --> 00:35:37.650 align:middle line:84%
no, for n-th term, I'm sorry,
choose n x's, k minus n 1's.

00:35:37.650 --> 00:35:38.150 align:middle line:90%
Good?

00:35:38.150 --> 00:35:42.110 align:middle line:84%
So we need to choose whether
we'll use the x from this one,

00:35:42.110 --> 00:35:46.250 align:middle line:84%
the x from this one, the x
from this one, et cetera.

00:35:46.250 --> 00:35:48.590 align:middle line:90%
So we're choosing k x's--

00:35:48.590 --> 00:35:55.060 align:middle line:84%
we're choosing n x's out
of k things, which is just

00:35:55.060 --> 00:35:56.880 align:middle line:90%
n choose k-- or k choose n.

00:35:56.880 --> 00:35:57.860 align:middle line:90%
I'm sorry.

00:35:57.860 --> 00:36:01.560 align:middle line:84%
And so that's why a
sub n is k choose n.

00:36:01.560 --> 00:36:20.420 align:middle line:90%


00:36:20.420 --> 00:36:20.920 align:middle line:90%
OK.

00:36:20.920 --> 00:36:24.920 align:middle line:90%


00:36:24.920 --> 00:36:58.680 align:middle line:84%
So example 2, the a sub n is
the probability of n heads

00:36:58.680 --> 00:37:12.640 align:middle line:84%
when you flip a coin,
a biased coin, k times.

00:37:12.640 --> 00:37:16.570 align:middle line:84%
And we'll let p equal
probability of heads.

00:37:16.570 --> 00:37:24.960 align:middle line:90%


00:37:24.960 --> 00:37:29.060 align:middle line:90%
And q equals 1 minus p.

00:37:29.060 --> 00:37:38.720 align:middle line:90%


00:37:38.720 --> 00:37:50.725 align:middle line:84%
So A of x is equal to summation
a sub n x to the n is equal to k

00:37:50.725 --> 00:38:00.122 align:middle line:84%
choose n, p to the k, q to the
n minus k times x to the k--

00:38:00.122 --> 00:38:01.150 align:middle line:90%
x to the n.

00:38:01.150 --> 00:38:04.990 align:middle line:90%


00:38:04.990 --> 00:38:08.240 align:middle line:84%
I keep mixing up
my k's and my n's.

00:38:08.240 --> 00:38:13.350 align:middle line:90%


00:38:13.350 --> 00:38:15.750 align:middle line:90%
Let me apologize for that.

00:38:15.750 --> 00:38:16.490 align:middle line:90%
There we go.

00:38:16.490 --> 00:38:30.670 align:middle line:90%


00:38:30.670 --> 00:38:33.470 align:middle line:90%
And this is equal to--

00:38:33.470 --> 00:38:35.910 align:middle line:90%
I forgot the sum here.

00:38:35.910 --> 00:38:47.890 align:middle line:84%
This is equal to q
plus px to the n,

00:38:47.890 --> 00:38:49.400 align:middle line:90%
again, by the binomial theorem.

00:38:49.400 --> 00:38:55.210 align:middle line:90%


00:38:55.210 --> 00:39:00.690 align:middle line:84%
So hopefully, I will have
time to do a real example that

00:39:00.690 --> 00:39:02.610 align:middle line:84%
shows you why
generating functions are

00:39:02.610 --> 00:39:06.750 align:middle line:90%
useful before the end of class.

00:39:06.750 --> 00:39:11.170 align:middle line:84%
But if not, we'll get to it
tomorrow, or not tomorrow,

00:39:11.170 --> 00:39:12.620 align:middle line:90%
Thursday.

00:39:12.620 --> 00:39:13.120 align:middle line:90%
OK.

00:39:13.120 --> 00:39:16.250 align:middle line:90%


00:39:16.250 --> 00:39:19.010 align:middle line:84%
I want to say a few
more general things

00:39:19.010 --> 00:39:22.150 align:middle line:90%
about generating functions.

00:39:22.150 --> 00:39:24.970 align:middle line:90%


00:39:24.970 --> 00:39:31.380 align:middle line:84%
Let A, B be disjoint
classes of objects.

00:39:31.380 --> 00:39:44.920 align:middle line:90%


00:39:44.920 --> 00:39:54.210 align:middle line:84%
And C equals A union B,
where U is disjoint union.

00:39:54.210 --> 00:39:58.880 align:middle line:90%


00:39:58.880 --> 00:40:05.120 align:middle line:84%
So that just says that A
intersection B is the empty set.

00:40:05.120 --> 00:40:07.780 align:middle line:84%
So I want to say the
generating function for C of x.

00:40:07.780 --> 00:40:11.017 align:middle line:90%


00:40:11.017 --> 00:40:13.600 align:middle line:84%
So what we're going to do is we
want to express the generating

00:40:13.600 --> 00:40:16.680 align:middle line:84%
function for C of
x in terms of A

00:40:16.680 --> 00:40:20.800 align:middle line:84%
of x and B of x
is equal to A of--

00:40:20.800 --> 00:40:30.720 align:middle line:84%
well, it's going to be
sum C sub n, x to the n.

00:40:30.720 --> 00:40:35.120 align:middle line:84%
Well, C sub n is just
A sub n plus B sub

00:40:35.120 --> 00:40:45.060 align:middle line:84%
n is equal to sum A sub n
plus B sub n, x to the n,

00:40:45.060 --> 00:40:46.700 align:middle line:84%
which you can see
is the generating

00:40:46.700 --> 00:40:49.680 align:middle line:90%
function of A of x plus B of x.

00:40:49.680 --> 00:40:55.460 align:middle line:90%


00:40:55.460 --> 00:40:59.540 align:middle line:84%
So the next one, we want to
talk about multiplication

00:40:59.540 --> 00:41:01.140 align:middle line:90%
of generating functions.

00:41:01.140 --> 00:41:04.640 align:middle line:84%
This is actually, first,
pretty straightforward.

00:41:04.640 --> 00:41:08.900 align:middle line:84%
And second, is not
really that useful

00:41:08.900 --> 00:41:10.720 align:middle line:84%
when manipulating
generating functions.

00:41:10.720 --> 00:41:14.860 align:middle line:84%
Multiplying generating
functions is incredibly useful.

00:41:14.860 --> 00:41:17.350 align:middle line:90%
And we'll do an example.

00:41:17.350 --> 00:41:26.860 align:middle line:90%


00:41:26.860 --> 00:41:29.300 align:middle line:90%
So let's do the example first.

00:41:29.300 --> 00:41:46.590 align:middle line:84%
And then we will do
the formal explanation.

00:41:46.590 --> 00:41:55.130 align:middle line:90%


00:41:55.130 --> 00:41:59.880 align:middle line:84%
So let's say we have a 6-sided
dice and an 8-sided dice.

00:41:59.880 --> 00:42:10.210 align:middle line:90%


00:42:10.210 --> 00:42:11.280 align:middle line:90%
8-sided dice.

00:42:11.280 --> 00:42:16.490 align:middle line:90%


00:42:16.490 --> 00:42:29.490 align:middle line:84%
And we want to know what is
the probability of rolling,

00:42:29.490 --> 00:42:37.630 align:middle line:84%
OK, let's call it n, when we add
up the numbers from the two die.

00:42:37.630 --> 00:42:44.470 align:middle line:90%


00:42:44.470 --> 00:42:49.950 align:middle line:84%
And I should specify that the
6-sided dice is numbered 1

00:42:49.950 --> 00:42:53.330 align:middle line:84%
through 6, and the 8-sided
dice is numbered 1 through 8.

00:42:53.330 --> 00:43:04.310 align:middle line:90%


00:43:04.310 --> 00:43:16.730 align:middle line:84%
So let C sub n is equal to
number of ways of rolling n.

00:43:16.730 --> 00:43:24.870 align:middle line:90%


00:43:24.870 --> 00:43:30.110 align:middle line:90%
Claim-- C sub n is equal to--

00:43:30.110 --> 00:43:34.230 align:middle line:90%
or rather C sub n--

00:43:34.230 --> 00:43:39.940 align:middle line:84%
C of x is equal to
sum C sub n x to the n

00:43:39.940 --> 00:43:47.740 align:middle line:84%
is equal to x plus x
squared plus x cubed plus--

00:43:47.740 --> 00:43:55.760 align:middle line:84%
plus x to the 6th, x plus x
squared plus x cubed plus dot,

00:43:55.760 --> 00:44:07.940 align:middle line:84%
dot, dot plus x to the 8th
equals x plus 2x squared plus 3x

00:44:07.940 --> 00:44:16.260 align:middle line:84%
cubed plus dot, dot, dot,
plus 5x to the 5th plus 6x

00:44:16.260 --> 00:44:20.540 align:middle line:90%
to the 6th, plus 7x to the--

00:44:20.540 --> 00:44:34.900 align:middle line:84%
plus, sorry, 6x to the 7th, plus
6x to the 8th plus 6x to the 9th

00:44:34.900 --> 00:44:39.020 align:middle line:84%
plus 5x to the 10th,
plus dot, dot, dot.

00:44:39.020 --> 00:44:44.120 align:middle line:90%


00:44:44.120 --> 00:44:46.500 align:middle line:90%
Plus x to the 14th.

00:44:46.500 --> 00:45:00.640 align:middle line:90%


00:45:00.640 --> 00:45:02.030 align:middle line:90%
So how do we get that?

00:45:02.030 --> 00:45:23.680 align:middle line:90%


00:45:23.680 --> 00:45:25.360 align:middle line:84%
So you can see from
this that there

00:45:25.360 --> 00:45:27.960 align:middle line:90%
are five ways of rolling a 10.

00:45:27.960 --> 00:45:33.860 align:middle line:90%
You can roll a 6 and 4.

00:45:33.860 --> 00:45:43.830 align:middle line:84%
Or you could roll a 5 and
5, a 4 and 6, a 3 and 7,

00:45:43.830 --> 00:45:46.710 align:middle line:90%
and 2 and an 8.

00:45:46.710 --> 00:45:55.470 align:middle line:84%
And this works
because C sub n is

00:45:55.470 --> 00:46:02.780 align:middle line:90%
equal to summation j equals 0.

00:46:02.780 --> 00:46:07.310 align:middle line:90%


00:46:07.310 --> 00:46:09.890 align:middle line:90%
j equals 1 through n.

00:46:09.890 --> 00:46:27.810 align:middle line:90%


00:46:27.810 --> 00:46:28.310 align:middle line:90%
OK.

00:46:28.310 --> 00:46:31.450 align:middle line:90%


00:46:31.450 --> 00:46:35.710 align:middle line:90%
A sub j, B sub n minus j.

00:46:35.710 --> 00:46:38.570 align:middle line:90%


00:46:38.570 --> 00:46:42.450 align:middle line:84%
So if you want to get an n,
the first place has to be j.

00:46:42.450 --> 00:46:46.090 align:middle line:84%
And the second one
has to be n minus j.

00:46:46.090 --> 00:46:56.250 align:middle line:84%
And A j equals 1, if 1 is
less than j is less than 6,

00:46:56.250 --> 00:46:57.870 align:middle line:90%
0 otherwise.

00:46:57.870 --> 00:47:05.890 align:middle line:84%
And B sub j equals 1 if 1 is
less than j is less than 8,

00:47:05.890 --> 00:47:07.470 align:middle line:90%
and 0 otherwise.

00:47:07.470 --> 00:47:16.490 align:middle line:90%


00:47:16.490 --> 00:47:18.490 align:middle line:90%
Is this clear?

00:47:18.490 --> 00:47:22.010 align:middle line:84%
I mean to get an n, you have
to roll a j on the first dice

00:47:22.010 --> 00:47:24.070 align:middle line:84%
and an n minus j
on the second dice.

00:47:24.070 --> 00:47:26.170 align:middle line:84%
And you can only roll
a j on the first dice

00:47:26.170 --> 00:47:29.690 align:middle line:90%
if j is between 1 and 6.

00:47:29.690 --> 00:47:33.320 align:middle line:84%
And you can only roll it n
minus j on the second die

00:47:33.320 --> 00:47:35.620 align:middle line:90%
if j is between 1 and 8.

00:47:35.620 --> 00:47:39.240 align:middle line:90%


00:47:39.240 --> 00:47:53.000 align:middle line:84%
So if A of x is
equal to summation,

00:47:53.000 --> 00:47:58.720 align:middle line:90%
i equals 1 through 6 x to the i.

00:47:58.720 --> 00:48:09.480 align:middle line:84%
And B of x is equal to summation
i equals 1 through 8 x to the i.

00:48:09.480 --> 00:48:10.750 align:middle line:90%
That's not a very good 8.

00:48:10.750 --> 00:48:15.640 align:middle line:90%


00:48:15.640 --> 00:48:26.280 align:middle line:84%
Then C of x equals
of A of x, B of x,

00:48:26.280 --> 00:48:30.440 align:middle line:84%
because this is the formula
for multiplying polynomials.

00:48:30.440 --> 00:48:43.620 align:middle line:90%


00:48:43.620 --> 00:48:46.140 align:middle line:84%
So we have the generating
function for the first die

00:48:46.140 --> 00:48:48.940 align:middle line:84%
and the generating function
for the second die.

00:48:48.940 --> 00:48:52.820 align:middle line:84%
And we get the generating
function for the sum of the two

00:48:52.820 --> 00:48:54.630 align:middle line:90%
dies by just multiplying them.

00:48:54.630 --> 00:49:20.460 align:middle line:90%


00:49:20.460 --> 00:49:23.820 align:middle line:90%
And let's make this rigorous.

00:49:23.820 --> 00:49:31.710 align:middle line:84%
Let A, B be two
classes of objects.

00:49:31.710 --> 00:49:50.159 align:middle line:90%


00:49:50.159 --> 00:49:56.350 align:middle line:84%
A of x and B of x be their
generating functions.

00:49:56.350 --> 00:50:08.890 align:middle line:90%


00:50:08.890 --> 00:50:12.990 align:middle line:90%
Then-- oh, well--

00:50:12.990 --> 00:50:17.010 align:middle line:90%


00:50:17.010 --> 00:50:33.118 align:middle line:84%
the Cartesian product,
Product A cross B,

00:50:33.118 --> 00:50:42.870 align:middle line:84%
is A, B, A and A,
B and B. And we

00:50:42.870 --> 00:51:08.670 align:middle line:84%
want to claim that size of A, B
equals size of A plus size of B.

00:51:08.670 --> 00:51:27.540 align:middle line:84%
Then there are the Cartesian
product, A cross B,

00:51:27.540 --> 00:51:48.280 align:middle line:84%
has generating function A
of x, B of x equals C of x.

00:51:48.280 --> 00:52:25.880 align:middle line:90%


00:52:25.880 --> 00:52:46.280 align:middle line:84%
Proof-- OK, C sub n equals
summation k equals 0 through n,

00:52:46.280 --> 00:52:53.200 align:middle line:90%
a sub k, b sub n minus k.

00:52:53.200 --> 00:52:57.440 align:middle line:84%
So we want to look at
the things of size n

00:52:57.440 --> 00:52:59.680 align:middle line:90%
in the Cartesian product.

00:52:59.680 --> 00:53:09.480 align:middle line:84%
Well, they're the things of
size k in the first generating

00:53:09.480 --> 00:53:12.720 align:middle line:84%
function and times
the things of size n

00:53:12.720 --> 00:53:14.880 align:middle line:84%
minus k in the second
generating function.

00:53:14.880 --> 00:53:19.110 align:middle line:84%
And we want to sum
this over all k.

00:53:19.110 --> 00:53:25.150 align:middle line:84%
And now, we just need to
check that summation C

00:53:25.150 --> 00:53:32.270 align:middle line:84%
sub n x to the n is equal
to summation k equals 0

00:53:32.270 --> 00:53:38.750 align:middle line:84%
through n, a sub k, b
n minus k x to the n is

00:53:38.750 --> 00:53:43.310 align:middle line:90%
equal to sum k equals 0--

00:53:43.310 --> 00:53:50.710 align:middle line:84%
or rather, n equals
0 to infinity.

00:53:50.710 --> 00:53:53.630 align:middle line:84%
I forgot the second
sum here-- n equals 0

00:53:53.630 --> 00:53:59.990 align:middle line:84%
to infinity, k equals 0 to n,
which is just sum k equals 0

00:53:59.990 --> 00:54:04.390 align:middle line:84%
to infinity, a
sub k, x to the k,

00:54:04.390 --> 00:54:16.580 align:middle line:84%
summation j equals 0 to
infinity, b sub j, x to the j,

00:54:16.580 --> 00:54:22.140 align:middle line:84%
because when you multiply
these, you group the things

00:54:22.140 --> 00:54:26.580 align:middle line:84%
that have the same
k plus j equals n.

00:54:26.580 --> 00:54:30.420 align:middle line:84%
And that gives you
this term, sum k

00:54:30.420 --> 00:54:34.580 align:middle line:84%
equals 0 to n, A sub
k, B sub n minus k.

00:54:34.580 --> 00:54:35.260 align:middle line:90%
Yeah.

00:54:35.260 --> 00:54:35.927 align:middle line:90%
AUDIENCE: Sorry.

00:54:35.927 --> 00:54:37.380 align:middle line:90%
What does size mean?

00:54:37.380 --> 00:54:44.220 align:middle line:84%
PETER SHOR: Size is just
an arbitrary function

00:54:44.220 --> 00:54:56.580 align:middle line:84%
on these objects that correspond
to the n here in summation

00:54:56.580 --> 00:54:58.980 align:middle line:90%
a sub k, x to the k.

00:54:58.980 --> 00:55:04.580 align:middle line:84%
So when you have
generating functions,

00:55:04.580 --> 00:55:10.340 align:middle line:84%
you're grouping objects into
things that go with x to the k.

00:55:10.340 --> 00:55:17.520 align:middle line:84%
And those are what
we're calling size.

00:55:17.520 --> 00:55:19.920 align:middle line:84%
AUDIENCE: So is
it the power of x?

00:55:19.920 --> 00:55:22.640 align:middle line:84%
PETER SHOR: It's
the power of x that

00:55:22.640 --> 00:55:24.020 align:middle line:90%
is associated with the object.

00:55:24.020 --> 00:55:29.560 align:middle line:84%
And I think we should
look at an actual example.

00:55:29.560 --> 00:55:30.890 align:middle line:90%
So this is a simple example.

00:55:30.890 --> 00:56:04.960 align:middle line:90%


00:56:04.960 --> 00:56:20.110 align:middle line:84%
Example-- OK, suppose
you have one penny--

00:56:20.110 --> 00:56:27.320 align:middle line:84%
no, 6 pennies, 1
nickel, 2 dimes.

00:56:27.320 --> 00:56:31.870 align:middle line:90%


00:56:31.870 --> 00:56:48.880 align:middle line:84%
How many different ways
can you make n cents?

00:56:48.880 --> 00:56:58.510 align:middle line:90%


00:56:58.510 --> 00:57:07.670 align:middle line:84%
Claim-- the generating
function, let's

00:57:07.670 --> 00:57:18.770 align:middle line:84%
call it C of x is equal
to sum c n, x to the n.

00:57:18.770 --> 00:57:24.290 align:middle line:84%
So we'll let c sub n be the
number of different ways,

00:57:24.290 --> 00:57:33.050 align:middle line:84%
cn be number of ways
to make n cents with 6

00:57:33.050 --> 00:57:36.930 align:middle line:90%
pennies, a nickel, and 2 dimes.

00:57:36.930 --> 00:57:45.050 align:middle line:84%
C of x is equal to 1 plus x plus
x squared plus x cubed plus x

00:57:45.050 --> 00:57:53.410 align:middle line:84%
4th plus x 5th plus x 6th,
1 plus x to the fifth,

00:57:53.410 --> 00:57:58.100 align:middle line:84%
and 1 plus x to the
10th plus x to the 20th.

00:57:58.100 --> 00:58:07.930 align:middle line:90%


00:58:07.930 --> 00:58:14.960 align:middle line:84%
OK, so when you multiply
these things together--

00:58:14.960 --> 00:58:17.000 align:middle line:90%
let's look at the x to the 20--

00:58:17.000 --> 00:58:24.210 align:middle line:84%
let's look at the x to the, I'm
thinking, x to the 21st term.

00:58:24.210 --> 00:58:31.360 align:middle line:90%


00:58:31.360 --> 00:58:38.080 align:middle line:84%
So it can be got from x to the
6th times x to the 5th times x

00:58:38.080 --> 00:58:38.690 align:middle line:90%
to the 10th.

00:58:38.690 --> 00:58:45.120 align:middle line:90%


00:58:45.120 --> 00:58:50.830 align:middle line:84%
And we can also get it
from x times x to the 20th.

00:58:50.830 --> 00:58:54.840 align:middle line:90%


00:58:54.840 --> 00:58:57.600 align:middle line:84%
And those are the only
two ways you can get it.

00:58:57.600 --> 00:59:01.360 align:middle line:84%
So there are two
ways to make change--

00:59:01.360 --> 00:59:15.420 align:middle line:90%
two ways to pay $0.21.

00:59:15.420 --> 00:59:21.130 align:middle line:84%
So here the size is just
the number of cents.

00:59:21.130 --> 00:59:37.260 align:middle line:90%


00:59:37.260 --> 00:59:40.160 align:middle line:84%
OK, let's do something a
little bit more complicated.

00:59:40.160 --> 00:59:56.180 align:middle line:90%


00:59:56.180 --> 01:00:07.650 align:middle line:84%
How many ways are there
to pay, let's say,

01:00:07.650 --> 01:00:19.760 align:middle line:84%
n cents in an arbitrary number
of pennies, nickels, dimes.

01:00:19.760 --> 01:00:25.490 align:middle line:90%


01:00:25.490 --> 01:00:30.930 align:middle line:84%
Well, I want to claim that it's
1 plus x plus x squared plus x

01:00:30.930 --> 01:00:36.210 align:middle line:84%
cubed plus dot, dot, dot, times
1 plus x to the 5th plus x

01:00:36.210 --> 01:00:42.850 align:middle line:84%
to the 10th plus x to the
15th, plus dot, dot, dot,

01:00:42.850 --> 01:00:47.530 align:middle line:84%
times 1 plus x to the
10th, plus x to the 20th,

01:00:47.530 --> 01:00:53.530 align:middle line:84%
plus x to the 30th,
plus dot, dot, dot,

01:00:53.530 --> 01:01:00.170 align:middle line:84%
which is equal to 1 over 1 minus
x, 1 over 1 minus x to the 5th,

01:01:00.170 --> 01:01:02.720 align:middle line:84%
times 1 over 1
minus x to the 10th.

01:01:02.720 --> 01:01:07.750 align:middle line:90%


01:01:07.750 --> 01:01:11.290 align:middle line:84%
So cn x to the n
is equal to that.

01:01:11.290 --> 01:01:26.190 align:middle line:90%


01:01:26.190 --> 01:01:33.190 align:middle line:84%
OK, so now I want
to give an example

01:01:33.190 --> 01:01:37.010 align:middle line:84%
for how you would actually
use a generating function.

01:01:37.010 --> 01:01:39.270 align:middle line:84%
I mean, we have not
gotten to the end

01:01:39.270 --> 01:01:44.295 align:middle line:84%
of our overall description
of generating functions.

01:01:44.295 --> 01:01:45.670 align:middle line:84%
But I want to give
you an example

01:01:45.670 --> 01:01:50.210 align:middle line:84%
first of how you would actually
calculate something with them.

01:01:50.210 --> 01:01:56.950 align:middle line:90%


01:01:56.950 --> 01:02:01.690 align:middle line:84%
And I want to claim this
is really pretty neat.

01:02:01.690 --> 01:02:13.460 align:middle line:90%


01:02:13.460 --> 01:02:23.895 align:middle line:84%
What is sum k equals 0
through n, k n choose k.

01:02:23.895 --> 01:02:27.980 align:middle line:90%


01:02:27.980 --> 01:02:31.540 align:middle line:84%
So the first thing
is you can do it

01:02:31.540 --> 01:02:34.340 align:middle line:84%
by counting something
two different ways.

01:02:34.340 --> 01:02:38.240 align:middle line:84%
And I want to do it with
generating functions first.

01:02:38.240 --> 01:02:40.640 align:middle line:84%
And if I have any time
at the end of the class,

01:02:40.640 --> 01:02:44.500 align:middle line:84%
I'll check it by using
the technique of counting

01:02:44.500 --> 01:02:45.680 align:middle line:90%
in two different ways.

01:02:45.680 --> 01:02:48.060 align:middle line:90%
But I'm not sure I will.

01:02:48.060 --> 01:02:51.420 align:middle line:90%
So what is it?

01:02:51.420 --> 01:03:02.360 align:middle line:84%
k equals 0 through n, n choose
k times x to the k is equal to--

01:03:02.360 --> 01:03:04.220 align:middle line:84%
does anybody want to
tell me what this is?

01:03:04.220 --> 01:03:11.560 align:middle line:90%


01:03:11.560 --> 01:03:12.440 align:middle line:90%
Yeah.

01:03:12.440 --> 01:03:15.820 align:middle line:84%
AUDIENCE: Is it n times
2 to the n minus 1?

01:03:15.820 --> 01:03:18.720 align:middle line:90%


01:03:18.720 --> 01:03:22.080 align:middle line:84%
PETER SHOR: No, because we want
this as a function of something

01:03:22.080 --> 01:03:23.273 align:middle line:90%
with x's in it.

01:03:23.273 --> 01:03:24.440 align:middle line:90%
AUDIENCE: 1 plus x to the n.

01:03:24.440 --> 01:03:26.960 align:middle line:84%
PETER SHOR: Yeah, 1 plus
x to the n, that's right.

01:03:26.960 --> 01:03:29.460 align:middle line:90%
1 plus x to the n.

01:03:29.460 --> 01:03:31.360 align:middle line:90%
Excellent.

01:03:31.360 --> 01:03:32.640 align:middle line:90%
OK.

01:03:32.640 --> 01:03:36.040 align:middle line:90%
Now-- and this is--

01:03:36.040 --> 01:03:40.640 align:middle line:90%
we should call this F of x.

01:03:40.640 --> 01:03:45.200 align:middle line:84%
Now, how can we get
this out of that?

01:03:45.200 --> 01:03:47.920 align:middle line:90%
Well, let's differentiate.

01:03:47.920 --> 01:03:59.470 align:middle line:84%
d/dx F of x is equal to
sum k equals 0 through n,

01:03:59.470 --> 01:04:05.340 align:middle line:84%
k n choose k, x
to the k minus 1.

01:04:05.340 --> 01:04:09.430 align:middle line:90%


01:04:09.430 --> 01:04:11.810 align:middle line:90%
Right?

01:04:11.810 --> 01:04:12.870 align:middle line:90%
OK.

01:04:12.870 --> 01:04:15.550 align:middle line:84%
And now, let's
differentiate this.

01:04:15.550 --> 01:04:20.170 align:middle line:84%
Well, that's just n times
1 plus x to the n minus 1.

01:04:20.170 --> 01:04:24.270 align:middle line:90%


01:04:24.270 --> 01:04:32.710 align:middle line:84%
And now let's
substitute x equals 1.

01:04:32.710 --> 01:04:40.590 align:middle line:84%
Well, in this, we get sum k
equals 0 through n, k n choose

01:04:40.590 --> 01:04:43.230 align:middle line:90%
k.

01:04:43.230 --> 01:04:51.570 align:middle line:84%
And in this, we get n
times 2 to the n minus 1.

01:04:51.570 --> 01:04:56.083 align:middle line:90%


01:04:56.083 --> 01:04:56.583 align:middle line:90%
OK.

01:04:56.583 --> 01:04:59.754 align:middle line:90%


01:04:59.754 --> 01:05:01.020 align:middle line:90%
We have our answer.

01:05:01.020 --> 01:05:13.610 align:middle line:90%


01:05:13.610 --> 01:05:26.440 align:middle line:84%
And I want to say that we
kind of skipped a step here.

01:05:26.440 --> 01:05:33.650 align:middle line:90%


01:05:33.650 --> 01:05:54.680 align:middle line:84%
Generating function, for
k n choose k is sum k n

01:05:54.680 --> 01:05:56.920 align:middle line:90%
choose k, x to the k.

01:05:56.920 --> 01:05:59.626 align:middle line:90%


01:05:59.626 --> 01:06:01.620 align:middle line:90%
k equals 0 through n.

01:06:01.620 --> 01:06:04.560 align:middle line:90%


01:06:04.560 --> 01:06:12.040 align:middle line:84%
And what we calculated
here was just

01:06:12.040 --> 01:06:15.160 align:middle line:84%
k n choose k, x
to the k minus 1.

01:06:15.160 --> 01:06:22.620 align:middle line:84%
So this is actually n x 1
minus x to the n minus 1.

01:06:22.620 --> 01:06:28.320 align:middle line:90%


01:06:28.320 --> 01:06:31.640 align:middle line:84%
But since x, if we
substitute in x equals 1,

01:06:31.640 --> 01:06:35.520 align:middle line:84%
it doesn't matter if
we have x to the k or x

01:06:35.520 --> 01:06:39.430 align:middle line:84%
to the k minus 1 here, or
if we have this extra--

01:06:39.430 --> 01:06:42.360 align:middle line:90%


01:06:42.360 --> 01:06:47.600 align:middle line:84%
sorry, plus-- or if we
have this extra x here.

01:06:47.600 --> 01:06:52.980 align:middle line:84%
It will-- if x is
1, they're the same.

01:06:52.980 --> 01:07:04.700 align:middle line:84%
So to multiply the
n-th term in our--

01:07:04.700 --> 01:07:09.380 align:middle line:84%
to multiply the k-th term in
a generating function by k,

01:07:09.380 --> 01:07:14.500 align:middle line:84%
we just differentiate
and multiply by x.

01:07:14.500 --> 01:07:17.140 align:middle line:84%
And this is a very
useful trick, playing

01:07:17.140 --> 01:07:20.020 align:middle line:90%
with generating functions.

01:07:20.020 --> 01:07:24.660 align:middle line:84%
So how would you do this with
counting two different ways?

01:07:24.660 --> 01:07:25.340 align:middle line:90%
Anybody?

01:07:25.340 --> 01:07:33.860 align:middle line:90%


01:07:33.860 --> 01:07:34.950 align:middle line:90%
Yes.

01:07:34.950 --> 01:07:37.280 align:middle line:84%
AUDIENCE: Is that--
I'm just like,

01:07:37.280 --> 01:07:42.420 align:middle line:84%
what's the question is it
the line above it or the--

01:07:42.420 --> 01:07:43.700 align:middle line:90%
PETER SHOR: You mean this?

01:07:43.700 --> 01:07:44.820 align:middle line:90%
AUDIENCE: Yeah.

01:07:44.820 --> 01:07:48.060 align:middle line:90%
PETER SHOR: It's k n choose k--

01:07:48.060 --> 01:07:52.210 align:middle line:84%
AUDIENCE: Oh, you ask
like what's like--

01:07:52.210 --> 01:07:56.570 align:middle line:84%
sorry, I want to ask, what
question are you answering?

01:07:56.570 --> 01:08:00.290 align:middle line:84%
PETER SHOR: Equals
n to the n minus 1.

01:08:00.290 --> 01:08:04.388 align:middle line:84%
Well, we're answering what
is summation k n choose k.

01:08:04.388 --> 01:08:05.930 align:middle line:84%
AUDIENCE: I mean
like you just asked,

01:08:05.930 --> 01:08:08.192 align:middle line:90%
counting two ways, like which--

01:08:08.192 --> 01:08:10.650 align:middle line:84%
PETER SHOR: Oh, we want to
answer this question by counting

01:08:10.650 --> 01:08:11.970 align:middle line:90%
in two different ways.

01:08:11.970 --> 01:08:16.410 align:middle line:84%
AUDIENCE: So it's like you
have a set of n elements

01:08:16.410 --> 01:08:18.149 align:middle line:84%
and you pick k
elements out of it.

01:08:18.149 --> 01:08:20.821 align:middle line:84%
And then from the k elements
you pick one special element?

01:08:20.821 --> 01:08:21.529 align:middle line:90%
PETER SHOR: Yeah.

01:08:21.529 --> 01:08:23.370 align:middle line:90%
Exactly.

01:08:23.370 --> 01:08:29.480 align:middle line:90%
So we have a set of n elements.

01:08:29.480 --> 01:08:33.250 align:middle line:90%


01:08:33.250 --> 01:08:36.300 align:middle line:90%
Choose k elements.

01:08:36.300 --> 01:08:40.529 align:middle line:90%


01:08:40.529 --> 01:08:45.699 align:middle line:90%
Choose one of the k elements.

01:08:45.699 --> 01:08:49.590 align:middle line:90%


01:08:49.590 --> 01:08:54.590 align:middle line:90%
So we have a special element.

01:08:54.590 --> 01:09:00.310 align:middle line:84%
And then we have a
subset of k and a subset

01:09:00.310 --> 01:09:03.210 align:middle line:90%
of n minus k minus 1.

01:09:03.210 --> 01:09:06.670 align:middle line:90%


01:09:06.670 --> 01:09:25.130 align:middle line:84%
And sum over k, we just have a
special element of k n choose k.

01:09:25.130 --> 01:09:32.550 align:middle line:90%


01:09:32.550 --> 01:09:42.630 align:middle line:84%
We have a special element and a
subset of the remaining subset

01:09:42.630 --> 01:09:45.660 align:middle line:90%
of n minus 1 other elements.

01:09:45.660 --> 01:09:53.180 align:middle line:90%


01:09:53.180 --> 01:09:56.480 align:middle line:84%
And you can pick the
special element n ways.

01:09:56.480 --> 01:10:10.220 align:middle line:90%


01:10:10.220 --> 01:10:17.780 align:middle line:84%
Other elements-- or
the subset, sorry--

01:10:17.780 --> 01:10:20.340 align:middle line:90%


01:10:20.340 --> 01:10:33.910 align:middle line:84%
the subset of other elements
is 2 to the n minus 1 ways.

01:10:33.910 --> 01:10:36.620 align:middle line:90%


01:10:36.620 --> 01:10:43.380 align:middle line:84%
And this gives n times
2 to the n minus 1,

01:10:43.380 --> 01:10:48.560 align:middle line:84%
which is what we wanted
in the first place.

01:10:48.560 --> 01:10:51.510 align:middle line:84%
OK, so that's two different
ways to solve this problem.

01:10:51.510 --> 01:11:01.320 align:middle line:90%


01:11:01.320 --> 01:11:04.840 align:middle line:84%
And I want to say
that so far we're

01:11:04.840 --> 01:11:06.880 align:middle line:84%
only doing things with
generating functions

01:11:06.880 --> 01:11:10.260 align:middle line:84%
that we could have done
more easily some other way.

01:11:10.260 --> 01:11:14.198 align:middle line:84%
But there are
things that you can

01:11:14.198 --> 01:11:16.240 align:middle line:84%
do with generating functions
that are much harder

01:11:16.240 --> 01:11:17.300 align:middle line:90%
to do other ways.

01:11:17.300 --> 01:11:20.200 align:middle line:84%
And we will eventually
get to those

01:11:20.200 --> 01:11:23.880 align:middle line:84%
when we start talking
about Fibonacci numbers.

01:11:23.880 --> 01:11:32.160 align:middle line:84%
And I think the next
thing I want to do

01:11:32.160 --> 01:11:34.140 align:middle line:84%
is too long to fit
into 3 minutes.

01:11:34.140 --> 01:11:38.350 align:middle line:84%
So I will let you go and
see everyone on Thursday.

01:11:38.350 --> 01:11:45.000 align:middle line:90%