# [Maxima] Numerical evaluation of zeta and psi functions

Andrej Vodopivec andrej.vodopivec at gmail.com
Sat Dec 30 11:32:59 CST 2006

```I also think that maxima is using incorrect reflection formula for
negative values of z:

psi[n](z) = (-1)^n*psi[n](-z) + (-1)^n*diff(cot(-%pi*z), z, n)

I think this should be

psi[n](z) = (-1)^n*psi[n](1-z)+(-1)^n*diff(cot(%pi*(1-z)), z, n)

With the last reflection formula the numerical values for psi agree
with the ones returned by maple. The last formula appears also on
http://mathworld.wolfram.com/PolygammaFunction.html

I will change the formula in numerical computation and symbolic
simplification of the psi function.

Andrej

On 12/30/06, Robert Dodier <robert.dodier at gmail.com> wrote:
> On 12/29/06, Andrej Vodopivec <andrej.vodopivec at gmail.com> wrote:
>
> > we have zeta(1.2) -> bfzeta(1.2, 18.0).
> > I propose we make bfzeta autoload from bffac.
>
> OK by me.
>
> > Also I propose we do psi[n](x) -> bfpsi(n, x, 18.0)
> > if n is a positive integer and x a float.
>
> OK by me. But I think what we want is float(bfpsi(n, x, 18))
> (fpprec argument is an integer).
>
> > Also bfpsi should autoload from bffac.
>
> How about if we make the other functions in bffac autoload as well.
>
> Thanks for looking into this --
>
> Robert
>
```