3.808 \(\int \frac{2 \sqrt{-1+x}+x}{\sqrt{-1+x} x} \, dx\)

Optimal. Leaf size=14 \[ 2 \sqrt{x-1}+2 \log (x) \]

[Out]

2*Sqrt[-1 + x] + 2*Log[x]

________________________________________________________________________________________

Rubi [A]  time = 0.117406, antiderivative size = 14, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 22, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.045, Rules used = {6688} \[ 2 \sqrt{x-1}+2 \log (x) \]

Antiderivative was successfully verified.

[In]

Int[(2*Sqrt[-1 + x] + x)/(Sqrt[-1 + x]*x),x]

[Out]

2*Sqrt[-1 + x] + 2*Log[x]

Rule 6688

Int[u_, x_Symbol] :> With[{v = SimplifyIntegrand[u, x]}, Int[v, x] /; SimplerIntegrandQ[v, u, x]]

Rubi steps

\begin{align*} \int \frac{2 \sqrt{-1+x}+x}{\sqrt{-1+x} x} \, dx &=\int \left (\frac{1}{\sqrt{-1+x}}+\frac{2}{x}\right ) \, dx\\ &=2 \sqrt{-1+x}+2 \log (x)\\ \end{align*}

Mathematica [A]  time = 0.0057806, size = 14, normalized size = 1. \[ 2 \sqrt{x-1}+2 \log (x) \]

Antiderivative was successfully verified.

[In]

Integrate[(2*Sqrt[-1 + x] + x)/(Sqrt[-1 + x]*x),x]

[Out]

2*Sqrt[-1 + x] + 2*Log[x]

________________________________________________________________________________________

Maple [A]  time = 0.002, size = 13, normalized size = 0.9 \begin{align*} 2\,\ln \left ( x \right ) +2\,\sqrt{x-1} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((x+2*(x-1)^(1/2))/x/(x-1)^(1/2),x)

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((x+2*(-1+x)^(1/2))/x/(-1+x)^(1/2),x, algorithm="maxima")

[Out]

2*sqrt(x - 1) + 2*log(x)

________________________________________________________________________________________

Fricas [A]  time = 1.74099, size = 35, normalized size = 2.5 \begin{align*} 2 \, \sqrt{x - 1} + 2 \, \log \left (x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((x+2*(-1+x)^(1/2))/x/(-1+x)^(1/2),x, algorithm="fricas")

[Out]

2*sqrt(x - 1) + 2*log(x)

________________________________________________________________________________________

Sympy [A]  time = 0.138341, size = 12, normalized size = 0.86 \begin{align*} 2 \sqrt{x - 1} + 2 \log{\left (x \right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((x+2*(-1+x)**(1/2))/x/(-1+x)**(1/2),x)

[Out]

2*sqrt(x - 1) + 2*log(x)

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((x+2*(-1+x)^(1/2))/x/(-1+x)^(1/2),x, algorithm="giac")

[Out]

2*sqrt(x - 1) + 2*log(x)