We are trying to switch from Mathematica to python with sympy. Unfortunately sympy is not that mighty. One task for our students was to calculate the resulting oscillation in the form

from the given form
I tried several common simplifying tools from sympy like simplify, trigsimp but nothing worked. Sympy just simplifys every term like
Does anyone know how to solve this task with sympy or other python modul ?

