[Date Index]
[Thread Index]
[Author Index]
Re: Question about yet another bug in Sum
*To*: mathgroup at smc.vnet.net
*Subject*: [mg35233] Re: [mg35204] Question about yet another bug in Sum
*From*: BobHanlon at aol.com
*Date*: Wed, 3 Jul 2002 05:13:54 -0400 (EDT)
*Sender*: owner-wri-mathgroup at wolfram.com
In a message dated 7/2/02 4:07:18 AM, vvb at mail.strace.net writes:
>Here is another bug in Sum.
>
> $Version
>
> "4.2 for Microsoft Windows (February 28, 2002)"
>
> Sum[Exp[-I Pi n] n /(1 + n^2), {n, 0, Infinity}]
>
>ACTUAL: Sum::"div": "Sum does not converge."
>
>EXPECTED: -1/2*HypergeometricPFQ[{2, 1 + I, 1 - I}, {2 - I, 2 + I}, -1]
>
>CHECK-UP: N[%, 20]//Chop
>
> -0.26961050270800898180
>
> NSum[Exp[-I Pi n] n/(1 + n^2), {n, 0, Infinity},
WorkingPrecision->20]//Chop
>
> -0.269610502708010
>
>This bug is present in 4.1, 4.0, 3.0. Version 2.2 leaves the sum
unevaluated.
>
>
>Can anyone explain the origin of the bug?
As a general rule it is worth simplifying the argument to Sum when possible.
$Version
4.1 for Mac OS X (November 5, 2001)
Sum[Simplify[Exp[(-I)*Pi*n]*(n/(1 + n^2)), Element[n, Integers]], {n, 0,
Infinity}]
(1/4)*PolyGamma[0, 1/2 - I/2] +
(1/4)*PolyGamma[0, 1/2 + I/2] -
(1/4)*PolyGamma[0, 1 - I/2] - (1/4)*PolyGamma[0, 1 + I/2]
N[%, 20]//Chop
-0.26961050270800898180
%%//FullSimplify
(1/4)*(HarmonicNumber[-(1/2) - I/2] +
HarmonicNumber[-(1/2) + I/2] - HarmonicNumber[-(I/2)] -
HarmonicNumber[I/2])
N[%, 20]//Chop
-0.26961050270800898180
Bob Hanlon
Chantilly, VA USA
Prev by Date:
**RE: RE: Absolute Value of Complex Numbers**
Next by Date:
**RE: non integer exponents in ContourPlot[]?**
Previous by thread:
**RE: Question about yet another bug in Sum**
Next by thread:
**Re: Question about yet another bug in Sum**
| |