3.31.60 \(\int \frac {-10 x-6 x^2+28 x^3+38 x^4+18 x^5+4 x^6+e^{2 x} (2 x^4+2 x^5)+e^x (-2 x^2+10 x^3+22 x^4+12 x^5+2 x^6)+(2+10 x-2 x^3-2 e^x x^3) \log (x)-2 \log ^2(x)}{x^3} \, dx\)

Optimal. Leaf size=26 \[ 7+\left (6+3 x+e^x x+x^2-\frac {x+\log (x)}{x}\right )^2 \]

________________________________________________________________________________________

Rubi [B]  time = 0.53, antiderivative size = 90, normalized size of antiderivative = 3.46, number of steps used = 38, number of rules used = 14, integrand size = 107, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.131, Rules used = {14, 2196, 2176, 2194, 6742, 2199, 2178, 2554, 1583, 1620, 2357, 2295, 2304, 2305} \begin {gather*} x^4+2 e^x x^3+\frac {8 x^3}{3}+6 e^x x^2+e^{2 x} x^2+9 x^2+\frac {\log ^2(x)}{x^2}+10 e^x x+20 x+\frac {10}{3} (x+1)^3-2 x \log (x)-2 e^x \log (x)-6 \log (x)-\frac {10 \log (x)}{x} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-10*x - 6*x^2 + 28*x^3 + 38*x^4 + 18*x^5 + 4*x^6 + E^(2*x)*(2*x^4 + 2*x^5) + E^x*(-2*x^2 + 10*x^3 + 22*x^
4 + 12*x^5 + 2*x^6) + (2 + 10*x - 2*x^3 - 2*E^x*x^3)*Log[x] - 2*Log[x]^2)/x^3,x]

[Out]

20*x + 10*E^x*x + 9*x^2 + 6*E^x*x^2 + E^(2*x)*x^2 + (8*x^3)/3 + 2*E^x*x^3 + x^4 + (10*(1 + x)^3)/3 - 6*Log[x]
- 2*E^x*Log[x] - (10*Log[x])/x - 2*x*Log[x] + Log[x]^2/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 1583

Int[(Px_)*(x_)^(m_.)*((a_) + (b_.)*(x_)^(n_.))^(p_), x_Symbol] :> Simp[(Coeff[Px, x, n - m - 1]*(a + b*x^n)^(p
 + 1))/(b*n*(p + 1)), x] + Int[(Px - Coeff[Px, x, n - m - 1]*x^(n - m - 1))*x^m*(a + b*x^n)^p, x] /; FreeQ[{a,
 b, m, n}, x] && PolyQ[Px, x] && IGtQ[p, 1] && IGtQ[n - m, 0] && NeQ[Coeff[Px, x, n - m - 1], 0]

Rule 1620

Int[(Px_)*((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[Px*(a + b*x)
^m*(c + d*x)^n, x], x] /; FreeQ[{a, b, c, d, m, n}, x] && PolyQ[Px, x] && (IntegersQ[m, n] || IGtQ[m, -2]) &&
GtQ[Expon[Px, x], 2]

Rule 2176

Int[((b_.)*(F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[((c + d*x)^m
*(b*F^(g*(e + f*x)))^n)/(f*g*n*Log[F]), x] - Dist[(d*m)/(f*g*n*Log[F]), Int[(c + d*x)^(m - 1)*(b*F^(g*(e + f*x
)))^n, x], x] /; FreeQ[{F, b, c, d, e, f, g, n}, x] && GtQ[m, 0] && IntegerQ[2*m] &&  !$UseGamma === True

Rule 2178

Int[(F_)^((g_.)*((e_.) + (f_.)*(x_)))/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[(F^(g*(e - (c*f)/d))*ExpIntegral
Ei[(f*g*(c + d*x)*Log[F])/d])/d, x] /; FreeQ[{F, c, d, e, f, g}, x] &&  !$UseGamma === True

Rule 2194

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

Rule 2196

Int[(F_)^((c_.)*(v_))*(u_), x_Symbol] :> Int[ExpandIntegrand[F^(c*ExpandToSum[v, x]), u, x], x] /; FreeQ[{F, c
}, x] && PolynomialQ[u, x] && LinearQ[v, x] &&  !$UseGamma === True

Rule 2199

Int[(F_)^((c_.)*(v_))*(u_)^(m_.)*(w_), x_Symbol] :> Int[ExpandIntegrand[F^(c*ExpandToSum[v, x]), w*NormalizePo
werOfLinear[u, x]^m, x], x] /; FreeQ[{F, c}, x] && PolynomialQ[w, x] && LinearQ[v, x] && PowerOfLinearQ[u, x]
&& IntegerQ[m] &&  !$UseGamma === True

Rule 2295

Int[Log[(c_.)*(x_)^(n_.)], x_Symbol] :> Simp[x*Log[c*x^n], x] - Simp[n*x, x] /; FreeQ[{c, n}, x]

Rule 2304

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

Rule 2305

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

Rule 2357

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*(RFx_), x_Symbol] :> With[{u = ExpandIntegrand[(a + b*Log[c*x^
n])^p, RFx, x]}, Int[u, x] /; SumQ[u]] /; FreeQ[{a, b, c, n}, x] && RationalFunctionQ[RFx, x] && IGtQ[p, 0]

Rule 2554

Int[Log[u_]*(v_), x_Symbol] :> With[{w = IntHide[v, x]}, Dist[Log[u], w, x] - Int[SimplifyIntegrand[(w*D[u, x]
)/u, x], x] /; InverseFunctionFreeQ[w, x]] /; InverseFunctionFreeQ[u, x]

Rule 6742

Int[u_, x_Symbol] :> With[{v = ExpandIntegrand[u, x]}, Int[v, x] /; SumQ[v]]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \left (2 e^{2 x} x (1+x)+\frac {2 e^x \left (-1+5 x+11 x^2+6 x^3+x^4-x \log (x)\right )}{x}+\frac {2 \left (-5 x-3 x^2+14 x^3+19 x^4+9 x^5+2 x^6+\log (x)+5 x \log (x)-x^3 \log (x)-\log ^2(x)\right )}{x^3}\right ) \, dx\\ &=2 \int e^{2 x} x (1+x) \, dx+2 \int \frac {e^x \left (-1+5 x+11 x^2+6 x^3+x^4-x \log (x)\right )}{x} \, dx+2 \int \frac {-5 x-3 x^2+14 x^3+19 x^4+9 x^5+2 x^6+\log (x)+5 x \log (x)-x^3 \log (x)-\log ^2(x)}{x^3} \, dx\\ &=2 \int \left (e^{2 x} x+e^{2 x} x^2\right ) \, dx+2 \int \left (\frac {e^x \left (-1+5 x+11 x^2+6 x^3+x^4\right )}{x}-e^x \log (x)\right ) \, dx+2 \int \left (\frac {(1+x)^2 \left (-5+7 x+5 x^2+2 x^3\right )}{x^2}-\frac {\left (-1-5 x+x^3\right ) \log (x)}{x^3}-\frac {\log ^2(x)}{x^3}\right ) \, dx\\ &=2 \int e^{2 x} x \, dx+2 \int e^{2 x} x^2 \, dx+2 \int \frac {(1+x)^2 \left (-5+7 x+5 x^2+2 x^3\right )}{x^2} \, dx+2 \int \frac {e^x \left (-1+5 x+11 x^2+6 x^3+x^4\right )}{x} \, dx-2 \int e^x \log (x) \, dx-2 \int \frac {\left (-1-5 x+x^3\right ) \log (x)}{x^3} \, dx-2 \int \frac {\log ^2(x)}{x^3} \, dx\\ &=e^{2 x} x+e^{2 x} x^2+\frac {10}{3} (1+x)^3-2 e^x \log (x)+\frac {\log ^2(x)}{x^2}+2 \int \frac {e^x}{x} \, dx-2 \int e^{2 x} x \, dx+2 \int \frac {(1+x)^2 \left (-5+7 x+2 x^3\right )}{x^2} \, dx+2 \int \left (5 e^x-\frac {e^x}{x}+11 e^x x+6 e^x x^2+e^x x^3\right ) \, dx-2 \int \frac {\log (x)}{x^3} \, dx-2 \int \left (\log (x)-\frac {\log (x)}{x^3}-\frac {5 \log (x)}{x^2}\right ) \, dx-\int e^{2 x} \, dx\\ &=-\frac {e^{2 x}}{2}+\frac {1}{2 x^2}+e^{2 x} x^2+\frac {10}{3} (1+x)^3+2 \text {Ei}(x)-2 e^x \log (x)+\frac {\log (x)}{x^2}+\frac {\log ^2(x)}{x^2}-2 \int \frac {e^x}{x} \, dx+2 \int e^x x^3 \, dx+2 \int \left (9-\frac {5}{x^2}-\frac {3}{x}+9 x+4 x^2+2 x^3\right ) \, dx-2 \int \log (x) \, dx+2 \int \frac {\log (x)}{x^3} \, dx+10 \int e^x \, dx+10 \int \frac {\log (x)}{x^2} \, dx+12 \int e^x x^2 \, dx+22 \int e^x x \, dx+\int e^{2 x} \, dx\\ &=10 e^x+20 x+22 e^x x+9 x^2+12 e^x x^2+e^{2 x} x^2+\frac {8 x^3}{3}+2 e^x x^3+x^4+\frac {10}{3} (1+x)^3-6 \log (x)-2 e^x \log (x)-\frac {10 \log (x)}{x}-2 x \log (x)+\frac {\log ^2(x)}{x^2}-6 \int e^x x^2 \, dx-22 \int e^x \, dx-24 \int e^x x \, dx\\ &=-12 e^x+20 x-2 e^x x+9 x^2+6 e^x x^2+e^{2 x} x^2+\frac {8 x^3}{3}+2 e^x x^3+x^4+\frac {10}{3} (1+x)^3-6 \log (x)-2 e^x \log (x)-\frac {10 \log (x)}{x}-2 x \log (x)+\frac {\log ^2(x)}{x^2}+12 \int e^x x \, dx+24 \int e^x \, dx\\ &=12 e^x+20 x+10 e^x x+9 x^2+6 e^x x^2+e^{2 x} x^2+\frac {8 x^3}{3}+2 e^x x^3+x^4+\frac {10}{3} (1+x)^3-6 \log (x)-2 e^x \log (x)-\frac {10 \log (x)}{x}-2 x \log (x)+\frac {\log ^2(x)}{x^2}-12 \int e^x \, dx\\ &=20 x+10 e^x x+9 x^2+6 e^x x^2+e^{2 x} x^2+\frac {8 x^3}{3}+2 e^x x^3+x^4+\frac {10}{3} (1+x)^3-6 \log (x)-2 e^x \log (x)-\frac {10 \log (x)}{x}-2 x \log (x)+\frac {\log ^2(x)}{x^2}\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [B]  time = 0.10, size = 63, normalized size = 2.42 \begin {gather*} \frac {x^3 \left (30+19 x+e^{2 x} x+6 x^2+x^3+2 e^x \left (5+3 x+x^2\right )\right )-2 x \left (5+\left (3+e^x\right ) x+x^2\right ) \log (x)+\log ^2(x)}{x^2} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-10*x - 6*x^2 + 28*x^3 + 38*x^4 + 18*x^5 + 4*x^6 + E^(2*x)*(2*x^4 + 2*x^5) + E^x*(-2*x^2 + 10*x^3 +
 22*x^4 + 12*x^5 + 2*x^6) + (2 + 10*x - 2*x^3 - 2*E^x*x^3)*Log[x] - 2*Log[x]^2)/x^3,x]

[Out]

(x^3*(30 + 19*x + E^(2*x)*x + 6*x^2 + x^3 + 2*E^x*(5 + 3*x + x^2)) - 2*x*(5 + (3 + E^x)*x + x^2)*Log[x] + Log[
x]^2)/x^2

________________________________________________________________________________________

fricas [B]  time = 0.57, size = 75, normalized size = 2.88 \begin {gather*} \frac {x^{6} + 6 \, x^{5} + x^{4} e^{\left (2 \, x\right )} + 19 \, x^{4} + 30 \, x^{3} + 2 \, {\left (x^{5} + 3 \, x^{4} + 5 \, x^{3}\right )} e^{x} - 2 \, {\left (x^{3} + x^{2} e^{x} + 3 \, x^{2} + 5 \, x\right )} \log \relax (x) + \log \relax (x)^{2}}{x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*log(x)^2+(-2*exp(x)*x^3-2*x^3+10*x+2)*log(x)+(2*x^5+2*x^4)*exp(x)^2+(2*x^6+12*x^5+22*x^4+10*x^3-
2*x^2)*exp(x)+4*x^6+18*x^5+38*x^4+28*x^3-6*x^2-10*x)/x^3,x, algorithm="fricas")

[Out]

(x^6 + 6*x^5 + x^4*e^(2*x) + 19*x^4 + 30*x^3 + 2*(x^5 + 3*x^4 + 5*x^3)*e^x - 2*(x^3 + x^2*e^x + 3*x^2 + 5*x)*l
og(x) + log(x)^2)/x^2

________________________________________________________________________________________

giac [B]  time = 0.23, size = 84, normalized size = 3.23 \begin {gather*} \frac {x^{6} + 2 \, x^{5} e^{x} + 6 \, x^{5} + x^{4} e^{\left (2 \, x\right )} + 6 \, x^{4} e^{x} + 19 \, x^{4} + 10 \, x^{3} e^{x} - 2 \, x^{3} \log \relax (x) - 2 \, x^{2} e^{x} \log \relax (x) + 30 \, x^{3} - 6 \, x^{2} \log \relax (x) - 10 \, x \log \relax (x) + \log \relax (x)^{2}}{x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*log(x)^2+(-2*exp(x)*x^3-2*x^3+10*x+2)*log(x)+(2*x^5+2*x^4)*exp(x)^2+(2*x^6+12*x^5+22*x^4+10*x^3-
2*x^2)*exp(x)+4*x^6+18*x^5+38*x^4+28*x^3-6*x^2-10*x)/x^3,x, algorithm="giac")

[Out]

(x^6 + 2*x^5*e^x + 6*x^5 + x^4*e^(2*x) + 6*x^4*e^x + 19*x^4 + 10*x^3*e^x - 2*x^3*log(x) - 2*x^2*e^x*log(x) + 3
0*x^3 - 6*x^2*log(x) - 10*x*log(x) + log(x)^2)/x^2

________________________________________________________________________________________

maple [B]  time = 0.05, size = 73, normalized size = 2.81




method result size



risch \(\frac {\ln \relax (x )^{2}}{x^{2}}-\frac {2 \left (x^{2}+{\mathrm e}^{x} x +5\right ) \ln \relax (x )}{x}+x^{4}+2 \,{\mathrm e}^{x} x^{3}+{\mathrm e}^{2 x} x^{2}+6 x^{3}+6 \,{\mathrm e}^{x} x^{2}+19 x^{2}+10 \,{\mathrm e}^{x} x -6 \ln \relax (x )+30 x\) \(73\)
default \(10 \,{\mathrm e}^{x} x +6 \,{\mathrm e}^{x} x^{2}+2 \,{\mathrm e}^{x} x^{3}-2 \,{\mathrm e}^{x} \ln \relax (x )+\frac {\ln \relax (x )^{2}}{x^{2}}+x^{4}+6 x^{3}+19 x^{2}+30 x -6 \ln \relax (x )+{\mathrm e}^{2 x} x^{2}-2 x \ln \relax (x )-\frac {10 \ln \relax (x )}{x}\) \(75\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((-2*ln(x)^2+(-2*exp(x)*x^3-2*x^3+10*x+2)*ln(x)+(2*x^5+2*x^4)*exp(x)^2+(2*x^6+12*x^5+22*x^4+10*x^3-2*x^2)*e
xp(x)+4*x^6+18*x^5+38*x^4+28*x^3-6*x^2-10*x)/x^3,x,method=_RETURNVERBOSE)

[Out]

ln(x)^2/x^2-2*(x^2+exp(x)*x+5)/x*ln(x)+x^4+2*exp(x)*x^3+exp(2*x)*x^2+6*x^3+6*exp(x)*x^2+19*x^2+10*exp(x)*x-6*l
n(x)+30*x

________________________________________________________________________________________

maxima [B]  time = 0.63, size = 135, normalized size = 5.19 \begin {gather*} x^{4} + 6 \, x^{3} + 19 \, x^{2} + \frac {1}{2} \, {\left (2 \, x^{2} - 2 \, x + 1\right )} e^{\left (2 \, x\right )} + \frac {1}{2} \, {\left (2 \, x - 1\right )} e^{\left (2 \, x\right )} + 2 \, {\left (x^{3} - 3 \, x^{2} + 6 \, x - 6\right )} e^{x} + 12 \, {\left (x^{2} - 2 \, x + 2\right )} e^{x} + 22 \, {\left (x - 1\right )} e^{x} - 2 \, x \log \relax (x) - 2 \, e^{x} \log \relax (x) + 30 \, x - \frac {10 \, \log \relax (x)}{x} + \frac {2 \, \log \relax (x)^{2} + 2 \, \log \relax (x) + 1}{2 \, x^{2}} - \frac {\log \relax (x)}{x^{2}} - \frac {1}{2 \, x^{2}} + 10 \, e^{x} - 6 \, \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*log(x)^2+(-2*exp(x)*x^3-2*x^3+10*x+2)*log(x)+(2*x^5+2*x^4)*exp(x)^2+(2*x^6+12*x^5+22*x^4+10*x^3-
2*x^2)*exp(x)+4*x^6+18*x^5+38*x^4+28*x^3-6*x^2-10*x)/x^3,x, algorithm="maxima")

[Out]

x^4 + 6*x^3 + 19*x^2 + 1/2*(2*x^2 - 2*x + 1)*e^(2*x) + 1/2*(2*x - 1)*e^(2*x) + 2*(x^3 - 3*x^2 + 6*x - 6)*e^x +
 12*(x^2 - 2*x + 2)*e^x + 22*(x - 1)*e^x - 2*x*log(x) - 2*e^x*log(x) + 30*x - 10*log(x)/x + 1/2*(2*log(x)^2 +
2*log(x) + 1)/x^2 - log(x)/x^2 - 1/2/x^2 + 10*e^x - 6*log(x)

________________________________________________________________________________________

mupad [B]  time = 2.02, size = 78, normalized size = 3.00 \begin {gather*} 30\,x-6\,\ln \relax (x)+x^2\,{\mathrm {e}}^{2\,x}+\frac {{\ln \relax (x)}^2}{x^2}-\ln \relax (x)\,\left (4\,x+2\,{\mathrm {e}}^x-\frac {2\,x^2-10}{x}\right )+19\,x^2+6\,x^3+x^4+{\mathrm {e}}^x\,\left (2\,x^3+6\,x^2+10\,x\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((exp(2*x)*(2*x^4 + 2*x^5) - 2*log(x)^2 - 10*x + exp(x)*(10*x^3 - 2*x^2 + 22*x^4 + 12*x^5 + 2*x^6) + log(x)
*(10*x - 2*x^3*exp(x) - 2*x^3 + 2) - 6*x^2 + 28*x^3 + 38*x^4 + 18*x^5 + 4*x^6)/x^3,x)

[Out]

30*x - 6*log(x) + x^2*exp(2*x) + log(x)^2/x^2 - log(x)*(4*x + 2*exp(x) - (2*x^2 - 10)/x) + 19*x^2 + 6*x^3 + x^
4 + exp(x)*(10*x + 6*x^2 + 2*x^3)

________________________________________________________________________________________

sympy [B]  time = 0.47, size = 73, normalized size = 2.81 \begin {gather*} x^{4} + 6 x^{3} + x^{2} e^{2 x} + 19 x^{2} + 30 x + \left (2 x^{3} + 6 x^{2} + 10 x - 2 \log {\relax (x )}\right ) e^{x} - 6 \log {\relax (x )} + \frac {\left (- 2 x^{2} - 10\right ) \log {\relax (x )}}{x} + \frac {\log {\relax (x )}^{2}}{x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*ln(x)**2+(-2*exp(x)*x**3-2*x**3+10*x+2)*ln(x)+(2*x**5+2*x**4)*exp(x)**2+(2*x**6+12*x**5+22*x**4+
10*x**3-2*x**2)*exp(x)+4*x**6+18*x**5+38*x**4+28*x**3-6*x**2-10*x)/x**3,x)

[Out]

x**4 + 6*x**3 + x**2*exp(2*x) + 19*x**2 + 30*x + (2*x**3 + 6*x**2 + 10*x - 2*log(x))*exp(x) - 6*log(x) + (-2*x
**2 - 10)*log(x)/x + log(x)**2/x**2

________________________________________________________________________________________