WEBVTT

00:00:00.499 --> 00:00:01.460
GILBERT STRANG: OK.

00:00:01.460 --> 00:00:04.370
So this is using Fourier series.

00:00:04.370 --> 00:00:08.220
So I had to pick
an equation where

00:00:08.220 --> 00:00:11.600
we were given a
function, and not just

00:00:11.600 --> 00:00:13.660
a couple of initial values.

00:00:13.660 --> 00:00:17.210
So I made the equation a
partial differential equation.

00:00:17.210 --> 00:00:20.910
The most famous one,
Laplace's equation.

00:00:20.910 --> 00:00:23.590
So this is the setup.

00:00:23.590 --> 00:00:27.393
And you'll see how
Fourier series comes in.

00:00:27.393 --> 00:00:28.900
We're in a circle.

00:00:28.900 --> 00:00:31.780
I'm going to make this
a nice model problem.

00:00:31.780 --> 00:00:36.180
So inside this circle we're
solving Laplace's equation.

00:00:36.180 --> 00:00:38.860
Laplace's equation was
the second derivative

00:00:38.860 --> 00:00:43.120
of u in the x direction,
plus the second derivative

00:00:43.120 --> 00:00:48.900
of u in the y direction, is 0.

00:00:48.900 --> 00:00:54.070
That's the way heat,
temperature, distributes itself

00:00:54.070 --> 00:00:55.070
when you leave it alone.

00:00:57.870 --> 00:01:04.099
In this problem I'm going to put
a source of heat at that point.

00:01:04.099 --> 00:01:06.390
So it'll be a point source.

00:01:06.390 --> 00:01:07.870
A delta function.

00:01:07.870 --> 00:01:13.290
And on the rest of the
boundary, temperature 0.

00:01:13.290 --> 00:01:17.240
So the boundary function
is a delta function

00:01:17.240 --> 00:01:21.170
with a spike at that one
point, and 0 elsewhere.

00:01:21.170 --> 00:01:25.770
And our problem is to solve
the Laplace's equation

00:01:25.770 --> 00:01:28.210
inside the circle.

00:01:28.210 --> 00:01:32.100
And we use polar coordinates
because we've got a circle.

00:01:32.100 --> 00:01:34.550
So there is the
equation with x and y,

00:01:34.550 --> 00:01:38.530
but we really are
thinking r and theta.

00:01:38.530 --> 00:01:41.240
And the reason is, you
get beautiful solutions

00:01:41.240 --> 00:01:45.570
to this equation
using r and theta.

00:01:45.570 --> 00:01:48.980
And that was a
family of solutions.

00:01:48.980 --> 00:01:52.840
r to the n-th cos
n theta just works.

00:01:52.840 --> 00:01:56.830
And so does r to the
n-th sine n theta.

00:01:56.830 --> 00:01:59.200
And that's for every n.

00:01:59.200 --> 00:02:01.180
So we have-- we can combine.

00:02:01.180 --> 00:02:02.890
We have a linear equation.

00:02:02.890 --> 00:02:07.490
We can take combinations of
solutions with coefficients

00:02:07.490 --> 00:02:11.810
a n in the cosines,
and bn in the sines.

00:02:11.810 --> 00:02:14.530
And now here's the key step.

00:02:14.530 --> 00:02:16.990
Put in r equal 1.

00:02:16.990 --> 00:02:18.360
Put r equal 1.

00:02:18.360 --> 00:02:26.880
And then this solution, u
at 1 and theta-- r equal 1--

00:02:26.880 --> 00:02:29.690
is the boundary.

00:02:29.690 --> 00:02:31.030
It's the circle.

00:02:31.030 --> 00:02:37.970
And that's where we're given u
of 1 to be the delta function.

00:02:37.970 --> 00:02:39.970
The point source.

00:02:39.970 --> 00:02:41.170
The delta function.

00:02:41.170 --> 00:02:43.750
Delta of theta.

00:02:43.750 --> 00:02:46.670
The point source
at theta equals 0.

00:02:46.670 --> 00:02:48.860
So you see our job.

00:02:48.860 --> 00:02:52.570
That function, that
boundary condition,

00:02:52.570 --> 00:02:56.730
is supposed to tell us
the a's and the b's.

00:02:56.730 --> 00:02:59.400
And then we have our solution.

00:02:59.400 --> 00:03:05.890
So by putting r equal
to 1 in this formula,

00:03:05.890 --> 00:03:07.930
we're supposed to get
the delta function.

00:03:07.930 --> 00:03:09.440
So let me put r equal 1.

00:03:09.440 --> 00:03:11.270
Easy to do.

