Re: Re: Re: bug in Mathematica 3.0 ?

*To*: mathgroup at smc.vnet.net*Subject*: [mg7278] Re: [mg7261] Re: [mg7239] Re: [mg7213] bug in Mathematica 3.0 ?*From*: George Woodrow III <georgeVW3 at worldnet.att.net>*Date*: Thu, 22 May 1997 09:17:56 -0400 (EDT)*Organization*: AT&T*Sender*: owner-wri-mathgroup at wolfram.com

Regarding the problem with Prime: I checked out w. meeussen's computations on my PowerMac 8100/80 and MMa 3.0. In[1]:= 2+2 Out[1]= 4 In[2]:= Timing[Prime[12345]] Out[2]= {0.0333333 Second,132241} In[3]:= Timing[Prime[123456]] Out[3]= {0.05 Second,1632899} In[4]:= Timing[Prime[1234567]] Out[4]= {0.15 Second,19394489} In[5]:= Timing[Prime[12345678]] Out[5]= {0.283333 Second,224284387} In[6]:= Timing[Prime[123456789]] <-- Pentium crashed here Out[6]= {3.05 Second,2543568463} In[7]:= Timing[Prime[1234567890]] Out[7]= {16.25 Second,28423087477} As you can see, MMa had no problem at all. I could even find Prime[1234567890]. I tried Prime[12345678901], but it took so long, I aborted the computation. On the PowerMac, at least, the problem does not exist. Since the Kernel is supposed to be source code identical across platforms, the problem may be in the dll. I don't know who is responsible for the code. As a sidelight, my timings are significantly shorter than w. meeussen's. I don't have the particulars on which penitom he used, but my PowerPC is a 601, and is slow compared to current offerings. Even 1 133 MHz pentium should be faster. hope this helps, george woodrow w.meeussen wrote: > > At 19:13 17-05-97 -0400, seanross at worldnet.att.net wrote: > >ASU_FS wrote: > >> > >> I'm using Mathematica ver: 3.0 for Win95 on a Pentium machine. > >> I typed in the following test: > >> Timing[Prime{123456789]]. > >> I get the following error: > >> MathKernel > >> This program has performed an illegal operation..... > >> The details: > >> MathKernel caused a divide error in module MathDll.dll at 0137:0072843e > >> > >> The same test on a 486 and Mathematica 2 on Windows 3.1 works well, and > >> also on a SGI with Mathematica ver: 3.0. > >> > >> Do other people have the same problem ? If so is there a fix to it. > >> > >> Regards, > >> R. Wathelet. > > > >I tried it on my win95 pentium and got the same message you did. I did > >fix the code so it read Timing[Prime[123456789]]. > > > > > In[37]:= > Timing[Prime[12345]] > Out[37]= > {0.06 Second,132241} > In[38]:= > Timing[Prime[123456]] > Out[38]= > {0.11 Second,1632899} > In[39]:= > Timing[Prime[1234567]] > Out[39]= > {0.71 Second,19394489} > In[40]:= > Timing[Prime[12345678]] > Out[40]= > {1.64 Second,224284387} > In[41]:= > Timing[Prime[123456789]] > Kernel made invalid operation ... > > you'r right !! > > Dr. Wouter L. J. MEEUSSEN > eu000949 at pophost.eunet.be > w.meeussen.vdmcc at vandemoortele.be