\(\int \frac {e^{4 x} (-392 x-28 x^2+812 x^3+114 x^4+4 x^5)+e^{4 x} (364 x+868 x^2+230 x^3+12 x^4) \log (3 x)+e^{4 x} (56 x+118 x^2+12 x^3) \log ^2(3 x)+e^{4 x} (2 x+4 x^2) \log ^3(3 x)}{x^3+3 x^2 \log (3 x)+3 x \log ^2(3 x)+\log ^3(3 x)} \, dx\) [2009]

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

Optimal result

Integrand size = 138, antiderivative size = 21 \[ \int \frac {e^{4 x} \left (-392 x-28 x^2+812 x^3+114 x^4+4 x^5\right )+e^{4 x} \left (364 x+868 x^2+230 x^3+12 x^4\right ) \log (3 x)+e^{4 x} \left (56 x+118 x^2+12 x^3\right ) \log ^2(3 x)+e^{4 x} \left (2 x+4 x^2\right ) \log ^3(3 x)}{x^3+3 x^2 \log (3 x)+3 x \log ^2(3 x)+\log ^3(3 x)} \, dx=e^{4 x} \left (x+\frac {14 x}{x+\log (3 x)}\right )^2 \] Output:

(14*x/(x+ln(3*x))+x)^2*exp(2*x)^2
                                                                                    
                                                                                    
 

Mathematica [A] (verified)

Time = 0.04 (sec) , antiderivative size = 26, normalized size of antiderivative = 1.24 \[ \int \frac {e^{4 x} \left (-392 x-28 x^2+812 x^3+114 x^4+4 x^5\right )+e^{4 x} \left (364 x+868 x^2+230 x^3+12 x^4\right ) \log (3 x)+e^{4 x} \left (56 x+118 x^2+12 x^3\right ) \log ^2(3 x)+e^{4 x} \left (2 x+4 x^2\right ) \log ^3(3 x)}{x^3+3 x^2 \log (3 x)+3 x \log ^2(3 x)+\log ^3(3 x)} \, dx=\frac {e^{4 x} x^2 (14+x+\log (3 x))^2}{(x+\log (3 x))^2} \] Input:

Integrate[(E^(4*x)*(-392*x - 28*x^2 + 812*x^3 + 114*x^4 + 4*x^5) + E^(4*x) 
*(364*x + 868*x^2 + 230*x^3 + 12*x^4)*Log[3*x] + E^(4*x)*(56*x + 118*x^2 + 
 12*x^3)*Log[3*x]^2 + E^(4*x)*(2*x + 4*x^2)*Log[3*x]^3)/(x^3 + 3*x^2*Log[3 
*x] + 3*x*Log[3*x]^2 + Log[3*x]^3),x]
 

Output:

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

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 {e^{4 x} \left (4 x^2+2 x\right ) \log ^3(3 x)+e^{4 x} \left (12 x^3+118 x^2+56 x\right ) \log ^2(3 x)+e^{4 x} \left (12 x^4+230 x^3+868 x^2+364 x\right ) \log (3 x)+e^{4 x} \left (4 x^5+114 x^4+812 x^3-28 x^2-392 x\right )}{x^3+3 x^2 \log (3 x)+\log ^3(3 x)+3 x \log ^2(3 x)} \, dx\)

\(\Big \downarrow \) 7292

\(\displaystyle \int \frac {2 e^{4 x} x \left (2 x^4+57 x^3+6 x^3 \log (3 x)+406 x^2+6 x^2 \log ^2(3 x)+115 x^2 \log (3 x)-14 x+2 x \log ^3(3 x)+\log ^3(3 x)+59 x \log ^2(3 x)+28 \log ^2(3 x)+434 x \log (3 x)+182 \log (3 x)-196\right )}{(x+\log (3 x))^3}dx\)

\(\Big \downarrow \) 27

\(\displaystyle 2 \int -\frac {e^{4 x} x \left (-2 x^4-6 \log (3 x) x^3-57 x^3-6 \log ^2(3 x) x^2-115 \log (3 x) x^2-406 x^2-2 \log ^3(3 x) x-59 \log ^2(3 x) x-434 \log (3 x) x+14 x-\log ^3(3 x)-28 \log ^2(3 x)-182 \log (3 x)+196\right )}{(x+\log (3 x))^3}dx\)

