3.3.87 \(\int \tan ^2(4 x) \, dx\) [287]

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

[Out]

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

________________________________________________________________________________________

Rubi [A]
time = 0.00, antiderivative size = 12, normalized size of antiderivative = 1.00, 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 = {3554, 8} \begin {gather*} \frac {1}{4} \tan (4 x)-x \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

-x + Tan[4*x]/4

Rule 8

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

Rule 3554

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]

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.01, size = 18, normalized size = 1.50 \begin {gather*} -\frac {1}{4} \tan ^{-1}(\tan (4 x))+\frac {1}{4} \tan (4 x) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

Mathics [A]
time = 1.77, size = 10, normalized size = 0.83 \begin {gather*} -x+\frac {\text {Tan}\left [4 x\right ]}{4} \end {gather*}

Antiderivative was successfully verified.

[In]

mathics('Integrate[Tan[4*x]^2,x]')

[Out]

-x + Tan[4 x] / 4

________________________________________________________________________________________

Maple [A]
time = 0.01, size = 15, normalized size = 1.25

method result size
norman \(-x +\frac {\tan \left (4 x \right )}{4}\) \(11\)
derivativedivides \(\frac {\tan \left (4 x \right )}{4}-\frac {\arctan \left (\tan \left (4 x \right )\right )}{4}\) \(15\)
default \(\frac {\tan \left (4 x \right )}{4}-\frac {\arctan \left (\tan \left (4 x \right )\right )}{4}\) \(15\)
risch \(-x +\frac {i}{2 \,{\mathrm e}^{8 i x}+2}\) \(17\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(tan(4*x)^2,x,method=_RETURNVERBOSE)

[Out]

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

________________________________________________________________________________________

Maxima [A]
time = 0.34, size = 10, normalized size = 0.83 \begin {gather*} -x + \frac {1}{4} \, \tan \left (4 \, x\right ) \end {gather*}

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 = 0.34, size = 10, normalized size = 0.83 \begin {gather*} -x + \frac {1}{4} \, \tan \left (4 \, x\right ) \end {gather*}

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.03, size = 12, normalized size = 1.00 \begin {gather*} - x + \frac {\sin {\left (4 x \right )}}{4 \cos {\left (4 x \right )}} \end {gather*}

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 = 0.03, size = 10, normalized size = 0.83 \begin {gather*} \frac {\tan \left (4 x\right )}{4}-x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Mupad [B]
time = 0.18, size = 10, normalized size = 0.83 \begin {gather*} \frac {\mathrm {tan}\left (4\,x\right )}{4}-x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

tan(4*x)/4 - x

________________________________________________________________________________________