Hello,

> PS: in the above code, I've simply cut and paste lines from
> Expression._maxima_(). In the present case, the super is not necessary
> and the code can be simplified to
>
> In Sage 6.2:
>
> sage:  from sage.calculus.calculus import maxima
> sage: abs(1/sqrt(x))._interface_(maxima)
> 1/sqrt(x)
> while in Sage 6.3:
>
> sage:  from sage.calculus.calculus import maxima
> sage: abs(1/sqrt(x))._interface_(maxima)
> abs(1/sqrt(_SAGE_VAR_x))

I see; actually I didn't test it in an older version of Maxima since I
only had 5.34.0 installed.  Maybe it is because of #16224 instead?  This
fixed a bug in the Maxima interface that changed (among other things)
which Sage function corresponds to Maxima's abs().

Anyway, a bit more experimenting shows that this behaviour can be fixed
using "declare(x, complex)":

(%i1) display2d: false;
(%o1) false
(%i2) abs(sqrt(x));
(%o2) sqrt(x)
(%i3) declare(x, complex);
(%o3) done
(%i4) abs(sqrt(x));
(%o4) abs(sqrt(x))
(%i5) abs(1/sqrt(x));
(%o5) abs(1/sqrt(x))

Peter

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to