00:03:11.270 --> 00:03:18.010
It's the sum of a n, 1
to the n-th, cos n theta,

00:03:18.010 --> 00:03:25.120
plus the sum of bn, 1 to
the n-th, sine n theta,

00:03:25.120 --> 00:03:28.000
is supposed to match
the delta function.

00:03:31.130 --> 00:03:33.500
So that's the Fourier series
for the delta function.

00:03:33.500 --> 00:03:35.180
That's the whole point.

00:03:35.180 --> 00:03:41.160
That we use a Fourier
series expression

00:03:41.160 --> 00:03:44.310
for the boundary function,
whatever that boundary function

00:03:44.310 --> 00:03:44.810
is.

00:03:44.810 --> 00:03:48.230
Here it's a particularly
nice neat one.

00:03:48.230 --> 00:03:52.300
And actually, the delta
function is an even function.

00:03:52.300 --> 00:03:58.180
It's 0 at theta and
it's 0 at minus theta.

00:03:58.180 --> 00:04:05.020
So changing theta to minus theta
still leaves me the spike at 0.

00:04:05.020 --> 00:04:08.080
So because it's
an even function,

00:04:08.080 --> 00:04:11.030
I won't see any signs.

00:04:11.030 --> 00:04:13.380
I won't see any odd functions.

00:04:13.380 --> 00:04:14.850
The sine theta.

00:04:14.850 --> 00:04:18.870
And I have an easy time
to find the coefficients

00:04:18.870 --> 00:04:20.890
a n of the cosines.

00:04:20.890 --> 00:04:26.330
Actually, we did that directly
from the formula for the a n's.

00:04:26.330 --> 00:04:28.990
Let me just remember
that formula.

00:04:28.990 --> 00:04:35.850
The formula was a0 was 1
over 2 pi times the average.

00:04:38.835 --> 00:04:43.490
a0 is the average value
of the temperature.

00:04:43.490 --> 00:04:48.800
And the temperature on the
boundary is delta theta.

00:04:48.800 --> 00:04:54.900
And that integrates to 1, and
we get the answer 1 over 2 pi.

00:04:54.900 --> 00:04:57.555
That's the average temperature.

00:04:57.555 --> 00:04:59.320
Isn't that a little weird?

00:04:59.320 --> 00:05:02.500
The temperature 0
except at one point.

00:05:02.500 --> 00:05:08.960
At that point it's a delta
function with the coefficient 1

00:05:08.960 --> 00:05:10.000
outside it.

00:05:10.000 --> 00:05:12.820
And then we get 1 over
2 pi as the average.

00:05:12.820 --> 00:05:19.570
The other a n's, the
coefficients of the cosines,

00:05:19.570 --> 00:05:25.360
are 1 over pi, times the
integral of our delta function,

00:05:25.360 --> 00:05:30.110
times cos n theta d theta.

00:05:30.110 --> 00:05:34.510
And the delta function,
that point source,

00:05:34.510 --> 00:05:38.660
picks out that number
at theta equals 0.

00:05:38.660 --> 00:05:40.350
And that number is 1.

00:05:40.350 --> 00:05:43.890
So I'm getting 1 over pi.

00:05:43.890 --> 00:05:47.830
So finally I now
know the a's and b's.

00:05:47.830 --> 00:05:51.230
When I put those in, that
tells me the solution.

00:05:51.230 --> 00:05:58.230
The solution-- now I can
put r back in the picture--

00:05:58.230 --> 00:05:59.990
it's a sum.

00:05:59.990 --> 00:06:03.410
Well, let me take the a0 term.

00:06:03.410 --> 00:06:09.200
The a0 is 1 over 2 pi--
that's the constant, that's

00:06:09.200 --> 00:06:22.780
the average-- plus the sum of
1 over pi cos n theta, from n

00:06:22.780 --> 00:06:26.450
equals 1 to infinity.

00:06:26.450 --> 00:06:27.853
And r to the n-th.

00:06:27.853 --> 00:06:29.250
Sorry. r to the n-th.

00:06:33.640 --> 00:06:35.650
So you see what happens.

00:06:35.650 --> 00:06:40.750
When r is 1, we have the Fourier
series for the delta function.

00:06:40.750 --> 00:06:45.350
That's the very
exceptional function

00:06:45.350 --> 00:06:47.950
that's given on the boundary.

00:06:47.950 --> 00:06:54.280
As soon as r is less than
1, these r to the n-th's

00:06:54.280 --> 00:06:58.450
get small, and we
have a series that

00:06:58.450 --> 00:07:00.740
adds up to a reasonable sum.

00:07:00.740 --> 00:07:06.890
And we can actually-- it's
possible to add up that series.

