3.8.49 \(\int \frac {-3-3 x+2 x^2 \log (x)}{x^3} \, dx\)

Optimal. Leaf size=24 \[ x+\frac {3+\frac {3}{2 x}-x^2}{x}+\log ^2(x) \]

________________________________________________________________________________________

Rubi [A]  time = 0.02, antiderivative size = 17, normalized size of antiderivative = 0.71, number of steps used = 4, number of rules used = 3, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.188, Rules used = {14, 37, 2301} \begin {gather*} \frac {3 (x+1)^2}{2 x^2}+\log ^2(x) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

(3*(1 + x)^2)/(2*x^2) + Log[x]^2

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 37

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[((a + b*x)^(m + 1)*(c + d*x)^(n +
1))/((b*c - a*d)*(m + 1)), x] /; FreeQ[{a, b, c, d, m, n}, x] && NeQ[b*c - a*d, 0] && EqQ[m + n + 2, 0] && NeQ
[m, -1]

Rule 2301

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))/(x_), x_Symbol] :> Simp[(a + b*Log[c*x^n])^2/(2*b*n), x] /; FreeQ[{a
, b, c, n}, x]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.00, size = 17, normalized size = 0.71 \begin {gather*} \frac {3}{2 x^2}+\frac {3}{x}+\log ^2(x) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

3/(2*x^2) + 3/x + Log[x]^2

________________________________________________________________________________________

fricas [A]  time = 0.54, size = 19, normalized size = 0.79 \begin {gather*} \frac {2 \, x^{2} \log \relax (x)^{2} + 6 \, x + 3}{2 \, x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2*log(x)-3*x-3)/x^3,x, algorithm="fricas")

[Out]

1/2*(2*x^2*log(x)^2 + 6*x + 3)/x^2

________________________________________________________________________________________

giac [A]  time = 0.30, size = 15, normalized size = 0.62 \begin {gather*} \log \relax (x)^{2} + \frac {3 \, {\left (2 \, x + 1\right )}}{2 \, x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2*log(x)-3*x-3)/x^3,x, algorithm="giac")

[Out]

log(x)^2 + 3/2*(2*x + 1)/x^2

________________________________________________________________________________________

maple [A]  time = 0.03, size = 16, normalized size = 0.67




method result size



default \(\ln \relax (x )^{2}+\frac {3}{x}+\frac {3}{2 x^{2}}\) \(16\)
risch \(\ln \relax (x )^{2}+\frac {3 x +\frac {3}{2}}{x^{2}}\) \(16\)
norman \(\frac {\frac {3}{2}+x^{2} \ln \relax (x )^{2}+3 x}{x^{2}}\) \(18\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((2*x^2*ln(x)-3*x-3)/x^3,x,method=_RETURNVERBOSE)

[Out]

ln(x)^2+3/x+3/2/x^2

________________________________________________________________________________________

maxima [A]  time = 0.51, size = 15, normalized size = 0.62 \begin {gather*} \log \relax (x)^{2} + \frac {3}{x} + \frac {3}{2 \, x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2*log(x)-3*x-3)/x^3,x, algorithm="maxima")

[Out]

log(x)^2 + 3/x + 3/2/x^2

________________________________________________________________________________________

mupad [B]  time = 0.53, size = 14, normalized size = 0.58 \begin {gather*} {\ln \relax (x)}^2+\frac {3\,x+\frac {3}{2}}{x^2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

log(x)^2 + (3*x + 3/2)/x^2

________________________________________________________________________________________

sympy [A]  time = 0.12, size = 15, normalized size = 0.62 \begin {gather*} \log {\relax (x )}^{2} - \frac {- 6 x - 3}{2 x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x**2*ln(x)-3*x-3)/x**3,x)

[Out]

log(x)**2 - (-6*x - 3)/(2*x**2)

________________________________________________________________________________________