Fourier series of constant on $2\pi$ intervals

428 Views Asked by At

I want to find a fourier expansion of only sines representing $g(x) = 1$ on the interval $[0, \pi]$. So I extend the function on $[-\pi, \pi]$ such that it is odd, and calculate $$b_k = \frac 1\pi \int_{-\pi}^0 -\sin(kx) dx + \frac 1\pi \int_0^\pi \sin(kx) dx = \begin{cases} \frac 4{\pi k} & \text{if $k$ is odd} \\ 0 & \text{if $k$ is even}\end{cases}$$

Now same thing, except that the function is defined on $[0, 2\pi]$. Again I extend it on $[-2\pi, 2\pi]$ and find

$$b_k = \frac 1{2\pi} \int_{-2\pi}^0 -\sin(kx) dx + \frac 1{2\pi} \int_0^{2\pi} \sin(kx) dx = 0$$

What's wrong with this? The fourier series is zero? I must have done some calculations wrong but I can't find the error...

1

There are 1 best solutions below

0
On BEST ANSWER

On an interval of length $T$, we have a complete orthogonal system consisting of the functions

$$\cos \frac{2\pi k x}{T},\; k \in \mathbb{N}\quad \text{and} \quad \sin \frac{2\pi k x}{T},\; k \in \mathbb{N}\setminus \{0\}.$$

For $T = 4\pi$, that means we also need the functions with half-integer frequencies, $\sin \bigl(n + \frac{1}{2}\bigr)x$ and $\cos \bigl(n + \frac{1}{2}\bigr)x$ - where for odd functions, only the sines appear in the Fourier expansion. The half-integer frequencies correspond to the odd $k$ in the expansion of $g$ on $[-\pi,\pi]$, while the integer frequencies correspond to the even $k$, and consequently all vanish.