albe…@spenarnc.xs4all.nl writes:
>In article <2026…@mips.complang.tuwien.ac.at>,
>Anton Ertl <ant…@mips.complang.tuwien.ac.at> wrote:
>>A better way to think about them is: Each FP number has an exact
>>value, but in some cases conversions to FP and FP operations round,
>>because there is no FP value for the exact result; this rounding leads
>>to errors. The size of this error is the subject of numerical
>>analysis.
>
>Exactly
>0.0001E0 DUP FSIN F-
I assume you mean FDUP here.
>looses a whole lot of precision.
>Maybe "imprecise numbers" is not a bad name after all.
It is. It's not the numbers that are imprecise, it's the operations.
They round (but not in every case).
In the present case the conversion from the decimal string to the FP
number rounds (but that makes little difference for what follows), and
FSIN rounds. F- does not round in this case, but the absolute error
from the FSIN rounding is still present in the result and is
relatively larger compared to the result, so the number of significant
digits is smaller; this phenomenon is called cancellation.
- anton
--
M. Anton Ertl http://www.complang.tuwien.ac.at/anton/home.html
comp.lang.forth FAQs: http://www.complang.tuwien.ac.at/forth/faq/toc.html
New standard: https://forth-standard.org/
EuroForth 2026 CFP: http://www.euroforth.org/ef26/cfp.html