Let $a_0=0, a_1=2,$ and $a_2=5$. Use generating functions to solve the recurrence equation: $$a_{n+3} = 5a_{n+2} - 7a_{n+1}+3a_n + 2^n$$ for $n\geq0$.
This is a book problem from Applied Combinatorics. I am really confused about tackling $2^n$ part of the recurrence relation using generating functions.
Edit:
I know I need to convert the recurrence into series and I have broken it down, but am struggling with getting it into a proper form to do partial fractions. These are the equations I have managed to get.
If we let $A(x) = \sum_{n \geq 0} a_n x^n$ be the generating function for $a_n$ then after the calculations I got:
$$A(x)\cdot(1-5x+7x^2-3x^3)= 12x^3 - 9 x^2 + \frac{2x}{1-2x}$$
After simplifying: $$A(x) = \frac{12x^3 - 9 x^2 + \frac{2x}{1-2x}}{1-5x+7x^2-3x^3}$$ $$= \frac{24 x^4 - 30 x^3 + 9 x^2 - 2 x}{(1-2x)(x-1)^2(3x-1)}$$
Then, the partial fraction decomposition is: $$A(x) = -\frac{8}{1-2x} + \frac{13}{4}\frac{1}{1-3x} + \frac{37}{4}\frac{1}{1-x} - \frac{1}{2} \frac{1}{(1-x)^2} - 4$$
I have tried to plug in the values, but something doesn't seem right. Please let me know where I would have gone wrong.