\(\Big \downarrow \) 25

\(\displaystyle -2 \int \frac {e^{4 x} x \left (-2 x^4-6 \log (3 x) x^3-57 x^3-6 \log ^2(3 x) x^2-115 \log (3 x) x^2-406 x^2-2 \log ^3(3 x) x-59 \log ^2(3 x) x-434 \log (3 x) x+14 x-\log ^3(3 x)-28 \log ^2(3 x)-182 \log (3 x)+196\right )}{(x+\log (3 x))^3}dx\)

\(\Big \downarrow \) 7293

\(\displaystyle -2 \int \left (\frac {196 e^{4 x} x (x+1)}{(x+\log (3 x))^3}-e^{4 x} x (2 x+1)-\frac {28 e^{4 x} x (2 x+1)}{x+\log (3 x)}-\frac {14 e^{4 x} x (27 x+13)}{(x+\log (3 x))^2}\right )dx\)

\(\Big \downarrow \) 2009

\(\displaystyle -2 \left (196 \int \frac {e^{4 x} x^2}{(x+\log (3 x))^3}dx-378 \int \frac {e^{4 x} x^2}{(x+\log (3 x))^2}dx-56 \int \frac {e^{4 x} x^2}{x+\log (3 x)}dx+196 \int \frac {e^{4 x} x}{(x+\log (3 x))^3}dx-182 \int \frac {e^{4 x} x}{(x+\log (3 x))^2}dx-28 \int \frac {e^{4 x} x}{x+\log (3 x)}dx-\frac {1}{2} e^{4 x} x^2\right )\)

Input:

Int[(E^(4*x)*(-392*x - 28*x^2 + 812*x^3 + 114*x^4 + 4*x^5) + E^(4*x)*(364* 
x + 868*x^2 + 230*x^3 + 12*x^4)*Log[3*x] + E^(4*x)*(56*x + 118*x^2 + 12*x^ 
3)*Log[3*x]^2 + E^(4*x)*(2*x + 4*x^2)*Log[3*x]^3)/(x^3 + 3*x^2*Log[3*x] + 
3*x*Log[3*x]^2 + Log[3*x]^3),x]
 

Output:

$Aborted
 
Maple [A] (verified)

Time = 1.39 (sec) , antiderivative size = 34, normalized size of antiderivative = 1.62

method result size
risch \(x^{2} {\mathrm e}^{4 x}+\frac {28 \left (x +\ln \left (3 x \right )+7\right ) x^{2} {\mathrm e}^{4 x}}{\left (x +\ln \left (3 x \right )\right )^{2}}\) \(34\)
parallelrisch \(\frac {2 x^{4} {\mathrm e}^{4 x}+4 \ln \left (3 x \right ) {\mathrm e}^{4 x} x^{3}+2 \ln \left (3 x \right )^{2} {\mathrm e}^{4 x} x^{2}+56 x^{3} {\mathrm e}^{4 x}+56 \ln \left (3 x \right ) {\mathrm e}^{4 x} x^{2}+392 x^{2} {\mathrm e}^{4 x}}{2 x^{2}+4 x \ln \left (3 x \right )+2 \ln \left (3 x \right )^{2}}\) \(103\)

Input:

int(((4*x^2+2*x)*exp(2*x)^2*ln(3*x)^3+(12*x^3+118*x^2+56*x)*exp(2*x)^2*ln( 
3*x)^2+(12*x^4+230*x^3+868*x^2+364*x)*exp(2*x)^2*ln(3*x)+(4*x^5+114*x^4+81 
2*x^3-28*x^2-392*x)*exp(2*x)^2)/(ln(3*x)^3+3*x*ln(3*x)^2+3*x^2*ln(3*x)+x^3 
),x,method=_RETURNVERBOSE)
 

Output:

