From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (qmail 7936 invoked from network); 28 Nov 1998 13:32:07 -0000 Received: from mail.redhat.com (199.183.24.239) by lists.redhat.com with SMTP; 28 Nov 1998 13:32:07 -0000 Received: from mars.neuro.uni-oldenburg.de (mars.neuro.uni-oldenburg.de [134.106.155.67]) by mail.redhat.com (8.8.7/8.8.7) with ESMTP id IAA00786 for ; Sat, 28 Nov 1998 08:30:55 -0500 Received: from neuro.uni-oldenburg.de (mars [134.106.155.67]) by mars.neuro.uni-oldenburg.de (8.9.1a/8.9.1) with ESMTP id OAA15373; Sat, 28 Nov 1998 14:24:54 GMT Sender: joe@mars.neuro.uni-oldenburg.de Message-ID: <366007B6.205A50C0@neuro.uni-oldenburg.de> Date: Sat, 28 Nov 1998 14:24:54 +0000 From: "Johannes G.D. Hausmann" Organization: Carl von Ossietzky Universitaet Oldenburg X-Mailer: Mozilla 4.5 [en] (X11; I; SunOS 5.5.1 sun4u) X-Accept-Language: en MIME-Version: 1.0 To: axp-list@redhat.com Subject: Re: Floating point problems References: <98112814241200.07172@apollo.bcas.de> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Transfer-Encoding: 7bit > What's wrong with the following program? > > main() { > double x = 1.0; > x *= 1e-310; > } > This is a denormal. From float.h: /* Minimum normalised double */ #undef DBL_MIN #define DBL_MIN 2.2250738585072014e-308 cu, Jo -- ----------------------------------------- Johannes Hausmann Carl von Ossietzky Universitaet Oldenburg FB Physik -- AG Komplexe Systeme EMail : joe@neuro.uni-oldenburg.de -----------------------------------------