\(\int \frac {-2-2 x+x^2}{(1+x+x^2) \sqrt {-1+x^3}} \, dx\) [159]

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

Optimal result

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

[Out]

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

Rubi [C] (verified)

Result contains higher order function than in optimal. Order 4 vs. order 2 in optimal.

Time = 1.48 (sec) , antiderivative size = 719, normalized size of antiderivative = 37.84, number of steps used = 27, number of rules used = 10, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.385, Rules used = {6860, 225, 2161, 2167, 2138, 21, 425, 435, 455, 37} \[ \int \frac {-2-2 x+x^2}{\left (1+x+x^2\right ) \sqrt {-1+x^3}} \, dx=\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (\sqrt {3}+i\right ) \sqrt {\frac {x^2+x+1}{\left (-x-\sqrt {3}+1\right )^2}} (1-x) \operatorname {EllipticF}\left (\arcsin \left (\frac {-x+\sqrt {3}+1}{-x-\sqrt {3}+1}\right ),-7+4 \sqrt {3}\right )}{\left (3+(2+i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (-x-\sqrt {3}+1\right )^2}} \sqrt {x^3-1}}-\frac {2 \sqrt [4]{3} \left (-\sqrt {3}+i\right ) \sqrt {2-\sqrt {3}} \sqrt {\frac {x^2+x+1}{\left (-x-\sqrt {3}+1\right )^2}} (1-x) \operatorname {EllipticF}\left (\arcsin \left (\frac {-x+\sqrt {3}+1}{-x-\sqrt {3}+1}\right ),-7+4 \sqrt {3}\right )}{\left (3+(2-i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (-x-\sqrt {3}+1\right )^2}} \sqrt {x^3-1}}-\frac {2 \sqrt {2-\sqrt {3}} \sqrt {\frac {x^2+x+1}{\left (-x-\sqrt {3}+1\right )^2}} (1-x) \operatorname {EllipticF}\left (\arcsin \left (\frac {-x+\sqrt {3}+1}{-x-\sqrt {3}+1}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (-x-\sqrt {3}+1\right )^2}} \sqrt {x^3-1}}-\frac {6 \sqrt [4]{3} \left (\sqrt {3}+(-2+i)\right ) \left (\sqrt {3}+i\right ) \sqrt {26+15 \sqrt {3}} \sqrt {\frac {x^2+x+1}{\left (-x+\sqrt {3}+1\right )^2}} (1-x) E\left (\arcsin \left (\frac {-x-\sqrt {3}+1}{-x+\sqrt {3}+1}\right )|-7-4 \sqrt {3}\right )}{\left (3+(2+i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (-x+\sqrt {3}+1\right )^2}} \sqrt {x^3-1}}+\frac {6 \sqrt [4]{3} \left (1+i \sqrt {3}\right ) \left (\sqrt {3}+(-2-i)\right ) \sqrt {26+15 \sqrt {3}} \sqrt {\frac {x^2+x+1}{\left (-x+\sqrt {3}+1\right )^2}} (1-x) E\left (\arcsin \left (\frac {-x-\sqrt {3}+1}{-x+\sqrt {3}+1}\right )|-7-4 \sqrt {3}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (-x+\sqrt {3}+1\right )^2}} \sqrt {x^3-1}}+\frac {2 (1-x)}{\sqrt {x^3-1}} \]

[In]

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

[Out]

