3.5.36 \(\int \frac {-2 \cot ^2(x)+\sin (x)}{(1+5 \tan ^2(x))^{3/2}} \, dx\) [436]

Optimal. Leaf size=94 \[ -\frac {1}{4} \tanh ^{-1}\left (\frac {2 \tan (x)}{\sqrt {1+5 \tan ^2(x)}}\right )-\frac {\cos (x)}{4 \sqrt {1+5 \tan ^2(x)}}-\frac {5 \cot (x)}{2 \sqrt {1+5 \tan ^2(x)}}-\frac {1}{8} \cos (x) \sqrt {1+5 \tan ^2(x)}+\frac {9}{2} \cot (x) \sqrt {1+5 \tan ^2(x)} \]

[Out]

-1/4*arctanh(2*tan(x)/(1+5*tan(x)^2)^(1/2))-1/4*cos(x)/(1+5*tan(x)^2)^(1/2)-5/2*cot(x)/(1+5*tan(x)^2)^(1/2)-1/
8*cos(x)*(1+5*tan(x)^2)^(1/2)+9/2*cot(x)*(1+5*tan(x)^2)^(1/2)

________________________________________________________________________________________

Rubi [A]
time = 0.27, antiderivative size = 94, normalized size of antiderivative = 1.00, number of steps used = 10, number of rules used = 10, integrand size = 22, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.454, Rules used = {4462, 12, 3751, 483, 597, 385, 212, 3745, 277, 197} \begin {gather*} -\frac {5 \sec (x)}{8 \sqrt {5 \sec ^2(x)-4}}+\frac {\cos (x)}{4 \sqrt {5 \sec ^2(x)-4}}-\frac {1}{4} \tanh ^{-1}\left (\frac {2 \tan (x)}{\sqrt {5 \tan ^2(x)+1}}\right )+\frac {9}{2} \sqrt {5 \tan ^2(x)+1} \cot (x)-\frac {5 \cot (x)}{2 \sqrt {5 \tan ^2(x)+1}} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-2*Cot[x]^2 + Sin[x])/(1 + 5*Tan[x]^2)^(3/2),x]

[Out]

-1/4*ArcTanh[(2*Tan[x])/Sqrt[1 + 5*Tan[x]^2]] + Cos[x]/(4*Sqrt[-4 + 5*Sec[x]^2]) - (5*Sec[x])/(8*Sqrt[-4 + 5*S
ec[x]^2]) - (5*Cot[x])/(2*Sqrt[1 + 5*Tan[x]^2]) + (9*Cot[x]*Sqrt[1 + 5*Tan[x]^2])/2

Rule 12

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

Rule 197

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

Rule 212

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))*ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x]
 /; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rule 277

Int[(x_)^(m_)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[x^(m + 1)*((a + b*x^n)^(p + 1)/(a*(m + 1))), x]
 - Dist[b*((m + n*(p + 1) + 1)/(a*(m + 1))), Int[x^(m + n)*(a + b*x^n)^p, x], x] /; FreeQ[{a, b, m, n, p}, x]
&& ILtQ[Simplify[(m + 1)/n + p + 1], 0] && NeQ[m, -1]

Rule 385

Int[((a_) + (b_.)*(x_)^(n_))^(p_)/((c_) + (d_.)*(x_)^(n_)), x_Symbol] :> Subst[Int[1/(c - (b*c - a*d)*x^n), x]
, x, x/(a + b*x^n)^(1/n)] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0] && EqQ[n*p + 1, 0] && IntegerQ[n]

Rule 483

Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_)*((c_) + (d_.)*(x_)^(n_))^(q_), x_Symbol] :> Simp[(-b)*(e*
x)^(m + 1)*(a + b*x^n)^(p + 1)*((c + d*x^n)^(q + 1)/(a*e*n*(b*c - a*d)*(p + 1))), x] + Dist[1/(a*n*(b*c - a*d)
*(p + 1)), Int[(e*x)^m*(a + b*x^n)^(p + 1)*(c + d*x^n)^q*Simp[c*b*(m + 1) + n*(b*c - a*d)*(p + 1) + d*b*(m + n
*(p + q + 2) + 1)*x^n, x], x], x] /; FreeQ[{a, b, c, d, e, m, q}, x] && NeQ[b*c - a*d, 0] && IGtQ[n, 0] && LtQ
[p, -1] && IntBinomialQ[a, b, c, d, e, m, n, p, q, x]

