Optimal. Leaf size=30 \[ 3+\frac {x^2}{-3+e^x}+x \left (x+x^5\right )-(-x+\log (x))^2 \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.79, antiderivative size = 29, normalized size of antiderivative = 0.97, number of steps
used = 30, number of rules used = 14, integrand size = 100, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.140, Rules used =
{6820, 6874, 2215, 2221, 2317, 2438, 2611, 2320, 6724, 2216, 2222, 2388, 2338, 2332}
\begin {gather*} x^6-\frac {x^2}{3-e^x}-\log ^2(x)+2 x \log (x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2215
Rule 2216
Rule 2221
Rule 2222
Rule 2317
Rule 2320
Rule 2332
Rule 2338
Rule 2388
Rule 2438
Rule 2611
Rule 6724
Rule 6820
Rule 6874
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \left (\frac {e^{2 x} \left (2+6 x^5\right )+6 \left (3-x+9 x^5\right )-e^x \left (12-2 x+x^2+36 x^5\right )}{\left (-3+e^x\right )^2}+\frac {2 (-1+x) \log (x)}{x}\right ) \, dx\\ &=2 \int \frac {(-1+x) \log (x)}{x} \, dx+\int \frac {e^{2 x} \left (2+6 x^5\right )+6 \left (3-x+9 x^5\right )-e^x \left (12-2 x+x^2+36 x^5\right )}{\left (-3+e^x\right )^2} \, dx\\ &=2 \int \log (x) \, dx-2 \int \frac {\log (x)}{x} \, dx+\int \left (-\frac {(-2+x) x}{-3+e^x}-\frac {3 x^2}{\left (-3+e^x\right )^2}+2 \left (1+3 x^5\right )\right ) \, dx\\ &=-2 x+2 x \log (x)-\log ^2(x)+2 \int \left (1+3 x^5\right ) \, dx-3 \int \frac {x^2}{\left (-3+e^x\right )^2} \, dx-\int \frac {(-2+x) x}{-3+e^x} \, dx\\ &=x^6+2 x \log (x)-\log ^2(x)-\int \frac {e^x x^2}{\left (-3+e^x\right )^2} \, dx+\int \frac {x^2}{-3+e^x} \, dx-\int \left (-\frac {2 x}{-3+e^x}+\frac {x^2}{-3+e^x}\right ) \, dx\\ &=-\frac {x^2}{3-e^x}-\frac {x^3}{9}+x^6+2 x \log (x)-\log ^2(x)+\frac {1}{3} \int \frac {e^x x^2}{-3+e^x} \, dx-\int \frac {x^2}{-3+e^x} \, dx\\ &=-\frac {x^2}{3-e^x}+x^6+\frac {1}{3} x^2 \log \left (1-\frac {e^x}{3}\right )+2 x \log (x)-\log ^2(x)-\frac {1}{3} \int \frac {e^x x^2}{-3+e^x} \, dx-\frac {2}{3} \int x \log \left (1-\frac {e^x}{3}\right ) \, dx\\ &=-\frac {x^2}{3-e^x}+x^6+2 x \log (x)-\log ^2(x)+\frac {2}{3} x \text {Li}_2\left (\frac {e^x}{3}\right )+\frac {2}{3} \int x \log \left (1-\frac {e^x}{3}\right ) \, dx-\frac {2}{3} \int \text {Li}_2\left (\frac {e^x}{3}\right ) \, dx\\ &=-\frac {x^2}{3-e^x}+x^6+2 x \log (x)-\log ^2(x)+\frac {2}{3} \int \text {Li}_2\left (\frac {e^x}{3}\right ) \, dx-\frac {2}{3} \text {Subst}\left (\int \frac {\text {Li}_2\left (\frac {x}{3}\right )}{x} \, dx,x,e^x\right )\\ &=-\frac {x^2}{3-e^x}+x^6+2 x \log (x)-\log ^2(x)-\frac {2 \text {Li}_3\left (\frac {e^x}{3}\right )}{3}+\frac {2}{3} \text {Subst}\left (\int \frac {\text {Li}_2\left (\frac {x}{3}\right )}{x} \, dx,x,e^x\right )\\ &=-\frac {x^2}{3-e^x}+x^6+2 x \log (x)-\log ^2(x)\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A]
time = 1.43, size = 26, normalized size = 0.87 \begin {gather*} \frac {x^2}{-3+e^x}+x^6+2 x \log (x)-\log ^2(x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.07, size = 36, normalized size = 1.20
method | result | size |
risch | \(-\ln \left (x \right )^{2}+2 x \ln \left (x \right )+\frac {x^{2} \left ({\mathrm e}^{x} x^{4}-3 x^{4}+1\right )}{{\mathrm e}^{x}-3}\) | \(36\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 74 vs.
\(2 (29) = 58\).
time = 0.30, size = 74, normalized size = 2.47 \begin {gather*} -\frac {3 \, x^{6} - x^{2} - {\left (x^{6} + 2 \, x \log \left (x\right ) - \log \left (x\right )^{2} - 2 \, x\right )} e^{x} + 6 \, x \log \left (x\right ) - 3 \, \log \left (x\right )^{2} - 6 \, x - 6}{e^{x} - 3} + \frac {2 \, {\left (x e^{x} - 3 \, x - 3\right )}}{e^{x} - 3} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.45, size = 44, normalized size = 1.47 \begin {gather*} \frac {x^{6} e^{x} - 3 \, x^{6} - {\left (e^{x} - 3\right )} \log \left (x\right )^{2} + x^{2} + 2 \, {\left (x e^{x} - 3 \, x\right )} \log \left (x\right )}{e^{x} - 3} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 0.09, size = 22, normalized size = 0.73 \begin {gather*} x^{6} + \frac {x^{2}}{e^{x} - 3} + 2 x \log {\left (x \right )} - \log {\left (x \right )}^{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.42, size = 48, normalized size = 1.60 \begin {gather*} \frac {x^{6} e^{x} - 3 \, x^{6} + 2 \, x e^{x} \log \left (x\right ) - e^{x} \log \left (x\right )^{2} + x^{2} - 6 \, x \log \left (x\right ) + 3 \, \log \left (x\right )^{2}}{e^{x} - 3} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 9.31, size = 25, normalized size = 0.83 \begin {gather*} 2\,x\,\ln \left (x\right )-{\ln \left (x\right )}^2+\frac {x^2}{{\mathrm {e}}^x-3}+x^6 \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________