Message Boards Message Boards

1
|
7262 Views
|
5 Replies
|
3 Total Likes
View groups...
Share
Share this post:

Integral gives different answers on different versions of Mathematica

Posted 6 years ago

In both Mathematica 10.4.1.0 and 11.1.0.0

Integrate[r^2 Sin[r^-3], {r, 0, \[Infinity]}]

gives

Integrate::idiv: Integral of r^2 Sin[1/r^3] does not converge on {0,\[Infinity]}.

Now, using

Integrate[r^2 Sin[r^-3 c], {r, 0, \[Infinity]}, 
 Assumptions -> {c \[Element] Reals}]

still gives

Integrate::idiv: Integral of r^2 Sin[c/r^3] does not converge on {0,\[Infinity]}.

in 11.1.0.0, but surprisingly gives

-(1/6) c (-2 + 2 EulerGamma + Log[c^2])

in 10.4.1.0. Which result is correct?

POSTED BY: Stefan Stoll
5 Replies
Posted 6 years ago
POSTED BY: Stefan Stoll

The math is pretty clear. It diverges due to 1/r asymptotoc behavior at infinity. One can see this using Series for example.

Series[r^2*Sin[r^-3], {r, Infinity, 2}]

(* Out[2]= SeriesData[r, 
DirectedInfinity[1], {1}, 1, 3, 1] *)
POSTED BY: Daniel Lichtblau
POSTED BY: Patrick Scheibe
Posted 6 years ago
POSTED BY: Stefan Stoll

Using Rubi, you can investigate a bit further, what steps are required to find an antiderivative

<< Rubi`
int = Steps[Int[r^2 Sin[r^-3 * c], r]]

Mathematica graphics

First, you can show that the solution is indeed one valid antiderivative of your expression:

In[31]:= D[int, r]

Out[31]= r^2 Sin[c/r^3]

Now, you can look at the limits of your integration bounds

In[32]:= Limit[int, r -> 0, Direction -> "FromAbove"]

Out[32]= ConditionalExpression[-(1/6) c (2 Log[c] - Log[c^2]),  c \[Element] Reals]

This looks good, but this here not

In[33]:= Limit[int, r -> Infinity]

Out[33]= c \[Infinity]

Therefore, I suspect your version 10.4 result is not correct and the integral does not converge.

POSTED BY: Patrick Scheibe
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract