Xref: utzoo comp.unix.sysv386:906 comp.unix.xenix.sco:332 Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!zaphod.mps.ohio-state.edu!samsung!uunet!mcsun!hp4nl!integow!hot From: hot@integow.uucp (Roland van Hout) Newsgroups: comp.unix.sysv386,comp.unix.xenix.sco Subject: Xenix 2.3.3 386 floating point problem Keywords: Xenix floating point Message-ID: <1191@integow.uucp> Date: 2 Oct 90 15:16:32 GMT Followup-To: comp.unix.sysv386 Organization: Integrity BV, Woerden, the Netherlands Lines: 27 We are using an 25 Mhz Compaq 300 Mb no FPU 8 Mb ram, and Xenix V.2.3.3. I'm expiriencing troubles with the calculation of floats: I have a float which contains :90099090001018.000000 I want add this 11.11 which is a char string, so this thru atof gives 11.110000 according to xenix this results in: 90099090001029.109000 So now we add 0.11 atoffed --> 0.110000 and we get 90099090001029.218000 then we add 1.11 atoffed --> 1.110000 according to xenix this is 90099090001030.328000, finally xenix got one right!!!!!!!! So now we add 1.11 atoffed --> 1.110000 this is 90099090001031.437000 and last but not least we add 1.10 atoffed --> 1.100000 and the result is 90099090001032.531000 I linked with -lm , so what am I doing wrong????????? -- UUCP: ..!uunet!mcsun!hp4nl!integow!hot or hot@integow.UUCP or hot@hot.mug Roland van Hout, Sr. software engineer, Integrity software consultants, Pelmolenlaan 16, 3447 GW Woerden, Netherlands, tel +31 3480-30131, fax +31 3480-30182 Sex is not the answer, sex is the question. The answer is YES!