Finding complex Fourier series of $f(x) = x$

410 Views Asked by At

Let $f(x) = x , \ \ 0\le x \lt 2$ and $f(x+2) = f(x)$. Find complex Fourier series of $f(x)$.

If we compute $c_n = \frac{1}{L}\int_{0}^{L}e^{-inx2\pi/L}f(x)dx = \int_{0}^{2}0.5e^{-inx\pi}xdx = \frac{2i\pi n}{\pi^2n^2}$ but if we integrate in other interval with length $2$, we got different answer. For example $\int_{-1}^{1}0.5e^{-inx\pi}xdx = \frac{2i\pi n(-1)^n}{\pi^2n^2}$ which differs from $c_n$ by a factor $(-1)^n$. Why this happens? Integrating over any interval with the length of period should be same.

2

There are 2 best solutions below

7
On BEST ANSWER

It is true that $\int_a^{a+2} f(x) dx$ is same for all $a$ but you cannot always substitute $x$ for $f(x)$ in this integral. For example when $x$ is between $-1$ and $0$ we have $f(x) =x+2$.

In your computation of $c_n$ you wrote $f(x)=x$ for $x$ between $-1 $ and $1$. That is not correct.

The function $f$ is defined by $f(x)=x-2n$ if $2n \leq n <2n+1$, $n$ varying over all integers.

0
On

Fourier series for the Saw-tooth function:$$f(x)=x,~ 0\le x \le 2~~~~(1)$$ Also $f(x)$ is periodic with a period of 2 such that $f(x+2)=f(x), \forall x \in R$ The complex Fourier series representation of $f(x)=x$ is written as $$f(x)=\frac{1}{2} \sum_{-N}^{N} C_n ~e^{i n\pi x}~~~~(2),$$ where $$C_n=\frac{1}{2}\int_{0}^{2} x e^{-in\pi x} dx=-e^{-2in\pi}~\frac{-1+e^{2in\pi}-2in\pi}{2n^2\pi^2}=\frac{i}{n \pi} ~~~~(3)$$ $C_0$ takes the limiting value of 1. In the Fig. below see the plot of (1) amd (3) by taking $N=20$ and using (3). See a good agreement expecting at the end points.

enter image description here