3.58.72 \(\int \frac {e^{-x} (-54 x^2+6 x^4+e^x (36+42 x+4 x^2)+e^x (-36 x-12 x^2) \log (3 x+x^2))}{9+3 x} \, dx\)

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

________________________________________________________________________________________

Rubi [A]  time = 0.48, antiderivative size = 32, normalized size of antiderivative = 1.19, number of steps used = 17, number of rules used = 8, integrand size = 59, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.136, Rules used = {6688, 2196, 2176, 2194, 698, 2495, 30, 43} \begin {gather*} -2 e^{-x} x^3+\frac {8 x^2}{3}-2 x^2 \log (x (x+3))+4 x \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-54*x^2 + 6*x^4 + E^x*(36 + 42*x + 4*x^2) + E^x*(-36*x - 12*x^2)*Log[3*x + x^2])/(E^x*(9 + 3*x)),x]

[Out]

4*x + (8*x^2)/3 - (2*x^3)/E^x - 2*x^2*Log[x*(3 + x)]

Rule 30

Int[(x_)^(m_.), x_Symbol] :> Simp[x^(m + 1)/(m + 1), x] /; FreeQ[m, x] && NeQ[m, -1]

Rule 43

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rule 698

Int[((d_.) + (e_.)*(x_))^(m_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ExpandIntegrand[(d +
 e*x)^m*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, m}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - b*d*
e + a*e^2, 0] && NeQ[2*c*d - b*e, 0] && IntegerQ[p] && (GtQ[p, 0] || (EqQ[a, 0] && IntegerQ[m]))

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 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 2495

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

Rule 6688

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

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \left (2 e^{-x} (-3+x) x^2+\frac {36+42 x+4 x^2}{9+3 x}-4 x \log (x (3+x))\right ) \, dx\\ &=2 \int e^{-x} (-3+x) x^2 \, dx-4 \int x \log (x (3+x)) \, dx+\int \frac {36+42 x+4 x^2}{9+3 x} \, dx\\ &=-2 x^2 \log (x (3+x))+2 \int x \, dx+2 \int \frac {x^2}{3+x} \, dx+2 \int \left (-3 e^{-x} x^2+e^{-x} x^3\right ) \, dx+\int \left (10+\frac {4 x}{3}-\frac {18}{3+x}\right ) \, dx\\ &=10 x+\frac {5 x^2}{3}-18 \log (3+x)-2 x^2 \log (x (3+x))+2 \int e^{-x} x^3 \, dx+2 \int \left (-3+x+\frac {9}{3+x}\right ) \, dx-6 \int e^{-x} x^2 \, dx\\ &=4 x+\frac {8 x^2}{3}+6 e^{-x} x^2-2 e^{-x} x^3-2 x^2 \log (x (3+x))+6 \int e^{-x} x^2 \, dx-12 \int e^{-x} x \, dx\\ &=4 x+12 e^{-x} x+\frac {8 x^2}{3}-2 e^{-x} x^3-2 x^2 \log (x (3+x))-12 \int e^{-x} \, dx+12 \int e^{-x} x \, dx\\ &=12 e^{-x}+4 x+\frac {8 x^2}{3}-2 e^{-x} x^3-2 x^2 \log (x (3+x))+12 \int e^{-x} \, dx\\ &=4 x+\frac {8 x^2}{3}-2 e^{-x} x^3-2 x^2 \log (x (3+x))\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.08, size = 37, normalized size = 1.37 \begin {gather*} 24+4 x+\frac {8 x^2}{3}-2 e^{-x} x^3-\log (387420489)-2 x^2 \log (x (3+x)) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-54*x^2 + 6*x^4 + E^x*(36 + 42*x + 4*x^2) + E^x*(-36*x - 12*x^2)*Log[3*x + x^2])/(E^x*(9 + 3*x)),x]

[Out]

24 + 4*x + (8*x^2)/3 - (2*x^3)/E^x - Log[387420489] - 2*x^2*Log[x*(3 + x)]

________________________________________________________________________________________

fricas [A]  time = 0.71, size = 40, normalized size = 1.48 \begin {gather*} -\frac {2}{3} \, {\left (3 \, x^{2} e^{x} \log \left (x^{2} + 3 \, x\right ) + 3 \, x^{3} - 2 \, {\left (2 \, x^{2} + 3 \, x\right )} e^{x}\right )} e^{\left (-x\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-12*x^2-36*x)*exp(x)*log(x^2+3*x)+(4*x^2+42*x+36)*exp(x)+6*x^4-54*x^2)/(3*x+9)/exp(x),x, algorithm
="fricas")

[Out]

-2/3*(3*x^2*e^x*log(x^2 + 3*x) + 3*x^3 - 2*(2*x^2 + 3*x)*e^x)*e^(-x)

