Integrate[] confuses real and imaginary parts

• To: mathgroup at smc.vnet.net
• Subject: [mg86563] Integrate[] confuses real and imaginary parts
• From: Peter Pein <petsie at dordos.net>
• Date: Thu, 13 Mar 2008 20:52:37 -0500 (EST)

```Dear group,

assuming there's a 6.x.y kernel behind http://integrals.wolfram.com/ ,
there is still a serious bug in Integrate[]:

I entered (to get definite integrals, I did not use "x" and expected
x*If[-1<Im[t0]<1,x*Pi,...] or sth equivalent):
Integrate[1/(1+(t-t0)^2),{t,-Infinity,Infinity}]

and I got

x*If[Im[t0] != 0, Pi, Integrate[ (1 + (t - t0)^2)^(-1), {t, -Infinity,
Infinity}, Assumptions -> t0 â?? Reals]]

Well, Im[I] is definitely != 0. And

Normal[Series[1/(1 + (t - I)^2), {t, 0, 1}]]
gives
1/4 + I/(2*t) - (I*t)/8

Integrate[1/(1+(t-I)^2),{t,-Infinity,Infinity}]
in the integrator's formular
gives an unevaluated result:

x*Integrate[(1 + (-I + t)^2)^(-1), {t, -Infinity, Infinity}]

which is OK to me, but "x*ComplexInfinity" or "Indeterminate" or
"\$Failed" would be better.

Best,
Peter

P.S.: This seems to be a hard task for most CASs:

Because I may not tell the name of other products, take the following as
anonymous examples:

(%i1) integrate(1/(1+(x-2*%i)^2), x, minf, inf);
(%o1) 0
(%i2) integrate(1/(1+(x-10001*%i/10000)^2), x, minf, inf);
Maxima encountered a Lisp error: Error in MACSYMA-TOP-LEVEL [or a
callee]: 100000000 is not of type SEQUENCE.Automatically continuing.To
reenable the Lisp debugger set *debugger-hook* to nil.
(%i3) integrate(1/(1+(x-(1+a)*%i)^2), x, minf, inf);Is  a  positive,
negative, or zero?p;
(%o3) 0
(%i4) integrate(1/(1+(x-(1+a)*%i)^2), x, minf, inf);
Is  a  positive, negative, or zero?
n;
Is  a+2  positive, negative, or zero?
n;
(%o4) 0
(%i5) integrate(1/(1+(x-(1+a)*%i)^2), x, minf, inf);
Is  a  positive, negative, or zero?
z;
(%o5) -(2*%pi*(4*a^2+12*a+8))/((-4*a-4)*(2*a+4))
(%i6) ratsimp(%);
(%o6) %pi
oh my....

or:
> int(1/(1+(t-t0)^2),t=-infinity..infinity);
Pi

> int(1/(1+(t-I)^2),t=-infinity..infinity);

undefined
> int(1/(1+(t-a*I)^2),t=-infinity..infinity);
{     0            a < -1
{
{ undefined        a = -1
{
{    Pi            a < 1
{
{ undefined        a = 1
{
{    -Pi           1 < a

wow! almost good; but:
> int(1/(1+(t-2*I)^2),t=-infinity..infinity);
0
is !=-Pi

or:

int(1/(1+(t-t0)^2),t=-infinity..infinity);
PI

int(1/(1+(t-I*10001/10000)^2),t=-infinity..infinity);
0

int(1/(1+(t-a*I)^2),t=-infinity..infinity);
int(1/((t - I*a)^2 + 1), t = -infinity..infinity)

```

• Prev by Date: Re: Puzzled by the "Variance"
• Next by Date: Re: Unexpected failures of FullSimplify on some Root elements
• Previous by thread: Re: NDSolve problem
• Next by thread: Strange font problem