a limit failure

6 views
Skip to first unread message

Martin R

unread,
Nov 20, 2022, 1:34:11 PM11/20/22
to FriCAS - computer algebra system
Apparently, the following should give 2:

(1) -> f := D(log(tan(%pi/2*tanh(x))), x)
(2) -> limit(f, x=%plusInfinity)

   (2)  "failed"


Best wishes,

Martin

Qian Yun

unread,
Nov 23, 2022, 4:21:47 AM11/23/22
to fricas...@googlegroups.com
FYI, it can be correctly solved by "mrv_limit" which uses Gruntz
algorithm. However I don't know why this code path is not enabled
for this function. (see "is_exp_log" in limitps.spad).

- Qian

(1) -> )expose MrvLimitPackage
MrvLimitPackage is now explicitly exposed in frame frame1
(1) -> f := D(log(tan(%pi/2*tanh(x))), x);

Type:
Expression(Integer)
(2) -> mrv_limit(f, x=%plusInfinity)

(2) 2

Waldek Hebisch

unread,
Nov 23, 2022, 12:48:04 PM11/23/22
to fricas...@googlegroups.com
On Wed, Nov 23, 2022 at 05:21:42PM +0800, Qian Yun wrote:
> FYI, it can be correctly solved by "mrv_limit" which uses Gruntz
> algorithm. However I don't know why this code path is not enabled
> for this function. (see "is_exp_log" in limitps.spad).
>
> - Qian
>
> (1) -> )expose MrvLimitPackage
> MrvLimitPackage is now explicitly exposed in frame frame1
> (1) -> f := D(log(tan(%pi/2*tanh(x))), x);
>
> Type:
> Expression(Integer)
> (2) -> mrv_limit(f, x=%plusInfinity)
>
> (2) 2

This is due to 'tan'. Termination of Gruntz algorithm depends
on having exp-log function, for trigonometric functions
Gruntz may fail. This is easy case, but ATM we have no way
to distinguish it from problematic cases.

--
Waldek Hebisch

Bill Page

unread,
Nov 23, 2022, 3:25:07 PM11/23/22
to fricas...@googlegroups.com
(1) -> f:=differentiate(complexNormalize(log(tan(%pi/2*tanh(x)))),x);

                                                    Type: Expression(Integer)
(2) -> output lines(formatExpression(f)$Format1D).1                  
  (-8*%pi*(%e^x)^2*%e^((%pi*sqrt(-1)*(%e^x)^2+(-%pi)*sqrt(-1))/((%e^x)^2+1)))/(
  (sqrt(-1)*(%e^x)^4+2*sqrt(-1)*(%e^x)^2+sqrt(-1))*(%e^((%pi*sqrt(-1)*(%e^x)^2+
  (-%pi)*sqrt(-1))/((%e^x)^2+1)))^2+(-sqrt(-1))*(%e^x)^4+-2*sqrt(-1)*(%e^x)^2-s
  qrt(-1))
                                                                   Type: Void
(3) -> limit(f,x=%plusInfinity)                                      

   (3)  2
                      Type: Union(OrderedCompletion(Expression(Integer)),...)

--
You received this message because you are subscribed to the Google Groups "FriCAS - computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fricas-devel...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fricas-devel/20221123174757.GA25181%40fricas.math.uni.wroc.pl.
Reply all
Reply to author
Forward
0 new messages