________________________________________________________________________________________

giac [A]  time = 0.14, size = 31, normalized size = 1.15 \begin {gather*} -2 \, x^{3} e^{\left (-x\right )} - 2 \, x^{2} \log \left (x^{2} + 3 \, x\right ) + \frac {8}{3} \, x^{2} + 4 \, x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-12*x^2-36*x)*exp(x)*log(x^2+3*x)+(4*x^2+42*x+36)*exp(x)+6*x^4-54*x^2)/(3*x+9)/exp(x),x, algorithm
="giac")

[Out]

-2*x^3*e^(-x) - 2*x^2*log(x^2 + 3*x) + 8/3*x^2 + 4*x

________________________________________________________________________________________

maple [A]  time = 0.34, size = 32, normalized size = 1.19




method result size



default \(-2 x^{2} \ln \left (x^{2}+3 x \right )+\frac {8 x^{2}}{3}+4 x -2 x^{3} {\mathrm e}^{-x}\) \(32\)
norman \(\left (-2 x^{3}+4 \,{\mathrm e}^{x} x +\frac {8 \,{\mathrm e}^{x} x^{2}}{3}-2 \,{\mathrm e}^{x} \ln \left (x^{2}+3 x \right ) x^{2}\right ) {\mathrm e}^{-x}\) \(39\)
risch \(-2 \ln \left (3+x \right ) x^{2}-\frac {x \left (-3 i \pi x \mathrm {csgn}\left (i x \left (3+x \right )\right )^{3} {\mathrm e}^{x}+3 i \pi x \mathrm {csgn}\left (i x \left (3+x \right )\right )^{2} \mathrm {csgn}\left (i x \right ) {\mathrm e}^{x}+3 i \pi x \mathrm {csgn}\left (i x \left (3+x \right )\right )^{2} \mathrm {csgn}\left (i \left (3+x \right )\right ) {\mathrm e}^{x}-3 i \pi x \,\mathrm {csgn}\left (i x \left (3+x \right )\right ) \mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i \left (3+x \right )\right ) {\mathrm e}^{x}+6 x \,{\mathrm e}^{x} \ln \relax (x )+6 x^{2}-8 \,{\mathrm e}^{x} x -12 \,{\mathrm e}^{x}\right ) {\mathrm e}^{-x}}{3}\) \(130\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((-12*x^2-36*x)*exp(x)*ln(x^2+3*x)+(4*x^2+42*x+36)*exp(x)+6*x^4-54*x^2)/(3*x+9)/exp(x),x,method=_RETURNVER
BOSE)

[Out]

-2*x^2*ln(x^2+3*x)+8/3*x^2+4*x-2*x^3/exp(x)

________________________________________________________________________________________

maxima [A]  time = 0.41, size = 34, normalized size = 1.26 \begin {gather*} -2 \, x^{3} e^{\left (-x\right )} - 2 \, x^{2} \log \left (x + 3\right ) - 2 \, x^{2} \log \relax (x) + \frac {8}{3} \, x^{2} + 4 \, x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-12*x^2-36*x)*exp(x)*log(x^2+3*x)+(4*x^2+42*x+36)*exp(x)+6*x^4-54*x^2)/(3*x+9)/exp(x),x, algorithm
="maxima")

[Out]

-2*x^3*e^(-x) - 2*x^2*log(x + 3) - 2*x^2*log(x) + 8/3*x^2 + 4*x

________________________________________________________________________________________

mupad [B]  time = 4.42, size = 31, normalized size = 1.15 \begin {gather*} 4\,x-2\,x^3\,{\mathrm {e}}^{-x}-2\,x^2\,\ln \left (x^2+3\,x\right )+\frac {8\,x^2}{3} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((exp(-x)*(exp(x)*(42*x + 4*x^2 + 36) - 54*x^2 + 6*x^4 - exp(x)*log(3*x + x^2)*(36*x + 12*x^2)))/(3*x + 9),
x)

[Out]

4*x - 2*x^3*exp(-x) - 2*x^2*log(3*x + x^2) + (8*x^2)/3

________________________________________________________________________________________

sympy [A]  time = 0.38, size = 31, normalized size = 1.15 \begin {gather*} - 2 x^{3} e^{- x} - 2 x^{2} \log {\left (x^{2} + 3 x \right )} + \frac {8 x^{2}}{3} + 4 x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-12*x**2-36*x)*exp(x)*ln(x**2+3*x)+(4*x**2+42*x+36)*exp(x)+6*x**4-54*x**2)/(3*x+9)/exp(x),x)

[Out]

-2*x**3*exp(-x) - 2*x**2*log(x**2 + 3*x) + 8*x**2/3 + 4*x

________________________________________________________________________________________