\(\int \frac {1}{(1+x+x^2)^{3/2}} \, dx\) [268]

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

Optimal result

Integrand size = 10, antiderivative size = 19 \[ \int \frac {1}{\left (1+x+x^2\right )^{3/2}} \, dx=\frac {2 (1+2 x)}{3 \sqrt {1+x+x^2}} \]

[Out]

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

Rubi [A] (verified)

Time = 0.00 (sec) , antiderivative size = 19, normalized size of antiderivative = 1.00, number of steps used = 1, number of rules used = 1, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {627} \[ \int \frac {1}{\left (1+x+x^2\right )^{3/2}} \, dx=\frac {2 (2 x+1)}{3 \sqrt {x^2+x+1}} \]

[In]

Int[(1 + x + x^2)^(-3/2),x]

[Out]

(2*(1 + 2*x))/(3*Sqrt[1 + x + x^2])

Rule 627

Int[((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(-3/2), x_Symbol] :> Simp[-2*((b + 2*c*x)/((b^2 - 4*a*c)*Sqrt[a + b*x
+ c*x^2])), x] /; FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*a*c, 0]

Rubi steps \begin{align*} \text {integral}& = \frac {2 (1+2 x)}{3 \sqrt {1+x+x^2}} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.13 (sec) , antiderivative size = 19, normalized size of antiderivative = 1.00 \[ \int \frac {1}{\left (1+x+x^2\right )^{3/2}} \, dx=\frac {2 (1+2 x)}{3 \sqrt {1+x+x^2}} \]

[In]

Integrate[(1 + x + x^2)^(-3/2),x]

[Out]

(2*(1 + 2*x))/(3*Sqrt[1 + x + x^2])

Maple [A] (verified)

Time = 0.43 (sec) , antiderivative size = 16, normalized size of antiderivative = 0.84

method result size
gosper \(\frac {\frac {2}{3}+\frac {4 x}{3}}{\sqrt {x^{2}+x +1}}\) \(16\)
default \(\frac {\frac {2}{3}+\frac {4 x}{3}}{\sqrt {x^{2}+x +1}}\) \(16\)
trager \(\frac {\frac {2}{3}+\frac {4 x}{3}}{\sqrt {x^{2}+x +1}}\) \(16\)
risch \(\frac {\frac {2}{3}+\frac {4 x}{3}}{\sqrt {x^{2}+x +1}}\) \(16\)

[In]

int(1/(x^2+x+1)^(3/2),x,method=_RETURNVERBOSE)

[Out]

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

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 34 vs. \(2 (15) = 30\).

Time = 0.23 (sec) , antiderivative size = 34, normalized size of antiderivative = 1.79 \[ \int \frac {1}{\left (1+x+x^2\right )^{3/2}} \, dx=\frac {2 \, {\left (2 \, x^{2} + \sqrt {x^{2} + x + 1} {\left (2 \, x + 1\right )} + 2 \, x + 2\right )}}{3 \, {\left (x^{2} + x + 1\right )}} \]

[In]

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

[Out]

2/3*(2*x^2 + sqrt(x^2 + x + 1)*(2*x + 1) + 2*x + 2)/(x^2 + x + 1)

Sympy [F]

\[ \int \frac {1}{\left (1+x+x^2\right )^{3/2}} \, dx=\int \frac {1}{\left (x^{2} + x + 1\right )^{\frac {3}{2}}}\, dx \]

[In]

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

[Out]

Integral((x**2 + x + 1)**(-3/2), x)

Maxima [A] (verification not implemented)

none

Time = 0.19 (sec) , antiderivative size = 22, normalized size of antiderivative = 1.16 \[ \int \frac {1}{\left (1+x+x^2\right )^{3/2}} \, dx=\frac {4 \, x}{3 \, \sqrt {x^{2} + x + 1}} + \frac {2}{3 \, \sqrt {x^{2} + x + 1}} \]

[In]

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

[Out]

4/3*x/sqrt(x^2 + x + 1) + 2/3/sqrt(x^2 + x + 1)

Giac [A] (verification not implemented)

none

Time = 0.30 (sec) , antiderivative size = 15, normalized size of antiderivative = 0.79 \[ \int \frac {1}{\left (1+x+x^2\right )^{3/2}} \, dx=\frac {2 \, {\left (2 \, x + 1\right )}}{3 \, \sqrt {x^{2} + x + 1}} \]

[In]

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

[Out]

2/3*(2*x + 1)/sqrt(x^2 + x + 1)

Mupad [B] (verification not implemented)

Time = 0.03 (sec) , antiderivative size = 13, normalized size of antiderivative = 0.68 \[ \int \frac {1}{\left (1+x+x^2\right )^{3/2}} \, dx=\frac {4\,\left (x+\frac {1}{2}\right )}{3\,\sqrt {x^2+x+1}} \]

[In]

int(1/(x + x^2 + 1)^(3/2),x)

[Out]

(4*(x + 1/2))/(3*(x + x^2 + 1)^(1/2))