\(\int \frac {(1-x-x^2) \log (4 e^{e^x})+\log ^2(4 e^{e^x}) (-2 x^2+4 x^3-2 x^4+(-2 x+4 x^2-2 x^3) \log (-x+x^2))+(e^x (-x^2+x^3)+e^x (-x+x^2) \log (-x+x^2)) \log (x+\log (-x+x^2))}{\log ^2(4 e^{e^x}) (-x^2+x^3+(-x+x^2) \log (-x+x^2))} \, dx\) [2937]

Optimal result
Mathematica [A] (verified)
Rubi [F]
Maple [C] (warning: unable to verify)
Fricas [A] (verification not implemented)
Sympy [A] (verification not implemented)
Maxima [A] (verification not implemented)
Giac [B] (verification not implemented)
Mupad [B] (verification not implemented)
Reduce [B] (verification not implemented)

Optimal result

Integrand size = 153, antiderivative size = 35 \[ \int \frac {\left (1-x-x^2\right ) \log \left (4 e^{e^x}\right )+\log ^2\left (4 e^{e^x}\right ) \left (-2 x^2+4 x^3-2 x^4+\left (-2 x+4 x^2-2 x^3\right ) \log \left (-x+x^2\right )\right )+\left (e^x \left (-x^2+x^3\right )+e^x \left (-x+x^2\right ) \log \left (-x+x^2\right )\right ) \log \left (x+\log \left (-x+x^2\right )\right )}{\log ^2\left (4 e^{e^x}\right ) \left (-x^2+x^3+\left (-x+x^2\right ) \log \left (-x+x^2\right )\right )} \, dx=2 x-x^2-\frac {\log (x+\log (x-(2-x) x))}{\log \left (4 e^{e^x}\right )} \] Output:

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

Mathematica [A] (verified)

Time = 0.31 (sec) , antiderivative size = 30, normalized size of antiderivative = 0.86 \[ \int \frac {\left (1-x-x^2\right ) \log \left (4 e^{e^x}\right )+\log ^2\left (4 e^{e^x}\right ) \left (-2 x^2+4 x^3-2 x^4+\left (-2 x+4 x^2-2 x^3\right ) \log \left (-x+x^2\right )\right )+\left (e^x \left (-x^2+x^3\right )+e^x \left (-x+x^2\right ) \log \left (-x+x^2\right )\right ) \log \left (x+\log \left (-x+x^2\right )\right )}{\log ^2\left (4 e^{e^x}\right ) \left (-x^2+x^3+\left (-x+x^2\right ) \log \left (-x+x^2\right )\right )} \, dx=2 x-x^2-\frac {\log (x+\log ((-1+x) x))}{\log \left (4 e^{e^x}\right )} \] Input:

Integrate[((1 - x - x^2)*Log[4*E^E^x] + Log[4*E^E^x]^2*(-2*x^2 + 4*x^3 - 2 
*x^4 + (-2*x + 4*x^2 - 2*x^3)*Log[-x + x^2]) + (E^x*(-x^2 + x^3) + E^x*(-x 
 + x^2)*Log[-x + x^2])*Log[x + Log[-x + x^2]])/(Log[4*E^E^x]^2*(-x^2 + x^3 
 + (-x + x^2)*Log[-x + x^2])),x]
 

Output:

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

Rubi [F]

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 {\left (-x^2-x+1\right ) \log \left (4 e^{e^x}\right )+\left (e^x \left (x^2-x\right ) \log \left (x^2-x\right )+e^x \left (x^3-x^2\right )\right ) \log \left (\log \left (x^2-x\right )+x\right )+\left (-2 x^4+4 x^3-2 x^2+\left (-2 x^3+4 x^2-2 x\right ) \log \left (x^2-x\right )\right ) \log ^2\left (4 e^{e^x}\right )}{\log ^2\left (4 e^{e^x}\right ) \left (x^3-x^2+\left (x^2-x\right ) \log \left (x^2-x\right )\right )} \, dx\)

\(\Big \downarrow \) 7239

\(\displaystyle \int \left (-\frac {x^2+x-1}{(x-1) x \log \left (4 e^{e^x}\right ) (x+\log ((x-1) x))}-2 x+\frac {e^x \log (x+\log ((x-1) x))}{\log ^2\left (4 e^{e^x}\right )}+2\right )dx\)

\(\Big \downarrow \) 2009

\(\displaystyle \int \frac {e^x \log (x+\log ((x-1) x))}{\log ^2\left (4 e^{e^x}\right )}dx-\int \frac {1}{\log \left (4 e^{e^x}\right ) (x+\log ((x-1) x))}dx-\int \frac {1}{(x-1) \log \left (4 e^{e^x}\right ) (x+\log ((x-1) x))}dx-\int \frac {1}{x \log \left (4 e^{e^x}\right ) (x+\log ((x-1) x))}dx-x^2+2 x\)

Input:

Int[((1 - x - x^2)*Log[4*E^E^x] + Log[4*E^E^x]^2*(-2*x^2 + 4*x^3 - 2*x^4 + 
 (-2*x + 4*x^2 - 2*x^3)*Log[-x + x^2]) + (E^x*(-x^2 + x^3) + E^x*(-x + x^2 
)*Log[-x + x^2])*Log[x + Log[-x + x^2]])/(Log[4*E^E^x]^2*(-x^2 + x^3 + (-x 
 + x^2)*Log[-x + x^2])),x]
 

Output:

$Aborted
 
Maple [C] (warning: unable to verify)

Result contains higher order function than in optimal. Order 9 vs. order 3.

Time = 0.29 (sec) , antiderivative size = 83, normalized size of antiderivative = 2.37

\[-x^{2}+2 x +\frac {2 i \ln \left (\ln \left (x \right )+\ln \left (-1+x \right )-\frac {i \pi \,\operatorname {csgn}\left (i x \left (-1+x \right )\right ) \left (-\operatorname {csgn}\left (i x \left (-1+x \right )\right )+\operatorname {csgn}\left (i x \right )\right ) \left (-\operatorname {csgn}\left (i x \left (-1+x \right )\right )+\operatorname {csgn}\left (i \left (-1+x \right )\right )\right )}{2}+x \right )}{-4 i \ln \left (2\right )-2 i \ln \left ({\mathrm e}^{{\mathrm e}^{x}}\right )}\]

Input:

int((((-2*x^3+4*x^2-2*x)*ln(x^2-x)-2*x^4+4*x^3-2*x^2)*ln(4*exp(exp(x)))^2+ 
(-x^2-x+1)*ln(4*exp(exp(x)))+((x^2-x)*exp(x)*ln(x^2-x)+(x^3-x^2)*exp(x))*l 
n(ln(x^2-x)+x))/((x^2-x)*ln(x^2-x)+x^3-x^2)/ln(4*exp(exp(x)))^2,x)
 

Output:

-x^2+2*x+2*I*ln(ln(x)+ln(-1+x)-1/2*I*Pi*csgn(I*x*(-1+x))*(-csgn(I*x*(-1+x) 
)+csgn(I*x))*(-csgn(I*x*(-1+x))+csgn(I*(-1+x)))+x)/(-4*I*ln(2)-2*I*ln(exp( 
exp(x))))
 

Fricas [A] (verification not implemented)

Time = 0.08 (sec) , antiderivative size = 44, normalized size of antiderivative = 1.26 \[ \int \frac {\left (1-x-x^2\right ) \log \left (4 e^{e^x}\right )+\log ^2\left (4 e^{e^x}\right ) \left (-2 x^2+4 x^3-2 x^4+\left (-2 x+4 x^2-2 x^3\right ) \log \left (-x+x^2\right )\right )+\left (e^x \left (-x^2+x^3\right )+e^x \left (-x+x^2\right ) \log \left (-x+x^2\right )\right ) \log \left (x+\log \left (-x+x^2\right )\right )}{\log ^2\left (4 e^{e^x}\right ) \left (-x^2+x^3+\left (-x+x^2\right ) \log \left (-x+x^2\right )\right )} \, dx=-\frac {{\left (x^{2} - 2 \, x\right )} e^{x} + 2 \, {\left (x^{2} - 2 \, x\right )} \log \left (2\right ) + \log \left (x + \log \left (x^{2} - x\right )\right )}{e^{x} + 2 \, \log \left (2\right )} \] Input:

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

