\(\int \frac {21 x+4 x^2+e^{1+e^4+2 x} (10+22 x+4 x^2)+(5+x) \log (5+x)}{5+x} \, dx\) [6439]

   Optimal result
   Rubi [B] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [A] (verification not implemented)
   Maxima [F]
   Giac [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 44, antiderivative size = 21 \[ \int \frac {21 x+4 x^2+e^{1+e^4+2 x} \left (10+22 x+4 x^2\right )+(5+x) \log (5+x)}{5+x} \, dx=x \left (2 \left (e^{1+e^4+2 x}+x\right )+\log (5+x)\right ) \]

[Out]

(2*x+2*exp(exp(2)^2+2*x+1)+ln(5+x))*x

Rubi [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(48\) vs. \(2(21)=42\).

Time = 0.16 (sec) , antiderivative size = 48, normalized size of antiderivative = 2.29, number of steps used = 10, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.159, Rules used = {6874, 2207, 2225, 6820, 78, 2436, 2332} \[ \int \frac {21 x+4 x^2+e^{1+e^4+2 x} \left (10+22 x+4 x^2\right )+(5+x) \log (5+x)}{5+x} \, dx=2 x^2-e^{2 x+e^4+1}+e^{2 x+e^4+1} (2 x+1)+(x+5) \log (x+5)-5 \log (x+5) \]

[In]

Int[(21*x + 4*x^2 + E^(1 + E^4 + 2*x)*(10 + 22*x + 4*x^2) + (5 + x)*Log[5 + x])/(5 + x),x]

[Out]

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

Rule 78

Int[((a_.) + (b_.)*(x_))*((c_) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p_.), x_Symbol] :> Int[ExpandIntegran
d[(a + b*x)*(c + d*x)^n*(e + f*x)^p, x], x] /; FreeQ[{a, b, c, d, e, f, n}, x] && NeQ[b*c - a*d, 0] && ((ILtQ[
n, 0] && ILtQ[p, 0]) || EqQ[p, 1] || (IGtQ[p, 0] && ( !IntegerQ[n] || LeQ[9*p + 5*(n + 2), 0] || GeQ[n + p + 1
, 0] || (GeQ[n + p + 2, 0] && RationalQ[a, b, c, d, e, f]))))

Rule 2207

Int[((b_.)*(F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[(c + d*x)^m*
((b*F^(g*(e + f*x)))^n/(f*g*n*Log[F])), x] - Dist[d*(m/(f*g*n*Log[F])), Int[(c + d*x)^(m - 1)*(b*F^(g*(e + f*x
)))^n, x], x] /; FreeQ[{F, b, c, d, e, f, g, n}, x] && GtQ[m, 0] && IntegerQ[2*m] &&  !TrueQ[$UseGamma]

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 2332

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

Rule 2436

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

Rule 6820

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

Rule 6874

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

Rubi steps \begin{align*} \text {integral}& = \int \left (2 e^{1+e^4+2 x} (1+2 x)+\frac {21 x+4 x^2+5 \log (5+x)+x \log (5+x)}{5+x}\right ) \, dx \\ & = 2 \int e^{1+e^4+2 x} (1+2 x) \, dx+\int \frac {21 x+4 x^2+5 \log (5+x)+x \log (5+x)}{5+x} \, dx \\ & = e^{1+e^4+2 x} (1+2 x)-2 \int e^{1+e^4+2 x} \, dx+\int \left (\frac {x (21+4 x)}{5+x}+\log (5+x)\right ) \, dx \\ & = -e^{1+e^4+2 x}+e^{1+e^4+2 x} (1+2 x)+\int \frac {x (21+4 x)}{5+x} \, dx+\int \log (5+x) \, dx \\ & = -e^{1+e^4+2 x}+e^{1+e^4+2 x} (1+2 x)+\int \left (1+4 x-\frac {5}{5+x}\right ) \, dx+\text {Subst}(\int \log (x) \, dx,x,5+x) \\ & = -e^{1+e^4+2 x}+2 x^2+e^{1+e^4+2 x} (1+2 x)-5 \log (5+x)+(5+x) \log (5+x) \\ \end{align*}

Mathematica [A] (verified)

Time = 0.11 (sec) , antiderivative size = 21, normalized size of antiderivative = 1.00 \[ \int \frac {21 x+4 x^2+e^{1+e^4+2 x} \left (10+22 x+4 x^2\right )+(5+x) \log (5+x)}{5+x} \, dx=x \left (2 \left (e^{1+e^4+2 x}+x\right )+\log (5+x)\right ) \]

[In]

Integrate[(21*x + 4*x^2 + E^(1 + E^4 + 2*x)*(10 + 22*x + 4*x^2) + (5 + x)*Log[5 + x])/(5 + x),x]

[Out]

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

Maple [A] (verified)

Time = 0.39 (sec) , antiderivative size = 24, normalized size of antiderivative = 1.14

method result size
risch \(x \ln \left (5+x \right )+2 x^{2}+2 \,{\mathrm e}^{1+2 x +{\mathrm e}^{4}} x\) \(24\)
norman \(x \ln \left (5+x \right )+2 x^{2}+2 \,{\mathrm e}^{1+2 x +{\mathrm e}^{4}} x\) \(26\)
parallelrisch \(2 x^{2}+x \ln \left (5+x \right )+2 \,{\mathrm e}^{1+2 x +{\mathrm e}^{4}} x -50\) \(27\)
default \({\mathrm e}^{1+2 x +{\mathrm e}^{4}} \left (1+2 x +{\mathrm e}^{4}\right )-{\mathrm e}^{1+2 x +{\mathrm e}^{4}}-{\mathrm e}^{1+2 x +{\mathrm e}^{4}} {\mathrm e}^{4}+2 x^{2}-5 \ln \left (5+x \right )+\left (5+x \right ) \ln \left (5+x \right )-5\) \(70\)
parts \({\mathrm e}^{1+2 x +{\mathrm e}^{4}} \left (1+2 x +{\mathrm e}^{4}\right )-{\mathrm e}^{1+2 x +{\mathrm e}^{4}}-{\mathrm e}^{1+2 x +{\mathrm e}^{4}} {\mathrm e}^{4}+2 x^{2}-5 \ln \left (5+x \right )+\left (5+x \right ) \ln \left (5+x \right )-5\) \(70\)

[In]

int(((5+x)*ln(5+x)+(4*x^2+22*x+10)*exp(exp(2)^2+2*x+1)+4*x^2+21*x)/(5+x),x,method=_RETURNVERBOSE)

[Out]

x*ln(5+x)+2*x^2+2*exp(1+2*x+exp(4))*x

Fricas [A] (verification not implemented)

none

Time = 0.26 (sec) , antiderivative size = 23, normalized size of antiderivative = 1.10 \[ \int \frac {21 x+4 x^2+e^{1+e^4+2 x} \left (10+22 x+4 x^2\right )+(5+x) \log (5+x)}{5+x} \, dx=2 \, x^{2} + 2 \, x e^{\left (2 \, x + e^{4} + 1\right )} + x \log \left (x + 5\right ) \]

[In]

integrate(((5+x)*log(5+x)+(4*x^2+22*x+10)*exp(exp(2)^2+2*x+1)+4*x^2+21*x)/(5+x),x, algorithm="fricas")

[Out]

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

Sympy [A] (verification not implemented)

Time = 0.12 (sec) , antiderivative size = 24, normalized size of antiderivative = 1.14 \[ \int \frac {21 x+4 x^2+e^{1+e^4+2 x} \left (10+22 x+4 x^2\right )+(5+x) \log (5+x)}{5+x} \, dx=2 x^{2} + 2 x e^{2 x + 1 + e^{4}} + x \log {\left (x + 5 \right )} \]

[In]

integrate(((5+x)*ln(5+x)+(4*x**2+22*x+10)*exp(exp(2)**2+2*x+1)+4*x**2+21*x)/(5+x),x)

[Out]

2*x**2 + 2*x*exp(2*x + 1 + exp(4)) + x*log(x + 5)

Maxima [F]

\[ \int \frac {21 x+4 x^2+e^{1+e^4+2 x} \left (10+22 x+4 x^2\right )+(5+x) \log (5+x)}{5+x} \, dx=\int { \frac {4 \, x^{2} + 2 \, {\left (2 \, x^{2} + 11 \, x + 5\right )} e^{\left (2 \, x + e^{4} + 1\right )} + {\left (x + 5\right )} \log \left (x + 5\right ) + 21 \, x}{x + 5} \,d x } \]

[In]

integrate(((5+x)*log(5+x)+(4*x^2+22*x+10)*exp(exp(2)^2+2*x+1)+4*x^2+21*x)/(5+x),x, algorithm="maxima")

[Out]

2*x^2 + 2*x*e^(2*x + e^4 + 1) - 10*e^(e^4 - 9)*exp_integral_e(1, -2*x - 10) + (x + 5)*log(x + 5) - 10*integrat
e(e^(2*x + e^4 + 1)/(x + 5), x) - 5*log(x + 5)

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 49 vs. \(2 (20) = 40\).

Time = 0.26 (sec) , antiderivative size = 49, normalized size of antiderivative = 2.33 \[ \int \frac {21 x+4 x^2+e^{1+e^4+2 x} \left (10+22 x+4 x^2\right )+(5+x) \log (5+x)}{5+x} \, dx=2 \, {\left (x + 5\right )}^{2} + 2 \, {\left (x + 5\right )} e^{\left (2 \, x + e^{4} + 1\right )} + {\left (x + 5\right )} \log \left (x + 5\right ) - 20 \, x - 10 \, e^{\left (2 \, x + e^{4} + 1\right )} - 5 \, \log \left (x + 5\right ) - 100 \]

[In]

integrate(((5+x)*log(5+x)+(4*x^2+22*x+10)*exp(exp(2)^2+2*x+1)+4*x^2+21*x)/(5+x),x, algorithm="giac")

[Out]

2*(x + 5)^2 + 2*(x + 5)*e^(2*x + e^4 + 1) + (x + 5)*log(x + 5) - 20*x - 10*e^(2*x + e^4 + 1) - 5*log(x + 5) -
100

Mupad [B] (verification not implemented)

Time = 12.77 (sec) , antiderivative size = 24, normalized size of antiderivative = 1.14 \[ \int \frac {21 x+4 x^2+e^{1+e^4+2 x} \left (10+22 x+4 x^2\right )+(5+x) \log (5+x)}{5+x} \, dx=x\,\ln \left (x+5\right )+2\,x^2+2\,x\,{\mathrm {e}}^{2\,x}\,\mathrm {e}\,{\mathrm {e}}^{{\mathrm {e}}^4} \]

[In]

int((21*x + log(x + 5)*(x + 5) + exp(2*x + exp(4) + 1)*(22*x + 4*x^2 + 10) + 4*x^2)/(x + 5),x)

[Out]

x*log(x + 5) + 2*x^2 + 2*x*exp(2*x)*exp(1)*exp(exp(4))