3.23.99 \(\int \frac {-32-8 x+8 x^2+(32+8 x^2) \log (x)}{x^2} \, dx\)

Optimal. Leaf size=27 \[ 4 \left (x+2 (1+x)-\frac {1}{2} x \left (1+\frac {(4+x)^2}{x^2}\right )\right ) \log (x) \]

________________________________________________________________________________________

Rubi [A]  time = 0.04, antiderivative size = 18, normalized size of antiderivative = 0.67, number of steps used = 6, number of rules used = 2, integrand size = 24, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.083, Rules used = {14, 2334} \begin {gather*} -8 \left (\frac {4}{x}-x\right ) \log (x)-8 \log (x) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-32 - 8*x + 8*x^2 + (32 + 8*x^2)*Log[x])/x^2,x]

[Out]

-8*Log[x] - 8*(4/x - x)*Log[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]]

Rule 2334

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*(x_)^(m_.)*((d_) + (e_.)*(x_)^(r_.))^(q_.), x_Symbol] :> With[{u = I
ntHide[x^m*(d + e*x^r)^q, x]}, Simp[u*(a + b*Log[c*x^n]), x] - Dist[b*n, Int[SimplifyIntegrand[u/x, x], x], x]
] /; FreeQ[{a, b, c, d, e, n, r}, x] && IGtQ[q, 0] && IntegerQ[m] &&  !(EqQ[q, 1] && EqQ[m, -1])

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.00, size = 17, normalized size = 0.63 \begin {gather*} -8 \log (x)-\frac {32 \log (x)}{x}+8 x \log (x) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-32 - 8*x + 8*x^2 + (32 + 8*x^2)*Log[x])/x^2,x]

[Out]

-8*Log[x] - (32*Log[x])/x + 8*x*Log[x]

________________________________________________________________________________________

fricas [A]  time = 0.62, size = 15, normalized size = 0.56 \begin {gather*} \frac {8 \, {\left (x^{2} - x - 4\right )} \log \relax (x)}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((8*x^2+32)*log(x)+8*x^2-8*x-32)/x^2,x, algorithm="fricas")

[Out]

8*(x^2 - x - 4)*log(x)/x

________________________________________________________________________________________

giac [A]  time = 0.22, size = 16, normalized size = 0.59 \begin {gather*} 8 \, {\left (x - \frac {4}{x}\right )} \log \relax (x) - 8 \, \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((8*x^2+32)*log(x)+8*x^2-8*x-32)/x^2,x, algorithm="giac")

[Out]

8*(x - 4/x)*log(x) - 8*log(x)

________________________________________________________________________________________

maple [A]  time = 0.05, size = 18, normalized size = 0.67




method result size



default \(8 x \ln \relax (x )-\frac {32 \ln \relax (x )}{x}-8 \ln \relax (x )\) \(18\)
risch \(\frac {8 \left (x^{2}-4\right ) \ln \relax (x )}{x}-8 \ln \relax (x )\) \(18\)
norman \(\frac {-8 x \ln \relax (x )+8 x^{2} \ln \relax (x )-32 \ln \relax (x )}{x}\) \(22\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((8*x^2+32)*ln(x)+8*x^2-8*x-32)/x^2,x,method=_RETURNVERBOSE)

[Out]

8*x*ln(x)-32*ln(x)/x-8*ln(x)

________________________________________________________________________________________

maxima [A]  time = 0.45, size = 17, normalized size = 0.63 \begin {gather*} 8 \, x \log \relax (x) - \frac {32 \, \log \relax (x)}{x} - 8 \, \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((8*x^2+32)*log(x)+8*x^2-8*x-32)/x^2,x, algorithm="maxima")

[Out]

8*x*log(x) - 32*log(x)/x - 8*log(x)

________________________________________________________________________________________

mupad [B]  time = 1.39, size = 15, normalized size = 0.56 \begin {gather*} -\frac {8\,\ln \relax (x)\,\left (-x^2+x+4\right )}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(8*x - 8*x^2 - log(x)*(8*x^2 + 32) + 32)/x^2,x)

[Out]

-(8*log(x)*(x - x^2 + 4))/x

________________________________________________________________________________________

sympy [A]  time = 0.11, size = 15, normalized size = 0.56 \begin {gather*} - 8 \log {\relax (x )} + \frac {\left (8 x^{2} - 32\right ) \log {\relax (x )}}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((8*x**2+32)*ln(x)+8*x**2-8*x-32)/x**2,x)

[Out]

-8*log(x) + (8*x**2 - 32)*log(x)/x

________________________________________________________________________________________