Rule 597

Int[((g_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^(n_))^(p_.)*((c_) + (d_.)*(x_)^(n_))^(q_.)*((e_) + (f_.)*(x_)^(n_)),
x_Symbol] :> Simp[e*(g*x)^(m + 1)*(a + b*x^n)^(p + 1)*((c + d*x^n)^(q + 1)/(a*c*g*(m + 1))), x] + Dist[1/(a*c*
g^n*(m + 1)), Int[(g*x)^(m + n)*(a + b*x^n)^p*(c + d*x^n)^q*Simp[a*f*c*(m + 1) - e*(b*c + a*d)*(m + n + 1) - e
*n*(b*c*p + a*d*q) - b*e*d*(m + n*(p + q + 2) + 1)*x^n, x], x], x] /; FreeQ[{a, b, c, d, e, f, g, p, q}, x] &&
 IGtQ[n, 0] && LtQ[m, -1]

Rule 3745

Int[sin[(e_.) + (f_.)*(x_)]^(m_.)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)]^2)^(p_.), x_Symbol] :> With[{ff = Free
Factors[Sec[e + f*x], x]}, Dist[1/(f*ff^m), Subst[Int[(-1 + ff^2*x^2)^((m - 1)/2)*((a - b + b*ff^2*x^2)^p/x^(m
 + 1)), x], x, Sec[e + f*x]/ff], x]] /; FreeQ[{a, b, e, f, p}, x] && IntegerQ[(m - 1)/2]

Rule 3751

Int[((d_.)*tan[(e_.) + (f_.)*(x_)])^(m_.)*((a_) + (b_.)*((c_.)*tan[(e_.) + (f_.)*(x_)])^(n_))^(p_.), x_Symbol]
 :> With[{ff = FreeFactors[Tan[e + f*x], x]}, Dist[c*(ff/f), Subst[Int[(d*ff*(x/c))^m*((a + b*(ff*x)^n)^p/(c^2
 + ff^2*x^2)), x], x, c*(Tan[e + f*x]/ff)], x]] /; FreeQ[{a, b, c, d, e, f, m, n, p}, x] && (IGtQ[p, 0] || EqQ
[n, 2] || EqQ[n, 4] || (IntegerQ[p] && RationalQ[n]))

Rule 4462

Int[(u_)*((v_) + (d_.)*(F_)[(c_.)*((a_.) + (b_.)*(x_))]^(n_.)), x_Symbol] :> With[{e = FreeFactors[Cos[c*(a +
b*x)], x]}, Int[ActivateTrig[u*v], x] + Dist[d, Int[ActivateTrig[u]*Sin[c*(a + b*x)]^n, x], x] /; FunctionOfQ[
Cos[c*(a + b*x)]/e, u, x]] /; FreeQ[{a, b, c, d}, x] &&  !FreeQ[v, x] && IntegerQ[(n - 1)/2] && NonsumQ[u] &&
(EqQ[F, Sin] || EqQ[F, sin])

Rubi steps

