Re: Is it done?
"Mark Miller" <[email protected]>
| Newsgroups | gmane.comp.lang.e.general |
|---|---|
| Message-ID | <[email protected]> |
On Dec 31, 2007 9:54 PM, Kevin Reid <[email protected]> wrote: > > (mismatch (file #P"/Users/erights/svn-other/e-on-cl/tests/ > > numbers.updoc") > > (source "def x := 2.0 ** -0.5") > > (expects ("value" "0.7071067811865476")) > > (instead ("value" "0.7071067811865475")) (opt-backtrace > > nil)) > > This is the floating-point problem I mentioned. I believe that > 0.7071067811865475 is actually the correct answer; please verify this. E-on-Java does give 0.7071067811865475. For this case, E-on-Java simply delegates to Java's StrictMath.pow(), which is supposed to use IEEE double precision with round-to-even. I'm not sure what else to do to verify this. Since this kind of thing may be sensitive to platform issues at several levels of abstraction, for the record, my "rune --version" prints E version: 0.9.1c at /Users/erights/ehome/ on Java version: 1.5.0_07 at /System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Home on OS: Mac OS X version: 10.4.11 on i386 (mac/x86) for erights in US -- Text by me above is hereby placed in the public domain Cheers, --MarkM