Optimal. Leaf size=16 \[ -6 x+6 \tan (x)-2 \sin ^2(x) \tan (x) \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.03, antiderivative size = 16, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, integrand size = 10, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.500, Rules used = {12, 2591, 288, 321, 203} \[ -6 x+6 \tan (x)-2 \sin ^2(x) \tan (x) \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 203
Rule 288
Rule 321
Rule 2591
Rubi steps
\begin {align*} \int 4 \sin ^2(x) \tan ^2(x) \, dx &=4 \int \sin ^2(x) \tan ^2(x) \, dx\\ &=4 \operatorname {Subst}\left (\int \frac {x^4}{\left (1+x^2\right )^2} \, dx,x,\tan (x)\right )\\ &=-2 \sin ^2(x) \tan (x)+6 \operatorname {Subst}\left (\int \frac {x^2}{1+x^2} \, dx,x,\tan (x)\right )\\ &=6 \tan (x)-2 \sin ^2(x) \tan (x)-6 \operatorname {Subst}\left (\int \frac {1}{1+x^2} \, dx,x,\tan (x)\right )\\ &=-6 x+6 \tan (x)-2 \sin ^2(x) \tan (x)\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.02, size = 18, normalized size = 1.12 \[ 4 \left (-\frac {3 x}{2}+\frac {1}{4} \sin (2 x)+\tan (x)\right ) \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.59, size = 22, normalized size = 1.38 \[ -\frac {2 \, {\left (3 \, x \cos \relax (x) - {\left (\cos \relax (x)^{2} + 2\right )} \sin \relax (x)\right )}}{\cos \relax (x)} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.14, size = 20, normalized size = 1.25 \[ -6 \, x + \frac {2 \, \tan \relax (x)}{\tan \relax (x)^{2} + 1} + 4 \, \tan \relax (x) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.04, size = 28, normalized size = 1.75 \[ \frac {4 \left (\sin ^{5}\relax (x )\right )}{\cos \relax (x )}+4 \left (\sin ^{3}\relax (x )+\frac {3 \sin \relax (x )}{2}\right ) \cos \relax (x )-6 x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.43, size = 20, normalized size = 1.25 \[ -6 \, x + \frac {2 \, \tan \relax (x)}{\tan \relax (x)^{2} + 1} + 4 \, \tan \relax (x) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 2.96, size = 18, normalized size = 1.12 \[ 2\,\cos \relax (x)\,\sin \relax (x)-6\,x+\frac {4\,\sin \relax (x)}{\cos \relax (x)} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.05, size = 20, normalized size = 1.25 \[ - 6 x + \frac {4 \sin ^{3}{\relax (x )}}{\cos {\relax (x )}} + 6 \sin {\relax (x )} \cos {\relax (x )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________