[sage-devel] elliptic_e(0.5, 0.1) differs from Mathematica 7 by about 0.04%.
Subject: [sage-devel] elliptic_e(0.5, 0.1) differs from Mathematica 7 by about 0.04%.
From: Valery Pipin
Date: Mon, 10 Aug 2009 15:37:51 +0900
>> Dr. David Kirkby wrote:
> >
> > Sorry last was for the previous version of Maxima
> >
> > [va at colombo maxima-5.19.0]$ rlwrap ./maxima-local
> > STYLE-WARNING:
> > redefining ASDF:PERFORM :AROUND (#<STANDARD-CLASS ASDF:LOAD-OP>
> > #<STANDARD-CLASS
> > ASDF:CL-SOURCE-FILE>) in DEFMETHOD
> > Maxima 5.19.0 http://maxima.sourceforge.net
> > Using Lisp SBCL 1.0.29
> > Distributed under the GNU Public License. See the file COPYING.
> > Dedicated to the memory of William Schelter.
> > The function bug_report() provides bug reporting information.
> > (%i1) elliptic_e(0.5, 0.1);
> > (%o1) .4980113944988315
> >
> > I wonder how sage people resist to use the high perfomance lisps like
> > cmucl or sbcl (which has windows version as well) to compile maxima.
> >
> > best luck
> > Valery
>
> You do not say what hardware you are using, which is quite relevant in
> this case.
>
> I've no idea how the Sage group would feel about switches lisps. Given
> they have just recently done that (I forgot what was used before), there
> might not be too much enthusiasm for it.
>
> Why do you think cmucl or sbcl would give high performance. Are you
> suggesting ecl would give lower performance?
Generally lower (factor 2-3), and sometimes much lower
>
> Previously I showed the result from Mathematica where I'd taken pains to
> use 1/2 for 0.5, 1/10 for 0.5, then computed the results to 50 digits
>
> In[4]:= N[EllipticE[1/2,1/10],50]
>
> Out[4]= 0.49801139449883153311546104061744810584963105068054
(%i1) fpprintprec:50;
(%o1) 50
(%i2) fpprec:128;
(%o2) 128
(%i3) bfloat(elliptic_e(0.5, 0.1));
(%o3) 4.980113944988314722550626356678549200296401977539b-1
>
> This would have used software emulation to do the high precision. I
> tried it again, this time doing no such thing, so I might expect
> Mathematica to use only the floating point processor of the Sun and Sun
> libraries, not its own. (Of course, with closed-source software), it is
> anyone's guess what is really happening)
Yes, that's right
>
> In[1]:= EllipticE[0.5,0.1]
>
> Out[1]= 0.498011
>
> which for all the digits shown, is the same result everyone else seems
> to get on their x86 boxes. This is on the same hardware. So if it was a
> problem on a Sun library, it is not one used by Mathematica.
>
> I'll ask on the ECL list. I'll also try to build this on some other
> Solaris (SPARC) hardware and also on some Solaris x86 hardware.
There is sbcl for solaris, I would recommend to try it instead ecl
best wishes
Valery