x^2*exp(4*x)+28*(x+ln(3*x)+7)*x^2*exp(4*x)/(x+ln(3*x))^2
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 73 vs. \(2 (20) = 40\).

Time = 0.09 (sec) , antiderivative size = 73, normalized size of antiderivative = 3.48 \[ \int \frac {e^{4 x} \left (-392 x-28 x^2+812 x^3+114 x^4+4 x^5\right )+e^{4 x} \left (364 x+868 x^2+230 x^3+12 x^4\right ) \log (3 x)+e^{4 x} \left (56 x+118 x^2+12 x^3\right ) \log ^2(3 x)+e^{4 x} \left (2 x+4 x^2\right ) \log ^3(3 x)}{x^3+3 x^2 \log (3 x)+3 x \log ^2(3 x)+\log ^3(3 x)} \, dx=\frac {x^{2} e^{\left (4 \, x\right )} \log \left (3 \, x\right )^{2} + 2 \, {\left (x^{3} + 14 \, x^{2}\right )} e^{\left (4 \, x\right )} \log \left (3 \, x\right ) + {\left (x^{4} + 28 \, x^{3} + 196 \, x^{2}\right )} e^{\left (4 \, x\right )}}{x^{2} + 2 \, x \log \left (3 \, x\right ) + \log \left (3 \, x\right )^{2}} \] Input:

integrate(((4*x^2+2*x)*exp(2*x)^2*log(3*x)^3+(12*x^3+118*x^2+56*x)*exp(2*x 
)^2*log(3*x)^2+(12*x^4+230*x^3+868*x^2+364*x)*exp(2*x)^2*log(3*x)+(4*x^5+1 
14*x^4+812*x^3-28*x^2-392*x)*exp(2*x)^2)/(log(3*x)^3+3*x*log(3*x)^2+3*x^2* 
log(3*x)+x^3),x, algorithm="fricas")
 

Output:

(x^2*e^(4*x)*log(3*x)^2 + 2*(x^3 + 14*x^2)*e^(4*x)*log(3*x) + (x^4 + 28*x^ 
3 + 196*x^2)*e^(4*x))/(x^2 + 2*x*log(3*x) + log(3*x)^2)
 

Sympy [B] (verification not implemented)

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

Time = 0.15 (sec) , antiderivative size = 66, normalized size of antiderivative = 3.14 \[ \int \frac {e^{4 x} \left (-392 x-28 x^2+812 x^3+114 x^4+4 x^5\right )+e^{4 x} \left (364 x+868 x^2+230 x^3+12 x^4\right ) \log (3 x)+e^{4 x} \left (56 x+118 x^2+12 x^3\right ) \log ^2(3 x)+e^{4 x} \left (2 x+4 x^2\right ) \log ^3(3 x)}{x^3+3 x^2 \log (3 x)+3 x \log ^2(3 x)+\log ^3(3 x)} \, dx=\frac {\left (x^{4} + 2 x^{3} \log {\left (3 x \right )} + 28 x^{3} + x^{2} \log {\left (3 x \right )}^{2} + 28 x^{2} \log {\left (3 x \right )} + 196 x^{2}\right ) e^{4 x}}{x^{2} + 2 x \log {\left (3 x \right )} + \log {\left (3 x \right )}^{2}} \] Input:

integrate(((4*x**2+2*x)*exp(2*x)**2*ln(3*x)**3+(12*x**3+118*x**2+56*x)*exp 
(2*x)**2*ln(3*x)**2+(12*x**4+230*x**3+868*x**2+364*x)*exp(2*x)**2*ln(3*x)+ 
(4*x**5+114*x**4+812*x**3-28*x**2-392*x)*exp(2*x)**2)/(ln(3*x)**3+3*x*ln(3 
*x)**2+3*x**2*ln(3*x)+x**3),x)
 

Output:

(x**4 + 2*x**3*log(3*x) + 28*x**3 + x**2*log(3*x)**2 + 28*x**2*log(3*x) + 
196*x**2)*exp(4*x)/(x**2 + 2*x*log(3*x) + log(3*x)**2)
 

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 83 vs. \(2 (20) = 40\).

