3.745 \(\int (\frac{(1+e^x) x}{\sqrt{e^x+x}}+2 \sqrt{e^x+x}) \, dx\)

Optimal. Leaf size=12 \[ 2 x \sqrt{x+e^x} \]

[Out]

2*x*Sqrt[E^x + x]

________________________________________________________________________________________

Rubi [A]  time = 0.258604, antiderivative size = 12, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 3, integrand size = 28, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.107, Rules used = {6742, 2273, 2262} \[ 2 x \sqrt{x+e^x} \]

Antiderivative was successfully verified.

[In]

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

[Out]

2*x*Sqrt[E^x + x]

Rule 6742

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

Rule 2273

Int[(x_)^(m_.)*(E^(x_) + (x_)^(m_.))^(n_), x_Symbol] :> -Simp[(E^x + x^m)^(n + 1)/(n + 1), x] + (Dist[m, Int[x
^(m - 1)*(E^x + x^m)^n, x], x] + Int[(E^x + x^m)^(n + 1), x]) /; RationalQ[m, n] && GtQ[m, 0] && LtQ[n, 0] &&
NeQ[n, -1]

Rule 2262

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

Rubi steps

\begin{align*} \int \left (\frac{\left (1+e^x\right ) x}{\sqrt{e^x+x}}+2 \sqrt{e^x+x}\right ) \, dx &=2 \int \sqrt{e^x+x} \, dx+\int \frac{\left (1+e^x\right ) x}{\sqrt{e^x+x}} \, dx\\ &=2 \int \sqrt{e^x+x} \, dx+\int \left (\frac{x}{\sqrt{e^x+x}}+\frac{e^x x}{\sqrt{e^x+x}}\right ) \, dx\\ &=2 \int \sqrt{e^x+x} \, dx+\int \frac{x}{\sqrt{e^x+x}} \, dx+\int \frac{e^x x}{\sqrt{e^x+x}} \, dx\\ &=-2 \sqrt{e^x+x}+2 x \sqrt{e^x+x}+\int \frac{1}{\sqrt{e^x+x}} \, dx-\int \frac{x}{\sqrt{e^x+x}} \, dx+\int \sqrt{e^x+x} \, dx\\ &=2 x \sqrt{e^x+x}\\ \end{align*}

Mathematica [A]  time = 0.0923953, size = 12, normalized size = 1. \[ 2 x \sqrt{x+e^x} \]

Antiderivative was successfully verified.

[In]

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

[Out]

2*x*Sqrt[E^x + x]

________________________________________________________________________________________

Maple [A]  time = 0.048, size = 10, normalized size = 0.8 \begin{align*} 2\,x\sqrt{{{\rm e}^{x}}+x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

2*x*(exp(x)+x)^(1/2)

________________________________________________________________________________________

Maxima [A]  time = 1.13824, size = 22, normalized size = 1.83 \begin{align*} \frac{2 \,{\left (x^{2} + x e^{x}\right )}}{\sqrt{x + e^{x}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

2*(x^2 + x*e^x)/sqrt(x + e^x)

________________________________________________________________________________________

Fricas [F(-2)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: UnboundLocalError} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Exception raised: UnboundLocalError

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{x e^{x} + 3 x + 2 e^{x}}{\sqrt{x + e^{x}}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Integral((x*exp(x) + 3*x + 2*exp(x))/sqrt(x + exp(x)), x)

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{x{\left (e^{x} + 1\right )}}{\sqrt{x + e^{x}}} + 2 \, \sqrt{x + e^{x}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

integrate(x*(e^x + 1)/sqrt(x + e^x) + 2*sqrt(x + e^x), x)