\(\int \frac {e^{-256 x+32 x^2-x^3} (2+2 x+2 e^{2 x} x^2+e^x (4 x+x^2-x^3)+(-512 x-128 x^2+58 x^3-3 x^4+e^{2 x} (-512 x^3+128 x^4-6 x^5)+e^x (-1024 x^2+52 x^4-3 x^5)) \log (\frac {2 x+x^2+2 e^x x^2}{2+2 e^x x}))}{2 x+x^2+2 e^{2 x} x^3+e^x (4 x^2+x^3)} \, dx\) [2815]

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

Optimal result

Integrand size = 169, antiderivative size = 29 \[ \int \frac {e^{-256 x+32 x^2-x^3} \left (2+2 x+2 e^{2 x} x^2+e^x \left (4 x+x^2-x^3\right )+\left (-512 x-128 x^2+58 x^3-3 x^4+e^{2 x} \left (-512 x^3+128 x^4-6 x^5\right )+e^x \left (-1024 x^2+52 x^4-3 x^5\right )\right ) \log \left (\frac {2 x+x^2+2 e^x x^2}{2+2 e^x x}\right )\right )}{2 x+x^2+2 e^{2 x} x^3+e^x \left (4 x^2+x^3\right )} \, dx=e^{-(-16+x)^2 x} \log \left (x+\frac {x}{2 e^x+\frac {2}{x}}\right ) \] Output:

ln(x/(2/x+2*exp(x))+x)/exp((x-16)^2*x)
 

Mathematica [A] (verified)

Time = 0.08 (sec) , antiderivative size = 33, normalized size of antiderivative = 1.14 \[ \int \frac {e^{-256 x+32 x^2-x^3} \left (2+2 x+2 e^{2 x} x^2+e^x \left (4 x+x^2-x^3\right )+\left (-512 x-128 x^2+58 x^3-3 x^4+e^{2 x} \left (-512 x^3+128 x^4-6 x^5\right )+e^x \left (-1024 x^2+52 x^4-3 x^5\right )\right ) \log \left (\frac {2 x+x^2+2 e^x x^2}{2+2 e^x x}\right )\right )}{2 x+x^2+2 e^{2 x} x^3+e^x \left (4 x^2+x^3\right )} \, dx=e^{-(-16+x)^2 x} \log \left (\frac {x \left (2+x+2 e^x x\right )}{2+2 e^x x}\right ) \] Input:

Integrate[(E^(-256*x + 32*x^2 - x^3)*(2 + 2*x + 2*E^(2*x)*x^2 + E^x*(4*x + 
 x^2 - x^3) + (-512*x - 128*x^2 + 58*x^3 - 3*x^4 + E^(2*x)*(-512*x^3 + 128 
*x^4 - 6*x^5) + E^x*(-1024*x^2 + 52*x^4 - 3*x^5))*Log[(2*x + x^2 + 2*E^x*x 
^2)/(2 + 2*E^x*x)]))/(2*x + x^2 + 2*E^(2*x)*x^3 + E^x*(4*x^2 + x^3)),x]
 

Output:

Log[(x*(2 + x + 2*E^x*x))/(2 + 2*E^x*x)]/E^((-16 + x)^2*x)
 

Rubi [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(152\) vs. \(2(29)=58\).

Time = 0.68 (sec) , antiderivative size = 152, normalized size of antiderivative = 5.24, number of steps used = 1, number of rules used = 1, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.006, Rules used = {2726}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {e^{-x^3+32 x^2-256 x} \left (2 e^{2 x} x^2+e^x \left (-x^3+x^2+4 x\right )+\left (-3 x^4+58 x^3-128 x^2+e^{2 x} \left (-6 x^5+128 x^4-512 x^3\right )+e^x \left (-3 x^5+52 x^4-1024 x^2\right )-512 x\right ) \log \left (\frac {2 e^x x^2+x^2+2 x}{2 e^x x+2}\right )+2 x+2\right )}{2 e^{2 x} x^3+x^2+e^x \left (x^3+4 x^2\right )+2 x} \, dx\)

\(\Big \downarrow \) 2726

\(\displaystyle \frac {e^{-x^3+32 x^2-256 x} \left (3 x^4-58 x^3+128 x^2+2 e^{2 x} \left (3 x^5-64 x^4+256 x^3\right )+e^x \left (3 x^5-52 x^4+1024 x^2\right )+512 x\right ) \log \left (\frac {2 e^x x^2+x^2+2 x}{2 \left (e^x x+1\right )}\right )}{\left (3 x^2-64 x+256\right ) \left (2 e^{2 x} x^3+x^2+e^x \left (x^3+4 x^2\right )+2 x\right )}\)