Time = 0.19 (sec) , antiderivative size = 83, normalized size of antiderivative = 3.95 \[ \int \frac {e^{4 x} \left (-392 x-28 x^2+812 x^3+114 x^4+4 x^5\right )+e^{4 x} \left (364 x+868 x^2+230 x^3+12 x^4\right ) \log (3 x)+e^{4 x} \left (56 x+118 x^2+12 x^3\right ) \log ^2(3 x)+e^{4 x} \left (2 x+4 x^2\right ) \log ^3(3 x)}{x^3+3 x^2 \log (3 x)+3 x \log ^2(3 x)+\log ^3(3 x)} \, dx=\frac {{\left (x^{4} + 2 \, x^{3} {\left (\log \left (3\right ) + 14\right )} + x^{2} \log \left (x\right )^{2} + {\left (\log \left (3\right )^{2} + 28 \, \log \left (3\right ) + 196\right )} x^{2} + 2 \, {\left (x^{3} + x^{2} {\left (\log \left (3\right ) + 14\right )}\right )} \log \left (x\right )\right )} e^{\left (4 \, x\right )}}{x^{2} + 2 \, x \log \left (3\right ) + \log \left (3\right )^{2} + 2 \, {\left (x + \log \left (3\right )\right )} \log \left (x\right ) + \log \left (x\right )^{2}} \] Input:

integrate(((4*x^2+2*x)*exp(2*x)^2*log(3*x)^3+(12*x^3+118*x^2+56*x)*exp(2*x 
)^2*log(3*x)^2+(12*x^4+230*x^3+868*x^2+364*x)*exp(2*x)^2*log(3*x)+(4*x^5+1 
14*x^4+812*x^3-28*x^2-392*x)*exp(2*x)^2)/(log(3*x)^3+3*x*log(3*x)^2+3*x^2* 
log(3*x)+x^3),x, algorithm="maxima")
 

Output:

(x^4 + 2*x^3*(log(3) + 14) + x^2*log(x)^2 + (log(3)^2 + 28*log(3) + 196)*x 
^2 + 2*(x^3 + x^2*(log(3) + 14))*log(x))*e^(4*x)/(x^2 + 2*x*log(3) + log(3 
)^2 + 2*(x + log(3))*log(x) + log(x)^2)
 

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 87 vs. \(2 (20) = 40\).

Time = 0.15 (sec) , antiderivative size = 87, normalized size of antiderivative = 4.14 \[ \int \frac {e^{4 x} \left (-392 x-28 x^2+812 x^3+114 x^4+4 x^5\right )+e^{4 x} \left (364 x+868 x^2+230 x^3+12 x^4\right ) \log (3 x)+e^{4 x} \left (56 x+118 x^2+12 x^3\right ) \log ^2(3 x)+e^{4 x} \left (2 x+4 x^2\right ) \log ^3(3 x)}{x^3+3 x^2 \log (3 x)+3 x \log ^2(3 x)+\log ^3(3 x)} \, dx=\frac {x^{4} e^{\left (4 \, x\right )} + 2 \, x^{3} e^{\left (4 \, x\right )} \log \left (3 \, x\right ) + x^{2} e^{\left (4 \, x\right )} \log \left (3 \, x\right )^{2} + 28 \, x^{3} e^{\left (4 \, x\right )} + 28 \, x^{2} e^{\left (4 \, x\right )} \log \left (3 \, x\right ) + 196 \, x^{2} e^{\left (4 \, x\right )}}{x^{2} + 2 \, x \log \left (3 \, x\right ) + \log \left (3 \, x\right )^{2}} \] Input:

integrate(((4*x^2+2*x)*exp(2*x)^2*log(3*x)^3+(12*x^3+118*x^2+56*x)*exp(2*x 
)^2*log(3*x)^2+(12*x^4+230*x^3+868*x^2+364*x)*exp(2*x)^2*log(3*x)+(4*x^5+1 
14*x^4+812*x^3-28*x^2-392*x)*exp(2*x)^2)/(log(3*x)^3+3*x*log(3*x)^2+3*x^2* 
log(3*x)+x^3),x, algorithm="giac")
 

