Subject: float(zeta(3)) does not evaluate numerically
From: Dieter Kaiser
Date: Sat, 31 Jan 2009 23:52:28 +0100
I have changed the implementation of the Zeta function to a simplifying
function.
Now something like zeta(3),numer; will give the expected numerical result. The
proposed extension to $sign to get the sign of the Zeta function for noun forms
with numerical constants is no longer needed.
Remarks:
1.
The algorithm of simp-zeta is almost the same as the old algorithm.
I have removed some direct calls to internal functions of the simplifier like
simpabs, red*, timesk, ... The old routine has a resimplify which is not
necessary. Futhermore I have sligtly changed the logic to get a more readable
code.
I have changed the result of zeta(1) to INFINITY, which is more correct and
added the new result zeta(inf) --> 1. Furthermore I have added code to check
more carefully the numbers ONE and ZERO.
2.
The zeta function has a problem with values near ZERO. (See bug report
SF[1995531 ] "zeta errors near 0.0 / 0.0b0".
One reason is that for small negative values the numerical routine does the
calculation for an argument (1-s). But for small values this is near by the
value ONE which is a pole.
I have tried to catch this problem. At least the divison by zero errors near the
value zero can be avoided if we do not try to evaluate zeta for values abs(s) <
10^(-fpprec). But there seems to be more problems near by the value ZERO in the
routine bfzeta.
Dieter Kaiser