3.36.3 \(\int \frac {-1-x^2}{x^2} \, dx\)

Optimal. Leaf size=21 \[ \frac {1}{3} \left (\frac {3}{2}+\frac {3}{x}\right )-x+\log (2)+\log (5) \]

________________________________________________________________________________________

Rubi [A]  time = 0.00, antiderivative size = 7, normalized size of antiderivative = 0.33, number of steps used = 2, number of rules used = 1, integrand size = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.091, Rules used = {14} \begin {gather*} \frac {1}{x}-x \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-1 - x^2)/x^2,x]

[Out]

x^(-1) - x

Rule 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
 &&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \left (-1-\frac {1}{x^2}\right ) \, dx\\ &=\frac {1}{x}-x\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.00, size = 7, normalized size = 0.33 \begin {gather*} \frac {1}{x}-x \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-1 - x^2)/x^2,x]

[Out]

x^(-1) - x

________________________________________________________________________________________

fricas [A]  time = 0.52, size = 10, normalized size = 0.48 \begin {gather*} -\frac {x^{2} - 1}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-(x^2 - 1)/x

________________________________________________________________________________________

giac [A]  time = 0.14, size = 7, normalized size = 0.33 \begin {gather*} -x + \frac {1}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-x + 1/x

________________________________________________________________________________________

maple [A]  time = 0.01, size = 8, normalized size = 0.38




method result size



default \(\frac {1}{x}-x\) \(8\)
risch \(\frac {1}{x}-x\) \(8\)
gosper \(-\frac {x^{2}-1}{x}\) \(11\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((-x^2-1)/x^2,x,method=_RETURNVERBOSE)

[Out]

1/x-x

________________________________________________________________________________________

maxima [A]  time = 0.58, size = 7, normalized size = 0.33 \begin {gather*} -x + \frac {1}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-x + 1/x

________________________________________________________________________________________

mupad [B]  time = 0.02, size = 7, normalized size = 0.33 \begin {gather*} \frac {1}{x}-x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/x - x

________________________________________________________________________________________

sympy [A]  time = 0.06, size = 3, normalized size = 0.14 \begin {gather*} - x + \frac {1}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-x + 1/x

________________________________________________________________________________________