\(\int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{e^{12} (1+x) (2+2 x)^2} \, dx\) [4052]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [A] (verification not implemented)
   Maxima [B] (verification not implemented)
   Giac [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 51, antiderivative size = 17 \[ \int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{e^{12} (1+x) (2+2 x)^2} \, dx=4+e^{\frac {x}{e^{12} (2+2 x)^2}}+x \]

[Out]

4+exp(x/exp(2)/exp(ln(2+2*x)+5)^2)+x

Rubi [A] (verified)

Time = 0.12 (sec) , antiderivative size = 17, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.078, Rules used = {12, 21, 6820, 6838} \[ \int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{e^{12} (1+x) (2+2 x)^2} \, dx=x+e^{\frac {x}{4 e^{12} (x+1)^2}} \]

[In]

Int[(E^(x/(E^12*(2 + 2*x)^2))*(1 - x) + E^12*(1 + x)*(2 + 2*x)^2)/(E^12*(1 + x)*(2 + 2*x)^2),x]

[Out]

E^(x/(4*E^12*(1 + x)^2)) + x

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 21

Int[(u_.)*((a_) + (b_.)*(v_))^(m_.)*((c_) + (d_.)*(v_))^(n_.), x_Symbol] :> Dist[(b/d)^m, Int[u*(c + d*v)^(m +
 n), x], x] /; FreeQ[{a, b, c, d, n}, x] && EqQ[b*c - a*d, 0] && IntegerQ[m] && ( !IntegerQ[n] || SimplerQ[c +
 d*x, a + b*x])

Rule 6820

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

Rule 6838

Int[(F_)^(v_)*(u_), x_Symbol] :> With[{q = DerivativeDivides[v, u, x]}, Simp[q*(F^v/Log[F]), x] /;  !FalseQ[q]
] /; FreeQ[F, x]

Rubi steps \begin{align*} \text {integral}& = \frac {\int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{(1+x) (2+2 x)^2} \, dx}{e^{12}} \\ & = \frac {\int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{(1+x)^3} \, dx}{4 e^{12}} \\ & = \frac {\int \left (4 e^{12}-\frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (-1+x)}{(1+x)^3}\right ) \, dx}{4 e^{12}} \\ & = x-\frac {\int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (-1+x)}{(1+x)^3} \, dx}{4 e^{12}} \\ & = e^{\frac {x}{4 e^{12} (1+x)^2}}+x \\ \end{align*}

Mathematica [A] (verified)

Time = 0.45 (sec) , antiderivative size = 17, normalized size of antiderivative = 1.00 \[ \int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{e^{12} (1+x) (2+2 x)^2} \, dx=e^{\frac {x}{4 e^{12} (1+x)^2}}+x \]

[In]

Integrate[(E^(x/(E^12*(2 + 2*x)^2))*(1 - x) + E^12*(1 + x)*(2 + 2*x)^2)/(E^12*(1 + x)*(2 + 2*x)^2),x]

[Out]

E^(x/(4*E^12*(1 + x)^2)) + x

Maple [A] (verified)

Time = 4.77 (sec) , antiderivative size = 14, normalized size of antiderivative = 0.82

method result size
risch \(x +{\mathrm e}^{\frac {x \,{\mathrm e}^{-12}}{4 \left (1+x \right )^{2}}}\) \(14\)
parts \(x +{\mathrm e}^{\frac {x \,{\mathrm e}^{-2} {\mathrm e}^{-10}}{\left (2+2 x \right )^{2}}}\) \(21\)
default \({\mathrm e}^{-2} \left ({\mathrm e}^{\frac {x \,{\mathrm e}^{-2} {\mathrm e}^{-10}}{\left (2+2 x \right )^{2}}} {\mathrm e}^{2}+{\mathrm e}^{2} x \right )\) \(32\)
norman \(\frac {\left (x^{3} {\mathrm e}^{5}-3 x \,{\mathrm e}^{5}+{\mathrm e}^{5} {\mathrm e}^{\frac {x \,{\mathrm e}^{-2} {\mathrm e}^{-10}}{\left (2+2 x \right )^{2}}}+x^{2} {\mathrm e}^{5} {\mathrm e}^{\frac {x \,{\mathrm e}^{-2} {\mathrm e}^{-10}}{\left (2+2 x \right )^{2}}}+2 x \,{\mathrm e}^{5} {\mathrm e}^{\frac {x \,{\mathrm e}^{-2} {\mathrm e}^{-10}}{\left (2+2 x \right )^{2}}}-2 \,{\mathrm e}^{5}\right ) {\mathrm e}^{-5}}{\left (1+x \right )^{2}}\) \(95\)
parallelrisch \(\frac {{\mathrm e}^{-2} \left ({\mathrm e}^{2} x^{2} \left (2+2 x \right )^{4} {\mathrm e}^{20} {\mathrm e}^{\frac {x \,{\mathrm e}^{-2} {\mathrm e}^{-10}}{\left (2+2 x \right )^{2}}}+2 \,{\mathrm e}^{2} x \left (2+2 x \right )^{4} {\mathrm e}^{20} {\mathrm e}^{\frac {x \,{\mathrm e}^{-2} {\mathrm e}^{-10}}{\left (2+2 x \right )^{2}}}+{\mathrm e}^{2} \left (2+2 x \right )^{4} {\mathrm e}^{20} {\mathrm e}^{\frac {x \,{\mathrm e}^{-2} {\mathrm e}^{-10}}{\left (2+2 x \right )^{2}}}+{\mathrm e}^{2} \left (2+2 x \right )^{4} {\mathrm e}^{20} x^{3}-3 \left (2+2 x \right )^{4} {\mathrm e}^{20} x \,{\mathrm e}^{2}-2 \left (2+2 x \right )^{4} {\mathrm e}^{20} {\mathrm e}^{2}\right ) {\mathrm e}^{-20}}{\left (2+2 x \right )^{4} \left (1+x \right )^{2}}\) \(172\)

[In]

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

[Out]

x+exp(1/4*x*exp(-12)/(1+x)^2)

Fricas [A] (verification not implemented)

none

Time = 0.25 (sec) , antiderivative size = 18, normalized size of antiderivative = 1.06 \[ \int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{e^{12} (1+x) (2+2 x)^2} \, dx=x + e^{\left (\frac {x e^{\left (-12\right )}}{4 \, {\left (x^{2} + 2 \, x + 1\right )}}\right )} \]

[In]

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

[Out]

x + e^(1/4*x*e^(-12)/(x^2 + 2*x + 1))

Sympy [A] (verification not implemented)

Time = 0.15 (sec) , antiderivative size = 14, normalized size of antiderivative = 0.82 \[ \int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{e^{12} (1+x) (2+2 x)^2} \, dx=x + e^{\frac {x}{\left (2 x + 2\right )^{2} e^{12}}} \]

[In]

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

[Out]

x + exp(x*exp(-12)/(2*x + 2)**2)

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 129 vs. \(2 (17) = 34\).

Time = 0.28 (sec) , antiderivative size = 129, normalized size of antiderivative = 7.59 \[ \int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{e^{12} (1+x) (2+2 x)^2} \, dx=\frac {1}{2} \, {\left ({\left (2 \, x - \frac {6 \, x + 5}{x^{2} + 2 \, x + 1} - 6 \, \log \left (x + 1\right )\right )} e^{12} + 3 \, {\left (\frac {4 \, x + 3}{x^{2} + 2 \, x + 1} + 2 \, \log \left (x + 1\right )\right )} e^{12} - \frac {3 \, {\left (2 \, x + 1\right )} e^{12}}{x^{2} + 2 \, x + 1} - \frac {e^{12}}{x^{2} + 2 \, x + 1} + 2 \, e^{\left (-\frac {1}{4 \, {\left (x^{2} e^{12} + 2 \, x e^{12} + e^{12}\right )}} + \frac {1}{4 \, {\left (x e^{12} + e^{12}\right )}} + 12\right )}\right )} e^{\left (-12\right )} \]

[In]

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

[Out]

1/2*((2*x - (6*x + 5)/(x^2 + 2*x + 1) - 6*log(x + 1))*e^12 + 3*((4*x + 3)/(x^2 + 2*x + 1) + 2*log(x + 1))*e^12
 - 3*(2*x + 1)*e^12/(x^2 + 2*x + 1) - e^12/(x^2 + 2*x + 1) + 2*e^(-1/4/(x^2*e^12 + 2*x*e^12 + e^12) + 1/4/(x*e
^12 + e^12) + 12))*e^(-12)

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 88 vs. \(2 (17) = 34\).

Time = 0.27 (sec) , antiderivative size = 88, normalized size of antiderivative = 5.18 \[ \int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{e^{12} (1+x) (2+2 x)^2} \, dx=x + e^{\left (-\frac {12 \, x^{2} e^{12}}{x^{2} e^{12} + 2 \, x e^{12} + e^{12}} - \frac {24 \, x e^{12}}{x^{2} e^{12} + 2 \, x e^{12} + e^{12}} + \frac {x}{4 \, {\left (x^{2} e^{12} + 2 \, x e^{12} + e^{12}\right )}} - \frac {12 \, e^{12}}{x^{2} e^{12} + 2 \, x e^{12} + e^{12}} + 12\right )} \]

[In]

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

[Out]

x + e^(-12*x^2*e^12/(x^2*e^12 + 2*x*e^12 + e^12) - 24*x*e^12/(x^2*e^12 + 2*x*e^12 + e^12) + 1/4*x/(x^2*e^12 +
2*x*e^12 + e^12) - 12*e^12/(x^2*e^12 + 2*x*e^12 + e^12) + 12)

Mupad [B] (verification not implemented)

Time = 0.73 (sec) , antiderivative size = 19, normalized size of antiderivative = 1.12 \[ \int \frac {e^{\frac {x}{e^{12} (2+2 x)^2}} (1-x)+e^{12} (1+x) (2+2 x)^2}{e^{12} (1+x) (2+2 x)^2} \, dx=x+{\mathrm {e}}^{\frac {x\,{\mathrm {e}}^{-12}}{4\,x^2+8\,x+4}} \]

[In]

int(-(exp(-2)*exp(- 2*log(2*x + 2) - 10)*(exp(x*exp(-2)*exp(- 2*log(2*x + 2) - 10))*(x - 1) - exp(2)*exp(2*log
(2*x + 2) + 10)*(x + 1)))/(x + 1),x)

[Out]

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