3.93.5 \(\int \frac {-1-e^x x^2 \log (2)+(-1+2 x-x^2) \log (2)+\log (x)}{x^2 \log (2)} \, dx\) [9205]

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

[Out]

5-ln(x)/x/ln(2)+1/x-exp(x)+ln(x^2)-x

________________________________________________________________________________________

Rubi [A]
time = 0.05, antiderivative size = 33, normalized size of antiderivative = 1.18, number of steps used = 9, number of rules used = 4, integrand size = 35, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.114, Rules used = {12, 14, 2225, 2341} \begin {gather*} -x-e^x+\frac {\log (4) \log (x)}{\log (2)}-\frac {\log \left (\frac {x}{2}\right )}{x \log (2)} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-1 - E^x*x^2*Log[2] + (-1 + 2*x - x^2)*Log[2] + Log[x])/(x^2*Log[2]),x]

[Out]

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

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 2225

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 2341

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
]

Rubi steps

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

________________________________________________________________________________________

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

Antiderivative was successfully verified.

[In]

Integrate[(-1 - E^x*x^2*Log[2] + (-1 + 2*x - x^2)*Log[2] + Log[x])/(x^2*Log[2]),x]

[Out]

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

________________________________________________________________________________________

Maple [A]
time = 0.72, size = 37, normalized size = 1.32

method result size
norman \(\frac {1+2 x \ln \left (x \right )-x^{2}-{\mathrm e}^{x} x -\frac {\ln \left (x \right )}{\ln \left (2\right )}}{x}\) \(30\)
risch \(-\frac {\ln \left (x \right )}{x \ln \left (2\right )}+\frac {2 x \ln \left (x \right )-x^{2}-{\mathrm e}^{x} x +1}{x}\) \(34\)
default \(\frac {-\frac {\ln \left (x \right )}{x}-x \ln \left (2\right )+\frac {\ln \left (2\right )}{x}+2 \ln \left (2\right ) \ln \left (x \right )-{\mathrm e}^{x} \ln \left (2\right )}{\ln \left (2\right )}\) \(37\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/ln(2)*(-ln(x)/x-x*ln(2)+ln(2)/x+2*ln(2)*ln(x)-exp(x)*ln(2))

________________________________________________________________________________________

Maxima [A]
time = 0.26, size = 35, normalized size = 1.25 \begin {gather*} -\frac {x \log \left (2\right ) + e^{x} \log \left (2\right ) - 2 \, \log \left (2\right ) \log \left (x\right ) - \frac {\log \left (2\right )}{x} + \frac {\log \left (x\right )}{x}}{\log \left (2\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Fricas [A]
time = 0.40, size = 35, normalized size = 1.25 \begin {gather*} -\frac {x e^{x} \log \left (2\right ) + {\left (x^{2} - 1\right )} \log \left (2\right ) - {\left (2 \, x \log \left (2\right ) - 1\right )} \log \left (x\right )}{x \log \left (2\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Sympy [A]
time = 0.10, size = 20, normalized size = 0.71 \begin {gather*} - x - e^{x} + 2 \log {\left (x \right )} - \frac {\log {\left (x \right )}}{x \log {\left (2 \right )}} + \frac {1}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Giac [A]
time = 0.40, size = 35, normalized size = 1.25 \begin {gather*} -\frac {x^{2} \log \left (2\right ) + x e^{x} \log \left (2\right ) - 2 \, x \log \left (2\right ) \log \left (x\right ) - \log \left (2\right ) + \log \left (x\right )}{x \log \left (2\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Mupad [B]
time = 7.98, size = 26, normalized size = 0.93 \begin {gather*} 2\,\ln \left (x\right )-{\mathrm {e}}^x-x+\frac {1}{x}-\frac {\ln \left (x\right )}{x\,\ln \left (2\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________