--------------------------------------------------------------------------- NameError Traceback (most recent call last) <ipython-input-4-19dc46bbe490> in <module>() ----> 1 exp0.subs(a1,10) NameError: name 'a1' is not defined
2*x1 + a3 + a4*x1*x2 + a5*x2**2 + 10*x1**2
--
You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
To post to this group, send email to sy...@googlegroups.com.
Visit this group at http://groups.google.com/group/sympy.
To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/26d01fa4-15fd-45da-b043-9197410f0286%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "sympy" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/sympy/VY5m2pmF7dM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to sympy+un...@googlegroups.com.
To post to this group, send email to sy...@googlegroups.com.
Visit this group at http://groups.google.com/group/sympy.
To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/CAKgW%3D6%2B5Sqnx%2B%2BPhnScj-S34rfAZQB_BuJK6RTRKPgXGBBvvJA%40mail.gmail.com.
For those who wonder why not use var() especially in combination with parse_expr(), the main reason I found is difficulty dealing with globals() and locals(). Instead of symbol injection, build your own dictionary. This maybe difficult to comprehend coming from interactive environment such as Mathematica.
--
You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
To post to this group, send email to sy...@googlegroups.com.
Visit this group at http://groups.google.com/group/sympy.
To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/3a7290dc-11ef-489f-a848-58e2a99e7a29%40googlegroups.com.