Output:

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

Sympy [A] (verification not implemented)

Time = 3.45 (sec) , antiderivative size = 24, normalized size of antiderivative = 0.69 \[ \int \frac {\left (1-x-x^2\right ) \log \left (4 e^{e^x}\right )+\log ^2\left (4 e^{e^x}\right ) \left (-2 x^2+4 x^3-2 x^4+\left (-2 x+4 x^2-2 x^3\right ) \log \left (-x+x^2\right )\right )+\left (e^x \left (-x^2+x^3\right )+e^x \left (-x+x^2\right ) \log \left (-x+x^2\right )\right ) \log \left (x+\log \left (-x+x^2\right )\right )}{\log ^2\left (4 e^{e^x}\right ) \left (-x^2+x^3+\left (-x+x^2\right ) \log \left (-x+x^2\right )\right )} \, dx=- x^{2} + 2 x - \frac {\log {\left (x + \log {\left (x^{2} - x \right )} \right )}}{e^{x} + 2 \log {\left (2 \right )}} \] Input:

integrate((((-2*x**3+4*x**2-2*x)*ln(x**2-x)-2*x**4+4*x**3-2*x**2)*ln(4*exp 
(exp(x)))**2+(-x**2-x+1)*ln(4*exp(exp(x)))+((x**2-x)*exp(x)*ln(x**2-x)+(x* 
*3-x**2)*exp(x))*ln(ln(x**2-x)+x))/((x**2-x)*ln(x**2-x)+x**3-x**2)/ln(4*ex 
p(exp(x)))**2,x)
 

Output:

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

Maxima [A] (verification not implemented)

Time = 0.20 (sec) , antiderivative size = 43, normalized size of antiderivative = 1.23 \[ \int \frac {\left (1-x-x^2\right ) \log \left (4 e^{e^x}\right )+\log ^2\left (4 e^{e^x}\right ) \left (-2 x^2+4 x^3-2 x^4+\left (-2 x+4 x^2-2 x^3\right ) \log \left (-x+x^2\right )\right )+\left (e^x \left (-x^2+x^3\right )+e^x \left (-x+x^2\right ) \log \left (-x+x^2\right )\right ) \log \left (x+\log \left (-x+x^2\right )\right )}{\log ^2\left (4 e^{e^x}\right ) \left (-x^2+x^3+\left (-x+x^2\right ) \log \left (-x+x^2\right )\right )} \, dx=-\frac {2 \, x^{2} \log \left (2\right ) + {\left (x^{2} - 2 \, x\right )} e^{x} - 4 \, x \log \left (2\right ) + \log \left (x + \log \left (x - 1\right ) + \log \left (x\right )\right )}{e^{x} + 2 \, \log \left (2\right )} \] Input:

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

Output:

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

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 96 vs. \(2 (30) = 60\).

Time = 0.24 (sec) , antiderivative size = 96, normalized size of antiderivative = 2.74 \[ \int \frac {\left (1-x-x^2\right ) \log \left (4 e^{e^x}\right )+\log ^2\left (4 e^{e^x}\right ) \left (-2 x^2+4 x^3-2 x^4+\left (-2 x+4 x^2-2 x^3\right ) \log \left (-x+x^2\right )\right )+\left (e^x \left (-x^2+x^3\right )+e^x \left (-x+x^2\right ) \log \left (-x+x^2\right )\right ) \log \left (x+\log \left (-x+x^2\right )\right )}{\log ^2\left (4 e^{e^x}\right ) \left (-x^2+x^3+\left (-x+x^2\right ) \log \left (-x+x^2\right )\right )} \, dx=-\frac {x^{2} e^{x} + 2 \, x^{2} \log \left (2\right ) - 2 \, x e^{x} - 4 \, x \log \left (2\right ) + 4 \, e^{x} \log \left (e^{x} + 2 \, \log \left (2\right )\right ) + 8 \, \log \left (2\right ) \log \left (e^{x} + 2 \, \log \left (2\right )\right ) - 4 \, e^{x} \log \left (-e^{x} - 2 \, \log \left (2\right )\right ) - 8 \, \log \left (2\right ) \log \left (-e^{x} - 2 \, \log \left (2\right )\right ) + \log \left (x + \log \left (x - 1\right ) + \log \left (x\right )\right )}{e^{x} + 2 \, \log \left (2\right )} \] Input:

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

