series (sin (x),x,pi /2)
O(1, (x, pi/2))
solve(1 - (x - pi/2)**2/2 + (x - pi/2)**4/24 + O((x - pi/2)**6, (x, pi/2)), x)
diff(1 - (x - pi/2)**2/2 + (x - pi/2)**4/24 + O((x - pi/2)**6, (x, pi/2)), x)
series(1 - (x - pi/2)**2/2 + (x - pi/2)**4/24 + O((x - pi/2)**6, (x, pi/2)), x, 0, 10)
Experiment with SymPy at SymPy Live.