\[ \int (a+a \sin (e+f x))^3 (A+B \sin (e+f x)) \sqrt {c-c \sin (e+f x)} \, dx \]
Optimal antiderivative \[ \frac {2 a^{3} \left (9 A +5 B \right ) c^{4} \left (\cos ^{7}\left (f x +e \right )\right )}{63 f \left (c -c \sin \left (f x +e \right )\right )^{\frac {7}{2}}}-\frac {2 a^{3} B \,c^{3} \left (\cos ^{7}\left (f x +e \right )\right )}{9 f \left (c -c \sin \left (f x +e \right )\right )^{\frac {5}{2}}} \]
command
integrate((a+a*sin(f*x+e))^3*(A+B*sin(f*x+e))*(c-c*sin(f*x+e))^(1/2),x, algorithm="giac")
Giac 1.9.0-11 via sagemath 9.6 output
\[ -\frac {\sqrt {2} {\left (7 \, B a^{3} \cos \left (-\frac {9}{4} \, \pi + \frac {9}{2} \, f x + \frac {9}{2} \, e\right ) \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) + 126 \, {\left (5 \, A a^{3} \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) + 2 \, B a^{3} \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )\right )} \cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right ) + 42 \, {\left (9 \, A a^{3} \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) + 5 \, B a^{3} \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )\right )} \cos \left (-\frac {3}{4} \, \pi + \frac {3}{2} \, f x + \frac {3}{2} \, e\right ) + 126 \, {\left (A a^{3} \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) + B a^{3} \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )\right )} \cos \left (-\frac {5}{4} \, \pi + \frac {5}{2} \, f x + \frac {5}{2} \, e\right ) + 9 \, {\left (2 \, A a^{3} \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) + 5 \, B a^{3} \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )\right )} \cos \left (-\frac {7}{4} \, \pi + \frac {7}{2} \, f x + \frac {7}{2} \, e\right )\right )} \sqrt {c}}{504 \, f} \]
Giac 1.7.0 via sagemath 9.3 output
\[ \text {Exception raised: NotImplementedError} \]________________________________________________________________________________________