1. Not finding help here? Sign up for a free 30min 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!

Generating Function

  1. Sep 26, 2012 #1
    Find the OGF for the recurrence

    a[itex]_{n}[/itex]= 6 * a[itex]_{n-1}[/itex]+ a[itex]_{n-2}[/itex] a[itex]_{0}[/itex]=2, a[itex]_{1}[/itex]=1



    So here is what I did

    I said let A = [itex]\sum[/itex][itex]_{2>=n} [/itex]a[itex]_{n}[/itex]x[itex]^{n}[/itex]


    then I got

    A = 6x (A+x) + x[itex]^{2}[/itex](A +x+2)

    which gets me

    A= [itex]\frac{6x^2+x^{3} +2x}{1-6x - x^2}[/itex]



    ButI should get [itex]\frac{2-x}{1-6x - x^2}[/itex]


    Can any one tell me what I am doing wrong ?
     
  2. jcsd
  3. Sep 26, 2012 #2

    SammyS

    User Avatar
    Staff Emeritus
    Science Advisor
    Homework Helper
    Gold Member

    This gets you a different A.
    Congrats on your 400th post ! :smile:
     
  4. Sep 26, 2012 #3
    Thank you on the congratulations. But I do not see how that get me a different A. Did I define what A is right. Usually the generating function start at zero but with this problem that gives you bad subscripts.
     
  5. Sep 26, 2012 #4

    Ray Vickson

    User Avatar
    Science Advisor
    Homework Helper

    I usually find it safer, to write things out a bit more:
    [tex] A = a_2 x^2 + a_3 x^3 + a_4 x^4 + \cdots = (6a_1 + a_0)x^2
    + (6a_2 + a_1)x^3 + (6a_3 + a_2)x^4 + \cdots\\
    = (6+2)x^2 + x^3 + 6x A + x^2 A = x^3 + 8x^2 + (x^2 + 6x)A.[/tex]
    This will give you a different A from what you obtained.

    Besides that difference, maybe the answer was for a GF starting at a_0*x^0, or at a_1*x^1. However, I checked that, and could not get the posted answer for any three variants of the problem. Just to be sure, I used Maple to get a solution, and got an answer in agreement with a_0 + a_1 x + A. Here is the Maple command, but I won't give the output, since that would deprive you of the fun of getting it yourself.
    > rsolve({a(n)=6*a(n-1)+a(n-2),a(1)=1,a(0)=2},a,'genfunc'(x));

    RGV
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: Generating Function
  1. Generating functions (Replies: 2)

  2. Generating Functions (Replies: 0)

  3. Generating Function (Replies: 0)

  4. Generating Function (Replies: 4)

Loading...