I don't think there's an efficient function to do it, if that's what you're looking for (i.e., one that doesn't require full expansion). It's not too hard to come up with, though.
Aaron Meurer On Jun 21, 2012, at 7:08 AM, Reckoner <[email protected]> wrote: Hi, I'm trying to expand polynomials such as (1+x+x**2+...+x**n)(1+y+y**2+...+y**n) and I would like to keep only those terms where the sum of the respective exponents is equal to some number. For example, I want only terms x^k*y^m where (k+m)==N. Can you help me get started with this using sympy? I read the documentation, but I'm not sure how to proceed with the extraction part. I can expand and create the polynomials just fine. Thanks in advance. -- 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/-/fU3tJk7pUDYJ. 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.
