3.61.58 \(\int \frac {(-4-5 x-x^2) \log (16+4 x)+(x-2 e^x x^2+(-4-x+e^x (8 x+2 x^2)) \log (16+4 x)) \log (\frac {e^{-x} (-5+10 e^x x)}{2 x})}{-4 x^2-x^3+e^x (8 x^3+2 x^4)} \, dx\)

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

________________________________________________________________________________________

Rubi [A]  time = 3.52, antiderivative size = 26, normalized size of antiderivative = 0.87, number of steps used = 17, number of rules used = 11, integrand size = 104, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.106, Rules used = {6688, 6742, 14, 36, 29, 31, 2395, 2551, 30, 2557, 2554} \begin {gather*} -\frac {\log \left (5-\frac {5 e^{-x}}{2 x}\right ) \log (4 x+16)}{x} \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

Rule 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
 &&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rule 29

Int[(x_)^(-1), x_Symbol] :> Simp[Log[x], x]

Rule 30

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

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rule 36

Int[1/(((a_.) + (b_.)*(x_))*((c_.) + (d_.)*(x_))), x_Symbol] :> Dist[b/(b*c - a*d), Int[1/(a + b*x), x], x] -
Dist[d/(b*c - a*d), Int[1/(c + d*x), x], x] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0]

Rule 2395

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

Rule 2551

Int[Log[u_]*((a_.) + (b_.)*(x_))^(m_.), x_Symbol] :> Simp[((a + b*x)^(m + 1)*Log[u])/(b*(m + 1)), x] - Dist[1/
(b*(m + 1)), Int[SimplifyIntegrand[((a + b*x)^(m + 1)*D[u, x])/u, x], x], x] /; FreeQ[{a, b, m}, x] && Inverse
FunctionFreeQ[u, x] && NeQ[m, -1]

Rule 2554

Int[Log[u_]*(v_), x_Symbol] :> With[{w = IntHide[v, x]}, Dist[Log[u], w, x] - Int[SimplifyIntegrand[(w*D[u, x]
)/u, x], x] /; InverseFunctionFreeQ[w, x]] /; InverseFunctionFreeQ[u, x]

Rule 2557

Int[Log[v_]*Log[w_]*(u_), x_Symbol] :> With[{z = IntHide[u, x]}, Dist[Log[v]*Log[w], z, x] + (-Int[SimplifyInt
egrand[(z*Log[w]*D[v, x])/v, x], x] - Int[SimplifyIntegrand[(z*Log[v]*D[w, x])/w, x], x]) /; InverseFunctionFr
eeQ[z, x]] /; InverseFunctionFreeQ[v, x] && InverseFunctionFreeQ[w, x]

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

________________________________________________________________________________________

Mathematica [A]  time = 0.47, size = 33, normalized size = 1.10 \begin {gather*} \log (4+x)-\frac {\left (x+\log \left (5-\frac {5 e^{-x}}{2 x}\right )\right ) \log (4 (4+x))}{x} \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

fricas [A]  time = 0.78, size = 28, normalized size = 0.93 \begin {gather*} -\frac {\log \left (4 \, x + 16\right ) \log \left (\frac {5 \, {\left (2 \, x e^{x} - 1\right )} e^{\left (-x\right )}}{2 \, x}\right )}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

giac [B]  time = 0.29, size = 69, normalized size = 2.30 \begin {gather*} \frac {2 \, \log \relax (2)^{2} - 2 \, \log \relax (2) \log \left (5 \, {\left (2 \, x e^{x} - 1\right )} e^{\left (-x\right )}\right ) + \log \relax (2) \log \left (x + 4\right ) - \log \left (5 \, {\left (2 \, x e^{x} - 1\right )} e^{\left (-x\right )}\right ) \log \left (x + 4\right ) + 2 \, \log \relax (2) \log \relax (x) + \log \left (x + 4\right ) \log \relax (x)}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

maple [C]  time = 0.27, size = 290, normalized size = 9.67




method result size



