[Cfp-interest 2674] Re: floating constants issue

Vincent Lefevre vincent at vinc17.net
Wed Feb 1 05:18:20 PST 2023


On 2023-02-01 13:59:51 +0100, Vincent Lefevre wrote:
> BTW, this rule for constants is unintuitive, thus error-prone, when
> using non-symmetric rounding, because negative constants do not exist,
> so that when writing "-0.1", the negation is done after rounding.
> I don't know whether this has already been discussed and what could be
> done. If the rule is kept as is, there should be at least an example
> to warn about this issue.

Moreover, if in the future, it is decided to support constants with
directed rounding via a suffix (for instance), then for the above
reason, only the symmetric roundings toward zero and away from zero
should be supported (this is sufficient), e.g. Z (toward Zero) and
Y (awaY from zero). So -0.1Z would also mean -0.1 rounded toward +inf
and -0.1Y would also mean -0.1 rounded toward -inf.

-- 
Vincent Lefèvre <vincent at vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)


More information about the Cfp-interest mailing list