3.59 \(\int \frac{\tan ^2(\sqrt{x})}{\sqrt{x}} \, dx\)

Optimal. Leaf size=16 \[ 2 \tan \left (\sqrt{x}\right )-2 \sqrt{x} \]

[Out]

-2*Sqrt[x] + 2*Tan[Sqrt[x]]

________________________________________________________________________________________

Rubi [A]  time = 0.0178689, antiderivative size = 16, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 3, integrand size = 14, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.214, Rules used = {3747, 3473, 8} \[ 2 \tan \left (\sqrt{x}\right )-2 \sqrt{x} \]

Antiderivative was successfully verified.

[In]

Int[Tan[Sqrt[x]]^2/Sqrt[x],x]

[Out]

-2*Sqrt[x] + 2*Tan[Sqrt[x]]

Rule 3747

Int[(x_)^(m_.)*((a_.) + (b_.)*Tan[(c_.) + (d_.)*(x_)^(n_)])^(p_.), x_Symbol] :> Dist[1/n, Subst[Int[x^(Simplif
y[(m + 1)/n] - 1)*(a + b*Tan[c + d*x])^p, x], x, x^n], x] /; FreeQ[{a, b, c, d, m, n, p}, x] && IGtQ[Simplify[
(m + 1)/n], 0] && IntegerQ[p]

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 \frac{\tan ^2\left (\sqrt{x}\right )}{\sqrt{x}} \, dx &=2 \operatorname{Subst}\left (\int \tan ^2(x) \, dx,x,\sqrt{x}\right )\\ &=2 \tan \left (\sqrt{x}\right )-2 \operatorname{Subst}\left (\int 1 \, dx,x,\sqrt{x}\right )\\ &=-2 \sqrt{x}+2 \tan \left (\sqrt{x}\right )\\ \end{align*}

Mathematica [A]  time = 0.034028, size = 18, normalized size = 1.12 \[ 2 \tan \left (\sqrt{x}\right )-2 \tan ^{-1}\left (\tan \left (\sqrt{x}\right )\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[Tan[Sqrt[x]]^2/Sqrt[x],x]

[Out]

-2*ArcTan[Tan[Sqrt[x]]] + 2*Tan[Sqrt[x]]

________________________________________________________________________________________

Maple [A]  time = 0.007, size = 13, normalized size = 0.8 \begin{align*} -2\,\sqrt{x}+2\,\tan \left ( \sqrt{x} \right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(tan(x^(1/2))^2/x^(1/2),x)

[Out]

-2*x^(1/2)+2*tan(x^(1/2))

________________________________________________________________________________________

Maxima [A]  time = 1.47961, size = 16, normalized size = 1. \begin{align*} -2 \, \sqrt{x} + 2 \, \tan \left (\sqrt{x}\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(x^(1/2))^2/x^(1/2),x, algorithm="maxima")

[Out]

-2*sqrt(x) + 2*tan(sqrt(x))

________________________________________________________________________________________

Fricas [A]  time = 2.28983, size = 39, normalized size = 2.44 \begin{align*} -2 \, \sqrt{x} + 2 \, \tan \left (\sqrt{x}\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(x^(1/2))^2/x^(1/2),x, algorithm="fricas")

[Out]

-2*sqrt(x) + 2*tan(sqrt(x))

________________________________________________________________________________________

Sympy [A]  time = 1.02012, size = 14, normalized size = 0.88 \begin{align*} - 2 \sqrt{x} + 2 \tan{\left (\sqrt{x} \right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(x**(1/2))**2/x**(1/2),x)

[Out]

-2*sqrt(x) + 2*tan(sqrt(x))

________________________________________________________________________________________

Giac [A]  time = 1.11438, size = 16, normalized size = 1. \begin{align*} -2 \, \sqrt{x} + 2 \, \tan \left (\sqrt{x}\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(x^(1/2))^2/x^(1/2),x, algorithm="giac")

[Out]

-2*sqrt(x) + 2*tan(sqrt(x))