00:07:06.890 --> 00:07:09.100
It's possible to
add up that series.

00:07:09.100 --> 00:07:14.580
It's a geometric series
if you switch from cosines

00:07:14.580 --> 00:07:16.130
to exponentials.

00:07:16.130 --> 00:07:18.850
That's usually the good
way to get good formulas.

00:07:18.850 --> 00:07:20.910
And here, so you can add it up.

00:07:20.910 --> 00:07:24.540
And I think there's a 1
over 2 pi still there.

00:07:24.540 --> 00:07:31.050
And I think it's 1 minus r
squared, over 1 plus r squared,

00:07:31.050 --> 00:07:37.260
minus 2r cos theta.

00:07:37.260 --> 00:07:39.700
Let me just be sure
I got that right.

00:07:39.700 --> 00:07:41.350
Yep, looks good.

00:07:41.350 --> 00:07:42.220
Looks good.

00:07:42.220 --> 00:07:43.690
And we could check if it's good.

00:07:46.200 --> 00:07:49.240
Let's take theta equal 0.

00:07:49.240 --> 00:07:51.290
So if we take theta equal 0.

00:07:51.290 --> 00:07:53.710
Let me draw that circle again.

00:07:53.710 --> 00:07:54.890
Theta equal 0.

00:07:54.890 --> 00:07:57.640
We're coming out on that ray.

00:07:57.640 --> 00:08:01.940
And we're expecting to see
infinity when we get there,

00:08:01.940 --> 00:08:03.120
at r equal 1.

00:08:03.120 --> 00:08:05.850
So theta equal 0.

00:08:05.850 --> 00:08:07.780
So let me just put that.

00:08:07.780 --> 00:08:12.210
On the ray, theta equal 0.

00:08:12.210 --> 00:08:15.020
This is what you should do.

00:08:15.020 --> 00:08:18.590
We have a formula
for all r and theta,

00:08:18.590 --> 00:08:21.620
but let's look at
some particular points

00:08:21.620 --> 00:08:23.200
to see what's happening.

00:08:23.200 --> 00:08:28.180
So along that ray,
where theta is 0,

00:08:28.180 --> 00:08:34.919
I have 1 over 2 pi, 1
minus r squared, over 1

00:08:34.919 --> 00:08:37.460
plus r squared, minus 2r.

00:08:37.460 --> 00:08:40.130
Because cos theta is 1.

00:08:40.130 --> 00:08:47.050
And 1 plus r squared, minus
2r, is 1 minus r squared.

00:08:47.050 --> 00:08:48.480
Right?

00:08:48.480 --> 00:08:52.010
Because cos theta
is 1 on this ray.

00:08:52.010 --> 00:08:53.010
Theta is 0.

00:08:53.010 --> 00:08:55.850
Cos theta is 1.

00:08:55.850 --> 00:08:59.580
And now 1 minus r will
factor out of this.

00:08:59.580 --> 00:09:04.250
And I think we get 1 plus r.

00:09:04.250 --> 00:09:07.760
And we still have a
1 minus r down below.

00:09:07.760 --> 00:09:09.880
I like that.

00:09:09.880 --> 00:09:12.160
You don't often, for partial
differential equations,

00:09:12.160 --> 00:09:15.770
get some nice expression
for the solution.

00:09:15.770 --> 00:09:17.270
So that's the solution.

00:09:17.270 --> 00:09:23.490
And as r goes to 1,
this solution blows up.

00:09:23.490 --> 00:09:24.040
Right.

00:09:24.040 --> 00:09:26.460
The temperature is
infinite on the boundary,

00:09:26.460 --> 00:09:29.700
but the temperature is
something reasonable inside.

00:09:29.700 --> 00:09:34.000
And at r equals 0,
I have 1 over 2 pi.

00:09:34.000 --> 00:09:34.790
Well, of course.

00:09:34.790 --> 00:09:36.760
It's the average value.

00:09:36.760 --> 00:09:39.310
Right at the center
that temperature

00:09:39.310 --> 00:09:41.710
is going to be the
average on the boundary.

00:09:41.710 --> 00:09:46.840
That's a natural key property
of Laplace's equation.

00:09:46.840 --> 00:09:48.830
It averages everything.

00:09:48.830 --> 00:09:53.780
Actually, if I take a
little circle in anywhere,

00:09:53.780 --> 00:09:56.800
those temperature in the
center of that circle

00:09:56.800 --> 00:10:00.470
would be the average
of the temperatures

00:10:00.470 --> 00:10:02.860
around the little circle.

00:10:02.860 --> 00:10:04.110
For all the circles.

