Download  Print this page

Comparison Of Fibl And Fib2 - HP -28S Manual

Advanced scientific calculator.
Hide thumbs

Advertisement

Example. Calculate F6 and FlO' Note that FIB2 is faster than FIBl.
Calculate F
6 .
[USER [
6
FI82
Calculate FlO'
10
F I 82
3:
2:
8
1:
55
IilDmDIIllDDmII _ _
Comparison of FIB1 and FIB2
FIBl calculates intermediate values Fi more than once, while FIB2 cal-
culates each intermediate Fi only once. Consequently, FIB2 is faster.
The difference in speed increases with the size of
n
because the time
required for FIBl grows exponentially with n, while the time required
for FIB2 grows only linearly with n.
The diagram below shows the beginning steps of FIBl calculating FlO'
Note the number of intermediate calculations: 1 in the first row, 2 in
the second row, 4 in the third row, and 8 in the fourth row.
28: Programming Examples
249

Advertisement

Table of Contents

   Also See for HP HP-28S

   Related Manuals for HP HP-28S

Comments to this Manuals

Symbols: 0
Latest comments: