43.18 Problem number 161

\[ \int \csc (e+f x) (a+b \sin (e+f x))^2 \, dx \]

Optimal antiderivative \[ 2 a b x -\frac {a^{2} \arctanh \left (\cos \left (f x +e \right )\right )}{f}-\frac {b^{2} \cos \left (f x +e \right )}{f} \]

command

integrate(csc(f*x+e)*(a+b*sin(f*x+e))^2,x, algorithm="giac")

Giac 1.9.0-11 via sagemath 9.6 output

\[ \frac {2 \, {\left (f x + e\right )} a b + a^{2} \log \left ({\left | \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) \right |}\right ) - \frac {2 \, b^{2}}{\tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + 1}}{f} \]

Giac 1.7.0 via sagemath 9.3 output

\[ \text {Exception raised: NotImplementedError} \]________________________________________________________________________________________