0

I think I've the graph wrong, just struggling with the Fourier series. question

Alex Vong
  • 1,654

1 Answers1

0

Your function is even on $[-\pi,\pi]$. So you end up with a Fourier cosine series only. For $n=1,2,3,\cdots$, $$ a_n=\frac{1}{\pi}\int_{-\pi}^{\pi}f(x)\cos(n x)dx \\= \frac{1}{\pi}\int_{-\pi}^{0}(\pi +x)\cos(n x)dx + \frac{1}{\pi}\int_{0}^{\pi}(\pi-x)\cos(n x)dx $$ For $n=0$, $$ a_0 = \frac{1}{2\pi}\int_{-\pi}^{0}(\pi +x)dx+\frac{1}{2\pi}\int_{0}^{\pi}(\pi-x)dx. $$

The Fourier series is

$$ f \sim \sum_{n=0}^{\infty}a_n \cos(n\pi x). $$

Disintegrating By Parts
  • 87,459
  • 5
  • 65
  • 149