\(\int \frac {x^2 \sqrt {a-a \sin (e+f x)}}{(c+c \sin (e+f x))^{3/2}} \, dx\) [182]

   Optimal result
   Rubi [A] (verified)
   Mathematica [C] (verified)
   Maple [F]
   Fricas [F(-2)]
   Sympy [F]
   Maxima [F]
   Giac [F]
   Mupad [F(-1)]

Optimal result

Integrand size = 33, antiderivative size = 280 \[ \int \frac {x^2 \sqrt {a-a \sin (e+f x)}}{(c+c \sin (e+f x))^{3/2}} \, dx=-\frac {2 a x}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a \text {arctanh}(\sin (e+f x)) \cos (e+f x)}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a \cos (e+f x) \log (\cos (e+f x))}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {a x^2 \sec (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a x \sin (e+f x)}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {a x^2 \tan (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \]

[Out]

-2*a*x/c/f^2/(a-a*sin(f*x+e))^(1/2)/(c+c*sin(f*x+e))^(1/2)+2*a*arctanh(sin(f*x+e))*cos(f*x+e)/c/f^3/(a-a*sin(f
*x+e))^(1/2)/(c+c*sin(f*x+e))^(1/2)+2*a*cos(f*x+e)*ln(cos(f*x+e))/c/f^3/(a-a*sin(f*x+e))^(1/2)/(c+c*sin(f*x+e)
)^(1/2)-a*x^2*sec(f*x+e)/c/f/(a-a*sin(f*x+e))^(1/2)/(c+c*sin(f*x+e))^(1/2)+2*a*x*sin(f*x+e)/c/f^2/(a-a*sin(f*x
+e))^(1/2)/(c+c*sin(f*x+e))^(1/2)+a*x^2*tan(f*x+e)/c/f/(a-a*sin(f*x+e))^(1/2)/(c+c*sin(f*x+e))^(1/2)

Rubi [A] (verified)

Time = 2.57 (sec) , antiderivative size = 280, normalized size of antiderivative = 1.00, number of steps used = 34, number of rules used = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.424, Rules used = {4700, 6873, 12, 6874, 4271, 3855, 4266, 2611, 2320, 6724, 3842, 4269, 3556, 4498} \[ \int \frac {x^2 \sqrt {a-a \sin (e+f x)}}{(c+c \sin (e+f x))^{3/2}} \, dx=\frac {2 a \cos (e+f x) \text {arctanh}(\sin (e+f x))}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c \sin (e+f x)+c}}+\frac {2 a \cos (e+f x) \log (\cos (e+f x))}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c \sin (e+f x)+c}}+\frac {2 a x \sin (e+f x)}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c \sin (e+f x)+c}}-\frac {2 a x}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c \sin (e+f x)+c}}+\frac {a x^2 \tan (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c \sin (e+f x)+c}}-\frac {a x^2 \sec (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c \sin (e+f x)+c}} \]

[In]

Int[(x^2*Sqrt[a - a*Sin[e + f*x]])/(c + c*Sin[e + f*x])^(3/2),x]

[Out]

(-2*a*x)/(c*f^2*Sqrt[a - a*Sin[e + f*x]]*Sqrt[c + c*Sin[e + f*x]]) + (2*a*ArcTanh[Sin[e + f*x]]*Cos[e + f*x])/
(c*f^3*Sqrt[a - a*Sin[e + f*x]]*Sqrt[c + c*Sin[e + f*x]]) + (2*a*Cos[e + f*x]*Log[Cos[e + f*x]])/(c*f^3*Sqrt[a
 - a*Sin[e + f*x]]*Sqrt[c + c*Sin[e + f*x]]) - (a*x^2*Sec[e + f*x])/(c*f*Sqrt[a - a*Sin[e + f*x]]*Sqrt[c + c*S
in[e + f*x]]) + (2*a*x*Sin[e + f*x])/(c*f^2*Sqrt[a - a*Sin[e + f*x]]*Sqrt[c + c*Sin[e + f*x]]) + (a*x^2*Tan[e
+ f*x])/(c*f*Sqrt[a - a*Sin[e + f*x]]*Sqrt[c + c*Sin[e + f*x]])

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 2320

