> > 
> > Do you mean convert my expression to Poly and use the all_coefs method ? 
>  I 
> > did that but it doesn't support multvariate poly 
> > Poly(a**2+b+5*c+2).all_coeffs() 
> > PolynomialError:  .. 
>
> Oh I guess you just want expr.coeffs() then, or expr.terms(). 
>
>
expr.coeffs() works ok but expr.terms() returns 
In [30]: Poly(a**2+b+5*c+2).terms()
Out[30]: [((2, 0, 0), 1), ((0, 1, 0), 1), ((0, 0, 1), 5), ((0, 0, 0), 2)]

Not a,b,c,1  as I want.  However, the as_coefficients_dict() works well 
(and I don't have to convert it to a Poly) .  Thanks    
 

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/sympy/-/bGrOnY3Ov0sJ.
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.

Reply via email to