Optimal. Leaf size=30 \[ \frac {\left (2-x+\left (4+\frac {x}{4}\right ) x\right ) \left (\frac {1}{x^2}-\log \left (x+x^2\right )\right )}{x} \]
________________________________________________________________________________________
Rubi [B] time = 0.45, antiderivative size = 99, normalized size of antiderivative = 3.30, number of steps used = 13, number of rules used = 8, integrand size = 67, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.119, Rules used = {1593, 6742, 1620, 2513, 14, 2334, 2414, 894} \begin {gather*} \frac {2}{x^3}+\frac {3}{x^2}+\frac {1}{4 x}-\frac {1}{4} \left (x+\frac {8}{x}\right ) \log (x)-3 \log (x)-\frac {1}{4} x \log (x+1)-\frac {2 \log (x+1)}{x}-3 \log (x+1)+\frac {1}{4} x (\log (x)+\log (x+1)-\log (x (x+1)))+\frac {2 (\log (x)+\log (x+1)-\log (x (x+1)))}{x} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 14
Rule 894
Rule 1593
Rule 1620
Rule 2334
Rule 2414
Rule 2513
Rule 6742
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {-24-48 x-33 x^2-29 x^3-25 x^4-2 x^5+\left (8 x^2+8 x^3-x^4-x^5\right ) \log \left (x+x^2\right )}{x^4 (4+4 x)} \, dx\\ &=\int \left (\frac {-24-48 x-33 x^2-29 x^3-25 x^4-2 x^5}{4 x^4 (1+x)}-\frac {\left (-8+x^2\right ) \log (x (1+x))}{4 x^2}\right ) \, dx\\ &=\frac {1}{4} \int \frac {-24-48 x-33 x^2-29 x^3-25 x^4-2 x^5}{x^4 (1+x)} \, dx-\frac {1}{4} \int \frac {\left (-8+x^2\right ) \log (x (1+x))}{x^2} \, dx\\ &=\frac {1}{4} \int \left (-2-\frac {24}{x^4}-\frac {24}{x^3}-\frac {9}{x^2}-\frac {20}{x}-\frac {3}{1+x}\right ) \, dx-\frac {1}{4} \int \frac {\left (-8+x^2\right ) \log (x)}{x^2} \, dx-\frac {1}{4} \int \frac {\left (-8+x^2\right ) \log (1+x)}{x^2} \, dx-\frac {1}{4} (-\log (x)-\log (1+x)+\log (x (1+x))) \int \frac {-8+x^2}{x^2} \, dx\\ &=\frac {2}{x^3}+\frac {3}{x^2}+\frac {9}{4 x}-\frac {x}{2}-5 \log (x)-\frac {1}{4} \left (\frac {8}{x}+x\right ) \log (x)-\frac {3}{4} \log (1+x)-\frac {2 \log (1+x)}{x}-\frac {1}{4} x \log (1+x)+\frac {1}{4} \int \left (1+\frac {8}{x^2}\right ) \, dx+\frac {1}{4} \int \frac {8+x^2}{x (1+x)} \, dx-\frac {1}{4} (-\log (x)-\log (1+x)+\log (x (1+x))) \int \left (1-\frac {8}{x^2}\right ) \, dx\\ &=\frac {2}{x^3}+\frac {3}{x^2}+\frac {1}{4 x}-\frac {x}{4}-5 \log (x)-\frac {1}{4} \left (\frac {8}{x}+x\right ) \log (x)-\frac {3}{4} \log (1+x)-\frac {2 \log (1+x)}{x}-\frac {1}{4} x \log (1+x)+\frac {2 (\log (x)+\log (1+x)-\log (x (1+x)))}{x}+\frac {1}{4} x (\log (x)+\log (1+x)-\log (x (1+x)))+\frac {1}{4} \int \left (1+\frac {8}{x}-\frac {9}{1+x}\right ) \, dx\\ &=\frac {2}{x^3}+\frac {3}{x^2}+\frac {1}{4 x}-3 \log (x)-\frac {1}{4} \left (\frac {8}{x}+x\right ) \log (x)-3 \log (1+x)-\frac {2 \log (1+x)}{x}-\frac {1}{4} x \log (1+x)+\frac {2 (\log (x)+\log (1+x)-\log (x (1+x)))}{x}+\frac {1}{4} x (\log (x)+\log (1+x)-\log (x (1+x)))\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.08, size = 48, normalized size = 1.60 \begin {gather*} \frac {1}{4} \left (\frac {8}{x^3}+\frac {12}{x^2}+\frac {1}{x}-12 \log (x)-12 \log (1+x)-\frac {8 \log (x (1+x))}{x}-x \log (x (1+x))\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.80, size = 35, normalized size = 1.17 \begin {gather*} \frac {x^{2} - {\left (x^{4} + 12 \, x^{3} + 8 \, x^{2}\right )} \log \left (x^{2} + x\right ) + 12 \, x + 8}{4 \, x^{3}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.23, size = 39, normalized size = 1.30 \begin {gather*} -\frac {1}{4} \, {\left (x + \frac {8}{x}\right )} \log \left (x^{2} + x\right ) + \frac {x^{2} + 12 \, x + 8}{4 \, x^{3}} - 3 \, \log \left (x + 1\right ) - 3 \, \log \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.11, size = 44, normalized size = 1.47
method | result | size |
risch | \(-\frac {\left (x^{2}+8\right ) \ln \left (x^{2}+x \right )}{4 x}-\frac {12 \ln \left (x^{2}+x \right ) x^{3}-x^{2}-12 x -8}{4 x^{3}}\) | \(44\) |
default | \(-\frac {x \ln \left (x^{2}+x \right )}{4}-3 \ln \left (x +1\right )-\frac {2 \ln \left (x^{2}+x \right )}{x}+\frac {1}{4 x}-3 \ln \relax (x )+\frac {2}{x^{3}}+\frac {3}{x^{2}}\) | \(47\) |
norman | \(\frac {2-3 \ln \left (x^{2}+x \right ) x^{3}+3 x +\frac {x^{2}}{4}-2 x^{2} \ln \left (x^{2}+x \right )-\frac {\ln \left (x^{2}+x \right ) x^{4}}{4}}{x^{3}}\) | \(48\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [B] time = 0.39, size = 81, normalized size = 2.70 \begin {gather*} -\frac {1}{2} \, x + \frac {2 \, x^{2} - {\left (x^{2} + 9 \, x + 8\right )} \log \left (x + 1\right ) - {\left (x^{2} - 8 \, x + 8\right )} \log \relax (x) - 8}{4 \, x} - \frac {6 \, {\left (2 \, x - 1\right )}}{x^{2}} + \frac {33}{4 \, x} + \frac {6 \, x^{2} - 3 \, x + 2}{x^{3}} - \frac {3}{4} \, \log \left (x + 1\right ) - 5 \, \log \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 5.85, size = 42, normalized size = 1.40 \begin {gather*} \frac {3\,x-x^2\,\left (2\,\ln \left (x^2+x\right )-\frac {1}{4}\right )+2}{x^3}-3\,\ln \left (x\,\left (x+1\right )\right )-\frac {x\,\ln \left (x^2+x\right )}{4} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.22, size = 39, normalized size = 1.30 \begin {gather*} - 3 \log {\left (x^{2} + x \right )} + \frac {\left (- x^{2} - 8\right ) \log {\left (x^{2} + x \right )}}{4 x} - \frac {- x^{2} - 12 x - 8}{4 x^{3}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________