3.4.33 \(\int \frac {\log (1+x)}{x^2} \, dx\) [333]

Optimal. Leaf size=18 \[ \log (x)-\log (1+x)-\frac {\log (1+x)}{x} \]

[Out]

ln(x)-ln(1+x)-ln(1+x)/x

________________________________________________________________________________________

Rubi [A]
time = 0.01, antiderivative size = 18, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.500, Rules used = {2442, 36, 29, 31} \begin {gather*} \log (x)-\frac {\log (x+1)}{x}-\log (x+1) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Log[1 + x]/x^2,x]

[Out]

Log[x] - Log[1 + x] - Log[1 + x]/x

Rule 29

Int[(x_)^(-1), x_Symbol] :> Simp[Log[x], x]

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rule 36

Int[1/(((a_.) + (b_.)*(x_))*((c_.) + (d_.)*(x_))), x_Symbol] :> Dist[b/(b*c - a*d), Int[1/(a + b*x), x], x] -
Dist[d/(b*c - a*d), Int[1/(c + d*x), x], x] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0]

Rule 2442

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))*((f_.) + (g_.)*(x_))^(q_.), x_Symbol] :> Simp[(f + g*
x)^(q + 1)*((a + b*Log[c*(d + e*x)^n])/(g*(q + 1))), x] - Dist[b*e*(n/(g*(q + 1))), Int[(f + g*x)^(q + 1)/(d +
 e*x), x], x] /; FreeQ[{a, b, c, d, e, f, g, n, q}, x] && NeQ[e*f - d*g, 0] && NeQ[q, -1]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]
time = 0.00, size = 18, normalized size = 1.00 \begin {gather*} \log (x)-\log (1+x)-\frac {\log (1+x)}{x} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Log[1 + x]/x^2,x]

[Out]

Log[x] - Log[1 + x] - Log[1 + x]/x

________________________________________________________________________________________

Mathics [A]
time = 1.77, size = 18, normalized size = 1.00 \begin {gather*} -\frac {\text {Log}\left [1+x\right ]}{x}+\text {Log}\left [x\right ]-\text {Log}\left [1+x\right ] \end {gather*}

Antiderivative was successfully verified.

[In]

mathics('Integrate[Log[1 + x]/x^2,x]')

[Out]

-Log[1 + x] / x + Log[x] - Log[1 + x]

________________________________________________________________________________________

Maple [A]
time = 0.02, size = 16, normalized size = 0.89

method result size
derivativedivides \(\ln \left (x \right )-\frac {\ln \left (1+x \right ) \left (1+x \right )}{x}\) \(16\)
default \(\ln \left (x \right )-\frac {\ln \left (1+x \right ) \left (1+x \right )}{x}\) \(16\)
meijerg \(\ln \left (x \right )-\frac {\left (2+2 x \right ) \ln \left (1+x \right )}{2 x}\) \(18\)
risch \(\ln \left (x \right )-\ln \left (1+x \right )-\frac {\ln \left (1+x \right )}{x}\) \(19\)
norman \(\frac {-\ln \left (1+x \right ) x -\ln \left (1+x \right )}{x}+\ln \left (x \right )\) \(22\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/x^2*ln(1+x),x,method=_RETURNVERBOSE)

[Out]

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

________________________________________________________________________________________

Maxima [A]
time = 0.26, size = 18, normalized size = 1.00 \begin {gather*} -\frac {\log \left (x + 1\right )}{x} - \log \left (x + 1\right ) + \log \left (x\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-log(x + 1)/x - log(x + 1) + log(x)

________________________________________________________________________________________

Fricas [A]
time = 0.37, size = 19, normalized size = 1.06 \begin {gather*} -\frac {{\left (x + 1\right )} \log \left (x + 1\right ) - x \log \left (x\right )}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-((x + 1)*log(x + 1) - x*log(x))/x

________________________________________________________________________________________

Sympy [A]
time = 0.06, size = 14, normalized size = 0.78 \begin {gather*} \log {\left (x \right )} - \log {\left (x + 1 \right )} - \frac {\log {\left (x + 1 \right )}}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

log(x) - log(x + 1) - log(x + 1)/x

________________________________________________________________________________________

Giac [A]
time = 0.00, size = 18, normalized size = 1.00 \begin {gather*} \ln \left |x\right |-\ln \left |x+1\right |-\frac {\ln \left (1+x\right )}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(log(1+x)/x^2,x)

[Out]

-log(x + 1)/x - log(abs(x + 1)) + log(abs(x))

________________________________________________________________________________________

Mupad [B]
time = 0.17, size = 18, normalized size = 1.00 \begin {gather*} -\ln \left (\frac {1}{x}+1\right )-\frac {\ln \left (x+1\right )}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

- log(1/x + 1) - log(x + 1)/x

________________________________________________________________________________________