Non-homogeneous recurrence relation
$a_{n} = c0.a_{n-1} + c1.a_{n-2} + c2.a_{n-3} + ...................+ ck.a_{n-k} + f(n)$
$f(n) \neq 0,$ It is non-homogeneous
$a_{n} = a_{n}^{h} + a_{n}^{p}$
$h \Rightarrow homogeneous$
$p \Rightarrow particular$
How to find the particular solution
$f(n) = t^{n}(b0 + b1.n + b2.n^{2} + b3.^n{3} + ........ + br.n^{r} )$
Case 1: if t is the root of the characteristic equation then
$a_{n}^{p} = t^{n}.n^{m}(C0 + C1.n + C2.n^{2} + .................. + Cr.n^{r})$, where m is the multiplicity of t
Case 2: if t is not the root of characteristic equation
$a_{n}^{p} = t^{n}(C0 + C1.n + C2.n^{2} + .................. + Cr.n^{r})$, where is the multiplicity of C0, C1,.....Cr are arbiary constans can be found by substituting particula sol in the given recurrence rel.
Example
$a_{n} - 5. a_{n-1} + 6.a_{n-2} = f(n)$
$a_{n} - 5. a_{n-1} + 6.a_{n-2} = 0$
on solving we get 2 and 3 as the roots of the above equation
$f(n) = 3^{n}(1)$
$f(n) = t^{n}(1.n^{0})$
on comparing, we get t = 3, which is the root of the equation. Case 1 is applied
$a_{n}^{p} = 3^{n}.n(C)$
$f(n) = 5^{n}(3n^{2} + 2n + 1)$
on comparing, we get t = 5, which is not the root of the equation. Case 2 is applied
$a_{n}^{p} = 5^{n}(An^{2} + Bn + C)$
$a_{n} + a_{n-1} = (3n).2^{n}$
$a_{n} + a_{n-1} = 0$
$t + 1 = 0 $
$t = -1$
$a_{n}^{p}= (0.n^{0} + 3n^{1}).2^{n}$
on comparing, we get t = 2, which is not the characteristic root, So case 2 is applied
$a_{n}^{p}= (cn + d).2^{n}$