3.72.3 \(\int \frac {x-2 e^x x+2 e^{-x} x (3-3 x-15 x^2+5 x^3+e^x (3-15 x^2))}{x} \, dx\)

Optimal. Leaf size=25 \[ x+\left (1+e^x\right ) \left (-2+2 e^{-x} x \left (3-5 x^2\right )\right ) \]

________________________________________________________________________________________

Rubi [A]  time = 0.12, antiderivative size = 32, normalized size of antiderivative = 1.28, number of steps used = 15, number of rules used = 4, integrand size = 46, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.087, Rules used = {14, 2194, 2196, 2176} \begin {gather*} -10 e^{-x} x^3-10 x^3+6 e^{-x} x+7 x-2 e^x \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(x - 2*E^x*x + (2*x*(3 - 3*x - 15*x^2 + 5*x^3 + E^x*(3 - 15*x^2)))/E^x)/x,x]

[Out]

-2*E^x + 7*x + (6*x)/E^x - 10*x^3 - (10*x^3)/E^x

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

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \left (7-2 e^x-30 x^2+2 e^{-x} \left (3-3 x-15 x^2+5 x^3\right )\right ) \, dx\\ &=7 x-10 x^3-2 \int e^x \, dx+2 \int e^{-x} \left (3-3 x-15 x^2+5 x^3\right ) \, dx\\ &=-2 e^x+7 x-10 x^3+2 \int \left (3 e^{-x}-3 e^{-x} x-15 e^{-x} x^2+5 e^{-x} x^3\right ) \, dx\\ &=-2 e^x+7 x-10 x^3+6 \int e^{-x} \, dx-6 \int e^{-x} x \, dx+10 \int e^{-x} x^3 \, dx-30 \int e^{-x} x^2 \, dx\\ &=-6 e^{-x}-2 e^x+7 x+6 e^{-x} x+30 e^{-x} x^2-10 x^3-10 e^{-x} x^3-6 \int e^{-x} \, dx+30 \int e^{-x} x^2 \, dx-60 \int e^{-x} x \, dx\\ &=-2 e^x+7 x+66 e^{-x} x-10 x^3-10 e^{-x} x^3-60 \int e^{-x} \, dx+60 \int e^{-x} x \, dx\\ &=60 e^{-x}-2 e^x+7 x+6 e^{-x} x-10 x^3-10 e^{-x} x^3+60 \int e^{-x} \, dx\\ &=-2 e^x+7 x+6 e^{-x} x-10 x^3-10 e^{-x} x^3\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.15, size = 30, normalized size = 1.20 \begin {gather*} -2 e^x+7 x-10 x^3+2 e^{-x} \left (3 x-5 x^3\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(x - 2*E^x*x + (2*x*(3 - 3*x - 15*x^2 + 5*x^3 + E^x*(3 - 15*x^2)))/E^x)/x,x]

[Out]

-2*E^x + 7*x - 10*x^3 + (2*(3*x - 5*x^3))/E^x

________________________________________________________________________________________

