Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SR.wild and maxima don't mix #21444

Closed
nbruin opened this issue Sep 8, 2016 · 6 comments
Closed

SR.wild and maxima don't mix #21444

nbruin opened this issue Sep 8, 2016 · 6 comments

Comments

@nbruin
Copy link
Contributor

nbruin commented Sep 8, 2016

This came up in ask-sage:

sage: tanh(SR.wild(0)) #for references; this works
tanh($0)
sage: coth(SR.wild(0))
ValueError: The name "" is not a valid Python identifier.

The traceback shows that this error happens when trying to parse back a maxima result with bare _SAGE_VAR_ in it (i.e., a sage variable with an empty name)

It seems #20134 is implicated.

Another problem arises when a wildcard expression gets sent to maxima:

sage: sin(SR.wild(0)).simplify_full()
TypeError: ECL says: THROW: The catch MACSYMA-QUIT is undefined.

It may be that we can resolve both errors by ensuring that wildcards roundtrip properly to maxima (e.g., convert them to _SAGE_WILDCARD_0 rather than the syntactically illegal _SAGE_VAR_$0 and parse them back properly too).

It may also be that by giving coth and friends a slightly different treatment we can get them in line with tanh etc.

CC: @rwst

Component: symbolics

Reviewer: Michael Orlitzky

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

@nbruin nbruin added this to the sage-7.4 milestone Sep 8, 2016
@rwst
Copy link

rwst commented Sep 8, 2016

comment:3

This works in 7.4beta3, i.e., the coth(SR.wild(0)) part, not the simplify of course.

@kcrisman
Copy link
Member

kcrisman commented Sep 8, 2016

comment:4

This works in 7.4beta3, i.e., the coth(SR.wild(0)) part, not the simplify of course.

I was figuring that a Pynac upgrade might do it, because I remembered you adding those functions recently. Should we have one ticket just to doctest that works, and then leave this ticket for the round-trip issue?

@rwst
Copy link

rwst commented Sep 8, 2016

comment:5

Yes please.

@kcrisman
Copy link
Member

kcrisman commented Sep 8, 2016

comment:6

See #21455

@rwst
Copy link

rwst commented Oct 2, 2017

comment:7

Probably a duplicate of #16335.

@rwst rwst removed this from the sage-7.4 milestone Oct 2, 2017
@orlitzky
Copy link
Contributor

Reviewer: Michael Orlitzky

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants