[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: operation of 'round' function
From: |
Al Petrofsky |
Subject: |
Re: operation of 'round' function |
Date: |
07 Feb 2002 13:07:41 -0800 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.2.50 |
address@hidden (Ronan Waide) writes:
> On February 7, address@hidden said:
> > 0.5 is exactly halfway between 0 and 1, so the additional rule is that in
> > case of a tie the even number is used.
>
> That makes no sense whatsover.
>
> If you ask any person who's done basic fractional math, or indeed any
> language other than elisp that supports the concept of rounding
> fractional numbers, you will find that 0.5 is /always/ rounded up.
> --
> Ronan Waide / Java Developer / euroConex Technologies Ltd.
??????????????
Java Language Specification, section 4.2.4:
The Java programming language requires that floating-point
arithmetic behave as if every floating-point operator rounded its
floating-point result to the result precision. Inexact results must
be rounded to the representable value nearest to the infinitely
precise result; if the two nearest representable values are equally
near, the one with its least significant bit zero is chosen. This
is the IEEE 754 standard's default rounding mode known as round to
nearest.
--
Al Petrofsky / Z-80 Assembly Developer / inexplicably unemployed
- Re: operation of 'round' function, (continued)
- Re: operation of 'round' function, Andreas Schwab, 2002/02/07
- Re: operation of 'round' function, Ronan Waide, 2002/02/07
- Re: operation of 'round' function, Ronan Waide, 2002/02/07
- Re: operation of 'round' function, Francesco Potorti`, 2002/02/08
- Re: operation of 'round' function, Eli Zaretskii, 2002/02/08
- Re: operation of 'round' function, Francesco Potorti`, 2002/02/08
- Re: operation of 'round' function, David Kastrup, 2002/02/07
- Re: operation of 'round' function,
Al Petrofsky <=
- Message not available
- Re: operation of 'round' function, Deepak Goel, 2002/02/07
- Re: operation of 'round' function, David Masterson, 2002/02/07
- Re: operation of 'round' function, Deepak Goel, 2002/02/08
- Re: operation of 'round' function. Why does it matter?, Alan Mackenzie, 2002/02/09
- Re: operation of 'round' function. Why does it matter?, David Kastrup, 2002/02/09
- Re: operation of 'round' function. Why does it matter?, Alan Mackenzie, 2002/02/10
- Re: operation of 'round' function. Why does it matter?, David Kastrup, 2002/02/11
- Re: operation of 'round' function. Why does it matter?, Eli Zaretskii, 2002/02/12
- Re: operation of 'round' function, David Kastrup, 2002/02/07
- Re: operation of 'round' function, Francesco Potorti`, 2002/02/07