fricas [A]  time = 0.63, size = 53, normalized size = 2.12 \begin {gather*} -{\left ({\left (10 \, x^{3} - 7 \, x\right )} e^{\left (-x + \log \left (2 \, x\right )\right )} + {\left (5 \, x^{2} - 3\right )} e^{\left (-2 \, x + 2 \, \log \left (2 \, x\right )\right )} + 4 \, x\right )} e^{\left (x - \log \left (2 \, x\right )\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((((-15*x^2+3)*exp(x)+5*x^3-15*x^2-3*x+3)*exp(log(2*x)-x)-2*exp(x)*x+x)/x,x, algorithm="fricas")

[Out]

-((10*x^3 - 7*x)*e^(-x + log(2*x)) + (5*x^2 - 3)*e^(-2*x + 2*log(2*x)) + 4*x)*e^(x - log(2*x))

________________________________________________________________________________________

giac [A]  time = 0.19, size = 28, normalized size = 1.12 \begin {gather*} -10 \, x^{3} - 2 \, {\left (5 \, x^{3} - 3 \, x\right )} e^{\left (-x\right )} + 7 \, x - 2 \, e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((((-15*x^2+3)*exp(x)+5*x^3-15*x^2-3*x+3)*exp(log(2*x)-x)-2*exp(x)*x+x)/x,x, algorithm="giac")

[Out]

-10*x^3 - 2*(5*x^3 - 3*x)*e^(-x) + 7*x - 2*e^x

________________________________________________________________________________________

maple [A]  time = 0.03, size = 28, normalized size = 1.12




method result size



risch \(-10 x^{3}+7 x -2 \,{\mathrm e}^{x}+\left (-10 x^{3}+6 x \right ) {\mathrm e}^{-x}\) \(28\)
default \(7 x -10 x^{3}-2 \,{\mathrm e}^{x}+6 x \,{\mathrm e}^{-x}-10 x^{3} {\mathrm e}^{-x}\) \(30\)
norman \(\left (6 x -10 x^{3}-2 \,{\mathrm e}^{2 x}+7 \,{\mathrm e}^{x} x -10 \,{\mathrm e}^{x} x^{3}\right ) {\mathrm e}^{-x}\) \(33\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((((-15*x^2+3)*exp(x)+5*x^3-15*x^2-3*x+3)*exp(ln(2*x)-x)-2*exp(x)*x+x)/x,x,method=_RETURNVERBOSE)

[Out]

-10*x^3+7*x-2*exp(x)+(-10*x^3+6*x)*exp(-x)

________________________________________________________________________________________

maxima [B]  time = 0.38, size = 61, normalized size = 2.44 \begin {gather*} -10 \, x^{3} - 10 \, {\left (x^{3} + 3 \, x^{2} + 6 \, x + 6\right )} e^{\left (-x\right )} + 30 \, {\left (x^{2} + 2 \, x + 2\right )} e^{\left (-x\right )} + 6 \, {\left (x + 1\right )} e^{\left (-x\right )} + 7 \, x - 6 \, e^{\left (-x\right )} - 2 \, e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((((-15*x^2+3)*exp(x)+5*x^3-15*x^2-3*x+3)*exp(log(2*x)-x)-2*exp(x)*x+x)/x,x, algorithm="maxima")

[Out]

-10*x^3 - 10*(x^3 + 3*x^2 + 6*x + 6)*e^(-x) + 30*(x^2 + 2*x + 2)*e^(-x) + 6*(x + 1)*e^(-x) + 7*x - 6*e^(-x) -
2*e^x

________________________________________________________________________________________

mupad [B]  time = 0.06, size = 29, normalized size = 1.16 \begin {gather*} 7\,x-2\,{\mathrm {e}}^x+6\,x\,{\mathrm {e}}^{-x}-10\,x^3\,{\mathrm {e}}^{-x}-10\,x^3 \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(2*x*exp(x) - x + exp(log(2*x) - x)*(3*x + exp(x)*(15*x^2 - 3) + 15*x^2 - 5*x^3 - 3))/x,x)

[Out]

7*x - 2*exp(x) + 6*x*exp(-x) - 10*x^3*exp(-x) - 10*x^3

________________________________________________________________________________________

sympy [A]  time = 0.15, size = 24, normalized size = 0.96 \begin {gather*} - 10 x^{3} + 7 x + \left (- 10 x^{3} + 6 x\right ) e^{- x} - 2 e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((((-15*x**2+3)*exp(x)+5*x**3-15*x**2-3*x+3)*exp(ln(2*x)-x)-2*exp(x)*x+x)/x,x)

[Out]

-10*x**3 + 7*x + (-10*x**3 + 6*x)*exp(-x) - 2*exp(x)

________________________________________________________________________________________