Comment #2 on issue 2007 by asmeurer: (exp(exp(x))).atoms(exp)
http://code.google.com/p/sympy/issues/detail?id=2007

Well, I think I remember Chris implementing something where if you pass an argument to atoms, then it gives you all the terms that match that, like:

(sin(x + 1) + sin(x)*cos(x)).atoms(sin)
set(sin(x), sin(1 + x))

I need something like this for building the tower of differential extensions for the integration algorithm so that, for example, if an expression has exp(x), exp(2*x) and exp(x/2) all in it somewhere, I make sure to choose the extension t = exp(x/2) so that exp(x) == t**2 and exp(2*x) == t**4. Otherwise, if I choose one of the other ones, say t = exp(x), then exp(x/2) == sqrt(t) will be algebraic, which we must avoid.

--
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