risch \(\frac {\ln \left (4 x +16\right ) \ln \left ({\mathrm e}^{x}\right )}{x}+\frac {\ln \left (4 x +16\right ) \left (-i \pi \,\mathrm {csgn}\left (i \left ({\mathrm e}^{x} x -\frac {1}{2}\right )\right ) \mathrm {csgn}\left (i {\mathrm e}^{-x} \left ({\mathrm e}^{x} x -\frac {1}{2}\right )\right )^{2}+i \pi \,\mathrm {csgn}\left (i \left ({\mathrm e}^{x} x -\frac {1}{2}\right )\right ) \mathrm {csgn}\left (i {\mathrm e}^{-x} \left ({\mathrm e}^{x} x -\frac {1}{2}\right )\right ) \mathrm {csgn}\left (i {\mathrm e}^{-x}\right )+i \pi \mathrm {csgn}\left (i {\mathrm e}^{-x} \left ({\mathrm e}^{x} x -\frac {1}{2}\right )\right )^{3}-i \pi \mathrm {csgn}\left (i {\mathrm e}^{-x} \left ({\mathrm e}^{x} x -\frac {1}{2}\right )\right )^{2} \mathrm {csgn}\left (i {\mathrm e}^{-x}\right )-i \pi \,\mathrm {csgn}\left (i {\mathrm e}^{-x} \left ({\mathrm e}^{x} x -\frac {1}{2}\right )\right ) \mathrm {csgn}\left (\frac {i \left ({\mathrm e}^{x} x -\frac {1}{2}\right ) {\mathrm e}^{-x}}{x}\right )^{2}+i \pi \,\mathrm {csgn}\left (i {\mathrm e}^{-x} \left ({\mathrm e}^{x} x -\frac {1}{2}\right )\right ) \mathrm {csgn}\left (\frac {i \left ({\mathrm e}^{x} x -\frac {1}{2}\right ) {\mathrm e}^{-x}}{x}\right ) \mathrm {csgn}\left (\frac {i}{x}\right )-i \pi \mathrm {csgn}\left (\frac {i \left ({\mathrm e}^{x} x -\frac {1}{2}\right ) {\mathrm e}^{-x}}{x}\right )^{2} \mathrm {csgn}\left (\frac {i}{x}\right )+i \pi \mathrm {csgn}\left (\frac {i \left ({\mathrm e}^{x} x -\frac {1}{2}\right ) {\mathrm e}^{-x}}{x}\right )^{3}-2 \ln \relax (5)+2 \ln \relax (x )-2 \ln \left ({\mathrm e}^{x} x -\frac {1}{2}\right )\right )}{2 x}\) \(290\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/x*ln(4*x+16)*ln(exp(x))+1/2*ln(4*x+16)*(-I*Pi*csgn(I*(exp(x)*x-1/2))*csgn(I*exp(-x)*(exp(x)*x-1/2))^2+I*Pi*c
sgn(I*(exp(x)*x-1/2))*csgn(I*exp(-x)*(exp(x)*x-1/2))*csgn(I*exp(-x))+I*Pi*csgn(I*exp(-x)*(exp(x)*x-1/2))^3-I*P
i*csgn(I*exp(-x)*(exp(x)*x-1/2))^2*csgn(I*exp(-x))-I*Pi*csgn(I*exp(-x)*(exp(x)*x-1/2))*csgn(I/x*(exp(x)*x-1/2)
*exp(-x))^2+I*Pi*csgn(I*exp(-x)*(exp(x)*x-1/2))*csgn(I/x*(exp(x)*x-1/2)*exp(-x))*csgn(I/x)-I*Pi*csgn(I/x*(exp(
x)*x-1/2)*exp(-x))^2*csgn(I/x)+I*Pi*csgn(I/x*(exp(x)*x-1/2)*exp(-x))^3-2*ln(5)+2*ln(x)-2*ln(exp(x)*x-1/2))/x

________________________________________________________________________________________

maxima [B]  time = 0.50, size = 58, normalized size = 1.93 \begin {gather*} -\frac {2 \, \log \relax (5) \log \relax (2) - 2 \, \log \relax (2)^{2} + {\left (2 \, \log \relax (2) + \log \left (x + 4\right )\right )} \log \left (2 \, x e^{x} - 1\right ) - {\left (x - \log \relax (5) + \log \relax (2) + \log \relax (x)\right )} \log \left (x + 4\right ) - 2 \, \log \relax (2) \log \relax (x)}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

mupad [B]  time = 5.10, size = 29, normalized size = 0.97 \begin {gather*} \ln \left (x+4\right )-\frac {\ln \left (4\,x+16\right )\,\ln \left (\frac {5\,\left (2\,x\,{\mathrm {e}}^x-1\right )}{2\,x}\right )}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

log(x + 4) - (log(4*x + 16)*log((5*(2*x*exp(x) - 1))/(2*x)))/x

________________________________________________________________________________________

sympy [A]  time = 0.69, size = 26, normalized size = 0.87 \begin {gather*} - \frac {\log {\left (\frac {\left (5 x e^{x} - \frac {5}{2}\right ) e^{- x}}{x} \right )} \log {\left (4 x + 16 \right )}}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-log((5*x*exp(x) - 5/2)*exp(-x)/x)*log(4*x + 16)/x

________________________________________________________________________________________