\[ \int \cos ^3(c+d x) (a \sin (c+d x)+b \tan (c+d x)) \, dx \]
Optimal antiderivative \[ -\frac {b \left (\cos ^{3}\left (d x +c \right )\right )}{3 d}-\frac {a \left (\cos ^{4}\left (d x +c \right )\right )}{4 d} \]
command
integrate(cos(d*x+c)^3*(a*sin(d*x+c)+b*tan(d*x+c)),x, algorithm="giac")
Giac 1.9.0-11 via sagemath 9.6 output
\[ \text {output too large to display} \]
Giac 1.7.0 via sagemath 9.3 output \[ \text {Exception raised: NotImplementedError} \]_______________________________________________________