On Tue, Nov 1, 2016 at 2:26 PM, Nathan Thern <
nth...@gmail.com> wrote:
> According to
>
http://docs.sympy.org/latest/modules/core.html
> f.rewrite(exp), f.rewrite(sin, exp), and f.rewrite([sin,], exp) are all
> valid.
> I found that I can replace just the sin term with the following expression:
>
>>>> f.replace(sin, lambda arg: sin(arg).rewrite(sin, exp))
> -I*(exp(I*x) - exp(-I*x))/2 + cos(y)/gamma(z)
>
> This seems to create the functionality I was expecting.
> But I'm still not sure if I don't understand what the docs are saying about
> rewrite or if there's a bug.
described (only rewriting the sin as exp). I'd have to debug it to see