[Top][All Lists]

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

Re: [Axiom-developer] 20080221.01.tpd.patch (7099: complex gamma functio

From: Waldek Hebisch
Subject: Re: [Axiom-developer] 20080221.01.tpd.patch (7099: complex gamma function investigation)
Date: Fri, 22 Feb 2008 03:35:52 +0100 (CET)

Tim Daly wrote:
> >> 
> >> fixed 7099: complex Gamma bug
> >> 
> >> Note that at the value 1.0+4.6i there is a radical departure between
> >> the table and the computed values in the imaginary part of the value
> >> even though the real part is exact.
> >
> >(11) -> Gamma(1. + 4.5*%i)
> >
> >   (11)  - 0.004501804477919395 + 4.8078797963506284e-4 %i
> >                                                    Type: Complex DoubleFloat
> >(12) -> Gamma(1. + 4.6*%i)
> >
> >   (12)  - 0.0039079873004091254 - 1.7801308638883733e-4 %i
> >                                                    Type: Complex DoubleFloat
> >
> >So, value of Gamma crossed brunch cut of logarithm and we have jump
> >in numeric value by -2Pi.  However, the formulas in texbooks (including
> >Abramowitz and Stegun) do not use numeric logarithm: log(Gamma(z))
> >in texbooks is a holomrphic function for Re z > 0, in particular
> >texbook log(Gamma(z)) is continouos, while numeric one have jumps.
> The question is whether we want the numeric results to be
> continuous. What's your opinion?

For numeric log(Gamma(z)) what I want does not matter very much:
both log and Gamma have established definitions and the result
is determined by the rules.  Even if we allow ourself freedom
to choose different version of logarithm, since values of Gamma
turn around origin they will mit discontinity of logarithm -- no
single version will make the composition continuous.

There is different story if you consider logGamma function, which
satisfies exp(logGamma(z)) = Gamma(z).  Naively, one would write
logGamma(z) = log(Gamma(z)), but for numeric computation it is
useless to have discontinities: it is much better to choose 
continuous version of logGamma (one can not make logGamma
continuous everywhere, but one put cuts at negative real
numbers and have continuity elsewere).

                              Waldek Hebisch

reply via email to

[Prev in Thread] Current Thread [Next in Thread]