From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,a48e5b99425d742a X-Google-Attributes: gid103376,public From: "Marin David Condic, 561.796.8997, M/S 731-93" Subject: Re: Papers on the Ariane-5 crash and Design by Contract Date: 1997/03/20 Message-ID: <97032020033927@psavax.pwfl.com>#1/1 X-Deja-AN: 227125874 Sender: Ada programming language Comments: Gated by NETNEWS@AUVM.AMERICAN.EDU X-Vms-To: SMTP%"INFO-ADA@VM1.NODAK.EDU" Newsgroups: comp.lang.ada X-Vms-Cc: CONDIC Date: 1997-03-20T00:00:00+00:00 List-Id: Thomas writes: >I have implemented a number of signal processing algorithms both using >small integer and floating point arithmetic. The floating point >versions were not only much easier to develop, they also were >considerably more robust. That is true even if both the inputs >and outputs of the system are actually small integers (as they >usually are when it comes to sensors and effectors). On low-end >hardware, the floating point versions are, of course, somewhat >slower (on modern RISCs there is often no difference). > We've found that on machines with on-board floating point, the difference between scaled integers and floating point ends up being about a wash. While the integer arithmetic may be faster, there's usually more overhead in converting between scalings and so forth. (Of course, this may be very application specific. YMMV) As for overflow situations - you're right that the use of floating point usually means more than enough resolution so you never see it overflow. It might have saved the Ariane. What might also have saved them would be if the arithmetic on the machine had saturated instead of causing an interrupt. (Disable the interrupt & let the hardware saturate or enable the interrupt & put your own saturation software in there.) Floating point usually saturates the way you want it to from hardware, but fixed usually doesn't. MDC Marin David Condic, Senior Computer Engineer ATT: 561.796.8997 M/S 731-96 Technet: 796.8997 Pratt & Whitney, GESP Fax: 561.796.4669 P.O. Box 109600 Internet: CONDICMA@PWFL.COM West Palm Beach, FL 33410-9600 Internet: CONDIC@FLINET.COM =============================================================================== In Vegas, I got into a long argument with the man at the roulette wheel over what I considered to be an odd number. -- Steven Wright ===============================================================================