Int[u_, x_Symbol] :> With[{v = FunctionOfExponential[u, x]}, Dist[v/D[v, x], Subst[Int[FunctionOfExponentialFu
nction[u, x]/x, x], x, v], x]] /; FunctionOfExponentialQ[u, x] &&  !MatchQ[u, (w_)*((a_.)*(v_)^(n_))^(m_) /; F
reeQ[{a, m, n}, x] && IntegerQ[m*n]] &&  !MatchQ[u, E^((c_.)*((a_.) + (b_.)*x))*(F_)[v_] /; FreeQ[{a, b, c}, x
] && InverseFunctionQ[F[x]]]

Rule 2611

Int[Log[1 + (e_.)*((F_)^((c_.)*((a_.) + (b_.)*(x_))))^(n_.)]*((f_.) + (g_.)*(x_))^(m_.), x_Symbol] :> Simp[(-(
f + g*x)^m)*(PolyLog[2, (-e)*(F^(c*(a + b*x)))^n]/(b*c*n*Log[F])), x] + Dist[g*(m/(b*c*n*Log[F])), Int[(f + g*
x)^(m - 1)*PolyLog[2, (-e)*(F^(c*(a + b*x)))^n], x], x] /; FreeQ[{F, a, b, c, e, f, g, n}, x] && GtQ[m, 0]

Rule 3556