(2*(1 - x))/Sqrt[-1 + x^3] + (6*3^(1/4)*(1 + I*Sqrt[3])*((-2 - I) + Sqrt[3])*Sqrt[26 + 15*Sqrt[3]]*(1 - x)*Sqr
t[(1 + x + x^2)/(1 + Sqrt[3] - x)^2]*EllipticE[ArcSin[(1 - Sqrt[3] - x)/(1 + Sqrt[3] - x)], -7 - 4*Sqrt[3]])/(
(3*I + (1 + 2*I)*Sqrt[3])^3*Sqrt[(1 - x)/(1 + Sqrt[3] - x)^2]*Sqrt[-1 + x^3]) - (6*3^(1/4)*((-2 + I) + Sqrt[3]
)*(I + Sqrt[3])*Sqrt[26 + 15*Sqrt[3]]*(1 - x)*Sqrt[(1 + x + x^2)/(1 + Sqrt[3] - x)^2]*EllipticE[ArcSin[(1 - Sq
rt[3] - x)/(1 + Sqrt[3] - x)], -7 - 4*Sqrt[3]])/((3 + (2 + I)*Sqrt[3])^3*Sqrt[(1 - x)/(1 + Sqrt[3] - x)^2]*Sqr
t[-1 + x^3]) - (2*Sqrt[2 - Sqrt[3]]*(1 - x)*Sqrt[(1 + x + x^2)/(1 - Sqrt[3] - x)^2]*EllipticF[ArcSin[(1 + Sqrt
[3] - x)/(1 - Sqrt[3] - x)], -7 + 4*Sqrt[3]])/(3^(1/4)*Sqrt[-((1 - x)/(1 - Sqrt[3] - x)^2)]*Sqrt[-1 + x^3]) -
(2*3^(1/4)*(I - Sqrt[3])*Sqrt[2 - Sqrt[3]]*(1 - x)*Sqrt[(1 + x + x^2)/(1 - Sqrt[3] - x)^2]*EllipticF[ArcSin[(1
 + Sqrt[3] - x)/(1 - Sqrt[3] - x)], -7 + 4*Sqrt[3]])/((3 + (2 - I)*Sqrt[3])*Sqrt[-((1 - x)/(1 - Sqrt[3] - x)^2
)]*Sqrt[-1 + x^3]) + (2*3^(1/4)*Sqrt[2 - Sqrt[3]]*(I + Sqrt[3])*(1 - x)*Sqrt[(1 + x + x^2)/(1 - Sqrt[3] - x)^2
]*EllipticF[ArcSin[(1 + Sqrt[3] - x)/(1 - Sqrt[3] - x)], -7 + 4*Sqrt[3]])/((3 + (2 + I)*Sqrt[3])*Sqrt[-((1 - x
)/(1 - Sqrt[3] - x)^2)]*Sqrt[-1 + x^3])

Rule 21

Int[(u_.)*((a_) + (b_.)*(v_))^(m_.)*((c_) + (d_.)*(v_))^(n_.), x_Symbol] :> Dist[(b/d)^m, Int[u*(c + d*v)^(m +
 n), x], x] /; FreeQ[{a, b, c, d, n}, x] && EqQ[b*c - a*d, 0] && IntegerQ[m] && ( !IntegerQ[n] || SimplerQ[c +
 d*x, a + b*x])

Rule 37

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

Rule 225

Int[1/Sqrt[(a_) + (b_.)*(x_)^3], x_Symbol] :> With[{r = Numer[Rt[b/a, 3]], s = Denom[Rt[b/a, 3]]}, Simp[2*Sqrt
[2 - Sqrt[3]]*(s + r*x)*(Sqrt[(s^2 - r*s*x + r^2*x^2)/((1 - Sqrt[3])*s + r*x)^2]/(3^(1/4)*r*Sqrt[a + b*x^3]*Sq
rt[(-s)*((s + r*x)/((1 - Sqrt[3])*s + r*x)^2)]))*EllipticF[ArcSin[((1 + Sqrt[3])*s + r*x)/((1 - Sqrt[3])*s + r
*x)], -7 + 4*Sqrt[3]], x]] /; FreeQ[{a, b}, x] && NegQ[a]

Rule 425

