Find the general term for sequence ($a_n$) which equates to the recursive equation $a_{n+3}=5a_{n+2}-7a_{n+1}+3a_n+16+24n^2+36*3^n$ Find the general term for sequence ($a_n$) which equates to the recursive equation $a_{n+3}=5a_{n+2}-7a_{n+1}+3a_n+16+24n^2+36*3^n$ with $a_0=3$, $a_1=5$ and $a_2=27$
I tried doing this question by working out how much $a_k$ is for some $a_k$.
$a_3=5*27-7*5+3*3+16+24*9+36*3^3=1383$
As soon as I saw this huge result, I realized that I was going down the wrong path. I then thought that maybe it is a function like $f(x)=Ax^2+Bx+C$ and I tried substituting some values (I know that this is not correct mathematical thought, but I was hoping for some inspiration on what to do, inspiration which unfortunately did not come). All of these routes I attempted did not work out for me. This is the first time I am seeing a question of this type, could you please explain to me how to solve it, how you intuitively thought of each step and also what general thought pattern I should follow in the future when confronted with a question like this?

You can put it in WA e.g.
the recurrence
See the Recurrence equation solution section there.
Then just use the values for $a_0, a_1, a_2$ to find the constants $c_i$.
Probably there's good amount of theory behind that and that's what WA implemented.
And here is the solution with the constants found.
complete solution
All in all, I don't think this is a problem well-suited for humans, it's hard to guess the solution or find any pattern by just observing. Maybe there's some trick (or theoretical apparatus) to simplify things and solve it in the general case... but unless you know it, you have no chance.
At the end of the day the formula is:
$a(n) = -n (n ((n - 2) n + 9) - 3^{n + 1} + 1) + 3^n + 2$
