Transcript for:
Exploring Taylor and Maclaurin Series

in this video we're going to talk about how to find a Taylor series and the McLaurin series for different functions so let's start with this example let's find the Taylor series given a function f of x is equal to Ln X centered at c equal one so what we need to do is basically write out the first four derivatives so F Prime of x the derivative of Ln X that's one over X now to find a second derivative we need to rewrite it and then use the power rule so the second derivative is negative one divided by x squared and then to find the third derivative let's use the power rule again so for the third derivative it's going to be 2 divided by X cubed and then to find the fourth derivative is going to be negative 1 times negative two that's positive 2. and then we need to take the derivative of x to the negative third power so that's negative 3 x to the negative 4. so the fourth derivative is negative six divided by x to the fourth power now the next thing that we need to do is evaluate the function and the derivatives at C so F of 1 C is one that's going to be ln1 the natural log of 1 is 0. and then F Prime of 1 is going to be 1 over 1 which is one and then the second derivative evaluated at one that's negative one divided by 1 squared which is just negative one and for the third derivative it's going to be positive two and the value for the fourth derivative when X is one is negative six divided by one to the fourth or simply negative six so now we can get rid of this stuff now this is the formula that you want to use to write the expanded form of the Taylor series so it's F of C Plus F Prime of C times x minus C to the first power Plus F double Prime of C times x minus C to the second power divided by 2 factorial Plus the third derivative evaluated at c times x minus C to the third power divided by three factorial and then it just continues so f of x which is Ln X we could say that it's equal to F of C which is f of one and we know that F of one is zero and then Plus F Prime of C which is one times x minus c c is one and then the second derivative that's going to be negative one so that's F double Prime of C times x minus C to the second power divided by 2 factorial and then for the third derivative that's going to equal to so that's going to be plus 2 times x minus C to the third power divided by 3 factorial and then we have negative 6 x minus C to the fourth power divided by 4 factorial and then that's going to continue now let's simplify what we have so we don't need to write zero so we could say that the natural log of x is x minus C to the first power divided by one factorial and then minus we'll need to get rid of the C this is supposed to be x minus 1. to the first power and then it's going to be minus x minus one squared divided by 2 factorial which is simply two and then plus what is 2 divided by 3 factorial three factorials 3 times 2 times 1. and so we can cancel the two so therefore this is going to be plus x minus one to the third power divided by 3. I'm just going to write this as one so you can see the pattern and then we're going to have this is going to be negative now 6 divided by 4 factorial let's simplify that 4 factor is four times three times two times one so six will cancel with 3 times 2. so this is going to be x minus 1 to the fourth power divided by 4. so now we could see a pattern developing so how can we write in this series using summation notation so let's start with n equals zero and we're going to go to Infinity so when n is 0 we need to get one as an exponent when n is one we need to get 2. and when n is 2 we need to get 3. so therefore it's always one more than our n value so we're going to have n plus one so this is going to be x minus 1 raised to the N plus 1 power and since these numbers are the same we need to have an N plus 1 expression on the bottom now the last thing we need to deal with are the alternating signs it's going to alternate from positive to negative to positive and so forth so we can either use negative 1 to the N or negative 1 to the N Plus 1. which one should we use now when n is 0 for the first term we need to get a positive sign negative one to the zero power is positive one so we need to use this one and so I'm going to write that here negative 1 to the n so this is the Taylor series for the function lnx centered at c equal one and you can see the x minus one term which tells us that it's centered at C equals one for the sake of practice let's go ahead and try another example so find a Taylor series for the function f of x equals e to the X centered at C equals three so go ahead pause the video and take a minute to try this problem just like before let's make a list of the function and its derivatives so we have the function e to the x the first derivative is going to be e to the X as well as the second third and the fourth so all of the derivatives will be e to the x now F of C which is basically F of 3. that's e to the 3 and X can be the same as F Prime of 3 F double Prime of 3 and all of the derivatives they will all be equal to to the third power now let's write out the function so f of x is going to equal F of C plus F Prime of c times x minus C to the first power plus the second derivative times x minus C to the second power divided by 2 factorial and then it's going to be the third derivative times x minus C to the third power over three facts row and then that's just going to continue so our f of x is e to the x and F of C or F of 3 that's e to the third power F promise C is going to be the same thing e to the third power but times x minus C where C is three and then F double Prime of C is also going to be e to the third power and then it's going to be times x minus three to the second power over 2 factorial and then it's going to be e to the three x minus 3 to the third power over 3 factorial now we need to write a general power series that will give us what we see here so starting from zero go into Infinity we can see that the e to the third part it doesn't change so that's pretty much constant now the only part that changes are the exponents and the factorials therefore we need to represent those numbers with something that contains the letter n the only other part that doesn't change is x minus 3 for every term now when n equals zero we have the e to the third term when n equals one we're going to get this term and then this is 4 when n equals two and when n equals 3. and so notice that the N values matches with the exponents and the factorials so therefore we could say that this is x minus 3 to the N power divided by n factorial and this is the Taylor series for the function e to the x centered at c equal three let's move on to our next example problem number three find the MAC Lawrence series for the function f of x is equal to sine X the only difference between a Taylor series and a maclaurin series is that C equals zero for the maclaurin series so that's why there wasn't any c value given to you now the first derivative which is the derivative of sine that's going to be cosine and then the second derivative is negative sine X and then the derivative of negative sine that's going to be negative cosine X and then the fourth derivative is going to be the original sine X function now the fifth derivative is the same as the first and the sixth derivative is the same as the second and the pattern will repeat so to evaluate F of zero that's going to be sine 0 which is zero and then F Prime of zero cosine zero is one and then F double Prime of zero that's negative sine zero so that's zero and then for the third derivative it's going to be negative cosine of zero which is negative one and for the fourth derivative sine of zero is zero and so this is going to be the same as the fifth derivative and this is the sixth the seventh and then the eighth now let's write out the function that we need in order to get the McLaurin series so f of x is going to equal F of C but instead of f of C we're going to replace C with zero so it's going to be F of zero and then Plus Prime is zero times x minus C to the first power so that's x minus 0 to the first power which we can simply write x to the first power and then it's going to be the second derivative at zero times x squared over 2 factorial Plus the third derivative at zero times x cubed divided by 3 factorial and then that's going to continue so F of zero we could see that it's equal to zero and then F Prime of zero that's equal to one so we're going to have One X and then plus F double Prime of zero which is zero and then the third derivative it's equal to negative one so it's going to be negative x cubed over three factorial and then the next term for the fourth derivative is going to be zero and then plus the fifth derivative so it's going to be 1 times x to the fifth over 5 factorial and then plus 0 and then minus for the seventh derivative negative one times x to the seven divided by 7 factorial now let's simplify what we have so we can get rid of all of the zeros so our function which we can write as sine X that's equal to X which I'm going to write as x to the first power divided by 1 factorial and then minus x to the third power divided by 3 factorial plus x to the fifth power over five factorial minus x to the seventh power divided by 7 factorial and the series will go on forever so now let's write a general expression for that series so let's start from zero to Infinity so when n equals zero we need to get x to the first power over one factorial and when n is one we need to get three so let's write down the sequence so the sequence of numbers are 1 3 5 7 9 11 and so forth so when n is zero we get one when n is one we need to get three when n is two we need to get five and the pattern will continue now what we have is an an arithmetic sequence and to write the general formula for an arithmetic sequence we can use this equation so our a sub 1 term that's when n is one that's going to be three and the common difference we could see that is two all of the numbers are increasing by two and so we have the expression a sub n is three plus two n minus 2. 3 plus negative two that's one so we're going to get two n Plus 1. and so this is going to be X raised to the 2N plus 1 divided by two n plus 1 factorial since these numbers are the same so therefore they share the same general formula we'll just have a factorial symbol at the bottom now the last thing we need to deal with are the alternating signs so the first sign is positive when n is equal to zero so therefore we need to use negative one to the N power because negative one to the zero power will give us positive one so this is the McLaren series for sine X now in this problem we're going to find the maclaurin series for cosine X using the maclauren series for sine X so in the last problem we saw that the McLaurin series for sine X was x minus x to the third power divided by 3 factorial plus x to the fifth power divided by 5 factorial minus x to the seventh power divided by 7 factorial and this is going to continue all the way to Infinity so what we're going to do is take the derivative of both sides so on the left side we have the derivative of sine which will give us cosine X on the right side the derivative of x is one the derivative of x cubed is 3x squared and three factorial we can write it as three times two times one and two times one is two factorial so the next number is always one less than a previous number when dealing with factorials okay I'm not sure what just happened here now the derivative of x to the fifth power is 5X to the fourth power and 5 factorial I'm going to write that as 5 times 4 factorial now the derivative of x to the seventh power is going to be seven times x to the sixth power and let's write 7 factorial as 7 times 6 factorial now let's cancel the three we could cancel the five and let's cancel the 7. so we're left with cosine X is one minus x squared divided by 2 factorial plus x to the fourth over 4 factorial minus x to the sixth divided by 6 factorial now how can we represent this series using summation notation now the first thing I need to do is make some space because I'm always short of it using this board so what patterns do you see now keep in mind when n is zero we need to get one when n is one we need to get the exponents 2 and a factorial 2. now when n is 3 we need to get 4 factorial I mean a three I skipped two when nh2 needs to get 4 factorial and x to the fourth and then when n is three we need to get six so notice that the exponents and the factorials are always two times the N values so therefore this is going to be X raised to the 2N divided by 2N factorial the last thing that we need to talk about are the alternating signs so the first sign is positive so just like before we're going to use negative 1 to the N power so this is the McLaurin series for cosine X now there's another simpler way of getting the same answer I'm going to show it to you so we're going to start with this expression sine X which we said was the series from 0 to infinity and it was x to the two n plus 1 times negative 1 to the n divided by two n plus 1 factorial so all we need to do in this example is we just got to take the derivative of both sides so the left side is going to become cosine X now what about the derivative for the right side so let's rewrite the summation notation and we need to realize that negative 1 to the N is a constant two n plus 1 factorial that's a constant so the only thing we need to take the derivative of is X to the two n Plus 1. and let's use the power rule So based on the power rule the derivative of x to the n is n x to the N minus 1. so we need to take the exponent and move it to the front so that's going to be 2N plus one times x and then we'll need to subtract the exponent by 1. so let's do that what is 2N plus one minus 1. so we know that's going to be 2N and then divided by now this constant we're just going to rewrite it so that's going to be negative 1 to the N power now this constant will remain but we want to cancel the 2N Plus 1. so we're going to adjust the 2N plus 1 factorial now recall that a factorial is 8 times 7 factorial and so we're going to do something like this so first we're going to write the first number in this case that's 2N Plus 1. and then the next number is going to be 2N plus one lesson 1. to get the 7 is just 8 minus 1. so to get the next number it's going to be 2N plus 1 minus 1 which is 2N factorial now we can cancel two n Plus 1. and this gives us this answer as you can see so that's the second way to get the maclauren series for cosine X number five find the McLaurin series for cosine x squared So based on the last problem we saw that the McLaren series for cosine X was this expression so it's negative 1 to the n times x raised to the two n divided by 2 N factorial so if that's cosine X what can we say about cosine squared all we need to do is replace X with x squared so this is going to be negative 1 to the n times x squared raised to the 2N divided by 2N factorial now when you raise one exponent to another you need to multiply so 2 times 2N is 4N so therefore we can write the series for this composite function as negative one to the N times x raised to the 4N divided by 2N factorial and this is the answer so that's the McLaurin series for cosine x squared and that's what we need to do if you have a composite function now let's try this one number six find the McLaurin series for x cosine X so how can we do this if recall the McLaurin series for cosine X is this expression it's going to be the power series of negative 1 to the N times x to the raised to the 2N divided by 2 N factorial so all we need to do is multiply X by x to the 2N and so this is X to the first Power therefore we need to add 1 and 2N so the McLaurin series for x cosine X is going to be the summation from 0 to Infinity of negative 1 to the N times x raised to the 2N plus one over two n factorial and that's all you got to do for this problem now let's find the maclaurin series for the function x squared e raised to the negative X and this time use the data table with the list of elementary functions provided by your calculus textbook now e to the x is equal to the series from 0 to Infinity x to the N Over N factorial so if that's easy X what is e to the negative X so therefore e to the negative X should be equal to the series of negative x to the N Over N factorial so all we need to do is replace x with negative X now what can we say about Negative X to the n Negative X can be written as negative 1 times x and this is all affected by the exponent n so let's distribute n so this becomes negative 1 to the N times x to the n so we're going to have x squared times the series of negative 1 to the n x to the N divided by n factorial now at this point we can multiply x squared by x to the n so all we need to do is add the exponents so 2 plus n we can write that as n Plus 2. and so this is going to be the final answer so we have the series from 0 to infinity negative 1 to the N times x raised to the N plus 2 Over N factorial so that's equal to x squared e to the negative X and this is the final answer let's work on one more problem find the MAC Lawrence series for the function f of x equals cosine squared so what can we do with cosine squared of x we can use the power reducing formula 4 cosine squared which is one half times one plus cosine 2X this comes from the double angle formula of cosine two x but you rearrange it to solve for cosine squared now we know that cosine X is equal to this expression it's negative 1 to the N times x raised to the 2N over 2N factorial so therefore cosine 2X is going to be this expression it's going to be negative 1 to the n times 2x raised to the 2N divided by 2N factorial so all you need to do is replace X with 2X and that's it for this problem so you can leave your answer like this if you want to and so this is the McLaren series for cosine squared x