Output:

-(x^2*e^x + 2*x^2*log(2) - 2*x*e^x - 4*x*log(2) + 4*e^x*log(e^x + 2*log(2) 
) + 8*log(2)*log(e^x + 2*log(2)) - 4*e^x*log(-e^x - 2*log(2)) - 8*log(2)*l 
og(-e^x - 2*log(2)) + log(x + log(x - 1) + log(x)))/(e^x + 2*log(2))
 

Mupad [B] (verification not implemented)

Time = 2.43 (sec) , antiderivative size = 29, normalized size of antiderivative = 0.83 \[ \int \frac {\left (1-x-x^2\right ) \log \left (4 e^{e^x}\right )+\log ^2\left (4 e^{e^x}\right ) \left (-2 x^2+4 x^3-2 x^4+\left (-2 x+4 x^2-2 x^3\right ) \log \left (-x+x^2\right )\right )+\left (e^x \left (-x^2+x^3\right )+e^x \left (-x+x^2\right ) \log \left (-x+x^2\right )\right ) \log \left (x+\log \left (-x+x^2\right )\right )}{\log ^2\left (4 e^{e^x}\right ) \left (-x^2+x^3+\left (-x+x^2\right ) \log \left (-x+x^2\right )\right )} \, dx=2\,x-\frac {\ln \left (x+\ln \left (x^2-x\right )\right )}{\ln \left (4\right )+{\mathrm {e}}^x}-x^2 \] Input:

int((log(4*exp(exp(x)))*(x + x^2 - 1) + log(4*exp(exp(x)))^2*(log(x^2 - x) 
*(2*x - 4*x^2 + 2*x^3) + 2*x^2 - 4*x^3 + 2*x^4) + log(x + log(x^2 - x))*(e 
xp(x)*(x^2 - x^3) + exp(x)*log(x^2 - x)*(x - x^2)))/(log(4*exp(exp(x)))^2* 
(x^2 - x^3 + log(x^2 - x)*(x - x^2))),x)
 

Output:

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

Reduce [B] (verification not implemented)

Time = 0.22 (sec) , antiderivative size = 49, normalized size of antiderivative = 1.40 \[ \int \frac {\left (1-x-x^2\right ) \log \left (4 e^{e^x}\right )+\log ^2\left (4 e^{e^x}\right ) \left (-2 x^2+4 x^3-2 x^4+\left (-2 x+4 x^2-2 x^3\right ) \log \left (-x+x^2\right )\right )+\left (e^x \left (-x^2+x^3\right )+e^x \left (-x+x^2\right ) \log \left (-x+x^2\right )\right ) \log \left (x+\log \left (-x+x^2\right )\right )}{\log ^2\left (4 e^{e^x}\right ) \left (-x^2+x^3+\left (-x+x^2\right ) \log \left (-x+x^2\right )\right )} \, dx=\frac {-\mathrm {log}\left (\mathrm {log}\left (x^{2}-x \right )+x \right )-\mathrm {log}\left (4 e^{e^{x}}\right ) x^{2}+2 \,\mathrm {log}\left (4 e^{e^{x}}\right ) x}{\mathrm {log}\left (4 e^{e^{x}}\right )} \] Input:

int((((-2*x^3+4*x^2-2*x)*log(x^2-x)-2*x^4+4*x^3-2*x^2)*log(4*exp(exp(x)))^ 
2+(-x^2-x+1)*log(4*exp(exp(x)))+((x^2-x)*exp(x)*log(x^2-x)+(x^3-x^2)*exp(x 
))*log(log(x^2-x)+x))/((x^2-x)*log(x^2-x)+x^3-x^2)/log(4*exp(exp(x)))^2,x)
 

Output:

( - log(log(x**2 - x) + x) - log(4*e**(e**x))*x**2 + 2*log(4*e**(e**x))*x) 
/log(4*e**(e**x))