- #1
ognik
- 643
- 2
My book says the expansion of $f(x)=x, -\pi \lt x \lt \pi = \sum_{n=1}^{\infty} \frac{{(-1)}^{n+1}}{n}$, I get double that so please tell me where this is wrong:
f(x) is odd, so $a_n=0$
$ b_n=\frac{1}{\pi} \int_{-\pi}^{\pi}x Sin(nx) \,dx = \frac{1}{\pi} [\frac{1}{n^2}Sin(nx) - \frac{x}{n} Cos(nx)]^{\pi}_{-\pi} $ Sin term = 0, so
$= -\frac{1}{\pi} [ \frac{\pi}{n} Cosn\pi - \frac{(-\pi)}{n} Cosn\pi] = -\frac{2}{n}Cosn\pi =2\frac{(-1)^{n+1}}{n}$ ?
f(x) is odd, so $a_n=0$
$ b_n=\frac{1}{\pi} \int_{-\pi}^{\pi}x Sin(nx) \,dx = \frac{1}{\pi} [\frac{1}{n^2}Sin(nx) - \frac{x}{n} Cos(nx)]^{\pi}_{-\pi} $ Sin term = 0, so
$= -\frac{1}{\pi} [ \frac{\pi}{n} Cosn\pi - \frac{(-\pi)}{n} Cosn\pi] = -\frac{2}{n}Cosn\pi =2\frac{(-1)^{n+1}}{n}$ ?