You can compute the limit by expanding the real and imaginary parts:
In [19]: x = Symbol('x', real=True, positive=True)
In [20]: expand(exp(pi*I*x)/sqrt(x), complex=True)
Out[20]:
ⅈ⋅sin(π⋅x) cos(π⋅x)
────────── + ────────
√x √x
In [21]: limit(expand(exp(pi*I*x)/sqrt(x), complex=True), x, oo)
Out[21]: 0
Aaron Meurer
On Mon, Sep 7, 2015 at 12:37 PM, Paul Royik <[email protected]> wrote:
> Thank you.
>
> On Monday, September 7, 2015 at 10:52:12 AM UTC+3, Kalevi Suominen wrote:
>>
>>
>>
>> On Monday, September 7, 2015 at 9:37:58 AM UTC+3, Paul Royik wrote:
>>>
>>> I see this error when try to calculate limit of (-1)^x /sqrt(x) as x
>>> approaches infinity.
>>> Can somebody explain me what is the problem here?
>>
>>
>> ``(-1)^x`` is equal to ``exp(pi*I*x)``. As the function has no serial
>> expansion at infinity, SymPy attempts to use Gruntz' algorithm. It is
>> intended tor real functions, and SymPy assumes that everything is real. It
>> knows that ``pi`` is real and positive and the same is assumed of ``x``.
>> That leaves just one problem: what is the sign of I.
>>
>> Actually, there is currently no algorithm in SymPy capable of computing
>> the limit (which is 0 as ``x`` tends to ``oo`` on the real line),
>
> --
> You received this message because you are subscribed to the Google Groups
> "sympy" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/sympy.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/sympy/a3a3c6f0-2fcd-4324-af79-dc4dfa925247%40googlegroups.com.
>
> For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sympy.
To view this discussion on the web visit
https://groups.google.com/d/msgid/sympy/CAKgW%3D6KHNNfMYyY-ZWwxqACY3yoR-FstXDpENpr%3DiVU45STBaQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.