Int[((a_) + (b_.)*(x_)^(n_))^(p_)*((c_) + (d_.)*(x_)^(n_))^(q_), x_Symbol] :> Simp[(-b)*x*(a + b*x^n)^(p + 1)*
((c + d*x^n)^(q + 1)/(a*n*(p + 1)*(b*c - a*d))), x] + Dist[1/(a*n*(p + 1)*(b*c - a*d)), Int[(a + b*x^n)^(p + 1
)*(c + d*x^n)^q*Simp[b*c + n*(p + 1)*(b*c - a*d) + d*b*(n*(p + q + 2) + 1)*x^n, x], x], x] /; FreeQ[{a, b, c,
d, n, q}, x] && NeQ[b*c - a*d, 0] && LtQ[p, -1] &&  !( !IntegerQ[p] && IntegerQ[q] && LtQ[q, -1]) && IntBinomi
alQ[a, b, c, d, n, p, q, x]

Rule 435

Int[Sqrt[(a_) + (b_.)*(x_)^2]/Sqrt[(c_) + (d_.)*(x_)^2], x_Symbol] :> Simp[(Sqrt[a]/(Sqrt[c]*Rt[-d/c, 2]))*Ell
ipticE[ArcSin[Rt[-d/c, 2]*x], b*(c/(a*d))], x] /; FreeQ[{a, b, c, d}, x] && NegQ[d/c] && GtQ[c, 0] && GtQ[a, 0
]

Rule 455

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

Rule 2138

Int[1/(((a_) + (b_.)*(x_))*Sqrt[(c_) + (d_.)*(x_)^2]*Sqrt[(e_) + (f_.)*(x_)^2]), x_Symbol] :> Dist[a, Int[1/((
a^2 - b^2*x^2)*Sqrt[c + d*x^2]*Sqrt[e + f*x^2]), x], x] - Dist[b, Int[x/((a^2 - b^2*x^2)*Sqrt[c + d*x^2]*Sqrt[
e + f*x^2]), x], x] /; FreeQ[{a, b, c, d, e, f}, x]

Rule 2161

Int[1/(((c_) + (d_.)*(x_))*Sqrt[(a_) + (b_.)*(x_)^3]), x_Symbol] :> With[{q = Rt[b/a, 3]}, Dist[-q/((1 + Sqrt[
3])*d - c*q), Int[1/Sqrt[a + b*x^3], x], x] + Dist[d/((1 + Sqrt[3])*d - c*q), Int[(1 + Sqrt[3] + q*x)/((c + d*
x)*Sqrt[a + b*x^3]), x], x]] /; FreeQ[{a, b, c, d}, x] && NeQ[b^2*c^6 - 20*a*b*c^3*d^3 - 8*a^2*d^6, 0]

Rule 2167

Int[((e_) + (f_.)*(x_))/(((c_) + (d_.)*(x_))*Sqrt[(a_) + (b_.)*(x_)^3]), x_Symbol] :> With[{q = Simplify[(1 +
Sqrt[3])*(f/e)]}, Dist[4*3^(1/4)*Sqrt[2 - Sqrt[3]]*f*(1 + q*x)*(Sqrt[(1 - q*x + q^2*x^2)/(1 + Sqrt[3] + q*x)^2
]/(q*Sqrt[a + b*x^3]*Sqrt[(1 + q*x)/(1 + Sqrt[3] + q*x)^2])), Subst[Int[1/(((1 - Sqrt[3])*d - c*q + ((1 + Sqrt
[3])*d - c*q)*x)*Sqrt[1 - x^2]*Sqrt[7 - 4*Sqrt[3] + x^2]), x], x, (-1 + Sqrt[3] - q*x)/(1 + Sqrt[3] + q*x)], x
]] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[d*e - c*f, 0] && EqQ[b*e^3 - 2*(5 + 3*Sqrt[3])*a*f^3, 0] && NeQ[b*c^
3 - 2*(5 - 3*Sqrt[3])*a*d^3, 0]

Rule 6860

