Re: Bug in definite integral over Gamma function?
- To: mathgroup at smc.vnet.net
- Subject: [mg116830] Re: Bug in definite integral over Gamma function?
- From: Peter Pein <petsie at dordos.net>
- Date: Wed, 2 Mar 2011 04:31:47 -0500 (EST)
- References: <ik5f76$sif$1@smc.vnet.net>
Am 24.02.2011 12:25, schrieb H Hogreve:
> When getting weired results after a large chain of symbolic calculations,
> I spotted the reason to something that appears to be a bug in an
> integration, i.e., in
>
> Integrate[x^4*Exp[-x]*Gamma[2, x], {x, 0, Infinity}]
>
> The two 7.0 versions of Mathematica (32-bit Windows and 64-bit Linux)
> available for checking this integral yield the result
>
> -363/8
>
> which is obviously incorrect; a correct results can be obtained by
> computing the indefinite integral and taking the limits x->0 and
> x->Infinity. Moreover, the 6.0 version of Mathematica also gives the
> correct result for the definite integral.
>
> Now I am wondering how Mathematica 8 is handling this integral, and
> whether there are possibilities in Mathematica 7 to get the correct
> definite integral (other than via the indefinite one and boundary
> values) ?
>
> Many thanks in advance for any hints,
> H. Hogreve
>
Hi,
entering an additional "bus stop" at the route to infinity helps:
In[1]:= $Version
f[x_]=Exp[-x]x^4Gamma[2,x];
Integrate[f[x],{x,0,1,\[Infinity]}]
Out[1]= 7.0 for Microsoft Windows (64-bit) (February 18, 2009)
Out[2]= 21/8
Peter