Input:

Int[(E^(-256*x + 32*x^2 - x^3)*(2 + 2*x + 2*E^(2*x)*x^2 + E^x*(4*x + x^2 - 
 x^3) + (-512*x - 128*x^2 + 58*x^3 - 3*x^4 + E^(2*x)*(-512*x^3 + 128*x^4 - 
 6*x^5) + E^x*(-1024*x^2 + 52*x^4 - 3*x^5))*Log[(2*x + x^2 + 2*E^x*x^2)/(2 
 + 2*E^x*x)]))/(2*x + x^2 + 2*E^(2*x)*x^3 + E^x*(4*x^2 + x^3)),x]
 

Output:

(E^(-256*x + 32*x^2 - x^3)*(512*x + 128*x^2 - 58*x^3 + 3*x^4 + 2*E^(2*x)*( 
256*x^3 - 64*x^4 + 3*x^5) + E^x*(1024*x^2 - 52*x^4 + 3*x^5))*Log[(2*x + x^ 
2 + 2*E^x*x^2)/(2*(1 + E^x*x))])/((256 - 64*x + 3*x^2)*(2*x + x^2 + 2*E^(2 
*x)*x^3 + E^x*(4*x^2 + x^3)))
 

Defintions of rubi rules used

rule 2726
Int[(y_.)*(F_)^(u_)*((v_) + (w_)), x_Symbol] :> With[{z = v*(y/(Log[F]*D[u, 
 x]))}, Simp[F^u*z, x] /; EqQ[D[z, x], w*y]] /; FreeQ[F, x]
 
Maple [A] (verified)

Time = 100.70 (sec) , antiderivative size = 42, normalized size of antiderivative = 1.45

method result size
parallelrisch \(\ln \left (\frac {2 \,{\mathrm e}^{x} x^{2}+x^{2}+2 x}{2 \,{\mathrm e}^{x} x +2}\right ) {\mathrm e}^{-x^{3}+32 x^{2}-256 x}\) \(42\)
risch \({\mathrm e}^{-\left (x -16\right )^{2} x} \ln \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )+\frac {\left (-i \pi \,\operatorname {csgn}\left (i \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )\right ) \operatorname {csgn}\left (\frac {i}{{\mathrm e}^{x} x +1}\right ) \operatorname {csgn}\left (\frac {i \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )}{{\mathrm e}^{x} x +1}\right )+i \pi \,\operatorname {csgn}\left (i \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )\right ) {\operatorname {csgn}\left (\frac {i \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )}{{\mathrm e}^{x} x +1}\right )}^{2}+i \pi \,\operatorname {csgn}\left (\frac {i}{{\mathrm e}^{x} x +1}\right ) {\operatorname {csgn}\left (\frac {i \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )}{{\mathrm e}^{x} x +1}\right )}^{2}-i \pi {\operatorname {csgn}\left (\frac {i \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )}{{\mathrm e}^{x} x +1}\right )}^{3}+i \pi \,\operatorname {csgn}\left (\frac {i \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )}{{\mathrm e}^{x} x +1}\right ) {\operatorname {csgn}\left (\frac {i x \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )}{{\mathrm e}^{x} x +1}\right )}^{2}-i \pi \,\operatorname {csgn}\left (\frac {i \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )}{{\mathrm e}^{x} x +1}\right ) \operatorname {csgn}\left (\frac {i x \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )}{{\mathrm e}^{x} x +1}\right ) \operatorname {csgn}\left (i x \right )-i \pi {\operatorname {csgn}\left (\frac {i x \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )}{{\mathrm e}^{x} x +1}\right )}^{3}+i \pi {\operatorname {csgn}\left (\frac {i x \left (1+\left ({\mathrm e}^{x}+\frac {1}{2}\right ) x \right )}{{\mathrm e}^{x} x +1}\right )}^{2} \operatorname {csgn}\left (i x \right )+2 \ln \left (x \right )-2 \ln \left ({\mathrm e}^{x} x +1\right )\right ) {\mathrm e}^{-\left (x -16\right )^{2} x}}{2}\) \(352\)

Input:

int((((-6*x^5+128*x^4-512*x^3)*exp(x)^2+(-3*x^5+52*x^4-1024*x^2)*exp(x)-3* 
x^4+58*x^3-128*x^2-512*x)*ln((2*exp(x)*x^2+x^2+2*x)/(2*exp(x)*x+2))+2*exp( 
x)^2*x^2+(-x^3+x^2+4*x)*exp(x)+2*x+2)/(2*exp(x)^2*x^3+(x^3+4*x^2)*exp(x)+x 
^2+2*x)/exp(x^3-32*x^2+256*x),x,method=_RETURNVERBOSE)
 

Output:

ln(1/2/(exp(x)*x+1)*(2*exp(x)*x^2+x^2+2*x))/exp(x^3-32*x^2+256*x)
 

Fricas [A] (verification not implemented)

Time = 0.12 (sec) , antiderivative size = 41, normalized size of antiderivative = 1.41 \[ \int \frac {e^{-256 x+32 x^2-x^3} \left (2+2 x+2 e^{2 x} x^2+e^x \left (4 x+x^2-x^3\right )+\left (-512 x-128 x^2+58 x^3-3 x^4+e^{2 x} \left (-512 x^3+128 x^4-6 x^5\right )+e^x \left (-1024 x^2+52 x^4-3 x^5\right )\right ) \log \left (\frac {2 x+x^2+2 e^x x^2}{2+2 e^x x}\right )\right )}{2 x+x^2+2 e^{2 x} x^3+e^x \left (4 x^2+x^3\right )} \, dx=e^{\left (-x^{3} + 32 \, x^{2} - 256 \, x\right )} \log \left (\frac {2 \, x^{2} e^{x} + x^{2} + 2 \, x}{2 \, {\left (x e^{x} + 1\right )}}\right ) \] Input:

integrate((((-6*x^5+128*x^4-512*x^3)*exp(x)^2+(-3*x^5+52*x^4-1024*x^2)*exp 
(x)-3*x^4+58*x^3-128*x^2-512*x)*log((2*exp(x)*x^2+x^2+2*x)/(2*exp(x)*x+2)) 
+2*exp(x)^2*x^2+(-x^3+x^2+4*x)*exp(x)+2*x+2)/(2*exp(x)^2*x^3+(x^3+4*x^2)*e 
xp(x)+x^2+2*x)/exp(x^3-32*x^2+256*x),x, algorithm="fricas")
 

Output:

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

Sympy [F(-1)]

Timed out. \[ \int \frac {e^{-256 x+32 x^2-x^3} \left (2+2 x+2 e^{2 x} x^2+e^x \left (4 x+x^2-x^3\right )+\left (-512 x-128 x^2+58 x^3-3 x^4+e^{2 x} \left (-512 x^3+128 x^4-6 x^5\right )+e^x \left (-1024 x^2+52 x^4-3 x^5\right )\right ) \log \left (\frac {2 x+x^2+2 e^x x^2}{2+2 e^x x}\right )\right )}{2 x+x^2+2 e^{2 x} x^3+e^x \left (4 x^2+x^3\right )} \, dx=\text {Timed out} \] Input:

integrate((((-6*x**5+128*x**4-512*x**3)*exp(x)**2+(-3*x**5+52*x**4-1024*x* 
*2)*exp(x)-3*x**4+58*x**3-128*x**2-512*x)*ln((2*exp(x)*x**2+x**2+2*x)/(2*e 
xp(x)*x+2))+2*exp(x)**2*x**2+(-x**3+x**2+4*x)*exp(x)+2*x+2)/(2*exp(x)**2*x 
**3+(x**3+4*x**2)*exp(x)+x**2+2*x)/exp(x**3-32*x**2+256*x),x)
 

Output:

Timed out
 

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 70 vs. \(2 (24) = 48\).

Time = 26.56 (sec) , antiderivative size = 70, normalized size of antiderivative = 2.41 \[ \int \frac {e^{-256 x+32 x^2-x^3} \left (2+2 x+2 e^{2 x} x^2+e^x \left (4 x+x^2-x^3\right )+\left (-512 x-128 x^2+58 x^3-3 x^4+e^{2 x} \left (-512 x^3+128 x^4-6 x^5\right )+e^x \left (-1024 x^2+52 x^4-3 x^5\right )\right ) \log \left (\frac {2 x+x^2+2 e^x x^2}{2+2 e^x x}\right )\right )}{2 x+x^2+2 e^{2 x} x^3+e^x \left (4 x^2+x^3\right )} \, dx=-{\left ({\left (\log \left (2\right ) - \log \left (x\right )\right )} e^{\left (-x^{3} + 32 \, x^{2}\right )} - e^{\left (-x^{3} + 32 \, x^{2}\right )} \log \left (2 \, x e^{x} + x + 2\right ) + e^{\left (-x^{3} + 32 \, x^{2}\right )} \log \left (x e^{x} + 1\right )\right )} e^{\left (-256 \, x\right )} \] Input:

