Closed
Description
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