时间复杂度O(logn),时间复杂度O(logn)
Golden and Alternating, fast simple O(lg n) algorithms for Fibonacci
摘要:
两个非常快速和简单的O(lg n)算法的个人Fibonacci数,并比较竞争算法。一个简单的O(lg n)递归推导出,也可以适用于卢卡斯。给出了一个公式来估计最大的n,其中F_n不溢出实现的数据类型。对计算机表示太大的输入进行计时的危险会导致错误的研究结果。
英文摘要:
Two very fast and simple O(lg n) algorithms for individual Fibonacci numbers are given and compared to competing algorithms. A simple O(lg n) recursion is derived that can also be applied to Lucas. A formula is given to estimate the largest n, where F_n does not overflow the implementation's data type. The danger of timing runs on input that is too large for the computer representation leads to false research results.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。