Path: utzoo!mnetor!uunet!wyse!weitek!pyramid!prls!philabs!micomvax!ray From: ray@micomvax.UUCP (Ray Dunn) Newsgroups: comp.lang.c Subject: Re: How not to write a loop Message-ID: <947@micomvax.UUCP> Date: 18 Mar 88 22:44:55 GMT References: <296@draken.nada.kth.se> <64400004@convex> <7409@brl-smoke.ARPA> Reply-To: ray@micomvax.UUCP (Ray Dunn) Organization: Philips Electronics Ltd. (TDS - Montreal) St. Laurent P.Q., Canada Lines: 16 In article <7409@brl-smoke.ARPA> gwyn@brl.arpa (Doug Gwyn) writes: > >This is of course wrong. Floating-point imprecision is not due >simply to float<->double conversion, but is inherent in the >whole approach. Yup. Interestingly, this is one of the very first things I can remember being taught in "computer science" - NEVER test "reals" against absolute values - choose a precision and test against values +/- that precision. Mind you, that was in "autocoder", on a Ferranti Sirius, and the year was 1964. Ah well, yawn.... Ray Dunn. ..{philabs, mnetor, musocs}!micomvax!ray