$\ x(n+2)−1/2x(n+1)+1/8x(n)=cos(nπ/2)$
Guess a solution -$\ Acos(nπ/2)+Bsin(nπ/2)$ where A and B are constants
There were a question about this exact problem yersterday - Need help finding specific solution for second order nonhomogenous recurrence relation
But I did not understand the answer given, could someone explain what to do step-by-step after I have gotten to:
$\ x(n+2)−1/2x(n+1)+1/8x(n) = \Bigl(A\cos\frac{(n+2)\pi}2+B\sin\frac{(n+2)\pi}2\Bigr) -\frac12\Bigl(A\cos\frac{(n+1)\pi}2+B\sin\frac{(n+1)\pi}2\Bigr) +\frac18\Bigl(A\cos\frac{n\pi}2+B\sin\frac{n\pi}2\Bigr)\ $
I am stuck...