Int[(u_)/((a_.) + (b_.)*(x_)^(n_.) + (c_.)*(x_)^(n2_.)), x_Symbol] :> With[{v = RationalFunctionExpand[u/(a +
b*x^n + c*x^(2*n)), x]}, Int[v, x] /; SumQ[v]] /; FreeQ[{a, b, c}, x] && EqQ[n2, 2*n] && IGtQ[n, 0]

Rubi steps \begin{align*} \text {integral}& = \int \left (\frac {1}{\sqrt {-1+x^3}}-\frac {3 (1+x)}{\left (1+x+x^2\right ) \sqrt {-1+x^3}}\right ) \, dx \\ & = -\left (3 \int \frac {1+x}{\left (1+x+x^2\right ) \sqrt {-1+x^3}} \, dx\right )+\int \frac {1}{\sqrt {-1+x^3}} \, dx \\ & = -\frac {2 \sqrt {2-\sqrt {3}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-3 \int \left (\frac {1-\frac {i}{\sqrt {3}}}{\left (1-i \sqrt {3}+2 x\right ) \sqrt {-1+x^3}}+\frac {1+\frac {i}{\sqrt {3}}}{\left (1+i \sqrt {3}+2 x\right ) \sqrt {-1+x^3}}\right ) \, dx \\ & = -\frac {2 \sqrt {2-\sqrt {3}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\left (3-i \sqrt {3}\right ) \int \frac {1}{\left (1-i \sqrt {3}+2 x\right ) \sqrt {-1+x^3}} \, dx-\left (3+i \sqrt {3}\right ) \int \frac {1}{\left (1+i \sqrt {3}+2 x\right ) \sqrt {-1+x^3}} \, dx \\ & = -\frac {2 \sqrt {2-\sqrt {3}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {\left (3 i+\sqrt {3}\right ) \int \frac {1}{\sqrt {-1+x^3}} \, dx}{3 i+(1+2 i) \sqrt {3}}-\frac {\left (2 \left (3 i+\sqrt {3}\right )\right ) \int \frac {1+\sqrt {3}-x}{\left (1-i \sqrt {3}+2 x\right ) \sqrt {-1+x^3}} \, dx}{3 i+(1+2 i) \sqrt {3}}-\frac {\left (3+i \sqrt {3}\right ) \int \frac {1}{\sqrt {-1+x^3}} \, dx}{3+(2+i) \sqrt {3}}-\frac {\left (2 \left (3+i \sqrt {3}\right )\right ) \int \frac {1+\sqrt {3}-x}{\left (1+i \sqrt {3}+2 x\right ) \sqrt {-1+x^3}} \, dx}{3+(2+i) \sqrt {3}} \\ & = -\frac {2 \sqrt {2-\sqrt {3}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (1+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (i+\sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3+(2+i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {\left (8 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (3 i+\sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {1}{\left (1-i \sqrt {3}+2 \left (1-\sqrt {3}\right )+\left (1-i \sqrt {3}+2 \left (1+\sqrt {3}\right )\right ) x\right ) \sqrt {1-x^2} \sqrt {7-4 \sqrt {3}+x^2}} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right ) \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {\left (8 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (3+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {1}{\left (1+i \sqrt {3}+2 \left (1-\sqrt {3}\right )+\left (1+i \sqrt {3}+2 \left (1+\sqrt {3}\right )\right ) x\right ) \sqrt {1-x^2} \sqrt {7-4 \sqrt {3}+x^2}} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3+(2+i) \sqrt {3}\right ) \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}} \\ & = -\frac {2 \sqrt {2-\sqrt {3}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (1+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (i+\sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3+(2+i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {\left (8 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (3+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {x}{\sqrt {1-x^2} \sqrt {7-4 \sqrt {3}+x^2} \left (\left (1+i \sqrt {3}+2 \left (1-\sqrt {3}\right )\right )^2-\left (1+i \sqrt {3}+2 \left (1+\sqrt {3}\right )\right )^2 x^2\right )} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {\left (8 \sqrt [4]{3} \left (3-(2+i) \sqrt {3}\right ) \sqrt {2-\sqrt {3}} \left (3 i+\sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {1}{\sqrt {1-x^2} \sqrt {7-4 \sqrt {3}+x^2} \left (\left (1-i \sqrt {3}+2 \left (1-\sqrt {3}\right )\right )^2-\left (1-i \sqrt {3}+2 \left (1+\sqrt {3}\right )\right )^2 x^2\right )} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right ) \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {\left (8 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (3 i+\sqrt {3}\right ) \left (3+(2-i) \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {x}{\sqrt {1-x^2} \sqrt {7-4 \sqrt {3}+x^2} \left (\left (1-i \sqrt {3}+2 \left (1-\sqrt {3}\right )\right )^2-\left (1-i \sqrt {3}+2 \left (1+\sqrt {3}\right )\right )^2 x^2\right )} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right ) \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {\left (8 \sqrt [4]{3} \left (3-(2-i) \sqrt {3}\right ) \sqrt {2-\sqrt {3}} \left (3+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {1}{\sqrt {1-x^2} \sqrt {7-4 \sqrt {3}+x^2} \left (\left (1+i \sqrt {3}+2 \left (1-\sqrt {3}\right )\right )^2-\left (1+i \sqrt {3}+2 \left (1+\sqrt {3}\right )\right )^2 x^2\right )} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3+(2+i) \sqrt {3}\right ) \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}} \\ & = -\frac {2 \sqrt {2-\sqrt {3}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (1+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (i+\sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3+(2+i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {\left (8 \sqrt [4]{3} \left (3-(2+i) \sqrt {3}\right ) \sqrt {2-\sqrt {3}} \left (3 i+\sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {1}{\sqrt {1-x^2} \left (7-4 \sqrt {3}+x^2\right )^{3/2}} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {\left (8 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (3 i+\sqrt {3}\right ) \left (3+(2-i) \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {x}{\sqrt {1-x^2} \left (7-4 \sqrt {3}+x^2\right )^{3/2}} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {\left (8 \sqrt [4]{3} \left (3-(2-i) \sqrt {3}\right ) \sqrt {2-\sqrt {3}} \left (3+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {1}{\sqrt {1-x^2} \left (7-4 \sqrt {3}+x^2\right )^{3/2}} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3+(2+i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {\left (8 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (3+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {x}{\sqrt {1-x^2} \left (7-4 \sqrt {3}+x^2\right )^{3/2}} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3+(2+i) \sqrt {3}\right )^2 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}} \\ & = -\frac {2 \sqrt {2-\sqrt {3}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (1+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (i+\sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3+(2+i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {\left (4 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (3 i+\sqrt {3}\right ) \left (3+(2-i) \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {1}{\sqrt {1-x} \left (7-4 \sqrt {3}+x\right )^{3/2}} \, dx,x,\frac {\left (-1+\sqrt {3}+x\right )^2}{\left (1+\sqrt {3}-x\right )^2}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {\left (4 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (3+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {1}{\sqrt {1-x} \left (7-4 \sqrt {3}+x\right )^{3/2}} \, dx,x,\frac {\left (-1+\sqrt {3}+x\right )^2}{\left (1+\sqrt {3}-x\right )^2}\right )}{\left (3+(2+i) \sqrt {3}\right )^2 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {\left (2 \sqrt [4]{3} \left (3-(2+i) \sqrt {3}\right ) \sqrt {2-\sqrt {3}} \left (3 i+\sqrt {3}\right ) \left (26+15 \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {-7+4 \sqrt {3}-x^2}{\sqrt {1-x^2} \sqrt {7-4 \sqrt {3}+x^2}} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {\left (2 \sqrt [4]{3} \left (3-(2-i) \sqrt {3}\right ) \sqrt {2-\sqrt {3}} \left (3+i \sqrt {3}\right ) \left (26+15 \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {-7+4 \sqrt {3}-x^2}{\sqrt {1-x^2} \sqrt {7-4 \sqrt {3}+x^2}} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3+(2+i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}} \\ & = \frac {1-x}{\sqrt {-1+x^3}}+\frac {6 \left (i+\sqrt {3}\right ) (1-x)}{\left (2-\sqrt {3}\right ) \left (3+(2+i) \sqrt {3}\right )^2 \sqrt {-1+x^3}}-\frac {2 \sqrt {2-\sqrt {3}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (1+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (i+\sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3+(2+i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {\left (2 \sqrt [4]{3} \left (3-(2+i) \sqrt {3}\right ) \sqrt {2-\sqrt {3}} \left (3 i+\sqrt {3}\right ) \left (26+15 \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {\sqrt {7-4 \sqrt {3}+x^2}}{\sqrt {1-x^2}} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {\left (2 \sqrt [4]{3} \left (3-(2-i) \sqrt {3}\right ) \sqrt {2-\sqrt {3}} \left (3+i \sqrt {3}\right ) \left (26+15 \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}}\right ) \text {Subst}\left (\int \frac {\sqrt {7-4 \sqrt {3}+x^2}}{\sqrt {1-x^2}} \, dx,x,\frac {-1+\sqrt {3}+x}{1+\sqrt {3}-x}\right )}{\left (3+(2+i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}} \\ & = \frac {1-x}{\sqrt {-1+x^3}}+\frac {6 \left (i+\sqrt {3}\right ) (1-x)}{\left (2-\sqrt {3}\right ) \left (3+(2+i) \sqrt {3}\right )^2 \sqrt {-1+x^3}}+\frac {i \sqrt [4]{3} \sqrt {\frac {2}{3}-\frac {1}{\sqrt {3}}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}} E\left (\arcsin \left (\frac {1-\sqrt {3}-x}{1+\sqrt {3}-x}\right )|-7-4 \sqrt {3}\right )}{\sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {6 \sqrt [4]{3} \left ((-2+i)+\sqrt {3}\right ) \left (i+\sqrt {3}\right ) \sqrt {26+15 \sqrt {3}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1+\sqrt {3}-x\right )^2}} E\left (\arcsin \left (\frac {1-\sqrt {3}-x}{1+\sqrt {3}-x}\right )|-7-4 \sqrt {3}\right )}{\left (3+(2+i) \sqrt {3}\right )^3 \sqrt {\frac {1-x}{\left (1+\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}-\frac {2 \sqrt {2-\sqrt {3}} (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (1+i \sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3 i+(1+2 i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}}+\frac {2 \sqrt [4]{3} \sqrt {2-\sqrt {3}} \left (i+\sqrt {3}\right ) (1-x) \sqrt {\frac {1+x+x^2}{\left (1-\sqrt {3}-x\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {1+\sqrt {3}-x}{1-\sqrt {3}-x}\right ),-7+4 \sqrt {3}\right )}{\left (3+(2+i) \sqrt {3}\right ) \sqrt {-\frac {1-x}{\left (1-\sqrt {3}-x\right )^2}} \sqrt {-1+x^3}} \\ \end{align*}

Mathematica [A] (verified)

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

[In]

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

[Out]

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

Maple [A] (verified)

Time = 3.67 (sec) , antiderivative size = 13, normalized size of antiderivative = 0.68

method result size
gosper \(-\frac {2 \left (x -1\right )}{\sqrt {x^{3}-1}}\) \(13\)
risch \(-\frac {2 \left (x -1\right )}{\sqrt {x^{3}-1}}\) \(13\)
default \(-\frac {2 \left (x -1\right )}{\sqrt {\left (x -1\right ) \left (x^{2}+x +1\right )}}\) \(18\)
trager \(-\frac {2 \sqrt {x^{3}-1}}{x^{2}+x +1}\) \(18\)
elliptic \(-\frac {2 \left (x -1\right )}{\sqrt {\left (x -1\right ) \left (x^{2}+x +1\right )}}\) \(18\)

[In]

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

[Out]

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

Fricas [A] (verification not implemented)

none

Time = 0.25 (sec) , antiderivative size = 17, normalized size of antiderivative = 0.89 \[ \int \frac {-2-2 x+x^2}{\left (1+x+x^2\right ) \sqrt {-1+x^3}} \, dx=-\frac {2 \, \sqrt {x^{3} - 1}}{x^{2} + x + 1} \]

[In]

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

[Out]

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

Sympy [F]

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

[In]

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

[Out]

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

Maxima [A] (verification not implemented)

none

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

[In]

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

[Out]

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

Giac [F]

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

[In]

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

[Out]

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

Mupad [B] (verification not implemented)

Time = 4.98 (sec) , antiderivative size = 276, normalized size of antiderivative = 14.53 \[ \int \frac {-2-2 x+x^2}{\left (1+x+x^2\right ) \sqrt {-1+x^3}} \, dx=\frac {\sqrt {-\frac {x+\frac {1}{2}-\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}{-\frac {3}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}}\,\sqrt {\frac {x+\frac {1}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}{\frac {3}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}}\,\left (6+9\,\sin \left (2\,\mathrm {asin}\left (\sqrt {-\frac {x-1}{\frac {3}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}}\right )\right )\,\sqrt {\frac {x-1}{\frac {3}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}+1}\,\sqrt {-\frac {x-1}{\frac {3}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}}-6\,x+\sqrt {3}\,x\,2{}\mathrm {i}+\sqrt {3}\,2{}\mathrm {i}-\sqrt {3}\,x^2\,4{}\mathrm {i}-\sqrt {3}\,\sin \left (2\,\mathrm {asin}\left (\sqrt {-\frac {x-1}{\frac {3}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}}\right )\right )\,\sqrt {\frac {x-1}{\frac {3}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}+1}\,\sqrt {-\frac {x-1}{\frac {3}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}}\,3{}\mathrm {i}\right )}{6\,\sqrt {1-\frac {x-1}{-\frac {3}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}}\,\sqrt {\frac {x-1}{\frac {3}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}}+1}\,\sqrt {x^3+\left (-\left (-\frac {1}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}\right )\,\left (\frac {1}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}\right )-1\right )\,x+\left (-\frac {1}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}\right )\,\left (\frac {1}{2}+\frac {\sqrt {3}\,1{}\mathrm {i}}{2}\right )}} \]

[In]

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

[Out]

((-(x - (3^(1/2)*1i)/2 + 1/2)/((3^(1/2)*1i)/2 - 3/2))^(1/2)*((x + (3^(1/2)*1i)/2 + 1/2)/((3^(1/2)*1i)/2 + 3/2)
)^(1/2)*(3^(1/2)*x*2i - 6*x + 3^(1/2)*2i - 3^(1/2)*x^2*4i + 9*sin(2*asin((-(x - 1)/((3^(1/2)*1i)/2 + 3/2))^(1/
2)))*((x - 1)/((3^(1/2)*1i)/2 + 3/2) + 1)^(1/2)*(-(x - 1)/((3^(1/2)*1i)/2 + 3/2))^(1/2) - 3^(1/2)*sin(2*asin((
-(x - 1)/((3^(1/2)*1i)/2 + 3/2))^(1/2)))*((x - 1)/((3^(1/2)*1i)/2 + 3/2) + 1)^(1/2)*(-(x - 1)/((3^(1/2)*1i)/2
+ 3/2))^(1/2)*3i + 6))/(6*(1 - (x - 1)/((3^(1/2)*1i)/2 - 3/2))^(1/2)*((x - 1)/((3^(1/2)*1i)/2 + 3/2) + 1)^(1/2
)*(((3^(1/2)*1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/2) - x*(((3^(1/2)*1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/2) + 1) + x^3
)^(1/2))