0
$\begingroup$

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)$?

$\endgroup$
1

1 Answer 1

0
$\begingroup$

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 $

$\endgroup$
6
  • 1
    $\begingroup$ 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}$ $\endgroup$ Feb 18, 2018 at 15:34
  • 1
    $\begingroup$ Hi! I just edited my question so I deleted the comment. :) $\endgroup$
    – JDoeDoe
    Feb 18, 2018 at 15:36
  • $\begingroup$ 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$? $\endgroup$
    – JDoeDoe
    Feb 18, 2018 at 15:44
  • $\begingroup$ I guess my comment was more in general and not just because equation $(2)$ start with $1$. $\endgroup$
    – JDoeDoe
    Feb 18, 2018 at 15:49
  • $\begingroup$ @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$. $\endgroup$ Feb 18, 2018 at 15:52

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .