3.82 \(\int \tan ^2(x) \, dx\)

Optimal. Leaf size=6 \[ \tan (x)-x \]

[Out]

-x + Tan[x]

_______________________________________________________________________________________

Rubi [A]  time = 0.00858802, antiderivative size = 6, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 4, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.5 \[ \tan (x)-x \]

Antiderivative was successfully verified.

[In]  Int[Tan[x]^2,x]

[Out]

-x + Tan[x]

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 0.046925, size = 3, normalized size = 0.5 \[ - x + \tan{\left (x \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate(tan(x)**2,x)

[Out]

-x + tan(x)

_______________________________________________________________________________________

Mathematica [A]  time = 0.00364365, size = 6, normalized size = 1. \[ \tan (x)-x \]

Antiderivative was successfully verified.

[In]  Integrate[Tan[x]^2,x]

[Out]

-x + Tan[x]

_______________________________________________________________________________________

Maple [A]  time = 0., size = 7, normalized size = 1.2 \[ -x+\tan \left ( x \right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int(tan(x)^2,x)

[Out]

-x+tan(x)

_______________________________________________________________________________________

Maxima [A]  time = 1.59995, size = 8, normalized size = 1.33 \[ -x + \tan \left (x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(tan(x)^2,x, algorithm="maxima")

[Out]

-x + tan(x)

_______________________________________________________________________________________

Fricas [A]  time = 0.217639, size = 8, normalized size = 1.33 \[ -x + \tan \left (x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(tan(x)^2,x, algorithm="fricas")

[Out]

-x + tan(x)

_______________________________________________________________________________________

Sympy [A]  time = 0.04436, size = 7, normalized size = 1.17 \[ - x + \frac{\sin{\left (x \right )}}{\cos{\left (x \right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(tan(x)**2,x)

[Out]

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

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.204827, size = 8, normalized size = 1.33 \[ -x + \tan \left (x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(tan(x)^2,x, algorithm="giac")

[Out]

-x + tan(x)