Fibonnacci from 1 to 15 with 5 repetitions

This pages shows the relative performance of recursive and iterative methods of calculating the Fibonnacci series in XQuery. The code is explained in the XQuery Wikibook.

n fib recursive iterative
-1 0 0.2
0 0 0 0
1 1 0 0
2 1 0.2 0.2
3 2 0 0
4 3 0.4 0.2
5 5 0.4 0.2
6 8 0.6 0.2
7 13 1 0.2
8 21 1.6 0.4
9 34 2.6 0.2
10 55 4 0.4
11 89 6 0.4
12 144 8.2 0.4
13 233 12.8 0.4
14 377 18.6 0.2
15 610 32.8 0.2