[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

*To*: common-lisp@SU-AI.ARPA*Subject*: comparisons between floats and ratios*From*: "Gail Zacharias" <GZ%OZ.AI.MIT.EDU@XX.LCS.MIT.EDU>*Date*: Mon 27 Jan 86 08:42:53-EST

Is (> a-rational a-float) supposed to err out when (float a-rational a-float) would overflow? If so, there should at least be some way to tell ahead of time if that's going to happen, for people who want to write a more careful comparison routine. The only way I can figure out of doing this now is (> a-ratio (rational most-positive-xx-float)). Consing up a bignum representation of the largest float seems like a high price to pay for being careful. Since most floating point implementations can (internally at least) represent infinity, it shouldn't cause a great loss of efficiency to require that this case return T. A not-entirely-unrelated question: What kind of rounding is FLOAT supposed to do? -------

- Prev by Date:
**[no subject]** - Next by Date:
**Compiler side effects lossage** - Previous by thread:
**Re: comparisons between floats and ratios** - Next by thread:
**comparisons between floats and ratios** - Index(es):