Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've been told to construct a Fourier Series for the odd function that has period $2\pi$ and is equal to $\cos(x)$ for $x \in (0,\pi]$. For $f$ that is $2\pi$ period I have a formula
$$b_n=\int_{-\pi}^\pi f(x)\sin(nx) \, dx.$$
I don't know what this question is asking, I thought it wanted $f(x)=\cos(x)$ but when substituting in the equation, that would give an odd integrand so it would just be $0$.

share|cite|improve this question
First define $f(x) := \cos(x)$ for $x \in (0,\pi]$, then extend it to $[-\pi,0]$ in such a way that $f(x)$ is an odd function. Next extend it to a periodic function with period $ 2 \pi$. Now find the Fourier series of this $f$. – MichaelNgelo Jan 23 '13 at 0:36
This makes sense, but how would you extend $\cos(x)$ to $[-\pi,0]$ so that f(x) is an odd function since at $x=0$, $\cos(x)$ is not $0$? Don't odd functions have to pass through $(0,0)$ – user51327 Jan 23 '13 at 0:52
The extension is discontinuous: $f(x)=\cos x$ on $(0,\pi]$, $f(0)=0$, $f(x)=-\cos x$ on $[-\pi,0)$. – David Moews Jan 23 '13 at 1:23
up vote 0 down vote accepted

Since $f(x)$ is odd and equals $\cos x$ on $(0,\pi]$, it equals $-\cos (-x)=-\cos x$ on $[-\pi,0)$. So, $$ b_n:=\int_{-\pi}^\pi f(x) \sin nx \, dx $$ $$ = \int_{-\pi}^0 (-\cos x) \sin nx \, dx + \int_{0}^\pi (\cos x) \sin nx \, dx. $$

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.