HP Forums
(12C) Fibonacci Numbers and Develop the Fibonacci sequence - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Software Libraries (/forum-10.html)
+--- Forum: General Software Library (/forum-13.html)
+--- Thread: (12C) Fibonacci Numbers and Develop the Fibonacci sequence (/thread-9317.html)



(12C) Fibonacci Numbers and Develop the Fibonacci sequence - Gamo - 10-17-2017 11:42 AM

Finding the Fibonacci Number by using program on HP 12C

Code:

01 ENTER
02 5
03 SQR
04 STO 1
05 ENTER
06   1
07   +
08   2
09   /
10   X<>Y
11   Y^X
12   RCL 1
13   /
14   Fix 0
15   GTO 00

Example: 12 R/S result 144

Result accuracy is best below n<39


Develop the Fibonacci sequence with f1 = 1, f2 = 1
Answer: 1, 1, 2, 3, 5, 8, 13, 21, ...

Program:
Code:

ENTER
ENTER
R↓
R↓
+

Instruction: 1 ENTER 1 R/S result 2 and continue pressing R/S
result 3, 5, 8, 13, 21, 34, 55, 89, 144, ..

Instruction: 89 ENTER 144 R/S result 233 and continue pressing R/S
result 377, 610, 987, ...

To develop Fibonacci Numbers automatically add [PSE] and GTO 01 at the end of the program.


Gamo


RE: (12C) Fibonacci Numbers and Develop the Fibonacci sequence - Gamo - 01-23-2019 12:04 PM

For HP-12C Platinum in ALG mode.

Develop the Fibonacci sequence program.

---------------------------------------------

Procedure:

1 [R/S] [R/S] [R/S] ....... display Fibonacci Sequence

Remark: Must start from 1

--------------------------------------------

Example:

1 R/S 1
R/S 2
R/S 3
R/S 5
R/S 8
R/S ..........
--------------------------------------------
Program: ALG mode
Code:

[+] [X<>Y] [+] [LSTx] [=]

Remark:

To have this program keep on going automatically
Added [PSE] [GTO] 001


Gamo