Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.math.mathematica

Topic: Calculating a simple integral
Replies: 2   Last Post: Jun 10, 2013 4:04 AM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
Roland Franzius

Posts: 466
Registered: 12/7/04
Re: Calculating a simple integral
Posted: Jun 10, 2013 4:04 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Am 09.06.2013 10:26, schrieb dsmirnov90@gmail.com:
> If there is a way to calculate with Mathematica the following integral:
>
> in = -((-1 + Cos[kz])/(kz^2 (kr^2 + kz^2)^2 (kz^2 - 4 \[Pi]^2)^2))
> Integrate[in, {kz, -Infinity, Infinity}, Assumptions -> kr > 0]
>
> Another system calculates the same integral instantly. :)
>


Did you check the numerics?

The expression is a square of

f[x_,a_] = Sin[x/2]((x (x - 2 Pi)(x + 2 Pi)) /(x^2+a^2)

This function looks like a multiple Sinc function with a canceling of
zeroes of the numerator function sin(x/2) at x = 0 and +- 2pi by the
denominator polynomial.

Mathematica sticks in Nirwana with the definite integral but
accomplishes to find the indefinite integral

F[x_,a_] = Integrate[f[x,a]^2,x]

But, of course, with doubious imaginary parts and a definitely wrong
Limit[ F[x,a]-F[-x,a],x->oo]

despite the fact, that the derivative of F wrt to x is correct.

Another hint here, that the new developments in finding definite
integrals are probably full of errors implemented.

When setting
$Assumptions=x \in Reals && a>0
I got an errormessage by NIntegrate, that x > 1/4096 :-(


But the FourierTransform package is working

FL[a_]= Limit[ Sqrt[2 Pi] FourierTansform[f[x,a]^2,x,k ], k->0]

Compare numerically eg

FL[0.05`20]

and

NIntegrate[ f[x,0.05`20]^2,{x,-oo,oo},WorkingPrecision->20]

Hope ist helps.

--

Roland Franzius




Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.