Help with an algorithm for converting decimals to fractions
|
08-27-2014, 08:55 PM
(This post was last modified: 08-27-2014 08:56 PM by Namir.)
Post: #1
|
|||
|
|||
Help with an algorithm for converting decimals to fractions
I posted an HP Prime program that calculates the integer fractions that approximate a number with decimals (for a user-specified number of continued fraction coefficients). See the HP Prime listing if my description is ambiguous. The program uses an array to store the coefficients of the continued fraction. The program then uses the values in this array to calculate the final numerator and denominator that approximate the input decimal value.
The Math Pac for the HP-7 has a program that performs a similar task. I believe it does its task WITHOUT using an array to store the coefficients of the continued fraction!! My question to you all (and especially Jo Horn) is, "What is the algorithm that converts decimals to fractions that does not use an array to store the coefficients of the continued fraction. I will be happy if you give me a general algorithm. I appreciate your input! :-) Namir |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
Help with an algorithm for converting decimals to fractions - Namir - 08-27-2014 08:55 PM
RE: Help with an algorithm for converting decimals to fractions - Paul Dale - 08-27-2014, 10:12 PM
RE: Help with an algorithm for converting decimals to fractions - Thomas Klemm - 08-27-2014, 10:32 PM
RE: Help with an algorithm for converting decimals to fractions - CosmicTruth - 08-28-2014, 12:51 AM
RE: Help with an algorithm for converting decimals to fractions - Joe Horn - 08-28-2014, 06:03 AM
RE: Help with an algorithm for converting decimals to fractions - Joe Horn - 08-28-2014, 06:48 AM
|
User(s) browsing this thread: 1 Guest(s)