Find the general solution of the recurrence relation:
an = an-1 + 2an-2 , with a0 = 2 and a1 = 7.
Let us find the solution of the recurrence relation "a_n = a_{n-1} + 2a_{n-2}" , with "a_0 = 2" and "a_1 = 7". Let us solve the characteristic equation "k^2=k+2" which is equivalent to "k^2-k-2=0", and hence by Vieta's formulas has the solutions "k_1=-1" and "k_2=2." It follows that the solution of the equation is "a_n=C_1\\cdot (-1)^n+C_2\\cdot 2^n." Since "a_0 = 2" and "a_1 = 7", we have that "2=a_0=C_1+C_2" and "7=-C_1+2C_2." Therefore, "C_2=3" and "C_1=-1." We conclude that "a_n=(-1)^{n+1}+3\\cdot 2^n."
Comments
Leave a comment