\begin {align*} \int \frac {-2 \cot ^2(x)+\sin (x)}{\left (1+5 \tan ^2(x)\right )^{3/2}} \, dx &=\int -\frac {2 \cot ^2(x)}{\left (1+5 \tan ^2(x)\right )^{3/2}} \, dx+\int \frac {\sin (x)}{\left (1+5 \tan ^2(x)\right )^{3/2}} \, dx\\ &=-\left (2 \int \frac {\cot ^2(x)}{\left (1+5 \tan ^2(x)\right )^{3/2}} \, dx\right )+\text {Subst}\left (\int \frac {1}{x^2 \left (-4+5 x^2\right )^{3/2}} \, dx,x,\sec (x)\right )\\ &=\frac {\cos (x)}{4 \sqrt {-4+5 \sec ^2(x)}}-2 \text {Subst}\left (\int \frac {1}{x^2 \left (1+x^2\right ) \left (1+5 x^2\right )^{3/2}} \, dx,x,\tan (x)\right )+\frac {5}{2} \text {Subst}\left (\int \frac {1}{\left (-4+5 x^2\right )^{3/2}} \, dx,x,\sec (x)\right )\\ &=\frac {\cos (x)}{4 \sqrt {-4+5 \sec ^2(x)}}-\frac {5 \sec (x)}{8 \sqrt {-4+5 \sec ^2(x)}}-\frac {5 \cot (x)}{2 \sqrt {1+5 \tan ^2(x)}}+\frac {1}{2} \text {Subst}\left (\int \frac {-9-10 x^2}{x^2 \left (1+x^2\right ) \sqrt {1+5 x^2}} \, dx,x,\tan (x)\right )\\ &=\frac {\cos (x)}{4 \sqrt {-4+5 \sec ^2(x)}}-\frac {5 \sec (x)}{8 \sqrt {-4+5 \sec ^2(x)}}-\frac {5 \cot (x)}{2 \sqrt {1+5 \tan ^2(x)}}+\frac {9}{2} \cot (x) \sqrt {1+5 \tan ^2(x)}-\frac {1}{2} \text {Subst}\left (\int \frac {1}{\left (1+x^2\right ) \sqrt {1+5 x^2}} \, dx,x,\tan (x)\right )\\ &=\frac {\cos (x)}{4 \sqrt {-4+5 \sec ^2(x)}}-\frac {5 \sec (x)}{8 \sqrt {-4+5 \sec ^2(x)}}-\frac {5 \cot (x)}{2 \sqrt {1+5 \tan ^2(x)}}+\frac {9}{2} \cot (x) \sqrt {1+5 \tan ^2(x)}-\frac {1}{2} \text {Subst}\left (\int \frac {1}{1-4 x^2} \, dx,x,\frac {\tan (x)}{\sqrt {1+5 \tan ^2(x)}}\right )\\ &=-\frac {1}{4} \tanh ^{-1}\left (\frac {2 \tan (x)}{\sqrt {1+5 \tan ^2(x)}}\right )+\frac {\cos (x)}{4 \sqrt {-4+5 \sec ^2(x)}}-\frac {5 \sec (x)}{8 \sqrt {-4+5 \sec ^2(x)}}-\frac {5 \cot (x)}{2 \sqrt {1+5 \tan ^2(x)}}+\frac {9}{2} \cot (x) \sqrt {1+5 \tan ^2(x)}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.43, size = 75, normalized size = 0.80 \begin {gather*} \frac {\csc (x) \sec (x) \left (196-164 \cos (2 x)-9 \sin (x)-4 \tan ^{-1}\left (\frac {2 \sin (x)}{\sqrt {-3+2 \cos (2 x)}}\right ) \sqrt {-3+2 \cos (2 x)} \sin (x)+\sin (3 x)\right )}{16 \sqrt {-2+3 \sec ^2(x)+2 \tan ^2(x)}} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-2*Cot[x]^2 + Sin[x])/(1 + 5*Tan[x]^2)^(3/2),x]

[Out]

(Csc[x]*Sec[x]*(196 - 164*Cos[2*x] - 9*Sin[x] - 4*ArcTan[(2*Sin[x])/Sqrt[-3 + 2*Cos[2*x]]]*Sqrt[-3 + 2*Cos[2*x
]]*Sin[x] + Sin[3*x]))/(16*Sqrt[-2 + 3*Sec[x]^2 + 2*Tan[x]^2])

________________________________________________________________________________________

