(11C) Decimal Expansion of a Fraction
|
01-16-2021, 11:10 AM
(This post was last modified: 01-16-2021 11:32 AM by Gamo.)
Post: #1
|
|||
|
|||
(11C) Decimal Expansion of a Fraction
HP-11C program to give the decimal expansion of a fraction to
as many decimal places as desired. This program is the extended version from the one for the HP-12C found at this post: https://www.hpmuseum.org/forum/thread-16160.html Program will produce decimal expansion 8 digits at a time with each press of [R/S] give user another 8 digits. When program finish running read each digit from right to left on each set of 8 digits. ------------------------------------------------------------ Procedure: [FIX] 0 Numerator [ENTER] Denominator [f] [A] display 1 digit at a time until reach 8 digit then stop. Read decimal expansion from right to left if dispaly shown [87654321] reverse to 12345678 ------------------------------------------------------------ Example: I like to know decimal expansion digits to 24 decimal places ( 8 digits 3 times ) For 35/31 [f] [FIX] 0 35 [ENTER] 31 [f] [A] display 22,309,211 write down in reverse as 11290322 [R/S] dispaly 61,546,085 reverse as 58064516 [R/S] display 52,230,921 reverse as 12903225 answer: 11290322 58064516 12903225 Program: FIX 0 Code:
Gamo |
|||
01-16-2021, 05:30 PM
Post: #2
|
|||
|
|||
RE: (11C) Decimal Expansion of a Fraction
(01-16-2021 11:10 AM)Gamo Wrote: HP-11C program to give the decimal expansion of a fraction to Hi Gamo, I 'd like to propose you inserting a step [CHS] between [RCL I] [INT] and [10^X] (so, just before [10^X]) because you avoid the reverse reading. Keep you safe Laurent |
|||
01-17-2021, 05:25 AM
(This post was last modified: 01-17-2021 07:51 AM by Gamo.)
Post: #3
|
|||
|
|||
RE: (11C) Decimal Expansion of a Fraction
This update add-on Integer Reverse routine so now can be read normally.
Code:
Remark: If the result shown less than8 digits add 0 to the end to complete 8 digits set. Example: [xxxxxxx0] Gamo |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 2 Guest(s)