1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Cosine series of sine

  1. Oct 16, 2005 #1
    I tried to find the cosine series of the function [tex]f(x) = \sin x[/tex], using the equation below:

    [tex]S(x) = \frac{a_0}{2} + \sum_{n=1}^{\infty} a_n \cos(nx)[/tex]
    where: [tex]a_n = \frac{2}{\pi} \int_{0}^{\pi} f(x) \cos(nx) dx[/tex]

    I found:

    [tex]a_0 = \frac{4}{\pi}[/tex]
    [tex]a_n = \frac{2 }{\pi (1 - n^2)} (\cos(n \pi) + 1)[/tex]


    [tex]S(x) = \frac{2}{\pi} (1 - 2 \sum_{n=1}^{\infty} \frac{\cos(2nx)}{4n^2 - 1})[/tex]

    Making the graph of the first terms of the function above on my calculator, I noticed that this is actually [tex]| \sin x |[/tex], rather than just [tex]\sin x[/tex]. Why does this happen? Is there a way of figuring out the sum not using a calculator?

    Last edited: Oct 16, 2005
  2. jcsd
  3. Oct 16, 2005 #2


    User Avatar
    Science Advisor

    sinx is nonegative between 0 and pi, so sinx=|sinx| there.
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook