Optimal. Leaf size=20 \[ -\log ^2\left (x+x^2\right )+\log \left (4 e^x x \log (x)\right ) \]
________________________________________________________________________________________
Rubi [B] time = 0.53, antiderivative size = 47, normalized size of antiderivative = 2.35, number of steps used = 19, number of rules used = 11, integrand size = 40, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.275, Rules used = {1593, 6742, 43, 2302, 29, 2514, 2494, 2301, 2317, 2391, 2390} \begin {gather*} x+\log ^2(x)+\log ^2(x+1)+2 \log (x+1) \log (x)-2 \log (x (x+1)) \log (x)+\log (x)-2 \log (x+1) \log (x (x+1))+\log (\log (x)) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 29
Rule 43
Rule 1593
Rule 2301
Rule 2302
Rule 2317
Rule 2390
Rule 2391
Rule 2494
Rule 2514
Rule 6742
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {1+x+\left (1+2 x+x^2\right ) \log (x)+(-2-4 x) \log (x) \log \left (x+x^2\right )}{x (1+x) \log (x)} \, dx\\ &=\int \left (\frac {1+\log (x)+x \log (x)}{x \log (x)}-\frac {2 (1+2 x) \log (x (1+x))}{x (1+x)}\right ) \, dx\\ &=-\left (2 \int \frac {(1+2 x) \log (x (1+x))}{x (1+x)} \, dx\right )+\int \frac {1+\log (x)+x \log (x)}{x \log (x)} \, dx\\ &=-\left (2 \int \left (\frac {\log (x (1+x))}{x}+\frac {\log (x (1+x))}{1+x}\right ) \, dx\right )+\int \left (\frac {1+x}{x}+\frac {1}{x \log (x)}\right ) \, dx\\ &=-\left (2 \int \frac {\log (x (1+x))}{x} \, dx\right )-2 \int \frac {\log (x (1+x))}{1+x} \, dx+\int \frac {1+x}{x} \, dx+\int \frac {1}{x \log (x)} \, dx\\ &=-2 \log (x) \log (x (1+x))-2 \log (1+x) \log (x (1+x))+2 \int \frac {\log (x)}{x} \, dx+2 \int \frac {\log (x)}{1+x} \, dx+2 \int \frac {\log (1+x)}{x} \, dx+2 \int \frac {\log (1+x)}{1+x} \, dx+\int \left (1+\frac {1}{x}\right ) \, dx+\operatorname {Subst}\left (\int \frac {1}{x} \, dx,x,\log (x)\right )\\ &=x+\log (x)+\log ^2(x)+2 \log (x) \log (1+x)-2 \log (x) \log (x (1+x))-2 \log (1+x) \log (x (1+x))+\log (\log (x))-2 \text {Li}_2(-x)-2 \int \frac {\log (1+x)}{x} \, dx+2 \operatorname {Subst}\left (\int \frac {\log (x)}{x} \, dx,x,1+x\right )\\ &=x+\log (x)+\log ^2(x)+2 \log (x) \log (1+x)+\log ^2(1+x)-2 \log (x) \log (x (1+x))-2 \log (1+x) \log (x (1+x))+\log (\log (x))\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.08, size = 17, normalized size = 0.85 \begin {gather*} x+\log (x)-\log ^2(x (1+x))+\log (\log (x)) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.89, size = 17, normalized size = 0.85 \begin {gather*} -\log \left (x^{2} + x\right )^{2} + x + \log \relax (x) + \log \left (\log \relax (x)\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.27, size = 32, normalized size = 1.60 \begin {gather*} -2 \, {\left (\log \left (x + 1\right ) + \log \relax (x)\right )} \log \left (x + 1\right ) + \log \left (x + 1\right )^{2} - \log \relax (x)^{2} + x + \log \relax (x) + \log \left (\log \relax (x)\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.29, size = 28, normalized size = 1.40
method | result | size |
norman | \(x +\ln \left (x^{2}+x \right )-\ln \left (x^{2}+x \right )^{2}-\ln \left (x +1\right )+\ln \left (\ln \relax (x )\right )\) | \(28\) |
default | \(\ln \left (\ln \relax (x )\right )+x +\ln \relax (x )-2 \ln \relax (x ) \ln \left (x^{2}+x \right )+\ln \relax (x )^{2}+2 \ln \relax (x ) \ln \left (x +1\right )-2 \ln \left (x +1\right ) \ln \left (x^{2}+x \right )+\ln \left (x +1\right )^{2}\) | \(48\) |
risch | \(\ln \left (\ln \relax (x )\right )+x +i \pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i \left (x +1\right )\right ) \mathrm {csgn}\left (i x \left (x +1\right )\right ) \ln \relax (x )-i \pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x \left (x +1\right )\right )^{2} \ln \relax (x )-i \pi \,\mathrm {csgn}\left (i \left (x +1\right )\right ) \mathrm {csgn}\left (i x \left (x +1\right )\right )^{2} \ln \relax (x )+i \pi \mathrm {csgn}\left (i x \left (x +1\right )\right )^{3} \ln \relax (x )+\ln \relax (x )+i \pi \ln \left (x +1\right ) \mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i \left (x +1\right )\right ) \mathrm {csgn}\left (i x \left (x +1\right )\right )-i \pi \ln \left (x +1\right ) \mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x \left (x +1\right )\right )^{2}-i \pi \ln \left (x +1\right ) \mathrm {csgn}\left (i \left (x +1\right )\right ) \mathrm {csgn}\left (i x \left (x +1\right )\right )^{2}+i \pi \ln \left (x +1\right ) \mathrm {csgn}\left (i x \left (x +1\right )\right )^{3}-\ln \relax (x )^{2}-2 \ln \relax (x ) \ln \left (x +1\right )-\ln \left (x +1\right )^{2}\) | \(210\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.48, size = 29, normalized size = 1.45 \begin {gather*} -\log \left (x + 1\right )^{2} - 2 \, \log \left (x + 1\right ) \log \relax (x) - \log \relax (x)^{2} + x + \log \relax (x) + \log \left (\log \relax (x)\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.66, size = 17, normalized size = 0.85 \begin {gather*} -{\ln \left (x^2+x\right )}^2+x+\ln \left (\ln \relax (x)\right )+\ln \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.36, size = 17, normalized size = 0.85 \begin {gather*} x + \log {\relax (x )} - \log {\left (x^{2} + x \right )}^{2} + \log {\left (\log {\relax (x )} \right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________