3.42.100 \(\int \frac {2-12 x-2 x^2+e^{2 x} x^2-e^x x^2 \log (2)-16 \log (x^3)+2 \log ^2(x^3)}{2 x^2} \, dx\)

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

________________________________________________________________________________________

Rubi [A]  time = 0.07, antiderivative size = 51, normalized size of antiderivative = 1.42, number of steps used = 12, number of rules used = 5, integrand size = 50, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {12, 14, 2194, 2304, 2305} \begin {gather*} -\frac {\log ^2\left (x^3\right )}{x}+\frac {2 \log \left (x^3\right )}{x}+\frac {e^{2 x}}{4}-x+\frac {5}{x}-6 \log (x)-\frac {1}{2} e^x \log (2) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(2 - 12*x - 2*x^2 + E^(2*x)*x^2 - E^x*x^2*Log[2] - 16*Log[x^3] + 2*Log[x^3]^2)/(2*x^2),x]

[Out]

E^(2*x)/4 + 5/x - x - (E^x*Log[2])/2 - 6*Log[x] + (2*Log[x^3])/x - Log[x^3]^2/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 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 2194

Int[((F_)^((c_.)*((a_.) + (b_.)*(x_))))^(n_.), x_Symbol] :> Simp[(F^(c*(a + b*x)))^n/(b*c*n*Log[F]), x] /; Fre
eQ[{F, a, b, c, n}, x]

Rule 2304

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[((d*x)^(m + 1)*(a + b*Log[c*x^
n]))/(d*(m + 1)), x] - Simp[(b*n*(d*x)^(m + 1))/(d*(m + 1)^2), x] /; FreeQ[{a, b, c, d, m, n}, x] && NeQ[m, -1
]

Rule 2305

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[((d*x)^(m + 1)*(a + b*Lo
g[c*x^n])^p)/(d*(m + 1)), x] - Dist[(b*n*p)/(m + 1), Int[(d*x)^m*(a + b*Log[c*x^n])^(p - 1), x], x] /; FreeQ[{
a, b, c, d, m, n}, x] && NeQ[m, -1] && GtQ[p, 0]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\frac {1}{2} \int \frac {2-12 x-2 x^2+e^{2 x} x^2-e^x x^2 \log (2)-16 \log \left (x^3\right )+2 \log ^2\left (x^3\right )}{x^2} \, dx\\ &=\frac {1}{2} \int \left (e^{2 x}-e^x \log (2)-\frac {2 \left (-1+6 x+x^2+8 \log \left (x^3\right )-\log ^2\left (x^3\right )\right )}{x^2}\right ) \, dx\\ &=\frac {1}{2} \int e^{2 x} \, dx-\frac {1}{2} \log (2) \int e^x \, dx-\int \frac {-1+6 x+x^2+8 \log \left (x^3\right )-\log ^2\left (x^3\right )}{x^2} \, dx\\ &=\frac {e^{2 x}}{4}-\frac {1}{2} e^x \log (2)-\int \left (\frac {-1+6 x+x^2}{x^2}+\frac {8 \log \left (x^3\right )}{x^2}-\frac {\log ^2\left (x^3\right )}{x^2}\right ) \, dx\\ &=\frac {e^{2 x}}{4}-\frac {1}{2} e^x \log (2)-8 \int \frac {\log \left (x^3\right )}{x^2} \, dx-\int \frac {-1+6 x+x^2}{x^2} \, dx+\int \frac {\log ^2\left (x^3\right )}{x^2} \, dx\\ &=\frac {e^{2 x}}{4}+\frac {24}{x}-\frac {1}{2} e^x \log (2)+\frac {8 \log \left (x^3\right )}{x}-\frac {\log ^2\left (x^3\right )}{x}+6 \int \frac {\log \left (x^3\right )}{x^2} \, dx-\int \left (1-\frac {1}{x^2}+\frac {6}{x}\right ) \, dx\\ &=\frac {e^{2 x}}{4}+\frac {5}{x}-x-\frac {1}{2} e^x \log (2)-6 \log (x)+\frac {2 \log \left (x^3\right )}{x}-\frac {\log ^2\left (x^3\right )}{x}\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.08, size = 53, normalized size = 1.47 \begin {gather*} \frac {1}{2} \left (\frac {e^{2 x}}{2}+\frac {10}{x}-2 x-e^x \log (2)-12 \log (x)+\frac {4 \log \left (x^3\right )}{x}-\frac {2 \log ^2\left (x^3\right )}{x}\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(2 - 12*x - 2*x^2 + E^(2*x)*x^2 - E^x*x^2*Log[2] - 16*Log[x^3] + 2*Log[x^3]^2)/(2*x^2),x]

