# System of difference equations

Is there an effective way of finding a particular $x_n$, say $x_5$, of a system of difference equations $x_{n}=ax_{n+1}+bx_{n-1}$ where $a, b$ are constants and the $n$'s say are $\leq k$ (apart from actually substituting each equation into the next)? Thanks.

-
You could solve the constant-coefficient linear difference equation explicitly. This is second-order, so your characteristic polynomial is quadratic... – J. M. Oct 13 '11 at 12:35
@J.M.: Thanks. I am being silly. – olga Oct 13 '11 at 12:45
See this answer for a closed formula to solve such equations. – Pierre-Yves Gaillard Oct 13 '11 at 13:14
@Guesswhoitis. Please consider converting your comment into an answer, so that this question gets removed from the unanswered tab. If you do so, it is helpful to post it to this chat room to make people aware of it (and attract some upvotes). For further reading upon the issue of too many unanswered questions, see here, here or here. – Julian Kuelshammer May 6 '15 at 16:25