1
$\begingroup$

This question already has an answer here:

The fourier series is given by $$f(x)=\frac12a_0+\sum_{n=1}^\infty(a_n\cos(nx)+b_n\sin(nx))$$ after doing a few examples I noticed that whenever I was evaluating an even function the $a_n$ would disappear because it always turned out to be $0$ after calculating the integral, and when I was evaluating odd functions the $b_n$ would disappear because it would always turn out to be $0$ after calculating the integral.
So how come finding the fourier series of an even function causes the $a_n$ to be $0$ and vice versa for an odd function?

$\endgroup$

marked as duplicate by idknuttin, user91500, BLAZE, draks ..., Claude Leibovici Dec 10 '15 at 8:25

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 1
    $\begingroup$ You have "even" and "odd" interchanged. $\endgroup$ – Michael Hardy Dec 10 '15 at 0:32
  • 1
    $\begingroup$ Since $\sin$ is odd, if the function is even, there be no $\sin$ components or else the series wouldn't be even, and hence wouldn't equal the function. (And vice-versa) $\endgroup$ – David Dec 10 '15 at 0:33
  • 1
    $\begingroup$ The integral of an odd function over an interval symmetric about zero is zero. The Fourier coefficient for a cosine term for an odd function, or the Fourier coefficient for a sine term for an even function, is an integral of an odd function over such an interval. $\endgroup$ – Ian Dec 10 '15 at 0:35
1
$\begingroup$

Note that any function whose domain is symmetric about $0$ can be written uniquely as the sum of an even function and an odd function. For if $f(x) = e(x) + o(x)$ where $e$ is even and $o$ is odd, then $f(-x) = e(x) - o(x)$, so we can solve for $$e(x) =\frac{f(x) + f(-x)}{2}\\o(x) =\frac{f(x) - f(-x)}{2}$$ Conversely, for an arbitrary function $f$, we can define functions $e$ and $o$ by these formulas. It is easy to see that $e$ is even, $o$ is odd, and $f = e + o$.

If $f$ itself is even, then $e = f$, and $o(x) = 0$ for all $x$. If $f$ is odd, then $o = f$, and $e = 0$.

Now, since $\cos x$ is even, so is $$\frac {a_0} 2 + \sum_{n=1}^\infty a_n\cos nx$$ and similarly, $$\sum_{n=1}^\infty b_n\sin nx$$ is odd. Therefore if $$f(x) = \frac {a_0} 2 + \sum_{n=1}^\infty (a_n\cos nx + b_n\sin nx)$$ then $$e(x) = \frac {a_0} 2 + \sum_{n=1}^\infty a_n\cos nx\\ o(x) = \sum_{n=1}^\infty b_n\sin nx$$ And if $f$ itself is even or odd, then the opposite formula will be $0$.

$\endgroup$

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