Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

I Question about Fourier series

  1. Sep 19, 2016 #1
    I'm wondering if anyone could give me the intuition behind Fourier series. In class we have approximated functions over the interval ##[-\pi,\pi]## using either ##1, sin(nx), cos(nx)## or ##e^{inx}##.
    An example of an even function approximated could be:
    ##
    f(x) = \frac {(1,f(x))}{||1||^{2}}*1 + \sum^{inf}_{n=1}\frac{(cos(nx), f(x))}{||cos(nx)||^{2}}*cos(nx)
    ##
    where I've indicated the scalar product as (. , .) and the norm as || . ||.
    From what I've understood, whenever computing the approximation using sin(nx) or cos(nx) the index of the sum starts from 1 and goes to infinity. Whenever dealing with ##e^{inx}## the index starts from - infinity and goes to infinity.
    I think that when we compute the series approximation, we calculate the orthogonal projection of our original function on the infinite number of axis' given by ##1, sin(nx), cos(nx)## or ##e^{inx}##. Is this correct? And if it is, then why does the index start from 1 for sine and cosine whereas it's the whole integer set for the exponential base? Any help is much appreciated! :)
     
  2. jcsd
  3. Sep 19, 2016 #2

    stevendaryl

    User Avatar
    Staff Emeritus
    Science Advisor

    If you know Euler's formula, you can relate sines, cosines and exponentials as follows:

    [itex]e^{i n \theta} = cos(n \theta) + i sin(n \theta)[/itex]

    So you can rewrite a Fourier series:

    [itex]\sum_{n=-\infty}^{n=+\infty} c_n e^{i n \theta} = (\sum_{n= -\infty}^{+\infty} c_n cos(n \theta)) + i (\sum_{n=-\infty}^{+\infty} c_n sin(n \theta))[/itex]

    But we know: [itex]cos(n \theta) = cos(-n \theta)[/itex], and [itex]cos(0) = 1[/itex], and [itex]sin(n \theta) = - sin(n \theta)[/itex] and [itex]sin(0) = 0[/itex]. So we can rewrite this as follows:

    [itex]\sum_{n=-\infty}^{n=+\infty} c_n e^{i n \theta} = c_0 + (\sum_{n= 1}^{+\infty} (c_n + c_{-n}) cos(n \theta)) + i (\sum_{n=1}^{+\infty} (c_n - c_{-n}) sin(n \theta))[/itex]

    So a fourier series (where the index ranges from [itex]-\infty[/itex] to [itex]+\infty[/itex] is equivalent to a constant, plus a cosine series starting with 1, plus a sine series starting with +1.
     
  4. Sep 19, 2016 #3

    mathman

    User Avatar
    Science Advisor
    Gold Member

    [itex]cos(nx)=\frac{e^{inx}+e{-inx}}{2},\ sin(nx)=\frac{e^{inx}-e^{-inx}}{2i}[/itex]. If the function is even (cos series), the exp terms with +n and -n have the same coefficient, so you don't need them both. Similarly if the function is odd (sin series) the exp terms have coefficients wth the same magnitude and opposite sign, so you don't need them both. Functions neither odd or even need either the full exp series or sin and cos series together.
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?
Draft saved Draft deleted