 In previous videos, we've seen how one can use Maclaurin series and Taylor series to help us solve many calculus problems in a way that's oftentimes easier than without said Maclaurin series. And so it's gonna be beneficial for us to find Maclaurin series for functions. And therefore we oftentimes need to be able to multiple and divide power series in order to create new Maclaurin series. So case in point, take the function f of x which equals x times cosine of x. Notice that this function is x times cosine of x. It's a product of two functions. Now as x is a monomial, which is a polynomial, it's its own power series representation. You don't have to do anything for a polynomial. It's already a power series. Now for cosine of x, we've seen that it's a Maclaurin series is equal to the sum where n equals zero to infinity of negative one to the n times x to the two n over two in factorial. And so if we wanna find a Maclaurin series for f of x, we can take x and multiply by the Maclaurin series of cosine like we see right here. So we get x times this Maclaurin series. We'll times the Maclaurin series by x when you distribute this x through, because this is just a sum. You distribute it term by term by term by term by x point of rules. When you end up with this x to the two n and you times it by x, that'll give us x to the two n plus one that you see in right here. And so everything else is gonna be exactly the same. You get the sum from n equals zero to infinity negative one to the n. You get x to the two n plus one divided by two n factorial. So this gives you your Maclaurin series right here. You get x minus x cubed over two factorial plus x to the fifth over four factorial minus seven x to the seventh over six factorial, et cetera, et cetera. This gives you a Maclaurin series. And if you just need a Taylor polynomial approximation, we can take something like this in which case this would be t seven of x. This is the degree seven Taylor polynomial for x to the cosine of x, x times cosine of x, excuse me. And therefore we can get away with using this Taylor polynomial to approximate this function because these two things will be approximately the same thing. Great. Well, things can get a little more hairy of course when both factors have an infinite power series. Like what if we want the Maclaurin series for e to the x times sine of x, right? We've seen the Maclaurin series for e to the x. This would equal the sum where n equals zero to infinity of x to the n over n factorial in expanded form. We get one plus x plus x squared over two factorial plus x cubed over three factorial, continue on. We can do the Maclaurin series for sine. It's very similar to cosine that we saw just a moment ago. You take the sum where n ranges from zero to infinity of negative one to the n times x to the two n plus one over two n plus one factorial, right? In expanded form, this will look like x minus x cubed over three factorial plus x to the fifth over five factorial, continue on and on and on and on and on. So these power series are essentially just infinite polynomials. And so if you had a polynomial times a polynomial, like if you took one plus x plus x squared over two factorial and you wanted to multiply it by x minus x cubed over three factorial, if you did something like that, you would just foil this thing out. That's what you would do. You'd use the distributed property and look at all the possible products. You distribute the one, distribute the x, distribute the x squared. You look at all those possible combinations. The fact that the sequence is now infinite doesn't actually change how that works. So what we're gonna do is we're going to take the first power series and write it on top. So this is the power series for e to the x you're gonna see on top. And then I'm gonna take the Maclaurin series for sine and write it down below. And so we're gonna take sine of x right here. Now for convenience, I did put a space right here, right? Because I want like terms to be in common column. So we have an x column. I'm gonna skip this square column because sine doesn't have one. Then we get an x cube column. And you make this thing go as far as you want. Go on and on and on and on and on and on, right? And so now look at all the possible products. You're gonna have x times one, which is an x recorded here. You're gonna get x times x, which is an x squared. You put in the x squared column. You're gonna get x times one half x squared. That's gonna give you a one half x cube. You're gonna write it in the x cubed column. You get x times one sixth x cubed. That'll give you one sixth x to the fourth. We're gonna put in the x to the fourth column. And then keep on going as many times as you need to. Then take the next term. We have this negative one sixth x cube. You're gonna times that by one and you're gonna end up with a negative one sixth x cubed. Okay? Then you're gonna take negative one sixth x cube times that by x. That'll give you negative one sixth x to the fourth, which we get right here. Record the product there and keep on going. You're gonna get a one half x squared times negative one sixth x cubed. That would give you an x to the fifth term you put in that column. Then you're gonna take x cubed times x cubed, multiply those together. You're gonna get negative one over 36 x to the sixth. You put that in that column and keep on going. You'll notice I kind of do dot dot dots because how many columns do you need? Well, that kind of depends on what we're going for. We'll come back to that question in a moment. You do all those possible distributions. Just do one monomial at a time and go through every possibility from the first one. Okay? So you're gonna get two rows. Well, it depends on how many terms you did. You're gonna get one row for the first one. You're gonna get another row for the next one. And then depending on how many times you go down, you might get another row. But the thing is if you aligned everything in columns, we then can combine like terms very quickly. X plus nothing is an X. X squared plus nothing is an X squared. You get one half x cubed minus one sixth x cubed. In this case, we do have to find some common denominators, but the difference will be one third x cubed. So then we get a one sixth x to the fourth minus one sixth x to the fourth. Those will cancel. If we did the x to the fifth terms, we'd combine like terms there. If we did x to the sixth, we would combine some like terms right there. The key thing to make sure though is that you have to make sure you do enough rows so that everyone involved gets included there. Cause it's like, how do you produce an x to the fifth? An x to the fifth would come about by taking x times an x to the fourth. An x to the fifth would come about by doing an x cubed with an x. I'm sorry, I'm trying to do x to the fifth, x cubed with an x squared. You would also get an x to the fifth by taking an x fifth right here and times it by one. And those are the only possibilities. So if you want to get up to the x to the fifth, you might have to do an extra row. So you have to kind of do some extra rows right here. You get this kind of like this matrix of all this information. And so when you combine all these things together, this last row will be our power series representation. For each case, you get an x, you get an x squared, you get a one-third x cubed. The next term, well, the x to the fourth canceled outright, so you just have zero of those. The next one would be an x to the fifth, which we don't know what the coefficient is. We didn't do enough information, but we could find more information and do it if it was necessary. We could recursively find the coefficient of x to the fifth. And we could recursively find the coefficient of x to the seventh or x to the sixth or however many turns we need to do. So generally speaking, we don't have a formula for the product of these two Maclaurin series, at least not a general formula. We do get a recursive formula, and that's typically sufficient because honestly, like we saw in the previous video, when we were trying to estimate an integral using a Maclaurin series, typically we don't use the whole series. We actually use a Taylor polynomial, which is just a partial sum of the series. And so in fact, whatever it is, we need the Maclaurin series for e to the x times sine of x4. We actually might be a good way with just the degree three Taylor polynomial that we see on the screen right now. So this recursive approach is actually sufficient for our purposes. Sometimes we have to do division as well. Like what if we want the Maclaurin series for tangent of x? Tangent of x is the quotient of sine and cosine for which we know the Maclaurin series for sine and cosine. We just saw the one for sine. We've seen cosine previously, but here's a reminder in case we forgot it from eight minutes ago. Anyways, if we're trying to do long division with polynomials, you're gonna take the numerator. It's gonna be our dividend right here. Then the denominator is gonna be our divisor. So here's cosine's Maclaurin series. Here's sine's Maclaurin series. And you do all the possible quotients. How many ways does x divide into one? So you look at the term here, the first term here, the first term here. x divided by one is x. You're gonna record that number on the top, like you see right there. The next thing to do is you're gonna take the entire divisor and times it by x, in which case one times x is an x, right? One half x squared is gonna give us a negative one half x cubed. x times positive 124th x to the fourth is gonna be 124th x to the fifth, like so. And you keep on going as far as you need to go because they might tell you find the degree three Taylor polynomial or in this case, the degree five. And so then once you multiply the divisor by your quotient right there, x, you then subtract these things from above, right? x minus x is zero, so you get nothing there. Negative one sixth x cubed plus one half x cubed is gonna give you a one third x cubed. One over 120 x to the fifth minus 124th x to the fifth. The fractions can be a little bit tedious, but you're gonna get 130th x to the fifth. And then keep on going as many terms as you need, right? Then you repeat this process. Look at the first term, one third x cubed. And so you take one third x cubed and you divide it by one. All that, in this case, it's not super exciting. It's gonna be one third x cubed again, right? That's the number you're gonna record up here. And so then what we're gonna do, erase all this, we're gonna take this number and distribute it onto each term in the divisor. Go as far as you need and we're gonna record those things down here. And so assuming we got this number correctly, these two numbers should be identical. So when you subtract them, they're identical, just like Fred and George Weasley, one third x cubed minus one third x cubed, they're gonna cancel and then do the subsequent division right there. Negative 130th x to the fifth plus one sixth x to the fifth, that's gonna give you two fifteenths x to the fifth. And then keep on going and going and going as far as you need. The next question is then how many times does one divided into two fifteenths x to the fifth that then brings it up here and you can keep on going. And so then we've now figured out the first three terms of the Maclaurin series for tangent. You get x plus one third x cubed plus two fifteenths x to the fifth and you can keep on going on and on and on. This gives us a recursive way of finding the Maclaurin series for division and multiplication. And with a little bit more sophisticated mathematics, we can remove this recursion and actually get a general formula. It turns out these tangent numbers are actually kind of a fun sequence, like one, one third, two fifteenths, what's the next number. There's actually a nice formula that predicts what it's gonna be, but developing that formula goes beyond the scope of our class, a recursive formula will be sufficient for us and so we can find these Taylor series and these Taylor polynomials more specifically by recursion for division and quotients. And sometimes we're gonna need to be able to do these things. And so that brings us to the end of lecture 47, where we're gonna talk about Maclaurin series and Taylor series. As I keep on heading to in our next lecture 48, we're gonna talk about Taylor polynomials and focus more on how Taylor polynomials can be used to approximate problems, like integration like we've seen before. So we'll learn more about the Taylor polynomials next time, but we've already seen how useful they are. The Taylor polynomials approximate the Taylor series and like in situations like this, we don't know the whole Taylor series, but we do know the Taylor polynomial up to degree five. And so we might actually just use that to approximate sign, our tangent here. Tangent is approximately this polynomial right here. And so next time we'll talk some more about that and do let me know if you have any questions in the meanwhile, if you want to, I mean, feel free to post your comment or your questions in the comments below. I'm happy to answer them for you. It really is kind of fun and I hope to hear from you all next time. See ya.