3.47.35 \(\int \frac {-62-32 x-4 x^2+(32+16 x+2 x^2) \log (2 x)+(16+8 x+x^2) \log ^2(2 x)}{16+8 x+x^2} \, dx\)

Optimal. Leaf size=35 \[ 3-3 (x-\log (3))-x \left (\frac {x+\frac {2}{4+x}}{x}-\log ^2(2 x)\right ) \]

________________________________________________________________________________________

Rubi [A]  time = 0.08, antiderivative size = 19, normalized size of antiderivative = 0.54, number of steps used = 8, number of rules used = 5, integrand size = 51, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.098, Rules used = {27, 6688, 683, 2295, 2296} \begin {gather*} -4 x-\frac {2}{x+4}+x \log ^2(2 x) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-62 - 32*x - 4*x^2 + (32 + 16*x + 2*x^2)*Log[2*x] + (16 + 8*x + x^2)*Log[2*x]^2)/(16 + 8*x + x^2),x]

[Out]

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

Rule 27

Int[(u_.)*((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[u*Cancel[(b/2 + c*x)^(2*p)/c^p], x] /; Fr
eeQ[{a, b, c}, x] && EqQ[b^2 - 4*a*c, 0] && IntegerQ[p]

Rule 683

Int[((d_.) + (e_.)*(x_))^(m_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ExpandIntegrand[(d +
 e*x)^m*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, m}, x] && NeQ[b^2 - 4*a*c, 0] && EqQ[2*c*d - b*e,
 0] && IGtQ[p, 0] &&  !(EqQ[m, 3] && NeQ[p, 1])

Rule 2295

Int[Log[(c_.)*(x_)^(n_.)], x_Symbol] :> Simp[x*Log[c*x^n], x] - Simp[n*x, x] /; FreeQ[{c, n}, x]

Rule 2296

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.), x_Symbol] :> Simp[x*(a + b*Log[c*x^n])^p, x] - Dist[b*n*p, In
t[(a + b*Log[c*x^n])^(p - 1), x], x] /; FreeQ[{a, b, c, n}, x] && GtQ[p, 0] && IntegerQ[2*p]

Rule 6688

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

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.02, size = 21, normalized size = 0.60 \begin {gather*} -\frac {2}{4+x}-4 (4+x)+x \log ^2(2 x) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-62 - 32*x - 4*x^2 + (32 + 16*x + 2*x^2)*Log[2*x] + (16 + 8*x + x^2)*Log[2*x]^2)/(16 + 8*x + x^2),x
]

[Out]

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

________________________________________________________________________________________

fricas [A]  time = 1.02, size = 30, normalized size = 0.86 \begin {gather*} \frac {{\left (x^{2} + 4 \, x\right )} \log \left (2 \, x\right )^{2} - 4 \, x^{2} - 16 \, x - 2}{x + 4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((x^2+8*x+16)*log(2*x)^2+(2*x^2+16*x+32)*log(2*x)-4*x^2-32*x-62)/(x^2+8*x+16),x, algorithm="fricas")

[Out]

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

________________________________________________________________________________________

giac [A]  time = 0.20, size = 19, normalized size = 0.54 \begin {gather*} x \log \left (2 \, x\right )^{2} - 4 \, x - \frac {2}{x + 4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((x^2+8*x+16)*log(2*x)^2+(2*x^2+16*x+32)*log(2*x)-4*x^2-32*x-62)/(x^2+8*x+16),x, algorithm="giac")

[Out]

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

________________________________________________________________________________________

maple [A]  time = 0.11, size = 22, normalized size = 0.63




method result size



derivativedivides \(x \ln \left (2 x \right )^{2}-4 x -\frac {4}{2 x +8}\) \(22\)
default \(x \ln \left (2 x \right )^{2}-4 x -\frac {4}{2 x +8}\) \(22\)
risch \(x \ln \left (2 x \right )^{2}-\frac {2 \left (2 x^{2}+8 x +1\right )}{4+x}\) \(27\)
norman \(\frac {x^{2} \ln \left (2 x \right )^{2}-4 x^{2}+4 x \ln \left (2 x \right )^{2}+62}{4+x}\) \(33\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((x^2+8*x+16)*ln(2*x)^2+(2*x^2+16*x+32)*ln(2*x)-4*x^2-32*x-62)/(x^2+8*x+16),x,method=_RETURNVERBOSE)

[Out]

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

________________________________________________________________________________________

maxima [B]  time = 0.48, size = 82, normalized size = 2.34 \begin {gather*} -4 \, x + \frac {x^{2} \log \relax (2)^{2} + 4 \, x \log \relax (2)^{2} + {\left (x^{2} + 4 \, x\right )} \log \relax (x)^{2} + 2 \, {\left (x^{2} \log \relax (2) + 4 \, x {\left (\log \relax (2) - 1\right )}\right )} \log \relax (x) + 32 \, \log \relax (2)}{x + 4} - \frac {32 \, \log \left (2 \, x\right )}{x + 4} - \frac {2}{x + 4} + 8 \, \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((x^2+8*x+16)*log(2*x)^2+(2*x^2+16*x+32)*log(2*x)-4*x^2-32*x-62)/(x^2+8*x+16),x, algorithm="maxima")

[Out]

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

________________________________________________________________________________________

mupad [B]  time = 3.48, size = 18, normalized size = 0.51 \begin {gather*} x\,\left ({\ln \left (2\,x\right )}^2-4\right )-\frac {2}{x+4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(32*x - log(2*x)*(16*x + 2*x^2 + 32) - log(2*x)^2*(8*x + x^2 + 16) + 4*x^2 + 62)/(8*x + x^2 + 16),x)

[Out]

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

________________________________________________________________________________________

sympy [A]  time = 0.15, size = 15, normalized size = 0.43 \begin {gather*} x \log {\left (2 x \right )}^{2} - 4 x - \frac {2}{x + 4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((x**2+8*x+16)*ln(2*x)**2+(2*x**2+16*x+32)*ln(2*x)-4*x**2-32*x-62)/(x**2+8*x+16),x)

[Out]

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

________________________________________________________________________________________