# fourier series again

• Jan 25th 2009, 10:51 AM
James0502
fourier series again
f(x) = xsin(px)

to calculate the fourier series, I am struggling.. do I need to distinguish between when p = n?

I am really struggling with the integration of this.. could somebody please show me how I would go about it? many thanks
• Jan 25th 2009, 12:14 PM
Jester
Quote:

Originally Posted by James0502
f(x) = xsin(px)

to calculate the fourier series, I am struggling.. do I need to distinguish between when p = n?

I am really struggling with the integration of this.. could somebody please show me how I would go about it? many thanks

Is $\displaystyle p$ a positive integer?
• Jan 25th 2009, 12:16 PM
James0502
yes, sorry, that wasnt clear

any help would be so greatly appreciated!
• Jan 25th 2009, 03:46 PM
Jester
Quote:

Originally Posted by James0502
yes, sorry, that wasnt clear

any help would be so greatly appreciated!

Here's what I got

$\displaystyle a_0 = \frac{1}{\pi} \int_{- \pi}^{\pi} x \sin p x\, dx = - \frac{2 (-1)^p}{p}$

$\displaystyle a_n = \frac{1}{\pi} \int_{- \pi}^{\pi} x \sin p x \cos nx\, dx = - \frac{2 p}{p^2 -n^2}\,(-1)^{p+n}\;\;\;n \ne p$

$\displaystyle a_n = - \frac{1}{2p},\;\;\;n = p$

The series

$\displaystyle \frac{a_0}{2} + \sum_{i=1}^{\infty} a_n \cos nx$