RPN-PRGM: New Windows console application emulating HP calculators
|
02-22-2021, 04:40 AM
Post: #21
|
|||
|
|||
RE: RPN-PRGM: New Windows console application emulating HP calculators
Albert Chan,
Well, the fact that changing the Precision Control alters the results of the same operations is not a bug, but a well-known fact. As a matter of fact, is the basis of the example about the Forensics Algorithm: RPN.exe users manual Wrote:This is an example of such an operation based on the Forensics Algorithm: Another example: Code:
Antonio |
|||
02-22-2021, 02:10 PM
Post: #22
|
|||
|
|||
RE: RPN-PRGM: New Windows console application emulating HP calculators
(02-22-2021 04:40 AM)Aacini Wrote: Another example: We should expect 1e16 = 10.000e15, not 100.00e15 or 9.2234e15 Something is wrong with eng:# conversion. It seems FPUPC:# does not take effect right the way. (If it does, first line and last line should produce the same result) --- I had noticed RPN.exe version 1.0 reduced eng:# to 18 significant digits. Perhaps we can shift eng conversion code to sprintf ? Just break up the number into parts, then join them together. Note: we need to confirm 1 ≤ IP(|mantissa|) < 1000 Example: 1.23e1000 = (12 + .3) * 1e999 → "12.3e999" |
|||
02-23-2021, 01:54 AM
Post: #23
|
|||
|
|||
RE: RPN-PRGM: New Windows console application emulating HP calculators
I solved part of the mystery:
Code:
RPN.exe first parses the whole input line (using the current Precision Control). After that, the whole line is executed. This means that when the next line is parsed, the parse routine uses the same Precision Control set by the last executed line. Of course, this introduces differences... As I said several times, my ENG:p method is not reliable. You should conclude nothing about the FPU/RPN.exe operation based on the results displayed by ENG:p. I am looking for a more reliable method to show an 80-bits floating point number. Antonio |
|||
03-07-2021, 03:31 PM
Post: #24
|
|||
|
|||
RE: RPN-PRGM: New Windows console application emulating HP calculators
Now with manual in Spanish.
"Operaciones Aritméticas en RPN.html" |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 2 Guest(s)