I have a difference equation I want to convert to a explicit formula and I'm currently stuck.
The difference equation is as follows: $$ N_x = N_{x-1} + N_{x-3}, (f(x) = f(x-1) + f(x-3)), where: N_3 = 1, N_4 = 2, N_5 = 3 $$
I want to find the explicit formula for this difference equation.
I know how to solve it's characteristic equation and roots:
$$
λ^3 = λ + 1 \,\,\,\,\\
λ^3 - λ - 1 = 0
$$
This equation will give us one real solution and two imaginary solutions. The solutions of the equation are so convoluted that it is easier to give the approximate answers to illustrate the solutions:
$$
λ_1 ≈ 1.4656 \\
λ_2 ≈ -0.23279 - 0.79255i \\
λ_3 ≈ -0.23279 + 0.79255i
$$
This is the point at which I get stuck. I've solved difference equations in which there are either only real parts, or only imaginary parts. But I do not know how to solve for this case in which both imaginary- and real solutions are present. If someone could help me out, that would be amazing.
If you want to help me, you can just use $λ_1, λ_2\ and\ λ_3$ as variables for further calculations. Thanks in advance!
What you did is very correct but the problem is far to be simple.
For your information :
This is sequence $A000930$ in $OEIS$. If you look at the documentation you will notice that, in $192$, Simon Plouffe found that its generating function is $$\frac{1}{1-x-x^3}$$
A nice formula (given in the documentation) is $$N_x=\sum_{i=0}^{\left\lfloor \frac{x}{3}\right\rfloor}\binom{x-2 i}{i}$$
More complex (but nice) is the hypergeometric function $$a_n=\, _3F_2\left(\frac{1-n}{3},\frac{2-n}{3},-\frac{n}{3};\frac{1-n} {2},-\frac{n}{2};-\frac{27}{4}\right)$$