# Change of limits in this Fourier series?

I found the Fourier series $$f(x)=\frac{4k}{\pi}\sum_{n \text{ odd}}^{\infty}\frac{1}{n}\sin(n x) \tag 1$$ for the square wave function f(x)= \begin{cases} \begin{align} -k, \quad -\pi <x<0\\ k, \quad 0<x<\pi \end{align} \end{cases} But the answer is written as $$f(x)=\frac{4k}{\pi}\sum_{n=1}^{\infty}\frac{1}{2n-1}\sin(2n-1)x \tag 2$$

How can I find $(2)$ from $(1)$?

• Odd numbers can be written as $2n - 1$... Feb 18, 2018 at 14:33

This is your sum:$\displaystyle f(x)=\frac{4k}{\pi}\sum_{n \text{ odd}}^{\infty}\frac{1}{n}\sin(n x) \tag 1$ As it clearly states, for odd $n$ this summation have to be calculated.

So we say for odd $n$ we have: $n=2i-1$ where $i=1,2,...$

By substituting this into our summation we have: \begin{align} \displaystyle f(x)=\frac{4k}{\pi}\sum_{i=1}^{\infty}\frac{1}{2i-1}\sin((2i-1) x) \end{align} Or in another notation:

$\displaystyle f(x)=\frac{4k}{\pi}\sum_{n=1}^{\infty}\frac{1}{2n-1}\sin((2n-1) x) \tag 2$

• You are welcome @JDoeDoe. If you use $n=2i+1$ then $i$ should start from $0$ and not $1$ to have $n=1$. Saying $n=2i+1$ is also correct but since the final notation in the summation used $n=1$ for start of summation, I wrote with $n=2i-1$ to simply say $\sum_{n=1}$ and not $\sum_{n=0}$ Feb 18, 2018 at 15:34
• Hi! I just edited my question so I deleted the comment. :) Feb 18, 2018 at 15:36
• I think I got it. My only problem was if $n=2i-1$, how did you know $i=1,2, \dots$ and not $i=0,1,\dots$ instead? If $i=0$, we have $n=-1$, I guess $n$ has to be positive and therefore $i$ must start at $1$? Feb 18, 2018 at 15:44
• I guess my comment was more in general and not just because equation $(2)$ start with $1$. Feb 18, 2018 at 15:49
• @JDoeDoe $i=1,2,...$ because in the last summation we have $\displaystyle\sum_{n=1}$ and not $\displaystyle\sum_{n=0}$. If equation $(2)$ was: $\displaystyle\sum_{n=1}$ then I would choose $n=2i+1$ as well. About the general question: Trigonometric fourier series start from $0$. Feb 18, 2018 at 15:52