I've got an unusual (I think) problem. For a given number F_n (I don't know the value of n), I have to find numbers F_0, F_1 such that F_{n}=F_{n-1}+F_{n-2}. The additional difficulty is that this sequence should be as long as possible (value n for F_n should be the highest) and if there exist more then one solution I must take this with the smallest F_0. In short I must generate my "own" Fibonacci sequence. Some examples:
in: F_n = 10; out: F_0 = 0; F_1 = 2;
in: F_n = 17; out: F_0 = 1; F_1 = 5;
in: F_n = 4181; out: F_0 = 0; F_1 = 1;
What I observed for every sequence (with "Fibonacci rule") F_n there is:
F_n = Fib_n * F_1 + Fib_{n-1} * F_0
Where Fib_n is the n-th Fibonacci number. It is true especially for Fibonacci sequence. But I do not know whether this observation is worth anything. We don't know n and our task is to find F_1, F_0 so I think we have gained nothing. Any ideas?