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

Optimal. Leaf size=83 \[ -\frac {2}{-\sqrt {x^2-2 x-3}-x+1}+\frac {3}{2 \left (\sqrt {x^2-2 x-3}+x\right )}+4 \log \left (-\sqrt {x^2-2 x-3}-x+1\right )-4 \log \left (\sqrt {x^2-2 x-3}+x\right ) \]

[Out]

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

________________________________________________________________________________________

Rubi [A]  time = 0.03, antiderivative size = 83, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {2116, 893} \[ -\frac {2}{-\sqrt {x^2-2 x-3}-x+1}+\frac {3}{2 \left (\sqrt {x^2-2 x-3}+x\right )}+4 \log \left (-\sqrt {x^2-2 x-3}-x+1\right )-4 \log \left (\sqrt {x^2-2 x-3}+x\right ) \]

Antiderivative was successfully verified.

[In]

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

[Out]

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

Rule 893

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))^(n_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :
> Int[ExpandIntegrand[(d + e*x)^m*(f + g*x)^n*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, f, g}, x] &
& NeQ[e*f - d*g, 0] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - b*d*e + a*e^2, 0] && IntegerQ[p] && ((EqQ[p, 1] && I
ntegersQ[m, n]) || (ILtQ[m, 0] && ILtQ[n, 0]))

Rule 2116

Int[((g_.) + (h_.)*((d_.) + (e_.)*(x_) + (f_.)*Sqrt[(a_.) + (b_.)*(x_) + (c_.)*(x_)^2])^(n_))^(p_.), x_Symbol]
 :> Dist[2, Subst[Int[((g + h*x^n)^p*(d^2*e - (b*d - a*e)*f^2 - (2*d*e - b*f^2)*x + e*x^2))/(-2*d*e + b*f^2 +
2*e*x)^2, x], x, d + e*x + f*Sqrt[a + b*x + c*x^2]], x] /; FreeQ[{a, b, c, d, e, f, g, h, n}, x] && EqQ[e^2 -
c*f^2, 0] && IntegerQ[p]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.03, size = 79, normalized size = 0.95 \[ \frac {2}{\sqrt {x^2-2 x-3}+x-1}+\frac {3}{2 \left (\sqrt {x^2-2 x-3}+x\right )}+4 \log \left (-\sqrt {x^2-2 x-3}-x+1\right )-4 \log \left (\sqrt {x^2-2 x-3}+x\right ) \]

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

fricas [A]  time = 0.40, size = 97, normalized size = 1.17 \[ \frac {4 \, x^{2} - 8 \, {\left (2 \, x + 3\right )} \log \left (x^{2} - \sqrt {x^{2} - 2 \, x - 3} {\left (x + 1\right )} - 3\right ) - 8 \, {\left (2 \, x + 3\right )} \log \left (2 \, x + 3\right ) + 8 \, {\left (2 \, x + 3\right )} \log \left (-x + \sqrt {x^{2} - 2 \, x - 3}\right ) - 4 \, \sqrt {x^{2} - 2 \, x - 3} {\left (x + 3\right )} + 2 \, x - 15}{4 \, {\left (2 \, x + 3\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*(4*x^2 - 8*(2*x + 3)*log(x^2 - sqrt(x^2 - 2*x - 3)*(x + 1) - 3) - 8*(2*x + 3)*log(2*x + 3) + 8*(2*x + 3)*l
og(-x + sqrt(x^2 - 2*x - 3)) - 4*sqrt(x^2 - 2*x - 3)*(x + 3) + 2*x - 15)/(2*x + 3)

________________________________________________________________________________________

giac [B]  time = 0.51, size = 143, normalized size = 1.72 \[ \frac {1}{2} \, x - \frac {1}{2} \, \sqrt {x^{2} - 2 \, x - 3} - \frac {3 \, {\left (5 \, x - 5 \, \sqrt {x^{2} - 2 \, x - 3} + 3\right )}}{4 \, {\left ({\left (x - \sqrt {x^{2} - 2 \, x - 3}\right )}^{2} + 3 \, x - 3 \, \sqrt {x^{2} - 2 \, x - 3}\right )}} - \frac {9}{4 \, {\left (2 \, x + 3\right )}} - 2 \, \log \left ({\left | 2 \, x + 3 \right |}\right ) - 2 \, \log \left ({\left | -x + \sqrt {x^{2} - 2 \, x - 3} + 1 \right |}\right ) + 2 \, \log \left ({\left | -x + \sqrt {x^{2} - 2 \, x - 3} \right |}\right ) - 2 \, \log \left ({\left | -x + \sqrt {x^{2} - 2 \, x - 3} - 3 \right |}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*x - 1/2*sqrt(x^2 - 2*x - 3) - 3/4*(5*x - 5*sqrt(x^2 - 2*x - 3) + 3)/((x - sqrt(x^2 - 2*x - 3))^2 + 3*x - 3
*sqrt(x^2 - 2*x - 3)) - 9/4/(2*x + 3) - 2*log(abs(2*x + 3)) - 2*log(abs(-x + sqrt(x^2 - 2*x - 3) + 1)) + 2*log
(abs(-x + sqrt(x^2 - 2*x - 3))) - 2*log(abs(-x + sqrt(x^2 - 2*x - 3) - 3))

________________________________________________________________________________________

maple [A]  time = 0.02, size = 118, normalized size = 1.42 \[ \frac {x}{2}+2 \arctanh \left (\frac {-\frac {10 x}{3}-2}{\sqrt {-20 x +4 \left (x +\frac {3}{2}\right )^{2}-21}}\right )-2 \ln \left (2 x +3\right )+2 \ln \left (x -1+\sqrt {-5 x +\left (x +\frac {3}{2}\right )^{2}-\frac {21}{4}}\right )-\frac {9}{4 \left (2 x +3\right )}-\frac {2 \sqrt {-20 x +4 \left (x +\frac {3}{2}\right )^{2}-21}}{3}-\frac {\left (-5 x +\left (x +\frac {3}{2}\right )^{2}-\frac {21}{4}\right )^{\frac {3}{2}}}{3 \left (x +\frac {3}{2}\right )}+\frac {\left (2 x -2\right ) \sqrt {-5 x +\left (x +\frac {3}{2}\right )^{2}-\frac {21}{4}}}{6} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-2*ln(2*x+3)+1/2*x-9/4/(2*x+3)-2/3*(-20*x+4*(x+3/2)^2-21)^(1/2)+2*ln(x-1+(-5*x+(x+3/2)^2-21/4)^(1/2))+2*arctan
h(2/3*(-5*x-3)/(-20*x+4*(x+3/2)^2-21)^(1/2))-1/3/(x+3/2)*(-5*x+(x+3/2)^2-21/4)^(3/2)+1/6*(2*x-2)*(-5*x+(x+3/2)
^2-21/4)^(1/2)

________________________________________________________________________________________

maxima [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {1}{{\left (x + \sqrt {x^{2} - 2 \, x - 3}\right )}^{2}}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

mupad [F]  time = 0.00, size = -1, normalized size = -0.01 \[ \int \frac {1}{{\left (x+\sqrt {x^2-2\,x-3}\right )}^2} \,d x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {1}{\left (x + \sqrt {x^{2} - 2 x - 3}\right )^{2}}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Integral((x + sqrt(x**2 - 2*x - 3))**(-2), x)

________________________________________________________________________________________