Programming exercise (RPL/RPN) - Reciprocal Fibonacci Constant
|
02-19-2017, 04:04 PM
Post: #36
|
|||
|
|||
RE: Programming exercise (RPL/RPN) - Reciprocal Fibonacci Constant
Little OFF, but I wrote it also for my CASIO 50f. The original version was 12 steps and works as I want.
This new version is 19 steps and collects separately the numerator and denominator: \(\frac{N_i}{D_i}=\frac{N_{i-1}}{D_{i-1}}+\frac{1}{F_i}=\frac{F_i · N_{i-1}+D_{i-1}}{D_{i-1} · F_i}\) This version works well also, need only one improvement: a short fraction simplification routine - I hope I can fit it into the remained 10 steps, or I must to go to fx-3600P, where 39 steps available. The results: Code:
The program code: Code:
The variables and initial values: Code: K1: F_i-1, store 0 before start Csaba |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 4 Guest(s)