Z Thread Starter zulfi100 Joined Jun 7, 2012 656 Feb 11, 2016 #1 Hi, Book has provided a formula for computing Fibonacci series which was discovered by A. de Moivre. The formula is given below: Fib(n) = Φ raised to the power n/ square root of 5 Can some body please guide me what’s its running time? Zulfi.
Hi, Book has provided a formula for computing Fibonacci series which was discovered by A. de Moivre. The formula is given below: Fib(n) = Φ raised to the power n/ square root of 5 Can some body please guide me what’s its running time? Zulfi.
WBahn Joined Mar 31, 2012 26,398 Feb 11, 2016 #2 That depends on how long it takes to raise a constant to an integer power, and that depends on the algorithm used to calculate the value of a constant raised to an integer power, doesn't it?
That depends on how long it takes to raise a constant to an integer power, and that depends on the algorithm used to calculate the value of a constant raised to an integer power, doesn't it?
Z Thread Starter zulfi100 Joined Jun 7, 2012 656 Feb 11, 2016 #3 Hi, I found that the run time of power function is log(n). http://stackoverflow.com/questions/5231096/time-complexity-of-power. Thats the advantage of his technique otherwise the iterative version takes O(n) time. Zulfi.
Hi, I found that the run time of power function is log(n). http://stackoverflow.com/questions/5231096/time-complexity-of-power. Thats the advantage of his technique otherwise the iterative version takes O(n) time. Zulfi.