Results 1 to 9 of 9

Math Help - Fourier cosine series

  1. #1
    Newbie
    Joined
    Oct 2006
    Posts
    17

    Fourier cosine series

    Can someone help me with the following: (I'm getting lost with the integrals and I can't really type them here)

    f(x) = x(a-x), 0<= x <= a Find this in a Fourier cosine series.

    I have the answers, I'm just having trouble computing it.

    Thanks so much in advance.
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Senior Member DeMath's Avatar
    Joined
    Nov 2008
    From
    Moscow
    Posts
    473
    Thanks
    5
    Quote Originally Posted by BenWong View Post
    Can someone help me with the following: (I'm getting lost with the integrals and I can't really type them here)

    f(x) = x(a-x), 0<= x <= a Find this in a Fourier cosine series.

    I have the answers, I'm just having trouble computing it.

    Thanks so much in advance.
    You need to use these formulas:

    f\left( x \right) = {a_0} + \sum\limits_{n = 1}^\infty  {{a_n}\cos \left( {\frac{{\pi nx}}{l}} \right)} {\text{ }}\left( {{\text{0}} \leqslant x \leqslant l} \right),

    where {a_0} = \frac{1}{l}\int\limits_0^l {f\left( x \right)} dx and {a_n} = \frac{2}{l}\int\limits_0^l {f\left( x \right)\cos \left( {\frac{{\pi nx}}{l}} \right)} dx{\text{ }}\left( {n \geqslant 1} \right).

    In your case (problem) l = a.

    What you can not?
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Newbie
    Joined
    Oct 2006
    Posts
    17
    Yeah, how do you integrate

    x(a-x)cos(pi*n*x/a) dx?
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Junior Member
    Joined
    Apr 2008
    Posts
    48
    Quote Originally Posted by DeMath View Post
    {a_0} = \frac{1}{l}\int\limits_0^l {f\left( x \right)} dx
    Surely it's:

    {a_0} = \frac{2}{l}\int\limits_0^l {f\left( x \right)} dx?
    Follow Math Help Forum on Facebook and Google+

  5. #5
    Senior Member DeMath's Avatar
    Joined
    Nov 2008
    From
    Moscow
    Posts
    473
    Thanks
    5
    Quote Originally Posted by skamoni View Post
    Surely it's:

    {a_0} = \frac{2}{l}\int\limits_0^l {f\left( x \right)} dx?
    Look at it again carefully

    f\left( x \right) = {a_0} + \sum\limits_{n = 1}^\infty  {{a_n}\cos \left( {\frac{{\pi nx}}{l}} \right)} {\text{ }}\left( {{\text{0}} \leqslant x \leqslant l} \right)

    {\text{where }}{a_0} = \frac{1}{l}\int\limits_0^l {f\left( x \right)} dx{\text{ and }}{a_n} = \frac{2}{l}\int\limits_0^l {f\left( x \right)\cos \left( {\frac{{\pi nx}}{l}} \right)} dx{\text{ }}\left( {n \geqslant 1} \right)<br />

    Follow Math Help Forum on Facebook and Google+

  6. #6
    Junior Member
    Joined
    Apr 2008
    Posts
    48
    Sorry. Should have read that more carefully.

    I would suggest Integrating by parts, i'm guessing you know how to if you're studying Fourier series.
    Follow Math Help Forum on Facebook and Google+

  7. #7
    Senior Member DeMath's Avatar
    Joined
    Nov 2008
    From
    Moscow
    Posts
    473
    Thanks
    5
    Quote Originally Posted by BenWong View Post
    Can someone help me with the following: (I'm getting lost with the integrals and I can't really type them here)

    f(x) = x(a-x), 0<= x <= a Find this in a Fourier cosine series.

    I have the answers, I'm just having trouble computing it.

    Thanks so much in advance.
    So, Find a Fourier cosine series for f\left( x \right) = x\left( {a - x} \right), 0 \leqslant x \leqslant a.

    f\left( x \right) = {a_0} + \sum\limits_{n = 1}^\infty  {{a_n}\cos \left( {\frac{{\pi nx}}{l}} \right)} {\text{ }}\left( {{\text{0}} \leqslant x \leqslant l} \right),

    where {a_0} = \frac{1}{l}\int\limits_0^l {f\left( x \right)} dx{\text{ and }}{a_n} = \frac{2}{l}\int\limits_0^l {f\left( x \right)\cos \left( {\frac{{\pi nx}}{l}} \right)} dx{\text{ }}\left( {n \geqslant 1} \right).

    In your case (problem) l = a.

    {a_0} = \frac{1}{a}\int\limits_0^a {x\left( {a - x} \right)} dx = \frac{1}{a}\left. {\left( {\frac{{a{x^2}}}{2} - \frac{{{x^3}}}{3}} \right)} \right|_0^a = \frac{{{a^2}}}{2} - \frac{{{a^2}}}{3} = \frac{{{a^2}}}{6}.

    {a_n} = \frac{2}{a}\int\limits_0^a {x\left( {a - x} \right)\cos \left( {\frac{{\pi nx}}{a}} \right)} dx =

    = 2\int\limits_0^a x \cos \left( {\frac{{\pi nx}}{a}} \right)dx - \frac{2}{a}\int\limits_0^a {{x^2}} \cos \left( {\frac{{\pi nx}}{a}} \right)dx = {I_1} - {I_2}.

    {I_1} = 2\int\limits_0^a x \cos \left( {\frac{{\pi nx}}{a}} \right)dx = \frac{{2a}}{{\pi n}}\int\limits_0^a x d\left( {\sin \left( {\frac{{\pi nx}}{a}} \right)} \right) =

    = \left. {\frac{{2ax}}{{\pi n}}\sin \left( {\frac{{\pi nx}}{a}} \right)} \right|_0^a - \frac{{2a}}{{\pi n}}\int\limits_0^a {\sin \left( {\frac{{\pi nx}}{a}} \right)dx}  =

    = \left. {\frac{{2ax}}{{\pi n}}\sin \left( {\frac{{\pi nx}}{a}} \right)} \right|_0^a - \frac{{2{a^2}}}{{{\pi ^2}{n^2}}}\int\limits_0^a {\sin \left( {\frac{{\pi nx}}{a}} \right)d} \left( {\frac{{\pi nx}}{a}} \right) =

    = \left. {\left[ {\frac{{2ax}}{{\pi n}}\sin \left( {\frac{{\pi nx}}{a}} \right) + \frac{{2{a^2}}}{{{\pi ^2}{n^2}}}\cos \left( {\frac{{\pi nx}}{a}} \right)} \right]} \right|_0^a =

    = \frac{{2{a^2}}}{{\pi n}}\sin \left( {\pi n} \right) + \frac{{2{a^2}}}{{{\pi ^2}{n^2}}}\cos \left( {\pi n} \right) - \frac{{2{a^2}}}{{{\pi ^2}{n^2}}} =

    = \frac{{2{a^2}}}{{{\pi ^2}{n^2}}}{\left( { - 1} \right)^n} - \frac{{2{a^2}}}{{{\pi ^2}{n^2}}} = \frac{{2{a^2}}}{{{\pi ^2}{n^2}}}\left[ {{{\left( { - 1} \right)}^n} - 1} \right].

    {I_2} = \frac{2}{a}\int\limits_0^a {{x^2}} \cos \left( {\frac{{\pi nx}}{a}} \right)dx = \frac{2}{{\pi n}}\int\limits_0^a {{x^2}d\left( {\sin \left( {\frac{{\pi nx}}{a}} \right)} \right)}  =

    = \left. {\frac{{2{x^2}}}{{\pi n}}\sin \left( {\frac{{\pi nx}}{a}} \right)} \right|_0^a - \frac{4}{{\pi n}}\int\limits_0^a {x\sin \left( {\frac{{\pi nx}}{a}} \right)dx}  =

    = \left. {\frac{{2{x^2}}}{{\pi n}}\sin \left( {\frac{{\pi nx}}{a}} \right)} \right|_0^a + \frac{{4a}}{{{\pi ^2}{n^2}}}\int\limits_0^a {xd\left( {\cos \left( {\frac{{\pi nx}}{a}} \right)} \right)}  =

    = \left. {\left[ {\frac{{2{x^2}}}{{\pi n}}\sin \left( {\frac{{\pi nx}}{a}} \right) + \frac{{4ax}}{{{\pi ^2}{n^2}}}\cos \left( {\frac{{\pi nx}}{a}} \right)} \right]} \right|_0^a - \frac{{4a}}{{{\pi ^2}{n^2}}}\int\limits_0^a {\cos \left( {\frac{{\pi nx}}{a}} \right)} dx =

    = \left. {\left[ {\frac{{2{x^2}}}{{\pi n}}\sin \left( {\frac{{\pi nx}}{a}} \right) + \frac{{4ax}}{{{\pi ^2}{n^2}}}\cos \left( {\frac{{\pi nx}}{a}} \right)} \right]} \right|_0^a - \frac{{4{a^2}}}{{{\pi ^3}{n^3}}}\int\limits_0^a {\cos \left( {\frac{{\pi nx}}{a}} \right)} d\left( {\frac{{\pi nx}}<br />
{a}} \right) =

    = \left. {\left[ {\frac{{2{x^2}}}{{\pi n}}\sin \left( {\frac{{\pi nx}}<br />
{a}} \right) + \frac{{4ax}}{{{\pi ^2}{n^2}}}\cos \left( {\frac{{\pi nx}}<br />
{a}} \right) - \frac{{4{a^2}}}{{{\pi ^3}{n^3}}}\sin \left( {\frac{{\pi nx}}<br />
{a}} \right)} \right]} \right|_0^a =

    = \frac{{2{a^2}}}{{\pi n}}\sin \left( {\pi n} \right) + \frac{{4{a^2}}}{{{\pi ^2}{n^2}}}\cos \left( {\pi n} \right) - \frac{{4{a^2}}}{{{\pi ^3}{n^3}}}\sin \left( {\pi n} \right) = \frac{{4{a^2}}}{{{\pi ^2}{n^2}}}{\left( { - 1} \right)^n}.

    So, we have

    {a_n} = \frac{{2{a^2}}}{{{\pi ^2}{n^2}}}\left[ {{{\left( { - 1} \right)}^n} - 1} \right] - \frac{{4{a^2}}}{{{\pi ^2}{n^2}}}{\left( { - 1} \right)^n} = \frac{{2{a^2}}}{{{\pi ^2}{n^2}}}\left[ {{{\left( { - 1} \right)}^{n + 1}} - 1} \right].

    {a_1} = 0,{\text{ }}{a_2} =  - \frac{{4{a^2}}}{{4{\pi ^2}}},{\text{ }}{a_3} = 0,{\text{ }}{a_4} =  - \frac{{4{a^2}}}{{16{\pi ^2}}},{\text{ }} \ldots ,{\text{ }}{a_{2k - 1}} = 0,{\text{ }}{a_{2k}} =  - \frac{{4{a^2}}}{{{{\left( {2k} \right)}^2}{\pi ^2}}}{\text{.}}

    Finally, we have

    f\left( x \right) = \frac{{{a^2}}}{6} - \frac{{4{a^2}}}{{{\pi ^2}}}\sum\limits_{k = 1}^\infty  {\frac{1}{{{{\left( {2k} \right)}^2}}}\cos \left( {\frac{{2\pi kx}}{a}} \right)} {\text{ }}\left( {0 \leqslant x \leqslant a} \right).
    Last edited by DeMath; January 18th 2009 at 11:26 AM.
    Follow Math Help Forum on Facebook and Google+

  8. #8
    MHF Contributor
    Jester's Avatar
    Joined
    Dec 2008
    From
    Conway AR
    Posts
    2,361
    Thanks
    39
    Quote Originally Posted by DeMath View Post
    You need to use these formulas:

    f\left( x \right) = {a_0} + \sum\limits_{n = 1}^\infty {{a_n}\cos \left( {\frac{{\pi nx}}{l}} \right)} {\text{ }}\left( {{\text{0}} \leqslant x \leqslant l} \right),

    where {a_0} = \frac{1}{l}\int\limits_0^l {f\left( x \right)} dx and {a_n} = \frac{2}{l}\int\limits_0^l {f\left( x \right)\cos \left( {\frac{{\pi nx}}{l}} \right)} dx{\text{ }}\left( {n \geqslant 1} \right).

    In your case (problem) l = a.

    What you can not?
    If you define your Fourier cosine sereis as

    f\left( x \right) = \frac{a_0}{2} + \sum\limits_{n = 1}^\infty {{a_n}\cos \left( {\frac{{\pi nx}}{l}} \right)} {\text{ }}\left( {{\text{0}} \leqslant x \leqslant l} \right),

    then {a_n} = \frac{2}{l}\int\limits_0^l {f\left( x \right)\cos \left( {\frac{{\pi nx}}{l}} \right)} dx{\text{ }} n = 0, 1, 2, \cdots.

    Just one integral formula to remember.
    Follow Math Help Forum on Facebook and Google+

  9. #9
    Senior Member DeMath's Avatar
    Joined
    Nov 2008
    From
    Moscow
    Posts
    473
    Thanks
    5
    Quote Originally Posted by danny arrigo View Post
    If you define your Fourier cosine sereis as

    f\left( x \right) = \frac{a_0}{2} + \sum\limits_{n = 1}^\infty {{a_n}\cos \left( {\frac{{\pi nx}}{l}} \right)} {\text{ }}\left( {{\text{0}} \leqslant x \leqslant l} \right),

    then {a_n} = \frac{2}{l}\int\limits_0^l {f\left( x \right)\cos \left( {\frac{{\pi nx}}{l}} \right)} dx{\text{ }} n = 0, 1, 2, \cdots.

    Just one integral formula to remember.
    I understood you.
    This is the same, just in a more general way.
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. fourier cosine series
    Posted in the Differential Equations Forum
    Replies: 2
    Last Post: October 15th 2011, 04:01 AM
  2. Fourier sine and cosine series of x(Pi-x)
    Posted in the Advanced Applied Math Forum
    Replies: 3
    Last Post: January 2nd 2010, 12:42 PM
  3. Fourier series cosine
    Posted in the Differential Equations Forum
    Replies: 2
    Last Post: May 10th 2009, 12:18 PM
  4. is this a sine or cosine fourier series...
    Posted in the Advanced Math Topics Forum
    Replies: 1
    Last Post: February 14th 2009, 04:04 PM
  5. Fourier Cosine series of cos(x)
    Posted in the Advanced Applied Math Forum
    Replies: 2
    Last Post: October 14th 2006, 03:42 PM

Search Tags


/mathhelpforum @mathhelpforum