3.287 \(\int \tan ^2(4 x) \, dx\)

Optimal. Leaf size=12 \[ \frac{1}{4} \tan (4 x)-x \]

[Out]

-x + Tan[4*x]/4

________________________________________________________________________________________

Rubi [A]  time = 0.0053044, antiderivative size = 12, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 6, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.333, Rules used = {3473, 8} \[ \frac{1}{4} \tan (4 x)-x \]

Antiderivative was successfully verified.

[In]

Int[Tan[4*x]^2,x]

[Out]

-x + Tan[4*x]/4

Rule 3473

Int[((b_.)*tan[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(b*(b*Tan[c + d*x])^(n - 1))/(d*(n - 1)), x] - Dis
t[b^2, Int[(b*Tan[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1]

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rubi steps

\begin{align*} \int \tan ^2(4 x) \, dx &=\frac{1}{4} \tan (4 x)-\int 1 \, dx\\ &=-x+\frac{1}{4} \tan (4 x)\\ \end{align*}

Mathematica [A]  time = 0.0081634, size = 18, normalized size = 1.5 \[ \frac{1}{4} \tan (4 x)-\frac{1}{4} \tan ^{-1}(\tan (4 x)) \]

Antiderivative was successfully verified.

[In]

Integrate[Tan[4*x]^2,x]

[Out]

-ArcTan[Tan[4*x]]/4 + Tan[4*x]/4

________________________________________________________________________________________

Maple [A]  time = 0.003, size = 11, normalized size = 0.9 \begin{align*} -x+{\frac{\tan \left ( 4\,x \right ) }{4}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(tan(4*x)^2,x)

[Out]

-x+1/4*tan(4*x)

________________________________________________________________________________________

Maxima [A]  time = 1.46556, size = 14, normalized size = 1.17 \begin{align*} -x + \frac{1}{4} \, \tan \left (4 \, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(4*x)^2,x, algorithm="maxima")

[Out]

-x + 1/4*tan(4*x)

________________________________________________________________________________________

Fricas [A]  time = 2.01629, size = 26, normalized size = 2.17 \begin{align*} -x + \frac{1}{4} \, \tan \left (4 \, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(4*x)^2,x, algorithm="fricas")

[Out]

-x + 1/4*tan(4*x)

________________________________________________________________________________________

Sympy [A]  time = 0.06253, size = 12, normalized size = 1. \begin{align*} - x + \frac{\sin{\left (4 x \right )}}{4 \cos{\left (4 x \right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(4*x)**2,x)

[Out]

-x + sin(4*x)/(4*cos(4*x))

________________________________________________________________________________________

Giac [A]  time = 1.06407, size = 14, normalized size = 1.17 \begin{align*} -x + \frac{1}{4} \, \tan \left (4 \, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(4*x)^2,x, algorithm="giac")

[Out]

-x + 1/4*tan(4*x)