Output:

(x^4*e^(4*x) + 2*x^3*e^(4*x)*log(3*x) + x^2*e^(4*x)*log(3*x)^2 + 28*x^3*e^ 
(4*x) + 28*x^2*e^(4*x)*log(3*x) + 196*x^2*e^(4*x))/(x^2 + 2*x*log(3*x) + l 
og(3*x)^2)
 

Mupad [B] (verification not implemented)

Time = 3.15 (sec) , antiderivative size = 434, normalized size of antiderivative = 20.67 \[ \int \frac {e^{4 x} \left (-392 x-28 x^2+812 x^3+114 x^4+4 x^5\right )+e^{4 x} \left (364 x+868 x^2+230 x^3+12 x^4\right ) \log (3 x)+e^{4 x} \left (56 x+118 x^2+12 x^3\right ) \log ^2(3 x)+e^{4 x} \left (2 x+4 x^2\right ) \log ^3(3 x)}{x^3+3 x^2 \log (3 x)+3 x \log ^2(3 x)+\log ^3(3 x)} \, dx=\frac {{\mathrm {e}}^{4\,x}\,\left (224\,x^6+2129\,x^5+3727\,x^4+2439\,x^3+449\,x^2\right )}{x^3+3\,x^2+3\,x+1}-\frac {\frac {28\,x\,{\ln \left (3\,x\right )}^2\,\left (x\,{\mathrm {e}}^{4\,x}+2\,x^2\,{\mathrm {e}}^{4\,x}\right )}{x+1}-\frac {14\,x\,\left (14\,x\,{\mathrm {e}}^{4\,x}+x^2\,{\mathrm {e}}^{4\,x}-29\,x^3\,{\mathrm {e}}^{4\,x}-4\,x^4\,{\mathrm {e}}^{4\,x}\right )}{x+1}+\frac {14\,x\,\ln \left (3\,x\right )\,\left (13\,x\,{\mathrm {e}}^{4\,x}+31\,x^2\,{\mathrm {e}}^{4\,x}+8\,x^3\,{\mathrm {e}}^{4\,x}\right )}{x+1}}{x^2+2\,x\,\ln \left (3\,x\right )+{\ln \left (3\,x\right )}^2}-\frac {\frac {14\,x\,\left (93\,x^3\,{\mathrm {e}}^{4\,x}-29\,x^2\,{\mathrm {e}}^{4\,x}-15\,x\,{\mathrm {e}}^{4\,x}+227\,x^4\,{\mathrm {e}}^{4\,x}+148\,x^5\,{\mathrm {e}}^{4\,x}+16\,x^6\,{\mathrm {e}}^{4\,x}\right )}{{\left (x+1\right )}^3}+\frac {28\,x\,{\ln \left (3\,x\right )}^2\,\left (2\,x\,{\mathrm {e}}^{4\,x}+11\,x^2\,{\mathrm {e}}^{4\,x}+16\,x^3\,{\mathrm {e}}^{4\,x}+8\,x^4\,{\mathrm {e}}^{4\,x}\right )}{{\left (x+1\right )}^3}+\frac {28\,x\,\ln \left (3\,x\right )\,\left (15\,x\,{\mathrm {e}}^{4\,x}+85\,x^2\,{\mathrm {e}}^{4\,x}+139\,x^3\,{\mathrm {e}}^{4\,x}+90\,x^4\,{\mathrm {e}}^{4\,x}+16\,x^5\,{\mathrm {e}}^{4\,x}\right )}{{\left (x+1\right )}^3}}{x+\ln \left (3\,x\right )}+\ln \left (3\,x\right )\,{\mathrm {e}}^{4\,x}\,\left (\frac {224\,x^5+448\,x^4+308\,x^3+476\,x^2+700\,x+308}{x^3+3\,x^2+3\,x+1}-\frac {420\,x^2+700\,x+308}{x^3+3\,x^2+3\,x+1}\right ) \] Input:

