sagemath / sage

Main repository of SageMath
https://www.sagemath.org
Other
1.4k stars 474 forks source link

inconsistent (?) results in limit #30853

Open GMS103 opened 3 years ago

GMS103 commented 3 years ago

Tested with https://sagecell.sagemath.org (sorry, I do not have access to 9.2 yet).

sage: version()
'SageMath version 9.1, Release Date: 2020-05-20'

These two results seem to me inconsistent with one another:

sage: limit((-1)^x*exp(x),x=+oo),limit((-1)^x*exp(ln(x)),x=+oo)
(Infinity, und)

(if I understand well, the first means "complex infinity", and the second "undefined").

Adding assume(x,'integer') or assume(x>0) seems to have no effet.

Component: calculus

Issue created by migration from https://trac.sagemath.org/ticket/30853

GMS103 commented 3 years ago
comment:1

In https://cocalc.com, which has

sage: version()
'SageMath version 9.2, Release Date: 2020-10-24'

the results are the same.

8c6334bb-0548-4386-b6db-778cec786199 commented 3 years ago
comment:2

In 9.3.beta7, it is no longer the same. However, the und might come from the -1. If we consider limit((a)^x*exp(ln(x)),oo) or limit((a)^x*x,oo), for 0<a<1 the limit is 0, whereas for 1<a, the limit is Infinity.

Also, I think Infinity is specifically Unsigned Infinity.

If this is actually a bug, it is a Maxima bug.

mkoeppe commented 3 years ago
comment:3

Moving this ticket to 9.4, as it seems unlikely that it will be merged in 9.3, which is in the release candidate stage