Int[tan[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-Log[RemoveContent[Cos[c + d*x], x]]/d, x] /; FreeQ[{c, d}, x]

Rule 3842

Int[(x_)^(m_.)*Sec[(a_.) + (b_.)*(x_)^(n_.)]^(p_.)*Tan[(a_.) + (b_.)*(x_)^(n_.)]^(q_.), x_Symbol] :> Simp[x^(m
 - n + 1)*(Sec[a + b*x^n]^p/(b*n*p)), x] - Dist[(m - n + 1)/(b*n*p), Int[x^(m - n)*Sec[a + b*x^n]^p, x], x] /;
 FreeQ[{a, b, p}, x] && IntegerQ[n] && GeQ[m, n] && EqQ[q, 1]

Rule 3855

Int[csc[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-ArcTanh[Cos[c + d*x]]/d, x] /; FreeQ[{c, d}, x]

Rule 4266

Int[csc[(e_.) + Pi*(k_.) + (f_.)*(x_)]*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[-2*(c + d*x)^m*(ArcTanh[E
^(I*k*Pi)*E^(I*(e + f*x))]/f), x] + (-Dist[d*(m/f), Int[(c + d*x)^(m - 1)*Log[1 - E^(I*k*Pi)*E^(I*(e + f*x))],
 x], x] + Dist[d*(m/f), Int[(c + d*x)^(m - 1)*Log[1 + E^(I*k*Pi)*E^(I*(e + f*x))], x], x]) /; FreeQ[{c, d, e,
f}, x] && IntegerQ[2*k] && IGtQ[m, 0]

Rule 4269

Int[csc[(e_.) + (f_.)*(x_)]^2*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[(-(c + d*x)^m)*(Cot[e + f*x]/f), x
] + Dist[d*(m/f), Int[(c + d*x)^(m - 1)*Cot[e + f*x], x], x] /; FreeQ[{c, d, e, f}, x] && GtQ[m, 0]

Rule 4271

Int[(csc[(e_.) + (f_.)*(x_)]*(b_.))^(n_)*((c_.) + (d_.)*(x_))^(m_), x_Symbol] :> Simp[(-b^2)*(c + d*x)^m*Cot[e
 + f*x]*((b*Csc[e + f*x])^(n - 2)/(f*(n - 1))), x] + (Dist[b^2*d^2*m*((m - 1)/(f^2*(n - 1)*(n - 2))), Int[(c +
 d*x)^(m - 2)*(b*Csc[e + f*x])^(n - 2), x], x] + Dist[b^2*((n - 2)/(n - 1)), Int[(c + d*x)^m*(b*Csc[e + f*x])^
(n - 2), x], x] - Simp[b^2*d*m*(c + d*x)^(m - 1)*((b*Csc[e + f*x])^(n - 2)/(f^2*(n - 1)*(n - 2))), x]) /; Free
Q[{b, c, d, e, f}, x] && GtQ[n, 1] && NeQ[n, 2] && GtQ[m, 1]

Rule 4498

Int[((c_.) + (d_.)*(x_))^(m_.)*Sec[(a_.) + (b_.)*(x_)]*Tan[(a_.) + (b_.)*(x_)]^(p_), x_Symbol] :> -Int[(c + d*
x)^m*Sec[a + b*x]*Tan[a + b*x]^(p - 2), x] + Int[(c + d*x)^m*Sec[a + b*x]^3*Tan[a + b*x]^(p - 2), x] /; FreeQ[
{a, b, c, d, m}, x] && IGtQ[p/2, 0]

Rule 4700

Int[((g_.) + (h_.)*(x_))^(p_.)*((a_) + (b_.)*Sin[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*Sin[(e_.) + (f_.)*(x_
)])^(n_), x_Symbol] :> Dist[a^IntPart[m]*c^IntPart[m]*(a + b*Sin[e + f*x])^FracPart[m]*((c + d*Sin[e + f*x])^F
racPart[m]/Cos[e + f*x]^(2*FracPart[m])), Int[(g + h*x)^p*Cos[e + f*x]^(2*m)*(c + d*Sin[e + f*x])^(n - m), x],
 x] /; FreeQ[{a, b, c, d, e, f, g, h}, x] && EqQ[b*c + a*d, 0] && EqQ[a^2 - b^2, 0] && IntegerQ[p] && IntegerQ
[2*m] && IGeQ[n - m, 0]

Rule 6724

Int[PolyLog[n_, (c_.)*((a_.) + (b_.)*(x_))^(p_.)]/((d_.) + (e_.)*(x_)), x_Symbol] :> Simp[PolyLog[n + 1, c*(a
+ b*x)^p]/(e*p), x] /; FreeQ[{a, b, c, d, e, n, p}, x] && EqQ[b*d, a*e]

Rule 6873

Int[u_, x_Symbol] :> With[{v = NormalizeIntegrand[u, x]}, Int[v, x] /; v =!= u]

Rule 6874

Int[u_, x_Symbol] :> With[{v = ExpandIntegrand[u, x]}, Int[v, x] /; SumQ[v]]

Rubi steps \begin{align*} \text {integral}& = \frac {\cos (e+f x) \int x^2 \sec ^3(e+f x) (a-a \sin (e+f x))^2 \, dx}{a c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ & = \frac {\cos (e+f x) \int a^2 x^2 \sec ^3(e+f x) (1-\sin (e+f x))^2 \, dx}{a c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ & = \frac {(a \cos (e+f x)) \int x^2 \sec ^3(e+f x) (1-\sin (e+f x))^2 \, dx}{c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ & = \frac {(a \cos (e+f x)) \int \left (x^2 \sec ^3(e+f x)-2 x^2 \sec ^2(e+f x) \tan (e+f x)+x^2 \sec (e+f x) \tan ^2(e+f x)\right ) \, dx}{c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ & = \frac {(a \cos (e+f x)) \int x^2 \sec ^3(e+f x) \, dx}{c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(a \cos (e+f x)) \int x^2 \sec (e+f x) \tan ^2(e+f x) \, dx}{c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(2 a \cos (e+f x)) \int x^2 \sec ^2(e+f x) \tan (e+f x) \, dx}{c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ & = -\frac {a x}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {a x^2 \sec (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {a x^2 \tan (e+f x)}{2 c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(a \cos (e+f x)) \int x^2 \sec (e+f x) \, dx}{2 c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(a \cos (e+f x)) \int x^2 \sec (e+f x) \, dx}{c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(a \cos (e+f x)) \int x^2 \sec ^3(e+f x) \, dx}{c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(a \cos (e+f x)) \int \sec (e+f x) \, dx}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(2 a \cos (e+f x)) \int x \sec ^2(e+f x) \, dx}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ & = -\frac {2 a x}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {i a x^2 \arctan \left (e^{i (e+f x)}\right ) \cos (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {a \text {arctanh}(\sin (e+f x)) \cos (e+f x)}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {a x^2 \sec (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a x \sin (e+f x)}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {a x^2 \tan (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(a \cos (e+f x)) \int x^2 \sec (e+f x) \, dx}{2 c \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(a \cos (e+f x)) \int \sec (e+f x) \, dx}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(2 a \cos (e+f x)) \int \tan (e+f x) \, dx}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(a \cos (e+f x)) \int x \log \left (1-i e^{i (e+f x)}\right ) \, dx}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(a \cos (e+f x)) \int x \log \left (1+i e^{i (e+f x)}\right ) \, dx}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(2 a \cos (e+f x)) \int x \log \left (1-i e^{i (e+f x)}\right ) \, dx}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(2 a \cos (e+f x)) \int x \log \left (1+i e^{i (e+f x)}\right ) \, dx}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ & = -\frac {2 a x}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a \text {arctanh}(\sin (e+f x)) \cos (e+f x)}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a \cos (e+f x) \log (\cos (e+f x))}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {i a x \cos (e+f x) \operatorname {PolyLog}\left (2,-i e^{i (e+f x)}\right )}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {i a x \cos (e+f x) \operatorname {PolyLog}\left (2,i e^{i (e+f x)}\right )}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {a x^2 \sec (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a x \sin (e+f x)}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {a x^2 \tan (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(i a \cos (e+f x)) \int \operatorname {PolyLog}\left (2,-i e^{i (e+f x)}\right ) \, dx}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(i a \cos (e+f x)) \int \operatorname {PolyLog}\left (2,i e^{i (e+f x)}\right ) \, dx}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(2 i a \cos (e+f x)) \int \operatorname {PolyLog}\left (2,-i e^{i (e+f x)}\right ) \, dx}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(2 i a \cos (e+f x)) \int \operatorname {PolyLog}\left (2,i e^{i (e+f x)}\right ) \, dx}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(a \cos (e+f x)) \int x \log \left (1-i e^{i (e+f x)}\right ) \, dx}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(a \cos (e+f x)) \int x \log \left (1+i e^{i (e+f x)}\right ) \, dx}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ & = -\frac {2 a x}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a \text {arctanh}(\sin (e+f x)) \cos (e+f x)}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a \cos (e+f x) \log (\cos (e+f x))}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {a x^2 \sec (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a x \sin (e+f x)}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {a x^2 \tan (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(a \cos (e+f x)) \text {Subst}\left (\int \frac {\operatorname {PolyLog}(2,-i x)}{x} \, dx,x,e^{i (e+f x)}\right )}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(a \cos (e+f x)) \text {Subst}\left (\int \frac {\operatorname {PolyLog}(2,i x)}{x} \, dx,x,e^{i (e+f x)}\right )}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(2 a \cos (e+f x)) \text {Subst}\left (\int \frac {\operatorname {PolyLog}(2,-i x)}{x} \, dx,x,e^{i (e+f x)}\right )}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(2 a \cos (e+f x)) \text {Subst}\left (\int \frac {\operatorname {PolyLog}(2,i x)}{x} \, dx,x,e^{i (e+f x)}\right )}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(i a \cos (e+f x)) \int \operatorname {PolyLog}\left (2,-i e^{i (e+f x)}\right ) \, dx}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(i a \cos (e+f x)) \int \operatorname {PolyLog}\left (2,i e^{i (e+f x)}\right ) \, dx}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ & = -\frac {2 a x}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a \text {arctanh}(\sin (e+f x)) \cos (e+f x)}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a \cos (e+f x) \log (\cos (e+f x))}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {a \cos (e+f x) \operatorname {PolyLog}\left (3,-i e^{i (e+f x)}\right )}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {a \cos (e+f x) \operatorname {PolyLog}\left (3,i e^{i (e+f x)}\right )}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {a x^2 \sec (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a x \sin (e+f x)}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {a x^2 \tan (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {(a \cos (e+f x)) \text {Subst}\left (\int \frac {\operatorname {PolyLog}(2,-i x)}{x} \, dx,x,e^{i (e+f x)}\right )}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {(a \cos (e+f x)) \text {Subst}\left (\int \frac {\operatorname {PolyLog}(2,i x)}{x} \, dx,x,e^{i (e+f x)}\right )}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ & = -\frac {2 a x}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a \text {arctanh}(\sin (e+f x)) \cos (e+f x)}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a \cos (e+f x) \log (\cos (e+f x))}{c f^3 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}-\frac {a x^2 \sec (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {2 a x \sin (e+f x)}{c f^2 \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}}+\frac {a x^2 \tan (e+f x)}{c f \sqrt {a-a \sin (e+f x)} \sqrt {c+c \sin (e+f x)}} \\ \end{align*}

Mathematica [C] (verified)

Result contains complex when optimal does not.

Time = 1.90 (sec) , antiderivative size = 154, normalized size of antiderivative = 0.55 \[ \int \frac {x^2 \sqrt {a-a \sin (e+f x)}}{(c+c \sin (e+f x))^{3/2}} \, dx=-\frac {\left (\cos \left (\frac {1}{2} (e+f x)\right )+\sin \left (\frac {1}{2} (e+f x)\right )\right ) \sqrt {a-a \sin (e+f x)} \left (2 i f x+f^2 x^2+2 f x \cos (e+f x)-4 \log \left (i+e^{i (e+f x)}\right )+\left (2 i f x-4 \log \left (i+e^{i (e+f x)}\right )\right ) \sin (e+f x)\right )}{f^3 \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right ) (c (1+\sin (e+f x)))^{3/2}} \]

[In]

Integrate[(x^2*Sqrt[a - a*Sin[e + f*x]])/(c + c*Sin[e + f*x])^(3/2),x]

[Out]

-(((Cos[(e + f*x)/2] + Sin[(e + f*x)/2])*Sqrt[a - a*Sin[e + f*x]]*((2*I)*f*x + f^2*x^2 + 2*f*x*Cos[e + f*x] -
4*Log[I + E^(I*(e + f*x))] + ((2*I)*f*x - 4*Log[I + E^(I*(e + f*x))])*Sin[e + f*x]))/(f^3*(Cos[(e + f*x)/2] -
Sin[(e + f*x)/2])*(c*(1 + Sin[e + f*x]))^(3/2)))

Maple [F]

\[\int \frac {x^{2} \sqrt {a -\sin \left (f x +e \right ) a}}{\left (c +c \sin \left (f x +e \right )\right )^{\frac {3}{2}}}d x\]

[In]

int(x^2*(a-sin(f*x+e)*a)^(1/2)/(c+c*sin(f*x+e))^(3/2),x)

[Out]

int(x^2*(a-sin(f*x+e)*a)^(1/2)/(c+c*sin(f*x+e))^(3/2),x)

Fricas [F(-2)]

Exception generated. \[ \int \frac {x^2 \sqrt {a-a \sin (e+f x)}}{(c+c \sin (e+f x))^{3/2}} \, dx=\text {Exception raised: TypeError} \]

[In]

integrate(x^2*(a-a*sin(f*x+e))^(1/2)/(c+c*sin(f*x+e))^(3/2),x, algorithm="fricas")

[Out]

Exception raised: TypeError >>  Error detected within library code:   integrate: implementation incomplete (co
nstant residues)

Sympy [F]

\[ \int \frac {x^2 \sqrt {a-a \sin (e+f x)}}{(c+c \sin (e+f x))^{3/2}} \, dx=\int \frac {x^{2} \sqrt {- a \left (\sin {\left (e + f x \right )} - 1\right )}}{\left (c \left (\sin {\left (e + f x \right )} + 1\right )\right )^{\frac {3}{2}}}\, dx \]

[In]

integrate(x**2*(a-a*sin(f*x+e))**(1/2)/(c+c*sin(f*x+e))**(3/2),x)

[Out]

Integral(x**2*sqrt(-a*(sin(e + f*x) - 1))/(c*(sin(e + f*x) + 1))**(3/2), x)

Maxima [F]

\[ \int \frac {x^2 \sqrt {a-a \sin (e+f x)}}{(c+c \sin (e+f x))^{3/2}} \, dx=\int { \frac {\sqrt {-a \sin \left (f x + e\right ) + a} x^{2}}{{\left (c \sin \left (f x + e\right ) + c\right )}^{\frac {3}{2}}} \,d x } \]

[In]

integrate(x^2*(a-a*sin(f*x+e))^(1/2)/(c+c*sin(f*x+e))^(3/2),x, algorithm="maxima")

[Out]

integrate(sqrt(-a*sin(f*x + e) + a)*x^2/(c*sin(f*x + e) + c)^(3/2), x)

Giac [F]

\[ \int \frac {x^2 \sqrt {a-a \sin (e+f x)}}{(c+c \sin (e+f x))^{3/2}} \, dx=\int { \frac {\sqrt {-a \sin \left (f x + e\right ) + a} x^{2}}{{\left (c \sin \left (f x + e\right ) + c\right )}^{\frac {3}{2}}} \,d x } \]

[In]

integrate(x^2*(a-a*sin(f*x+e))^(1/2)/(c+c*sin(f*x+e))^(3/2),x, algorithm="giac")

[Out]

sage0*x

Mupad [F(-1)]

Timed out. \[ \int \frac {x^2 \sqrt {a-a \sin (e+f x)}}{(c+c \sin (e+f x))^{3/2}} \, dx=\int \frac {x^2\,\sqrt {a-a\,\sin \left (e+f\,x\right )}}{{\left (c+c\,\sin \left (e+f\,x\right )\right )}^{3/2}} \,d x \]

[In]

int((x^2*(a - a*sin(e + f*x))^(1/2))/(c + c*sin(e + f*x))^(3/2),x)

[Out]

int((x^2*(a - a*sin(e + f*x))^(1/2))/(c + c*sin(e + f*x))^(3/2), x)