Computing Fourier Series for x^2 Between -pi and pi

Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
5 replies · 6K views
Studious_stud
Messages
38
Reaction score
0

Homework Statement



15qyqe9.jpg


Homework Equations


Equations to compute Fourier series given in question


The Attempt at a Solution



Ok so I've just done this problem and I'm having some trouble computing the Fourier series of [itex]x^{2}[/itex] between -∏ < ∏

So first I calculate [itex]a_{0}[/itex] and that turns out to be [itex]\frac{∏^{2}}{3}[/itex], which according to wolfram is right.

Next [itex]a_{n}[/itex], which is the one I'm having trouble with. Essentially you have to do integration by parts twice (right?) and I end up getting something quite messy, as does wolfram

http://www.wolframalpha.com/input/?i=integrate+x^2+cos+%28n+x%29+dx+from+x%3D-pi+to+pi

Is there any way to clean this up for when I plug [itex]a_{n}[/itex] into the final formula?

[itex]b_{n}[/itex] is 0 obviously so there's no issue there (since it's an even function times an odd function).

Thanks in advance everyone. :)
 
Physics news on Phys.org
You should find it simplifies down to [itex]a_n = (-1)^n\frac{4}{n^2}[/itex]. Since you know n is an integer, you should find some terms vanish, etc.

You can get the answer from Wolfram Alpha by entering "FourierTrigSeries[x^2, x, 10]".
 
vela said:
You should find it simplifies down to [itex]a_n = (-1)^n\frac{4}{n^2}[/itex]. Since you know n is an integer, you should find some terms vanish, etc.

You can get the answer from Wolfram Alpha by entering "FourierTrigSeries[x^2, x, 10]".

Thanks for the response.

So let me get this right... [itex]cosn∏ = (-1)^n[/itex] and [itex]sinn∏ = (-1)^n[/itex]?

Sorry still a bit confused!
 
vela said:
Not quite. You might want to take a look at a plot of the trig functions.

Whoops, meant to say [itex]sinn∏=0[/itex], is this correct?