\(\int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+(4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)) \log (x^2)}{9 x^2+6 x^2 \log (x)+x^2 \log ^2(x)} \, dx\) [954]

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

Optimal result

Integrand size = 81, antiderivative size = 21 \[ \int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+\left (4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{9 x^2+6 x^2 \log (x)+x^2 \log ^2(x)} \, dx=\left (1+\log (x)-\frac {e}{x (3+\log (x))}\right ) \log \left (x^2\right ) \]

[Out]

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

Rubi [F]

\[ \int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+\left (4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{9 x^2+6 x^2 \log (x)+x^2 \log ^2(x)} \, dx=\int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+\left (4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{9 x^2+6 x^2 \log (x)+x^2 \log ^2(x)} \, dx \]

[In]

Int[(-6*E + 18*x + (-2*E + 30*x)*Log[x] + 14*x*Log[x]^2 + 2*x*Log[x]^3 + (4*E + 9*x + (E + 6*x)*Log[x] + x*Log
[x]^2)*Log[x^2])/(9*x^2 + 6*x^2*Log[x] + x^2*Log[x]^2),x]

[Out]

(8*E)/x + 6*E^4*ExpIntegralEi[-3 - Log[x]] + 2*Log[x] + Log[x]^2 + 8*E^4*ExpIntegralEi[-3 - Log[x]]*(3 + Log[x
]) - 4*E^4*ExpIntegralEi[-3 - Log[x]]*Log[x^2] - (9*Log[x^2])/(3 + Log[x]) - (4*E*Log[x^2])/(x*(3 + Log[x])) +
 18*Log[3 + Log[x]] + E*Defer[Int][(Log[x]*Log[x^2])/(x^2*(3 + Log[x])^2), x] + 6*Defer[Int][(Log[x]*Log[x^2])
/(x*(3 + Log[x])^2), x] + Defer[Int][(Log[x]^2*Log[x^2])/(x*(3 + Log[x])^2), x]

Rubi steps \begin{align*} \text {integral}& = \int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+\left (4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{x^2 (3+\log (x))^2} \, dx \\ & = \int \left (-\frac {6 e}{x^2 (3+\log (x))^2}+\frac {18}{x (3+\log (x))^2}-\frac {2 (e-15 x) \log (x)}{x^2 (3+\log (x))^2}+\frac {14 \log ^2(x)}{x (3+\log (x))^2}+\frac {2 \log ^3(x)}{x (3+\log (x))^2}+\frac {\left (4 e+9 x+e \log (x)+6 x \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{x^2 (3+\log (x))^2}\right ) \, dx \\ & = -\left (2 \int \frac {(e-15 x) \log (x)}{x^2 (3+\log (x))^2} \, dx\right )+2 \int \frac {\log ^3(x)}{x (3+\log (x))^2} \, dx+14 \int \frac {\log ^2(x)}{x (3+\log (x))^2} \, dx+18 \int \frac {1}{x (3+\log (x))^2} \, dx-(6 e) \int \frac {1}{x^2 (3+\log (x))^2} \, dx+\int \frac {\left (4 e+9 x+e \log (x)+6 x \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{x^2 (3+\log (x))^2} \, dx \\ & = \frac {6 e}{x (3+\log (x))}-2 \int \left (-\frac {3 (e-15 x)}{x^2 (3+\log (x))^2}+\frac {e-15 x}{x^2 (3+\log (x))}\right ) \, dx+2 \text {Subst}\left (\int \frac {x^3}{(3+x)^2} \, dx,x,\log (x)\right )+14 \text {Subst}\left (\int \frac {x^2}{(3+x)^2} \, dx,x,\log (x)\right )+18 \text {Subst}\left (\int \frac {1}{x^2} \, dx,x,3+\log (x)\right )+(6 e) \int \frac {1}{x^2 (3+\log (x))} \, dx+\int \left (\frac {4 e \log \left (x^2\right )}{x^2 (3+\log (x))^2}+\frac {9 \log \left (x^2\right )}{x (3+\log (x))^2}+\frac {e \log (x) \log \left (x^2\right )}{x^2 (3+\log (x))^2}+\frac {6 \log (x) \log \left (x^2\right )}{x (3+\log (x))^2}+\frac {\log ^2(x) \log \left (x^2\right )}{x (3+\log (x))^2}\right ) \, dx \\ & = -\frac {18}{3+\log (x)}+\frac {6 e}{x (3+\log (x))}-2 \int \frac {e-15 x}{x^2 (3+\log (x))} \, dx+2 \text {Subst}\left (\int \left (-6+x-\frac {27}{(3+x)^2}+\frac {27}{3+x}\right ) \, dx,x,\log (x)\right )+6 \int \frac {e-15 x}{x^2 (3+\log (x))^2} \, dx+6 \int \frac {\log (x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx+9 \int \frac {\log \left (x^2\right )}{x (3+\log (x))^2} \, dx+14 \text {Subst}\left (\int \left (1+\frac {9}{(3+x)^2}-\frac {6}{3+x}\right ) \, dx,x,\log (x)\right )+e \int \frac {\log (x) \log \left (x^2\right )}{x^2 (3+\log (x))^2} \, dx+(4 e) \int \frac {\log \left (x^2\right )}{x^2 (3+\log (x))^2} \, dx+(6 e) \text {Subst}\left (\int \frac {e^{-x}}{3+x} \, dx,x,\log (x)\right )+\int \frac {\log ^2(x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx \\ & = 6 e^4 \operatorname {ExpIntegralEi}(-3-\log (x))+2 \log (x)+\log ^2(x)-\frac {90}{3+\log (x)}+\frac {6 e}{x (3+\log (x))}-4 e^4 \operatorname {ExpIntegralEi}(-3-\log (x)) \log \left (x^2\right )-\frac {9 \log \left (x^2\right )}{3+\log (x)}-\frac {4 e \log \left (x^2\right )}{x (3+\log (x))}-30 \log (3+\log (x))-2 \int \left (\frac {e}{x^2 (3+\log (x))}-\frac {15}{x (3+\log (x))}\right ) \, dx+6 \int \left (\frac {e}{x^2 (3+\log (x))^2}-\frac {15}{x (3+\log (x))^2}\right ) \, dx+6 \int \frac {\log (x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx+18 \int \frac {1}{x (3+\log (x))} \, dx+e \int \frac {\log (x) \log \left (x^2\right )}{x^2 (3+\log (x))^2} \, dx-(8 e) \int \frac {-e^3 x \operatorname {ExpIntegralEi}(-3-\log (x))-\frac {1}{3+\log (x)}}{x^2} \, dx+\int \frac {\log ^2(x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx \\ & = 6 e^4 \operatorname {ExpIntegralEi}(-3-\log (x))+2 \log (x)+\log ^2(x)-\frac {90}{3+\log (x)}+\frac {6 e}{x (3+\log (x))}-4 e^4 \operatorname {ExpIntegralEi}(-3-\log (x)) \log \left (x^2\right )-\frac {9 \log \left (x^2\right )}{3+\log (x)}-\frac {4 e \log \left (x^2\right )}{x (3+\log (x))}-30 \log (3+\log (x))+6 \int \frac {\log (x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx+18 \text {Subst}\left (\int \frac {1}{x} \, dx,x,3+\log (x)\right )+30 \int \frac {1}{x (3+\log (x))} \, dx-90 \int \frac {1}{x (3+\log (x))^2} \, dx+e \int \frac {\log (x) \log \left (x^2\right )}{x^2 (3+\log (x))^2} \, dx-(2 e) \int \frac {1}{x^2 (3+\log (x))} \, dx+(6 e) \int \frac {1}{x^2 (3+\log (x))^2} \, dx-(8 e) \int \left (-\frac {e^3 \operatorname {ExpIntegralEi}(-3-\log (x))}{x}-\frac {1}{x^2 (3+\log (x))}\right ) \, dx+\int \frac {\log ^2(x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx \\ & = 6 e^4 \operatorname {ExpIntegralEi}(-3-\log (x))+2 \log (x)+\log ^2(x)-\frac {90}{3+\log (x)}-4 e^4 \operatorname {ExpIntegralEi}(-3-\log (x)) \log \left (x^2\right )-\frac {9 \log \left (x^2\right )}{3+\log (x)}-\frac {4 e \log \left (x^2\right )}{x (3+\log (x))}-12 \log (3+\log (x))+6 \int \frac {\log (x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx+30 \text {Subst}\left (\int \frac {1}{x} \, dx,x,3+\log (x)\right )-90 \text {Subst}\left (\int \frac {1}{x^2} \, dx,x,3+\log (x)\right )+e \int \frac {\log (x) \log \left (x^2\right )}{x^2 (3+\log (x))^2} \, dx-(2 e) \text {Subst}\left (\int \frac {e^{-x}}{3+x} \, dx,x,\log (x)\right )-(6 e) \int \frac {1}{x^2 (3+\log (x))} \, dx+(8 e) \int \frac {1}{x^2 (3+\log (x))} \, dx+\left (8 e^4\right ) \int \frac {\operatorname {ExpIntegralEi}(-3-\log (x))}{x} \, dx+\int \frac {\log ^2(x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx \\ & = 4 e^4 \operatorname {ExpIntegralEi}(-3-\log (x))+2 \log (x)+\log ^2(x)-4 e^4 \operatorname {ExpIntegralEi}(-3-\log (x)) \log \left (x^2\right )-\frac {9 \log \left (x^2\right )}{3+\log (x)}-\frac {4 e \log \left (x^2\right )}{x (3+\log (x))}+18 \log (3+\log (x))+6 \int \frac {\log (x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx+e \int \frac {\log (x) \log \left (x^2\right )}{x^2 (3+\log (x))^2} \, dx-(6 e) \text {Subst}\left (\int \frac {e^{-x}}{3+x} \, dx,x,\log (x)\right )+(8 e) \text {Subst}\left (\int \frac {e^{-x}}{3+x} \, dx,x,\log (x)\right )+\left (8 e^4\right ) \text {Subst}(\int \operatorname {ExpIntegralEi}(-3-x) \, dx,x,\log (x))+\int \frac {\log ^2(x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx \\ & = \frac {8 e}{x}+6 e^4 \operatorname {ExpIntegralEi}(-3-\log (x))+2 \log (x)+\log ^2(x)+8 e^4 \operatorname {ExpIntegralEi}(-3-\log (x)) (3+\log (x))-4 e^4 \operatorname {ExpIntegralEi}(-3-\log (x)) \log \left (x^2\right )-\frac {9 \log \left (x^2\right )}{3+\log (x)}-\frac {4 e \log \left (x^2\right )}{x (3+\log (x))}+18 \log (3+\log (x))+6 \int \frac {\log (x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx+e \int \frac {\log (x) \log \left (x^2\right )}{x^2 (3+\log (x))^2} \, dx+\int \frac {\log ^2(x) \log \left (x^2\right )}{x (3+\log (x))^2} \, dx \\ \end{align*}

Mathematica [A] (verified)

Time = 0.21 (sec) , antiderivative size = 41, normalized size of antiderivative = 1.95 \[ \int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+\left (4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{9 x^2+6 x^2 \log (x)+x^2 \log ^2(x)} \, dx=\frac {-e \log \left (x^2\right )+3 x \log (x) \left (2+\log \left (x^2\right )\right )+x \log ^2(x) \left (2+\log \left (x^2\right )\right )}{x (3+\log (x))} \]

[In]

Integrate[(-6*E + 18*x + (-2*E + 30*x)*Log[x] + 14*x*Log[x]^2 + 2*x*Log[x]^3 + (4*E + 9*x + (E + 6*x)*Log[x] +
 x*Log[x]^2)*Log[x^2])/(9*x^2 + 6*x^2*Log[x] + x^2*Log[x]^2),x]

[Out]

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

Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(47\) vs. \(2(22)=44\).

Time = 0.34 (sec) , antiderivative size = 48, normalized size of antiderivative = 2.29

method result size
parallelrisch \(-\frac {-\ln \left (x \right )^{2} \ln \left (x^{2}\right ) x -8 x \ln \left (x \right )^{2}+{\mathrm e} \ln \left (x^{2}\right )+9 x \ln \left (x^{2}\right )+72 x}{x \left (3+\ln \left (x \right )\right )}\) \(48\)
default \(-\frac {{\mathrm e} \ln \left (x^{2}\right )}{x \left (3+\ln \left (x \right )\right )}+\frac {6 \,{\mathrm e}}{\left (3+\ln \left (x \right )\right ) x}-\frac {2 \,{\mathrm e}}{x}+\frac {2 \,{\mathrm e} \ln \left (x \right )}{x \left (3+\ln \left (x \right )\right )}+\frac {\ln \left (x^{2}\right )^{2}}{4}+2 \ln \left (x \right )+\ln \left (x \right )^{2}\) \(70\)
risch \(2 \ln \left (x \right )^{2}-\frac {i \pi \ln \left (x \right ) \operatorname {csgn}\left (i x \right )^{2} \operatorname {csgn}\left (i x^{2}\right ) x -2 i \pi \ln \left (x \right ) \operatorname {csgn}\left (i x \right ) \operatorname {csgn}\left (i x^{2}\right )^{2} x +i \pi \ln \left (x \right ) \operatorname {csgn}\left (i x^{2}\right )^{3} x -4 x \ln \left (x \right )+4 \,{\mathrm e}}{2 x}+\frac {i {\mathrm e} \left (\pi \operatorname {csgn}\left (i x \right )^{2} \operatorname {csgn}\left (i x^{2}\right )-2 \pi \,\operatorname {csgn}\left (i x \right ) \operatorname {csgn}\left (i x^{2}\right )^{2}+\pi \operatorname {csgn}\left (i x^{2}\right )^{3}-12 i\right )}{2 x \left (3+\ln \left (x \right )\right )}\) \(142\)

[In]

int(((x*ln(x)^2+(exp(1)+6*x)*ln(x)+4*exp(1)+9*x)*ln(x^2)+2*x*ln(x)^3+14*x*ln(x)^2+(-2*exp(1)+30*x)*ln(x)-6*exp
(1)+18*x)/(x^2*ln(x)^2+6*x^2*ln(x)+9*x^2),x,method=_RETURNVERBOSE)

[Out]

-1/x*(-ln(x)^2*ln(x^2)*x-8*x*ln(x)^2+exp(1)*ln(x^2)+9*x*ln(x^2)+72*x)/(3+ln(x))

Fricas [A] (verification not implemented)

none

Time = 0.27 (sec) , antiderivative size = 37, normalized size of antiderivative = 1.76 \[ \int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+\left (4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{9 x^2+6 x^2 \log (x)+x^2 \log ^2(x)} \, dx=\frac {2 \, {\left (x \log \left (x\right )^{3} + 4 \, x \log \left (x\right )^{2} + {\left (3 \, x - e\right )} \log \left (x\right )\right )}}{x \log \left (x\right ) + 3 \, x} \]

[In]

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

[Out]

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

Sympy [A] (verification not implemented)

Time = 0.08 (sec) , antiderivative size = 31, normalized size of antiderivative = 1.48 \[ \int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+\left (4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{9 x^2+6 x^2 \log (x)+x^2 \log ^2(x)} \, dx=2 \log {\left (x \right )}^{2} + 2 \log {\left (x \right )} + \frac {6 e}{x \log {\left (x \right )} + 3 x} - \frac {2 e}{x} \]

[In]

integrate(((x*ln(x)**2+(exp(1)+6*x)*ln(x)+4*exp(1)+9*x)*ln(x**2)+2*x*ln(x)**3+14*x*ln(x)**2+(-2*exp(1)+30*x)*l
n(x)-6*exp(1)+18*x)/(x**2*ln(x)**2+6*x**2*ln(x)+9*x**2),x)

[Out]

2*log(x)**2 + 2*log(x) + 6*E/(x*log(x) + 3*x) - 2*E/x

Maxima [A] (verification not implemented)

none

Time = 0.22 (sec) , antiderivative size = 37, normalized size of antiderivative = 1.76 \[ \int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+\left (4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{9 x^2+6 x^2 \log (x)+x^2 \log ^2(x)} \, dx=\frac {2 \, {\left (x \log \left (x\right )^{3} + 4 \, x \log \left (x\right )^{2} + {\left (3 \, x - e\right )} \log \left (x\right )\right )}}{x \log \left (x\right ) + 3 \, x} \]

[In]

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

[Out]

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

Giac [A] (verification not implemented)

none

Time = 0.29 (sec) , antiderivative size = 37, normalized size of antiderivative = 1.76 \[ \int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+\left (4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{9 x^2+6 x^2 \log (x)+x^2 \log ^2(x)} \, dx=\frac {2 \, {\left (x \log \left (x\right )^{3} + 4 \, x \log \left (x\right )^{2} + 3 \, x \log \left (x\right ) - e \log \left (x\right )\right )}}{x \log \left (x\right ) + 3 \, x} \]

[In]

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

[Out]

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

Mupad [B] (verification not implemented)

Time = 9.76 (sec) , antiderivative size = 34, normalized size of antiderivative = 1.62 \[ \int \frac {-6 e+18 x+(-2 e+30 x) \log (x)+14 x \log ^2(x)+2 x \log ^3(x)+\left (4 e+9 x+(e+6 x) \log (x)+x \log ^2(x)\right ) \log \left (x^2\right )}{9 x^2+6 x^2 \log (x)+x^2 \log ^2(x)} \, dx=\frac {\ln \left (x\right )\,\left (2\,x+x\,\ln \left (x^2\right )\right )}{x}-\frac {\ln \left (x^2\right )\,\mathrm {e}}{x\,\left (\ln \left (x\right )+3\right )} \]

[In]

int((18*x - 6*exp(1) + 14*x*log(x)^2 + 2*x*log(x)^3 + log(x)*(30*x - 2*exp(1)) + log(x^2)*(9*x + 4*exp(1) + x*
log(x)^2 + log(x)*(6*x + exp(1))))/(6*x^2*log(x) + x^2*log(x)^2 + 9*x^2),x)

[Out]

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