Bill Allombert on Fri, 10 Dec 1999 12:22:57 +0100 (MET)


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: more zeta() faults


Michael Somos wrote
>>>
   What is think is interesting is the variety of different faults encountered :
   gp> for(n=1,30,print(n" "zeta(I+10^n)))
   1 1.000759077829856768809901195 - 0.0006401280267855239745764942372*I
   2 1.000000000000000000000000000 - 2.623314226356272336124975847 E-31*I
   3 1.000000000000000000000000000 - 2.993549263496598102783842505 E-302*I
   4 1.000000000000000000000000000 - 1.601996728198064104058581242 E-3011*I
   5 1.000000000000000000000000000 - 3.198125608525491241840590787 E-30104*I
   6 1.000000000000000000000000000 - 3.226876165408552144077256540 E-301031*I
     ***   overflow in R*R
   gp> for(n=1,30,print(n" "zeta(0+10^n)))
   1 1.000994575127818085337145958
   2 1.000000000000000000000000000
   3 1.000000000000000000000000000
   4 1.000000000000000000000000000
   5 1.000000000000000000000000000
   6 1.000000000000000000000000000
   7 1.000000000000000000000000000
   8 1.000000000000000000000000000
   9 1.000000000000000000000000000
     ***   impossible assignment I-->S
   gp> for(n=1,30,print(n" "zeta(1/3*10^n)))
   1 1.147356236882742872645615288
   2 1.000000000092399026901528289
   3 1.000000000000000000000000000
   4 1.000000000000000000000000000
   5 1.000000000000000000000000000
   6 1.000000000000000000000000000
   7 1.000000000000000000000000000
     ***   exponent too large in exp.
   gp> for(n=1,10,print(n" "zeta(1/10000^n)))
   1 -0.5000919038861036320095103010
   2 -0.5000000091893854323645512140
   3 -0.5000000000009189385332056772
   4 -0.5000000000000000918938718545
   5 -0.5000000000000000000748188871
   6 -0.5000000000000005856439856969
   7 -0.5000000000070312676220292861
   8 -0.5000001009959118357014707048
   9 -0.5013897738467078603232921279
   10 -18.70857365099656195236164656

   Sorry to bear bad news. Shalom, Michael
>>>>


? zeta(I+10^7)
In fact there are no bugs here!
PARI use different exponents for real and imaginary part of complex number.
In this case the exponent of the imaginary part is too small to be represented in PARI, 
so it returned an error.

? zeta(10^10)
   ***   impossible assignment I-->S
It is not really a bug since
? zeta(10^9+0.)
 ***   exponent too large in exp.   
? zeta(10^10+0.)
 ***   exponent too large in exp.   
which is in turn a little bug, since there is no good reason to overflow.

  ***   impossible assignment I-->S
is raised because PARI use a special function izeta for small integer but do not range check.
? zeta(1/3*10^8)
 ***   exponent too large in exp.
It is the same than above...


Bill.