00:10:04.110 --> 00:10:08.620
It's just the
Laplace's equation.

00:10:08.620 --> 00:10:11.790
Solving Laplace's equation
averages everything.

00:10:11.790 --> 00:10:20.560
And the result is that the
temperature function sort of

00:10:20.560 --> 00:10:23.190
smoothes out as I come in.

00:10:23.190 --> 00:10:26.600
Around the boundary
it's far from smooth.

00:10:26.600 --> 00:10:30.770
There's a big jolt
at theta equals 0.

00:10:30.770 --> 00:10:35.380
But if I look on that circle,
or that circle, or this circle,

00:10:35.380 --> 00:10:41.040
the temperature is a
nice smooth function.

00:10:41.040 --> 00:10:46.780
And it's never going to be above
the maximum on the boundary.

00:10:46.780 --> 00:10:50.280
And it's never going to be below
the minimum on the boundary.

00:10:50.280 --> 00:10:53.730
Everything's being averaged.

00:10:53.730 --> 00:10:57.390
So that's, you see, a use
of the Fourier series.

00:10:57.390 --> 00:10:59.350
For one particular function.

00:10:59.350 --> 00:11:04.260
I could do another function,
but I don't think I will.

00:11:04.260 --> 00:11:08.320
I could take the function that's
1 on the top of the circle

00:11:08.320 --> 00:11:11.630
and minus 1 on the bottom
half of the circle.

00:11:11.630 --> 00:11:15.710
OK, that's a function with a
jump, but not a delta function.

00:11:15.710 --> 00:11:19.500
So we would see a Fourier
series that would give us

00:11:19.500 --> 00:11:20.655
the a's and the b's.

00:11:20.655 --> 00:11:24.070
There would probably
only be b's in that case.

00:11:24.070 --> 00:11:24.690
Sine.

00:11:24.690 --> 00:11:25.950
Sine terms.

00:11:25.950 --> 00:11:29.900
And we'd get an answer.

00:11:29.900 --> 00:11:32.090
May I just, while I'm
talking about averages,

00:11:32.090 --> 00:11:34.470
add one final comment.

00:11:34.470 --> 00:11:39.020
Usually, for a
complicated region,

00:11:39.020 --> 00:11:42.880
we can't solve Laplace's
equation with formulas.

00:11:42.880 --> 00:11:45.500
It's not possible.

00:11:45.500 --> 00:11:50.810
We can't find sines and cosines
that match some crazy boundary.

00:11:50.810 --> 00:11:55.600
So we have to replace
Laplace's equation.

00:11:55.600 --> 00:11:58.320
So I'll write Laplace's
equation again.

00:12:05.160 --> 00:12:13.300
That goes into u--
we have a region.

00:12:13.300 --> 00:12:19.050
And we carve it out with a grid.

00:12:19.050 --> 00:12:22.680
And then at each
point on the grid,

00:12:22.680 --> 00:12:27.400
we have an equation connecting
the value of u at that point.

00:12:27.400 --> 00:12:30.690
Say u0 at the center.

00:12:30.690 --> 00:12:42.040
With u east, maybe, u
west, u north, and u south.

00:12:45.200 --> 00:12:47.640
So we have an
equation, and I want

00:12:47.640 --> 00:12:49.690
to write that equation down.

00:12:49.690 --> 00:12:56.010
u center is just going
to be the average.

00:12:56.010 --> 00:13:05.270
It's just going to be 1/4 of
u east, u west, u north, and u

00:13:05.270 --> 00:13:05.770
south.

00:13:09.070 --> 00:13:13.150
So that'll be true at--
that equation will hold.

00:13:13.150 --> 00:13:15.730
The unknowns are all these u's.

00:13:15.730 --> 00:13:17.690
The u's of all the mesh points.

00:13:17.690 --> 00:13:20.490
And I have an equation
at every mesh point.

00:13:20.490 --> 00:13:26.640
So I have the same number of
equations from the mesh points

00:13:26.640 --> 00:13:29.890
as unknowns at the mesh points.

00:13:29.890 --> 00:13:36.500
I solve that big system, and
that gives me a solution u.

00:13:36.500 --> 00:13:40.170
An approximate solution
u to Laplace's equation.

00:13:40.170 --> 00:13:44.180
So this would be called
Laplace's difference equation,

00:13:44.180 --> 00:13:49.520
or Laplace's five-point
scheme, because it uses

00:13:49.520 --> 00:13:53.040
five points in that average.

00:13:53.040 --> 00:13:53.810
OK.

00:13:53.810 --> 00:13:57.650
That's an important problem
in numerical analysis.

00:13:57.650 --> 00:13:59.360
Thank you.