integrate((((-6*x^5+128*x^4-512*x^3)*exp(x)^2+(-3*x^5+52*x^4-1024*x^2)*exp 
(x)-3*x^4+58*x^3-128*x^2-512*x)*log((2*exp(x)*x^2+x^2+2*x)/(2*exp(x)*x+2)) 
+2*exp(x)^2*x^2+(-x^3+x^2+4*x)*exp(x)+2*x+2)/(2*exp(x)^2*x^3+(x^3+4*x^2)*e 
xp(x)+x^2+2*x)/exp(x^3-32*x^2+256*x),x, algorithm="maxima")
 

Output:

-((log(2) - log(x))*e^(-x^3 + 32*x^2) - e^(-x^3 + 32*x^2)*log(2*x*e^x + x 
+ 2) + e^(-x^3 + 32*x^2)*log(x*e^x + 1))*e^(-256*x)
 

Giac [A] (verification not implemented)

Time = 0.44 (sec) , antiderivative size = 41, normalized size of antiderivative = 1.41 \[ \int \frac {e^{-256 x+32 x^2-x^3} \left (2+2 x+2 e^{2 x} x^2+e^x \left (4 x+x^2-x^3\right )+\left (-512 x-128 x^2+58 x^3-3 x^4+e^{2 x} \left (-512 x^3+128 x^4-6 x^5\right )+e^x \left (-1024 x^2+52 x^4-3 x^5\right )\right ) \log \left (\frac {2 x+x^2+2 e^x x^2}{2+2 e^x x}\right )\right )}{2 x+x^2+2 e^{2 x} x^3+e^x \left (4 x^2+x^3\right )} \, dx=e^{\left (-x^{3} + 32 \, x^{2} - 256 \, x\right )} \log \left (\frac {2 \, x^{2} e^{x} + x^{2} + 2 \, x}{2 \, {\left (x e^{x} + 1\right )}}\right ) \] Input:

integrate((((-6*x^5+128*x^4-512*x^3)*exp(x)^2+(-3*x^5+52*x^4-1024*x^2)*exp 
(x)-3*x^4+58*x^3-128*x^2-512*x)*log((2*exp(x)*x^2+x^2+2*x)/(2*exp(x)*x+2)) 
+2*exp(x)^2*x^2+(-x^3+x^2+4*x)*exp(x)+2*x+2)/(2*exp(x)^2*x^3+(x^3+4*x^2)*e 
xp(x)+x^2+2*x)/exp(x^3-32*x^2+256*x),x, algorithm="giac")
 

Output:

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

Mupad [B] (verification not implemented)

Time = 3.51 (sec) , antiderivative size = 42, normalized size of antiderivative = 1.45 \[ \int \frac {e^{-256 x+32 x^2-x^3} \left (2+2 x+2 e^{2 x} x^2+e^x \left (4 x+x^2-x^3\right )+\left (-512 x-128 x^2+58 x^3-3 x^4+e^{2 x} \left (-512 x^3+128 x^4-6 x^5\right )+e^x \left (-1024 x^2+52 x^4-3 x^5\right )\right ) \log \left (\frac {2 x+x^2+2 e^x x^2}{2+2 e^x x}\right )\right )}{2 x+x^2+2 e^{2 x} x^3+e^x \left (4 x^2+x^3\right )} \, dx=\ln \left (\frac {2\,x+2\,x^2\,{\mathrm {e}}^x+x^2}{2\,x\,{\mathrm {e}}^x+2}\right )\,{\mathrm {e}}^{-256\,x}\,{\mathrm {e}}^{-x^3}\,{\mathrm {e}}^{32\,x^2} \] Input:

int((exp(32*x^2 - 256*x - x^3)*(2*x + 2*x^2*exp(2*x) - log((2*x + 2*x^2*ex 
p(x) + x^2)/(2*x*exp(x) + 2))*(512*x + exp(x)*(1024*x^2 - 52*x^4 + 3*x^5) 
+ exp(2*x)*(512*x^3 - 128*x^4 + 6*x^5) + 128*x^2 - 58*x^3 + 3*x^4) + exp(x 
)*(4*x + x^2 - x^3) + 2))/(2*x + 2*x^3*exp(2*x) + exp(x)*(4*x^2 + x^3) + x 
^2),x)
 

