11
$\begingroup$

I'm trying to determine the limit of the sequence of functions

$$f_n(x)=\left(\frac{1}{\pi}\arctan(n x) + 1/2\right)^n. $$

I define

f[x_, n_] := (1/2 + ArcTan[n x]/Pi)^n

And enter

Limit[f[x, n], n -> Infinity]

This gives the answer 0.

If I instead enter

Assuming[x > 0, Limit[f[x, n], n -> Infinity]]

I get the answer $$e^{-\frac{1}{x\pi}}. $$

While

Assuming[x < 0, Limit[f[x, n], n -> Infinity]]

gives the answer 0 again.

Why does the normal Limit give the answer assuming that x<0? Is this a bug, or have I missed something?

Thanks in advance.

$\endgroup$
  • $\begingroup$ Please only use the tag bugs post-hoc, if it is confirmed by WRI or the community. $\endgroup$ – István Zachar Oct 16 '13 at 12:19
  • 1
    $\begingroup$ I think it's a bug. The result is not always 0 as you check by using 1 for instance in place of x. $\endgroup$ – b.gates.you.know.what Oct 16 '13 at 12:51
  • 7
    $\begingroup$ Probably a bug or at least a limitation in calculus code. Limit will rely on Series and at least for elementary functions that will ignore branch cut issues unless assumptions are provided that give a clear indication of what side of such a cut we are on. $\endgroup$ – Daniel Lichtblau Oct 16 '13 at 15:55
2
$\begingroup$

It's not a bug in 11.1, but if this is still the case in 11.2, then it will be a bug. :)

Functions that take Assumptions are allowed to make assumptions when necessary. But they are also supposed to tell you when they do that. This is controlled by the GenerateConditions option. Limit in version 11.1 doesn't have this option. It's old, and I don't know that we have a defined behavior. But we're giving Limit a facelift in 11.2, including adding the option. When, unless you disable GenerateConditions, it should report the non-generic assumption x < 0. There will also be a dedicated function for taking limits of sequences instead of functions.

|improve this answer|||||
$\endgroup$
  • $\begingroup$ How exciting! Since Limit is very related to Series, does that mean Series is getting a facelift too? $\endgroup$ – QuantumDot Sep 1 '17 at 3:19
  • $\begingroup$ Not yet. I think it is safer to say that we will be laying down pieces for Series before we tackle it head on. $\endgroup$ – Itai Seggev Sep 4 '17 at 21:44
  • $\begingroup$ Cool; may I make a request? Could you make these functions so they are easily user-extensible? $\endgroup$ – QuantumDot Sep 5 '17 at 1:44
  • $\begingroup$ You're certainly free to make the request... :) More seriously, I would suggest sending a report to support@wolfram.com with the suggestion, being as specific as possible. If it's logged in our database as something customers are asking for, it has a higher chance of being implemented. $\endgroup$ – Itai Seggev Sep 5 '17 at 18:54
0
$\begingroup$

Let's plot the limit of $f$ for a varying value of $x$ as $n$ approches $+\infty$:

DiscretePlot[Limit[f[x, n], n -> Infinity], {x, -10, 10, 0.5}]

enter image description here

Based on this discontinuity, I would not be surprised if Limit cannot handle it. Besides, when I evaluate Limit[f[x, n], n -> Infinity], I don't get a result. In conclusion, since you have two different regimes, you should specify which regime you are in.

Assuming[x < 0, Limit[f[x, n], n -> Infinity]]

Output: $0$

Assuming[x > 0, Limit[f[x, n], n -> Infinity]]

Output: $e^{-\frac{1}{\pi x}}$

These answer can be visually justified based on the following plots:

Plot[f[-1, n], {n, 0, 10}, Frame -> True, FrameLabel -> {"n", "f[1,n]"}]

enter image description here

Plot[f[+1, n], {n, 0, 10}, Frame -> True, FrameLabel -> {"n", "f[1,n]"}]

enter image description here

|improve this answer|||||
$\endgroup$
0
$\begingroup$

No problem with

Limit[(1/2 + ArcTan[n x]/Pi)^n, n -> Infinity, Assumptions -> x > 0]

$e^{-\frac{1}{\pi x}} $

|improve this answer|||||
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.