3.38.92 \(\int \frac {1+(8+2 x-16 x^3-4 x^4) \log ^2(4+x)}{(4+x) \log ^2(4+x)} \, dx\)

Optimal. Leaf size=18 \[ 2+2 x-x^4-\frac {1}{\log (4+x)} \]

________________________________________________________________________________________

Rubi [A]  time = 0.17, antiderivative size = 17, normalized size of antiderivative = 0.94, number of steps used = 7, number of rules used = 5, integrand size = 36, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.139, Rules used = {6688, 6742, 2390, 2302, 30} \begin {gather*} -x^4+2 x-\frac {1}{\log (x+4)} \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

Rule 30

Int[(x_)^(m_.), x_Symbol] :> Simp[x^(m + 1)/(m + 1), x] /; FreeQ[m, x] && NeQ[m, -1]

Rule 2302

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)/(x_), x_Symbol] :> Dist[1/(b*n), Subst[Int[x^p, x], x, a + b*L
og[c*x^n]], x] /; FreeQ[{a, b, c, n, p}, x]

Rule 2390

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_) + (g_.)*(x_))^(q_.), x_Symbol] :> Dist[1/
e, Subst[Int[((f*x)/d)^q*(a + b*Log[c*x^n])^p, x], x, d + e*x], x] /; FreeQ[{a, b, c, d, e, f, g, n, p, q}, x]
 && EqQ[e*f - d*g, 0]

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 \left (4+x-8 x^3-2 x^4\right )+\frac {1}{\log ^2(4+x)}}{4+x} \, dx\\ &=\int \left (-2 \left (-1+2 x^3\right )+\frac {1}{(4+x) \log ^2(4+x)}\right ) \, dx\\ &=-\left (2 \int \left (-1+2 x^3\right ) \, dx\right )+\int \frac {1}{(4+x) \log ^2(4+x)} \, dx\\ &=2 x-x^4+\operatorname {Subst}\left (\int \frac {1}{x \log ^2(x)} \, dx,x,4+x\right )\\ &=2 x-x^4+\operatorname {Subst}\left (\int \frac {1}{x^2} \, dx,x,\log (4+x)\right )\\ &=2 x-x^4-\frac {1}{\log (4+x)}\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.05, size = 17, normalized size = 0.94 \begin {gather*} 2 x-x^4-\frac {1}{\log (4+x)} \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

fricas [A]  time = 0.66, size = 22, normalized size = 1.22 \begin {gather*} -\frac {{\left (x^{4} - 2 \, x\right )} \log \left (x + 4\right ) + 1}{\log \left (x + 4\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

maple [A]  time = 0.09, size = 18, normalized size = 1.00




method result size



risch \(-x^{4}+2 x -\frac {1}{\ln \left (4+x \right )}\) \(18\)
norman \(\frac {-1+2 x \ln \left (4+x \right )-x^{4} \ln \left (4+x \right )}{\ln \left (4+x \right )}\) \(26\)
derivativedivides \(-\left (4+x \right )^{4}+16 \left (4+x \right )^{3}-96 \left (4+x \right )^{2}+1032+258 x -\frac {1}{\ln \left (4+x \right )}\) \(35\)
default \(-\left (4+x \right )^{4}+16 \left (4+x \right )^{3}-96 \left (4+x \right )^{2}+1032+258 x -\frac {1}{\ln \left (4+x \right )}\) \(35\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

maxima [A]  time = 0.50, size = 17, normalized size = 0.94 \begin {gather*} -x^{4} + 2 \, x - \frac {1}{\log \left (x + 4\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________