int((exp(4*x)*(812*x^3 - 28*x^2 - 392*x + 114*x^4 + 4*x^5) + log(3*x)^3*ex 
p(4*x)*(2*x + 4*x^2) + log(3*x)*exp(4*x)*(364*x + 868*x^2 + 230*x^3 + 12*x 
^4) + log(3*x)^2*exp(4*x)*(56*x + 118*x^2 + 12*x^3))/(3*x*log(3*x)^2 + 3*x 
^2*log(3*x) + log(3*x)^3 + x^3),x)
 

Output:

(exp(4*x)*(449*x^2 + 2439*x^3 + 3727*x^4 + 2129*x^5 + 224*x^6))/(3*x + 3*x 
^2 + x^3 + 1) - ((28*x*log(3*x)^2*(x*exp(4*x) + 2*x^2*exp(4*x)))/(x + 1) - 
 (14*x*(14*x*exp(4*x) + x^2*exp(4*x) - 29*x^3*exp(4*x) - 4*x^4*exp(4*x)))/ 
(x + 1) + (14*x*log(3*x)*(13*x*exp(4*x) + 31*x^2*exp(4*x) + 8*x^3*exp(4*x) 
))/(x + 1))/(2*x*log(3*x) + log(3*x)^2 + x^2) - ((14*x*(93*x^3*exp(4*x) - 
29*x^2*exp(4*x) - 15*x*exp(4*x) + 227*x^4*exp(4*x) + 148*x^5*exp(4*x) + 16 
*x^6*exp(4*x)))/(x + 1)^3 + (28*x*log(3*x)^2*(2*x*exp(4*x) + 11*x^2*exp(4* 
x) + 16*x^3*exp(4*x) + 8*x^4*exp(4*x)))/(x + 1)^3 + (28*x*log(3*x)*(15*x*e 
xp(4*x) + 85*x^2*exp(4*x) + 139*x^3*exp(4*x) + 90*x^4*exp(4*x) + 16*x^5*ex 
p(4*x)))/(x + 1)^3)/(x + log(3*x)) + log(3*x)*exp(4*x)*((700*x + 476*x^2 + 
 308*x^3 + 448*x^4 + 224*x^5 + 308)/(3*x + 3*x^2 + x^3 + 1) - (700*x + 420 
*x^2 + 308)/(3*x + 3*x^2 + x^3 + 1))
 

Reduce [B] (verification not implemented)

Time = 0.17 (sec) , antiderivative size = 55, normalized size of antiderivative = 2.62 \[ \int \frac {e^{4 x} \left (-392 x-28 x^2+812 x^3+114 x^4+4 x^5\right )+e^{4 x} \left (364 x+868 x^2+230 x^3+12 x^4\right ) \log (3 x)+e^{4 x} \left (56 x+118 x^2+12 x^3\right ) \log ^2(3 x)+e^{4 x} \left (2 x+4 x^2\right ) \log ^3(3 x)}{x^3+3 x^2 \log (3 x)+3 x \log ^2(3 x)+\log ^3(3 x)} \, dx=\frac {e^{4 x} x^{2} \left (\mathrm {log}\left (3 x \right )^{2}+2 \,\mathrm {log}\left (3 x \right ) x +28 \,\mathrm {log}\left (3 x \right )+x^{2}+28 x +196\right )}{\mathrm {log}\left (3 x \right )^{2}+2 \,\mathrm {log}\left (3 x \right ) x +x^{2}} \] Input:

int(((4*x^2+2*x)*exp(2*x)^2*log(3*x)^3+(12*x^3+118*x^2+56*x)*exp(2*x)^2*lo 
g(3*x)^2+(12*x^4+230*x^3+868*x^2+364*x)*exp(2*x)^2*log(3*x)+(4*x^5+114*x^4 
+812*x^3-28*x^2-392*x)*exp(2*x)^2)/(log(3*x)^3+3*x*log(3*x)^2+3*x^2*log(3* 
x)+x^3),x)
 

Output:

(e**(4*x)*x**2*(log(3*x)**2 + 2*log(3*x)*x + 28*log(3*x) + x**2 + 28*x + 1 
96))/(log(3*x)**2 + 2*log(3*x)*x + x**2)