0:00:00.000,0:00:00.660 0:00:00.660,0:00:02.930 In the last video, we[br]took the Maclaurin series 0:00:02.930,0:00:04.180 of cosine of x. 0:00:04.180,0:00:06.670 We approximated it[br]using this polynomial. 0:00:06.670,0:00:08.560 And we saw this pretty[br]interesting pattern. 0:00:08.560,0:00:10.310 Let's see if we can[br]find a similar pattern 0:00:10.310,0:00:14.360 if we try to approximate sine[br]of x using a Maclaurin series. 0:00:14.360,0:00:16.000 And once again, a[br]Maclaurin series 0:00:16.000,0:00:18.240 is really the same thing[br]as a Taylor series, 0:00:18.240,0:00:20.800 where we are centering[br]our approximation 0:00:20.800,0:00:23.740 around x is equal to 0. 0:00:23.740,0:00:26.830 So it's just a special[br]case of a Taylor series. 0:00:26.830,0:00:29.870 So let's take f of[br]x in this situation 0:00:29.870,0:00:31.410 to be equal to sine of x. 0:00:31.410,0:00:36.380 0:00:36.380,0:00:38.890 And let's do the same thing[br]that we did with cosine of x. 0:00:38.890,0:00:40.598 Let's just take the[br]different derivatives 0:00:40.598,0:00:42.450 of sine of x really fast. 0:00:42.450,0:00:46.240 So if you have the first[br]derivative of sine of x, 0:00:46.240,0:00:48.490 is just cosine of x. 0:00:48.490,0:00:51.160 The second derivative[br]of the sine of x 0:00:51.160,0:00:55.880 is the derivative of cosine of[br]x, which is negative sine of x. 0:00:55.880,0:00:58.790 The third derivative is going[br]to be the derivative of this. 0:00:58.790,0:01:00.437 So I'll just write[br]a 3 in parentheses 0:01:00.437,0:01:02.270 there, instead of doing[br]prime, prime, prime. 0:01:02.270,0:01:04.310 So the third derivative[br]is the derivative 0:01:04.310,0:01:07.790 of this, which is[br]negative cosine of x. 0:01:07.790,0:01:11.570 The fourth derivative[br]is the derivative 0:01:11.570,0:01:15.020 of this, which is[br]positive sine of x again. 0:01:15.020,0:01:17.950 So you see, just like cosine[br]of x, it kind of cycles 0:01:17.950,0:01:19.990 after you take the[br]derivative enough times. 0:01:19.990,0:01:22.550 And we care-- in order to do[br]the Maclaurin, series-- we care 0:01:22.550,0:01:26.840 about evaluating the function,[br]and each of these derivatives 0:01:26.840,0:01:28.450 at x is equal to 0. 0:01:28.450,0:01:30.220 So let's do that. 0:01:30.220,0:01:32.510 So for this, let me do this[br]in a different color, not 0:01:32.510,0:01:34.030 that same blue. 0:01:34.030,0:01:36.320 I'll do it in this purple color. 0:01:36.320,0:01:38.810 So f-- that's hard[br]to see, I think 0:01:38.810,0:01:40.930 So let's do this[br]other blue color. 0:01:40.930,0:01:45.620 So f of 0, in this[br]situation, is 0. 0:01:45.620,0:01:50.280 And f, the first derivative[br]evaluated at 0, is 1. 0:01:50.280,0:01:52.880 Cosine of 0 is 1. 0:01:52.880,0:01:57.300 Negative sine of 0[br]is going to be 0. 0:01:57.300,0:02:01.210 So f prime prime, the second[br]derivative evaluated at 0 is 0. 0:02:01.210,0:02:06.335 The third derivative[br]evaluated at 0 is negative 1. 0:02:06.335,0:02:08.411 Cosine of 0 is 1. 0:02:08.411,0:02:09.660 You have a negative out there. 0:02:09.660,0:02:10.850 It is negative 1. 0:02:10.850,0:02:14.850 And then the fourth[br]derivative evaluated at 0 0:02:14.850,0:02:16.594 is going to be 0 again. 0:02:16.594,0:02:18.385 And we could keep going,[br]but once again, it 0:02:18.385,0:02:19.593 seems like there's a pattern. 0:02:19.593,0:02:21.130 0, 1, 0, negative[br]1, 0, then you're 0:02:21.130,0:02:22.920 going to go back to positive 1. 0:02:22.920,0:02:24.750 So on and so forth. 0:02:24.750,0:02:28.230 So let's find its[br]polynomial representation 0:02:28.230,0:02:29.510 using the Maclaurin series. 0:02:29.510,0:02:31.380 And just a reminder,[br]this one up here, 0:02:31.380,0:02:34.210 this was approximately[br]cosine of x. 0:02:34.210,0:02:36.220 And you'll get closer and[br]closer to cosine of x. 0:02:36.220,0:02:37.960 I'm not rigorously[br]showing you how 0:02:37.960,0:02:40.760 close, in that it's definitely[br]the exact same thing as cosine 0:02:40.760,0:02:42.710 of x, but you get closer[br]and closer and closer 0:02:42.710,0:02:44.975 to cosine of x as you[br]keep adding terms here. 0:02:44.975,0:02:46.350 And if you go to[br]infinity, you're 0:02:46.350,0:02:48.920 going to be pretty[br]much at cosine of x. 0:02:48.920,0:02:51.490 Now let's do the same[br]thing for sine of x. 0:02:51.490,0:02:52.960 So I'll pick a new color. 0:02:52.960,0:02:54.980 This green should be nice. 0:02:54.980,0:02:56.820 So this is our new p of x. 0:02:56.820,0:02:58.590 So this is approximately[br]going to be 0:02:58.590,0:03:01.600 sine of x, as we add[br]more and more terms. 0:03:01.600,0:03:06.820 And so the first term here, f[br]of 0, that's just going to be 0. 0:03:06.820,0:03:09.050 So we're not even going[br]to need to include that. 0:03:09.050,0:03:11.090 The next term is[br]going to be f prime 0:03:11.090,0:03:13.800 of 0, which is 1, times x. 0:03:13.800,0:03:15.880 So it's going to be x. 0:03:15.880,0:03:18.450 Then the next term is f[br]prime, the second derivative 0:03:18.450,0:03:21.220 at 0, which we see here is 0. 0:03:21.220,0:03:23.020 Let me scroll down a little bit. 0:03:23.020,0:03:24.340 It is 0. 0:03:24.340,0:03:26.610 So we won't have[br]the second term. 0:03:26.610,0:03:29.590 This third term right[br]here, the third derivative 0:03:29.590,0:03:32.920 of sine of x evaluated[br]at 0, is negative 1. 0:03:32.920,0:03:36.830 So we're now going[br]to have a negative 1. 0:03:36.830,0:03:39.490 Let me scroll down[br]so you can see this. 0:03:39.490,0:03:42.240 Negative 1-- this is[br]negative 1 in this case-- 0:03:42.240,0:03:45.505 times x to the third[br]over 3 factorial. 0:03:45.505,0:03:50.880 0:03:50.880,0:03:52.860 And then the next[br]term is going to be 0, 0:03:52.860,0:03:55.850 because that's the[br]fourth derivative. 0:03:55.850,0:03:59.660 The fourth derivative evaluated[br]at 0 is the next coefficient. 0:03:59.660,0:04:03.052 We see that that is going to be[br]0, so it's going to drop off. 0:04:03.052,0:04:04.510 And what you're[br]going to see here-- 0:04:04.510,0:04:06.825 and actually maybe I haven't[br]done enough terms for you, 0:04:06.825,0:04:08.300 for you to feel good about this. 0:04:08.300,0:04:10.330 Let me do one more[br]term right over here. 0:04:10.330,0:04:12.690 Just so it becomes clear. 0:04:12.690,0:04:15.450 f of the fifth[br]derivative of x is 0:04:15.450,0:04:17.440 going to be cosine of x again. 0:04:17.440,0:04:20.209 The fifth derivative-- we'll[br]do it in that same color, 0:04:20.209,0:04:27.180 just so it's consistent-- the[br]fifth derivative evaluated at 0 0:04:27.180,0:04:29.570 is going to be 1. 0:04:29.570,0:04:33.470 So the fourth derivative[br]evaluated at 0 is 0, 0:04:33.470,0:04:36.860 then you go to the fifth[br]derivative evaluated at 0, 0:04:36.860,0:04:38.814 it's going to be positive 1. 0:04:38.814,0:04:40.730 And if I kept doing this,[br]it would be positive 0:04:40.730,0:04:44.440 1-- I have to write the 1[br]as the coefficient-- times x 0:04:44.440,0:04:47.770 to the fifth over 5 factorial. 0:04:47.770,0:04:50.530 So there's something[br]interesting going on here. 0:04:50.530,0:04:55.500 For cosine of x, I had 1,[br]essentially 1 times x to the 0. 0:04:55.500,0:04:58.420 Then I don't have x[br]to the first power. 0:04:58.420,0:05:00.240 I don't have x to the[br]odd powers, actually. 0:05:00.240,0:05:02.830 And then I just essentially have[br]x to all of the even powers. 0:05:02.830,0:05:06.650 And whatever power it is, I'm[br]dividing it by that factorial. 0:05:06.650,0:05:09.400 And then the sines[br]keep switching. 0:05:09.400,0:05:12.300 I shouldn't say this is an even[br]power, because 0 really isn't. 0:05:12.300,0:05:14.440 Well, I guess you can[br]view it as an even number, 0:05:14.440,0:05:17.540 because-- well I won't[br]go into all of that. 0:05:17.540,0:05:22.440 But it's essentially 0, 2,[br]4, 6, so on and so forth. 0:05:22.440,0:05:24.200 So this is[br]interesting, especially 0:05:24.200,0:05:25.440 when you compare to this. 0:05:25.440,0:05:26.760 This is all of the odd powers. 0:05:26.760,0:05:29.060 This is x to the first[br]over 1 factorial. 0:05:29.060,0:05:30.300 I didn't write it here. 0:05:30.300,0:05:32.580 This is x to the[br]third over 3 factorial 0:05:32.580,0:05:34.477 plus x to the fifth[br]over 5 factorial. 0:05:34.477,0:05:35.810 Yeah, 0 would be an even number. 0:05:35.810,0:05:39.830 Anyway, my brain is in a[br]different place right now. 0:05:39.830,0:05:40.890 And you could keep going. 0:05:40.890,0:05:43.190 If we kept this process[br]up, you would then 0:05:43.190,0:05:44.280 keep switching sines. 0:05:44.280,0:05:48.200 X to the seventh over[br]7 factorial plus x 0:05:48.200,0:05:49.527 to the ninth over 9 factorial. 0:05:49.527,0:05:51.110 So there's something[br]interesting here. 0:05:51.110,0:05:55.280 You once again see this[br]kind of complimentary nature 0:05:55.280,0:05:56.930 between sine and cosine here. 0:05:56.930,0:05:58.630 You see almost[br]this-- they're kind 0:05:58.630,0:06:00.960 of filling each[br]other's gaps over here. 0:06:00.960,0:06:03.220 Cosine of x is all[br]of the even powers 0:06:03.220,0:06:05.680 of x divided by that[br]power's factorial. 0:06:05.680,0:06:08.310 Sine of x, when you take its[br]polynomial representation, 0:06:08.310,0:06:12.470 is all of the odd powers of[br]x divided by its factorial, 0:06:12.470,0:06:14.100 and you switch sines. 0:06:14.100,0:06:16.640 In the next video,[br]I'll do e to the x. 0:06:16.640,0:06:18.660 And what's really[br]fascinating is that e 0:06:18.660,0:06:22.310 to the x starts to look like[br]a little bit of a combination 0:06:22.310,0:06:24.050 here, but not quite. 0:06:24.050,0:06:25.790 And you really do[br]get the combination 0:06:25.790,0:06:28.310 when you involve[br]imaginary numbers. 0:06:28.310,0:06:32.860 And that's when it starts to[br]get really, really mind blowing.