Solving a non-homogeneous linear recurrence relation So i have this non-homogeneous linear recurrence relation to solve:
$$a_{n}=2a_{n-1}-a_{n-2}+2^n+2$$
$a_{1}=7$ and $a_{2}=19$
I know that the non-homogeneous part is $2^n$ and i know how to solve homogeneous linear recurrence relations, but when i get a non-homogeneous one i have no idea how to approach it. 
I have this as well: $b_{n}=Aq^n$ when the non-homogeneous part is an exponential function look-alike. So yeah i know it should be of help, but i don't know how to apply it in solution. I need to make a characteristic polynomial as well(if that's what it is called) but i am really stuck at using all that in practical example.
So i am not sure how to solve it, any hints or help would really be appreciated.

Define:
$g_n := a_{n}-a_{n-1}$
Then $a_{n}=2a_{n-1}-a_{n-2}+2^n+2 \implies a_{n}-a_{n-1}=a_{n-1}-a_{n-2}+2^n+2 \\\ \implies g_n = g_{n-1} + 2^n +2 \implies  g_n- g_{n-1} = 2^n +2$
$$g_n- g_{n-1} = 2^n +2 $$
$$g_{n-1}- g_{n-2} = 2^{n-1} +2 $$
$$.$$
$$.$$
$$.$$
$$g_3- g_{2} = 2^3 +2 $$
Since $g_2 = 19-7=12$, then $g_n = \sum_{i=3}^n g_i-g_{i-1} +g_2 = 2^3\times \frac{1-2^{n-3+1}}{1-2} + 2\times (n-3+1) + 12= 2^{n+1}+2n$ Therefore $a_n-a_{n-1} = 2^{n+1}+2n$.For all $n \geq 3$.
$$a_n-a_{n-1} = 2^{n+1}+2n$$
$$a_{n-1}-a_{n-2} = 2^{n}+2(n-1)$$
$$.$$
$$.$$
$$.$$
$$a_3-a_{2} = 2^4+2 \times 3$$
$a_n =  \sum_{i = 3}^{n} a_i - a_{i-1} + a_{2} = 2^4 \times \frac{1-2^{n-3+1}}{1-2}+  (3+n) \times (n-3+1)  + 19 = n^2+n +2^{n+2}-3$. For all $n \geq 3$.
EDIT:
For generalization:
$$a_n = Aa_{n-1}+Ba_{n-2} + P(n)$$
Assert: $$a_n - C a_{n-1} = D (a_{n-1} - Ca_{n-2}) + P(n) \implies 
$$ Where $C,D \in \mathbb C$
\begin{cases}C+D = A \\ CD = -B\end{cases}
so $C,D$ is roots of $x^2-Ax-B=0$
