On Jun 22, 2012, at 11:19 AM, Pietro Battiston <[email protected]> wrote:
> Hello, I have another small issue. > > I'm trying to use the "mathematica" parser from > sympy.parsing.mathematica¹, but differently from what I expect, > > mathematica( "a b" ) > > raises a SympifyError (while for instance > > mathematica( "a^b" ) > > correctly returns a**b). > > Is this a bug or am I missing anything? > > thanks in advance for any suggestion > > Pietro > > > ¹ Not that I have any Mathematica code around, I just seem to understand > from the source that it (theoretically) supports "^" and implicit > multiplication... please let me know if there's a better way to get > those. ^ is automatically supported by sympify. The implicit multiplication support in the mathematica parser is actually quite limited. See for example http://code.google.com/p/sympy/issues/detail?id=2864. Unfortunately, we don't really have a better function for it, but it might be possible to extend the sympify parser to do it (optionally), or else you could try writing a separate parser to do it (or improve the Mathematica parser). Aaron Meurer > > -- > You received this message because you are subscribed to the Google Groups > "sympy" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/sympy?hl=en. > -- You received this message because you are subscribed to the Google Groups "sympy" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/sympy?hl=en.
