Fixed remaining problem in doctest, plus test added for it
[sympy.git] / sympy / simplify / tests / test_rewrite.py
blob4b547f00d424560f2cded8ff596b8a9374271f53
1 from sympy import sin, exp, Symbol, I, cot
3 x = Symbol("x")
5 def test_has():
6 assert cot(x).has(x)
7 assert cot(x).has(cot)
8 assert not cot(x).has(sin)
9 assert sin(x).has(x)
10 assert sin(x).has(sin)
11 assert not sin(x).has(cot)
13 def test_sin_exp_rewrite():
14 assert sin(x).rewrite(sin, exp) == -I/2*(exp(I*x)-exp(-I*x))