Solving linear homogeneous difference equation Let $a_{n+2} + a_{n+1} - 6a_n = 0$ and $a_1=1, a_0 = 0$ be given. How do we solve such a difference equation?
I set $a_n =Aw^n$. Then, we get $Aw^{n+2}-Aw^{n+1}-6Aw^n =0$. After that we have $(r^2+r-6)=0$ and $r=w^n = -3,2$.
I plug $-3$ in the first equation and it is satisfied but $2$ does not satisyfing it. What can I do next?
 A: There is a nice way to solve this type of recurrence with operators.
1- Define the operator $E^k$ which does $E^ka_n=a_{n+k}.$
2- So this recurrence can be writen in the form
$$(E^2+E-6)a_n=0$$
this kind of operator have an factorization (like polynomials)
$$(E+3)(E-2)a_n=0 $$
3- An operator in the form (E-r) annihilates  $Cr^n$
$$(E-r)Cr^n=Cr^{n+1}-rCr^n=0. $$
4- It can be shown that, in this case
$$a_n=c_1(-3)^n+c_2(2)^n.$$
5- But we don't need to stop there. We can find the contants $c_1$ and $c_2$, in a easy way with those operators.
Apply $E+3$
$$a_{n+1}+3a_n=c_2(2)^{n+1}+3c_2(2)^n, $$
take $n=0$ and use the initial conditions $a_0=0$, $a_1=1$
$$a_1+3a_0=2c_2+3c_2= 1$$
so $c_2=1/5$.
Now apply $E-2$
$$a_{n+1}-2a_n=c_1(-3)^{n+1} -2c_1(-3)^n, $$
take $n=0$ again
$$1=-c_1.3-2c_1, $$
so $$c_1=-1/5. $$
The solution is
$$a_n=((2)^n-(-3)^n)/5 .$$
A: The characteristic equation is 
$$
r^2+r-6=0\iff(r+3)(r-2)=0\iff r=-3,2.
$$
Thus,
the solution is 
$$
a_n=c_{1}(-3)^{n}+c_{2}2^n
$$
for some $c_{1},c_{2}\in\mathbb{R}$ (as $(-3)^n$ and $2^n$ are linearly independent in a two dimensional solution space). Use the fact that $a_{0}=0$ and $a_{1}=1$ to determine the $c_{i}$.