Maple [C] Result contains higher order function than in optimal. Order 4 vs. order 3.
time = 1.36, size = 975, normalized size = 10.37

method result size
default \(\text {Expression too large to display}\) \(975\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((-2*cot(x)^2+sin(x))/(1+5*tan(x)^2)^(3/2),x,method=_RETURNVERBOSE)

[Out]

1/8*I/(-9+4*5^(1/2))^(1/2)/(2+5^(1/2))^2/(-2+5^(1/2))^2/(4*cos(x)^2-5)^2*(4*I*cos(x)*EllipticF(I*(cos(x)-1)*(-
2+5^(1/2))/sin(x),9+4*5^(1/2))*2^(1/2)*((2*cos(x)*5^(1/2)-4*cos(x)-2*5^(1/2)+5)/(1+cos(x)))^(1/2)*(-2*(2*cos(x
)*5^(1/2)+4*cos(x)-2*5^(1/2)-5)/(1+cos(x)))^(1/2)*sin(x)-8*I*EllipticPi((-9+4*5^(1/2))^(1/2)*(cos(x)-1)/sin(x)
,-1/(-9+4*5^(1/2)),(-9-4*5^(1/2))^(1/2)/(-9+4*5^(1/2))^(1/2))*2^(1/2)*((2*cos(x)*5^(1/2)-4*cos(x)-2*5^(1/2)+5)
/(1+cos(x)))^(1/2)*(-2*(2*cos(x)*5^(1/2)+4*cos(x)-2*5^(1/2)-5)/(1+cos(x)))^(1/2)*sin(x)+4*I*EllipticF(I*(cos(x
)-1)*(-2+5^(1/2))/sin(x),9+4*5^(1/2))*2^(1/2)*((2*cos(x)*5^(1/2)-4*cos(x)-2*5^(1/2)+5)/(1+cos(x)))^(1/2)*(-2*(
2*cos(x)*5^(1/2)+4*cos(x)-2*5^(1/2)-5)/(1+cos(x)))^(1/2)*sin(x)-3*I*cos(x)*arctanh(1/2*(-16)^(1/2)*cos(x)*(cos
(x)-1)/sin(x)^2/(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2))*5^(1/2)*(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2)*sin(x)-8*I*
2^(1/2)*((2*cos(x)*5^(1/2)-4*cos(x)-2*5^(1/2)+5)/(1+cos(x)))^(1/2)*(-2*(2*cos(x)*5^(1/2)+4*cos(x)-2*5^(1/2)-5)
/(1+cos(x)))^(1/2)*EllipticPi((-9+4*5^(1/2))^(1/2)*(cos(x)-1)/sin(x),-1/(-9+4*5^(1/2)),(-9-4*5^(1/2))^(1/2)/(-
9+4*5^(1/2))^(1/2))*sin(x)*cos(x)-3*cos(x)*sin(x)*arctan(2*cos(x)*(cos(x)-1)/sin(x)^2/(-(4*cos(x)^2-5)/(1+cos(
x))^2)^(1/2))*5^(1/2)*(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2)+6*I*cos(x)*arctanh(1/2*(-16)^(1/2)*cos(x)*(cos(x)-1
)/sin(x)^2/(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2))*(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2)*sin(x)-3*I*arctanh(1/2*(
-16)^(1/2)*cos(x)*(cos(x)-1)/sin(x)^2/(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2))*5^(1/2)*(-(4*cos(x)^2-5)/(1+cos(x)
)^2)^(1/2)*sin(x)+2*cos(x)^2*sin(x)*5^(1/2)+6*cos(x)*sin(x)*(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2)*arctan(2*cos(
x)*(cos(x)-1)/sin(x)^2/(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2))-3*sin(x)*arctan(2*cos(x)*(cos(x)-1)/sin(x)^2/(-(4
*cos(x)^2-5)/(1+cos(x))^2)^(1/2))*5^(1/2)*(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2)+6*I*arctanh(1/2*(-16)^(1/2)*cos
(x)*(cos(x)-1)/sin(x)^2/(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2))*(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2)*sin(x)-4*co
s(x)^2*sin(x)-164*cos(x)^2*5^(1/2)+6*arctan(2*cos(x)*(cos(x)-1)/sin(x)^2/(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2))
*(-(4*cos(x)^2-5)/(1+cos(x))^2)^(1/2)*sin(x)+328*cos(x)^2-5*sin(x)*5^(1/2)+10*sin(x)+180*5^(1/2)-360)*cos(x)^3
*(-(4*cos(x)^2-5)/cos(x)^2)^(3/2)/sin(x)

________________________________________________________________________________________

Maxima [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*cot(x)^2+sin(x))/(1+5*tan(x)^2)^(3/2),x, algorithm="maxima")