[Out]

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

________________________________________________________________________________________

fricas [A]  time = 0.59, size = 43, normalized size = 1.19 \begin {gather*} -\frac {2 \, x e^{x} \log \relax (2) + 4 \, x^{2} - x e^{\left (2 \, x\right )} + 8 \, {\left (x - 1\right )} \log \left (x^{3}\right ) + 4 \, \log \left (x^{3}\right )^{2} - 20}{4 \, x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

giac [A]  time = 0.12, size = 41, normalized size = 1.14 \begin {gather*} -\frac {2 \, x e^{x} \log \relax (2) + 4 \, x^{2} - x e^{\left (2 \, x\right )} + 24 \, x \log \relax (x) + 36 \, \log \relax (x)^{2} - 24 \, \log \relax (x) - 20}{4 \, x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-1/4*(2*x*e^x*log(2) + 4*x^2 - x*e^(2*x) + 24*x*log(x) + 36*log(x)^2 - 24*log(x) - 20)/x

________________________________________________________________________________________

maple [A]  time = 0.12, size = 56, normalized size = 1.56




method result size



default \(\frac {{\mathrm e}^{2 x}}{4}+\frac {8 \ln \left (x^{3}\right )}{x}+\frac {23}{x}+\frac {-36-2 \ln \left (x^{3}\right )^{2}-12 \ln \left (x^{3}\right )}{2 x}-x -6 \ln \relax (x )-\frac {{\mathrm e}^{x} \ln \relax (2)}{2}\) \(56\)
risch \(-\frac {9 \ln \relax (x )^{2}}{x}+\frac {3 i \left (\pi \mathrm {csgn}\left (i x \right )^{2} \mathrm {csgn}\left (i x^{2}\right )-2 \pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{2}\right )^{2}+\pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{2}\right ) \mathrm {csgn}\left (i x^{3}\right )-\pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{3}\right )^{2}+\pi \mathrm {csgn}\left (i x^{2}\right )^{3}-\pi \,\mathrm {csgn}\left (i x^{2}\right ) \mathrm {csgn}\left (i x^{3}\right )^{2}+\pi \mathrm {csgn}\left (i x^{3}\right )^{3}-2 i\right ) \ln \relax (x )}{x}-\frac {-20+4 x^{2}-x \,{\mathrm e}^{2 x}+24 x \ln \relax (x )-2 \pi ^{2} \mathrm {csgn}\left (i x^{2}\right )^{4} \mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{3}\right )-4 \pi ^{2} \mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{2}\right ) \mathrm {csgn}\left (i x^{3}\right )^{4}-2 \pi ^{2} \mathrm {csgn}\left (i x \right )^{3} \mathrm {csgn}\left (i x^{2}\right )^{2} \mathrm {csgn}\left (i x^{3}\right )+2 \pi ^{2} \mathrm {csgn}\left (i x \right )^{3} \mathrm {csgn}\left (i x^{2}\right ) \mathrm {csgn}\left (i x^{3}\right )^{2}-3 \pi ^{2} \mathrm {csgn}\left (i x \right )^{2} \mathrm {csgn}\left (i x^{2}\right )^{2} \mathrm {csgn}\left (i x^{3}\right )^{2}+4 \pi ^{2} \mathrm {csgn}\left (i x \right )^{2} \mathrm {csgn}\left (i x^{2}\right )^{3} \mathrm {csgn}\left (i x^{3}\right )-2 \pi ^{2} \mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{2}\right )^{3} \mathrm {csgn}\left (i x^{3}\right )^{2}+6 \pi ^{2} \mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{2}\right )^{2} \mathrm {csgn}\left (i x^{3}\right )^{3}-4 i \pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{3}\right )^{2}-4 i \pi \,\mathrm {csgn}\left (i x^{2}\right ) \mathrm {csgn}\left (i x^{3}\right )^{2}+4 i \pi \mathrm {csgn}\left (i x \right )^{2} \mathrm {csgn}\left (i x^{2}\right )-8 i \pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{2}\right )^{2}+2 x \ln \relax (2) {\mathrm e}^{x}-6 \pi ^{2} \mathrm {csgn}\left (i x^{2}\right )^{4} \mathrm {csgn}\left (i x \right )^{2}+4 \pi ^{2} \mathrm {csgn}\left (i x^{2}\right )^{3} \mathrm {csgn}\left (i x \right )^{3}-\pi ^{2} \mathrm {csgn}\left (i x^{2}\right )^{2} \mathrm {csgn}\left (i x \right )^{4}+2 \pi ^{2} \mathrm {csgn}\left (i x^{2}\right )^{4} \mathrm {csgn}\left (i x^{3}\right )^{2}-2 \pi ^{2} \mathrm {csgn}\left (i x^{2}\right )^{3} \mathrm {csgn}\left (i x^{3}\right )^{3}-\pi ^{2} \mathrm {csgn}\left (i x \right )^{2} \mathrm {csgn}\left (i x^{3}\right )^{4}+2 \pi ^{2} \mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{3}\right )^{5}-\pi ^{2} \mathrm {csgn}\left (i x^{2}\right )^{2} \mathrm {csgn}\left (i x^{3}\right )^{4}+2 \pi ^{2} \mathrm {csgn}\left (i x^{2}\right ) \mathrm {csgn}\left (i x^{3}\right )^{5}-\pi ^{2} \mathrm {csgn}\left (i x^{2}\right )^{6}-\pi ^{2} \mathrm {csgn}\left (i x^{3}\right )^{6}+4 \pi ^{2} \mathrm {csgn}\left (i x^{2}\right )^{5} \mathrm {csgn}\left (i x \right )+4 i \pi \mathrm {csgn}\left (i x^{3}\right )^{3}+4 i \pi \mathrm {csgn}\left (i x^{2}\right )^{3}+4 i \pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{2}\right ) \mathrm {csgn}\left (i x^{3}\right )}{4 x}\) \(750\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*exp(x)^2+8*ln(x^3)/x+23/x+1/2*(-36-2*ln(x^3)^2-12*ln(x^3))/x-x-6*ln(x)-1/2*exp(x)*ln(2)

________________________________________________________________________________________

maxima [A]  time = 0.35, size = 45, normalized size = 1.25 \begin {gather*} -\frac {1}{2} \, e^{x} \log \relax (2) - x - \frac {\log \left (x^{3}\right )^{2}}{x} + \frac {2 \, \log \left (x^{3}\right )}{x} + \frac {5}{x} + \frac {1}{4} \, e^{\left (2 \, x\right )} - 6 \, \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

mupad [B]  time = 2.96, size = 42, normalized size = 1.17 \begin {gather*} \frac {{\mathrm {e}}^{2\,x}}{4}-x-2\,\ln \left (x^3\right )+\frac {-{\ln \left (x^3\right )}^2+2\,\ln \left (x^3\right )+5}{x}-\frac {{\mathrm {e}}^x\,\ln \relax (2)}{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(6*x + 8*log(x^3) - (x^2*exp(2*x))/2 - log(x^3)^2 + x^2 + (x^2*exp(x)*log(2))/2 - 1)/x^2,x)

[Out]

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

________________________________________________________________________________________

sympy [A]  time = 0.37, size = 41, normalized size = 1.14 \begin {gather*} - x + \frac {e^{2 x}}{4} - \frac {e^{x} \log {\relax (2 )}}{2} - 6 \log {\relax (x )} - \frac {\log {\left (x^{3} \right )}^{2}}{x} + \frac {2 \log {\left (x^{3} \right )}}{x} + \frac {5}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/2*(2*ln(x**3)**2-16*ln(x**3)+exp(x)**2*x**2-x**2*ln(2)*exp(x)-2*x**2-12*x+2)/x**2,x)

[Out]

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

________________________________________________________________________________________