Output:

log((2*x + 2*x^2*exp(x) + x^2)/(2*x*exp(x) + 2))*exp(-256*x)*exp(-x^3)*exp 
(32*x^2)
 

Reduce [F]

\[ \int \frac {e^{-256 x+32 x^2-x^3} \left (2+2 x+2 e^{2 x} x^2+e^x \left (4 x+x^2-x^3\right )+\left (-512 x-128 x^2+58 x^3-3 x^4+e^{2 x} \left (-512 x^3+128 x^4-6 x^5\right )+e^x \left (-1024 x^2+52 x^4-3 x^5\right )\right ) \log \left (\frac {2 x+x^2+2 e^x x^2}{2+2 e^x x}\right )\right )}{2 x+x^2+2 e^{2 x} x^3+e^x \left (4 x^2+x^3\right )} \, dx =\text {Too large to display} \] Input:

int((((-6*x^5+128*x^4-512*x^3)*exp(x)^2+(-3*x^5+52*x^4-1024*x^2)*exp(x)-3* 
x^4+58*x^3-128*x^2-512*x)*log((2*exp(x)*x^2+x^2+2*x)/(2*exp(x)*x+2))+2*exp 
(x)^2*x^2+(-x^3+x^2+4*x)*exp(x)+2*x+2)/(2*exp(x)^2*x^3+(x^3+4*x^2)*exp(x)+ 
x^2+2*x)/exp(x^3-32*x^2+256*x),x)
 

Output:

2*int(e**(32*x**2)/(2*e**(x**3 + 258*x)*x**3 + e**(x**3 + 257*x)*x**3 + 4* 
e**(x**3 + 257*x)*x**2 + e**(x**3 + 256*x)*x**2 + 2*e**(x**3 + 256*x)*x),x 
) + 2*int(e**(32*x**2)/(2*e**(x**3 + 258*x)*x**2 + e**(x**3 + 257*x)*x**2 
+ 4*e**(x**3 + 257*x)*x + e**(x**3 + 256*x)*x + 2*e**(x**3 + 256*x)),x) + 
4*int(e**(32*x**2)/(2*e**(x**3 + 257*x)*x**2 + e**(x**3 + 256*x)*x**2 + 4* 
e**(x**3 + 256*x)*x + e**(x**3 + 255*x)*x + 2*e**(x**3 + 255*x)),x) - int( 
(e**(32*x**2)*x**2)/(2*e**(x**3 + 257*x)*x**2 + e**(x**3 + 256*x)*x**2 + 4 
*e**(x**3 + 256*x)*x + e**(x**3 + 255*x)*x + 2*e**(x**3 + 255*x)),x) - 3*i 
nt((e**(32*x**2)*log((2*e**x*x**2 + x**2 + 2*x)/(2*e**x*x + 2))*x**4)/(2*e 
**(x**3 + 257*x)*x**2 + e**(x**3 + 256*x)*x**2 + 4*e**(x**3 + 256*x)*x + e 
**(x**3 + 255*x)*x + 2*e**(x**3 + 255*x)),x) - 6*int((e**(32*x**2)*log((2* 
e**x*x**2 + x**2 + 2*x)/(2*e**x*x + 2))*x**4)/(2*e**(x**3 + 256*x)*x**2 + 
e**(x**3 + 255*x)*x**2 + 4*e**(x**3 + 255*x)*x + e**(x**3 + 254*x)*x + 2*e 
**(x**3 + 254*x)),x) - 3*int((e**(32*x**2)*log((2*e**x*x**2 + x**2 + 2*x)/ 
(2*e**x*x + 2))*x**3)/(2*e**(x**3 + 258*x)*x**2 + e**(x**3 + 257*x)*x**2 + 
 4*e**(x**3 + 257*x)*x + e**(x**3 + 256*x)*x + 2*e**(x**3 + 256*x)),x) + 5 
2*int((e**(32*x**2)*log((2*e**x*x**2 + x**2 + 2*x)/(2*e**x*x + 2))*x**3)/( 
2*e**(x**3 + 257*x)*x**2 + e**(x**3 + 256*x)*x**2 + 4*e**(x**3 + 256*x)*x 
+ e**(x**3 + 255*x)*x + 2*e**(x**3 + 255*x)),x) + 128*int((e**(32*x**2)*lo 
g((2*e**x*x**2 + x**2 + 2*x)/(2*e**x*x + 2))*x**3)/(2*e**(x**3 + 256*x)...