[Out]

Timed out

________________________________________________________________________________________

Fricas [A]
time = 1.27, size = 97, normalized size = 1.03 \begin {gather*} \frac {2 \, {\left (4 \, \cos \left (x\right )^{2} - 5\right )} \log \left (\sqrt {-\frac {4 \, \cos \left (x\right )^{2} - 5}{\cos \left (x\right )^{2}}} \cos \left (x\right ) - 2 \, \sin \left (x\right )\right ) \sin \left (x\right ) + {\left (164 \, \cos \left (x\right )^{3} - {\left (2 \, \cos \left (x\right )^{3} - 5 \, \cos \left (x\right )\right )} \sin \left (x\right ) - 180 \, \cos \left (x\right )\right )} \sqrt {-\frac {4 \, \cos \left (x\right )^{2} - 5}{\cos \left (x\right )^{2}}}}{8 \, {\left (4 \, \cos \left (x\right )^{2} - 5\right )} \sin \left (x\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*cot(x)^2+sin(x))/(1+5*tan(x)^2)^(3/2),x, algorithm="fricas")

[Out]

1/8*(2*(4*cos(x)^2 - 5)*log(sqrt(-(4*cos(x)^2 - 5)/cos(x)^2)*cos(x) - 2*sin(x))*sin(x) + (164*cos(x)^3 - (2*co
s(x)^3 - 5*cos(x))*sin(x) - 180*cos(x))*sqrt(-(4*cos(x)^2 - 5)/cos(x)^2))/((4*cos(x)^2 - 5)*sin(x))

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} - \int \left (- \frac {\sin {\left (x \right )}}{5 \sqrt {5 \tan ^{2}{\left (x \right )} + 1} \tan ^{2}{\left (x \right )} + \sqrt {5 \tan ^{2}{\left (x \right )} + 1}}\right )\, dx - \int \frac {2 \cot ^{2}{\left (x \right )}}{5 \sqrt {5 \tan ^{2}{\left (x \right )} + 1} \tan ^{2}{\left (x \right )} + \sqrt {5 \tan ^{2}{\left (x \right )} + 1}}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*cot(x)**2+sin(x))/(1+5*tan(x)**2)**(3/2),x)

[Out]

-Integral(-sin(x)/(5*sqrt(5*tan(x)**2 + 1)*tan(x)**2 + sqrt(5*tan(x)**2 + 1)), x) - Integral(2*cot(x)**2/(5*sq
rt(5*tan(x)**2 + 1)*tan(x)**2 + sqrt(5*tan(x)**2 + 1)), x)

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*cot(x)^2+sin(x))/(1+5*tan(x)^2)^(3/2),x, algorithm="giac")

[Out]

integrate(-(2*cot(x)^2 - sin(x))/(5*tan(x)^2 + 1)^(3/2), x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {\sin \left (x\right )-2\,{\mathrm {cot}\left (x\right )}^2}{{\left (5\,{\mathrm {tan}\left (x\right )}^2+1\right )}^{3/2}} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((sin(x) - 2*cot(x)^2)/(5*tan(x)^2 + 1)^(3/2),x)

[Out]

int((sin(x) - 2*cot(x)^2)/(5*tan(x)^2 + 1)^(3/2), x)

________________________________________________________________________________________