Discovering the Taylor Series for cos(x) at PI: Finding the Right Pattern

Join the discussion
Registration is free. Start your own thread to ask a follow-up.
5 replies · 2K views
bobber205
Messages
26
Reaction score
0
Trying to find the Taylor Series for cos(x) where x0 is PI.
I've gotten

Code:
cos(x) -1
-sin(x) 0
-cos(x) 1
sin(x) 0
cos(x) -1

It's clearly 0 every other term so I need 2k or 2k-1. But the -1 term switches between -1 and 1
How in world do I deal with this? xD

Thanks for any suggestions. I am assuming I've made a mistake somewhere.
I've asked my fellow students and they're cheating with k+1 which does work.

Thanks! :)
 
Physics news on Phys.org
bobber205 said:
Trying to find the Taylor Series for cos(x) where x0 is PI.
I've gotten

Code:
cos(x) -1
-sin(x) 0
-cos(x) 1
sin(x) 0
cos(x) -1

It's clearly 0 every other term so I need 2k or 2k-1. But the -1 term switches between -1 and 1
How in world do I deal with this? xD

Thanks for any suggestions. I am assuming I've made a mistake somewhere.
I've asked my fellow students and they're cheating with k+1 which does work.
Thanks! :)
Why would you think k + 1 is cheating? I'm assuming you're talking about the exponent on -1 to give sign alternation.
 
So far, you have, for the Taylor's series of cosine(x), about [itex]\pi[/itex],
-1 + (1/2)x2- (1/4!)x4+ ...

First, it should be clear that you will only have even powers of x and even numbers can be written "2n". That is, (1/(2(2))!)x4= (1/(2!) x2(2) and (1/6!)x6 = 1/(3(2))! x2(3). The only problem, then, is the power of -1.

The first term is n= 1 and that is positive. (-1)n would give (-1)1= -1. To fix that you could just multiply the entire sum by -1:
(-1)(-1+ (1/2!)x2- (1/6!)x6+ ...+ (-1)^n/(2n)! x2n+ ...)

That is the same as multiplying the -1 in each term:
1- (1/2!)x2- (1/6!)x6+ ...+ (-1)(-1)n/(2n)! x2n+...

Which can also be written with (-1)n+1:
1- (1/2!) x2- (1/6!)x6+ ...+ (-1)n+1/(2n)! x2n+ ...

Nothing "cheating" about that.
 
HallsofIvy said:
So far, you have, for the Taylor's series of cosine(x), about [itex]\pi[/itex],
-1 + (1/2)x2- (1/4!)x4+ ...
Since this is a Taylor's series about [itex]\pi[/itex], all of the terms should be powers of [itex]x - \pi[/itex], not powers of x.
HallsofIvy said:
First, it should be clear that you will only have even powers of x and even numbers can be written "2n". That is, (1/(2(2))!)x4= (1/(2!) x2(2) and (1/6!)x6 = 1/(3(2))! x2(3). The only problem, then, is the power of -1.

The first term is n= 1 and that is positive. (-1)n would give (-1)1= -1. To fix that you could just multiply the entire sum by -1:
(-1)(-1+ (1/2!)x2- (1/6!)x6+ ...+ (-1)^n/(2n)! x2n+ ...)

That is the same as multiplying the -1 in each term:
1- (1/2!)x2- (1/6!)x6+ ...+ (-1)(-1)n/(2n)! x2n+...

Which can also be written with (-1)n+1:
1- (1/2!) x2- (1/6!)x6+ ...+ (-1)n+1/(2n)! x2n+ ...

Nothing "cheating" about that.