I modified the error estimate (which was purely heuristic before).
I don’t know where this goes, but here’s an idea of how the code works, and how I obtained the new error estimate. First FunctionExpandFibonacci:
In[1]:=
Then, an approximation to the inverse for large n:
In[2]:=
Series expand:
In[3]:=
So, the leading order approximation is the first term, which can be rewritten as Log[GoldenRatio,Sqrt[5]z]. The error (which should be larger than the actual error because Abs[Cos[x]]<1) is:
In[4]:=
So, an approximation to the relative error is , implying that the precision of the answer is less than .
Now, Root only needs an approximate root sufficiently close so that there is only 1 actual root in the vicinity of the approximate root. Hence, we can construct a Root object by specifying the needed relation, and using an approximate root. For large enough inputs, the above approximation is sufficient to enable Root to work.