3.30.2 \(\int \frac {-2-4 x+(-2 x-4 x^2-2 x^3) \log (x+x^2)+(-2 x-2 x^2) \log (x+x^2) \log (\log (x+x^2))}{(x^2+x^3) \log (x+x^2)+(x+x^2) \log (x+x^2) \log (\log (x+x^2))} \, dx\)

Optimal. Leaf size=19 \[ 2 (3-x-\log (x+\log (\log (x (1+x))))) \]

________________________________________________________________________________________

Rubi [A]  time = 1.14, antiderivative size = 16, normalized size of antiderivative = 0.84, number of steps used = 5, number of rules used = 4, integrand size = 86, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.047, Rules used = {6688, 12, 6742, 6684} \begin {gather*} -2 x-2 \log (x+\log (\log (x (x+1)))) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

-2*x - 2*Log[x + Log[Log[x*(1 + 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 6684

Int[(u_)/(y_), x_Symbol] :> With[{q = DerivativeDivides[y, u, x]}, Simp[q*Log[RemoveContent[y, x]], x] /;  !Fa
lseQ[q]]

Rule 6688

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

Rule 6742

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

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {2 (-1-2 x-x (1+x) \log (x (1+x)) (1+x+\log (\log (x (1+x)))))}{x (1+x) \log (x (1+x)) (x+\log (\log (x (1+x))))} \, dx\\ &=2 \int \frac {-1-2 x-x (1+x) \log (x (1+x)) (1+x+\log (\log (x (1+x))))}{x (1+x) \log (x (1+x)) (x+\log (\log (x (1+x))))} \, dx\\ &=2 \int \left (-1+\frac {-1-2 x-x \log (x (1+x))-x^2 \log (x (1+x))}{x (1+x) \log (x (1+x)) (x+\log (\log (x (1+x))))}\right ) \, dx\\ &=-2 x+2 \int \frac {-1-2 x-x \log (x (1+x))-x^2 \log (x (1+x))}{x (1+x) \log (x (1+x)) (x+\log (\log (x (1+x))))} \, dx\\ &=-2 x-2 \log (x+\log (\log (x (1+x))))\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.23, size = 14, normalized size = 0.74 \begin {gather*} -2 (x+\log (x+\log (\log (x (1+x))))) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

-2*(x + Log[x + Log[Log[x*(1 + x)]]])

________________________________________________________________________________________

fricas [A]  time = 0.92, size = 16, normalized size = 0.84 \begin {gather*} -2 \, x - 2 \, \log \left (x + \log \left (\log \left (x^{2} + x\right )\right )\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

giac [A]  time = 0.29, size = 16, normalized size = 0.84 \begin {gather*} -2 \, x - 2 \, \log \left (x + \log \left (\log \left (x^{2} + x\right )\right )\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

maple [F]  time = 0.01, size = 0, normalized size = 0.00 \[\int \frac {\left (-2 x^{2}-2 x \right ) \ln \left (x^{2}+x \right ) \ln \left (\ln \left (x^{2}+x \right )\right )+\left (-2 x^{3}-4 x^{2}-2 x \right ) \ln \left (x^{2}+x \right )-4 x -2}{\left (x^{2}+x \right ) \ln \left (x^{2}+x \right ) \ln \left (\ln \left (x^{2}+x \right )\right )+\left (x^{3}+x^{2}\right ) \ln \left (x^{2}+x \right )}\, dx\]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((-2*x^2-2*x)*ln(x^2+x)*ln(ln(x^2+x))+(-2*x^3-4*x^2-2*x)*ln(x^2+x)-4*x-2)/((x^2+x)*ln(x^2+x)*ln(ln(x^2+x))
+(x^3+x^2)*ln(x^2+x)),x)

[Out]

int(((-2*x^2-2*x)*ln(x^2+x)*ln(ln(x^2+x))+(-2*x^3-4*x^2-2*x)*ln(x^2+x)-4*x-2)/((x^2+x)*ln(x^2+x)*ln(ln(x^2+x))
+(x^3+x^2)*ln(x^2+x)),x)

________________________________________________________________________________________

maxima [A]  time = 0.48, size = 17, normalized size = 0.89 \begin {gather*} -2 \, x - 2 \, \log \left (x + \log \left (\log \left (x + 1\right ) + \log \relax (x)\right )\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-2*x - 2*log(x + log(log(x + 1) + log(x)))

________________________________________________________________________________________

mupad [B]  time = 2.40, size = 16, normalized size = 0.84 \begin {gather*} -2\,x-2\,\ln \left (x+\ln \left (\ln \left (x\,\left (x+1\right )\right )\right )\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

- 2*x - 2*log(x + log(log(x*(x + 1))))

________________________________________________________________________________________

sympy [A]  time = 0.51, size = 17, normalized size = 0.89 \begin {gather*} - 2 x - 2 \log {\left (x + \log {\left (\log {\left (x^{2} + x \right )} \right )} \right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-2*x**2-2*x)*ln(x**2+x)*ln(ln(x**2+x))+(-2*x**3-4*x**2-2*x)*ln(x**2+x)-4*x-2)/((x**2+x)*ln(x**2+x)
*ln(ln(x**2+x))+(x**3+x**2)*ln(x**2+x)),x)

[Out]

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

________________________________________________________________________________________