diff (cot (x*y),y)

diff(cot(x*y), y)

solve(cot(x*y), y)

series(cot(x*y), y, 0, 10)

Need more control? Try SymPy Live.