Comment #2 on issue 2064 by [email protected]: terms_gcd(sqrt(4 + 4*x)) doesn't give 2*sqrt(1 + x)
http://code.google.com/p/sympy/issues/detail?id=2064

There is a version with a similar name that is expr-based that lives in core.exprtools. I've modified that and made a more general factor_terms function that now gives

    >>> gcd_terms(sqrt(4+4*x))
    2*sqrt(x + 1)

gcd_terms is meant to look for explicit factors (like `x` and `y` in `x*y`, not hidden factors like `x + 1` in `x**2 - 1`); with modifications it now recurses; with factor_terms, such a gcd is removed without expanding the input expression for commutative and non-commutative expressions.

This work is in my `quick` branch.

--
You received this message because you are subscribed to the Google Groups 
"sympy-issues" 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-issues?hl=en.

Reply via email to