3.281 \(\int \frac {3+2 x}{(3+2 x+x^2)^2 \sqrt {4+2 x+x^2}} \, dx\)

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

________________________________________________________________________________________

Rubi [A]  time = 0.07, antiderivative size = 76, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 6, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.214, Rules used = {1016, 1025, 982, 204, 1024, 206} \[ -\frac {\sqrt {x^2+2 x+4} (3-x)}{4 \left (x^2+2 x+3\right )}-\frac {\tan ^{-1}\left (\frac {x+1}{\sqrt {2} \sqrt {x^2+2 x+4}}\right )}{4 \sqrt {2}}+\tanh ^{-1}\left (\sqrt {x^2+2 x+4}\right ) \]

Antiderivative was successfully verified.

[In]

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

[Out]

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

Rule 204

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> -Simp[ArcTan[(Rt[-b, 2]*x)/Rt[-a, 2]]/(Rt[-a, 2]*Rt[-b, 2]), x] /
; FreeQ[{a, b}, x] && PosQ[a/b] && (LtQ[a, 0] || LtQ[b, 0])

Rule 206

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTanh[(Rt[-b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[-b, 2]), x]
 /; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rule 982

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

Rule 1016

Int[((g_.) + (h_.)*(x_))*((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_)*((d_) + (e_.)*(x_) + (f_.)*(x_)^2)^(q_), x_Sy
mbol] :> Simp[((a + b*x + c*x^2)^(p + 1)*(d + e*x + f*x^2)^(q + 1)*(g*c*(2*a*c*e - b*(c*d + a*f)) + (g*b - a*h
)*(2*c^2*d + b^2*f - c*(b*e + 2*a*f)) + c*(g*(2*c^2*d + b^2*f - c*(b*e + 2*a*f)) - h*(b*c*d - 2*a*c*e + a*b*f)
)*x))/((b^2 - 4*a*c)*((c*d - a*f)^2 - (b*d - a*e)*(c*e - b*f))*(p + 1)), x] + Dist[1/((b^2 - 4*a*c)*((c*d - a*
f)^2 - (b*d - a*e)*(c*e - b*f))*(p + 1)), Int[(a + b*x + c*x^2)^(p + 1)*(d + e*x + f*x^2)^q*Simp[(b*h - 2*g*c)
*((c*d - a*f)^2 - (b*d - a*e)*(c*e - b*f))*(p + 1) + (b^2*(g*f) - b*(h*c*d + g*c*e + a*h*f) + 2*(g*c*(c*d - a*
f) - a*(-(h*c*e))))*(a*f*(p + 1) - c*d*(p + 2)) - e*((g*c)*(2*a*c*e - b*(c*d + a*f)) + (g*b - a*h)*(2*c^2*d +
b^2*f - c*(b*e + 2*a*f)))*(p + q + 2) - (2*f*((g*c)*(2*a*c*e - b*(c*d + a*f)) + (g*b - a*h)*(2*c^2*d + b^2*f -
 c*(b*e + 2*a*f)))*(p + q + 2) - (b^2*g*f - b*(h*c*d + g*c*e + a*h*f) + 2*(g*c*(c*d - a*f) - a*(-(h*c*e))))*(b
*f*(p + 1) - c*e*(2*p + q + 4)))*x - c*f*(b^2*(g*f) - b*(h*c*d + g*c*e + a*h*f) + 2*(g*c*(c*d - a*f) + a*h*c*e
))*(2*p + 2*q + 5)*x^2, x], x], x] /; FreeQ[{a, b, c, d, e, f, g, h, q}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[e^2
- 4*d*f, 0] && LtQ[p, -1] && NeQ[(c*d - a*f)^2 - (b*d - a*e)*(c*e - b*f), 0] &&  !( !IntegerQ[p] && ILtQ[q, -1
])

Rule 1024

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

Rule 1025

Int[((g_.) + (h_.)*(x_))/(((a_) + (b_.)*(x_) + (c_.)*(x_)^2)*Sqrt[(d_.) + (e_.)*(x_) + (f_.)*(x_)^2]), x_Symbo
l] :> -Dist[(h*e - 2*g*f)/(2*f), Int[1/((a + b*x + c*x^2)*Sqrt[d + e*x + f*x^2]), x], x] + Dist[h/(2*f), Int[(
e + 2*f*x)/((a + b*x + c*x^2)*Sqrt[d + e*x + f*x^2]), x], x] /; FreeQ[{a, b, c, d, e, f, g, h}, x] && NeQ[b^2
- 4*a*c, 0] && NeQ[e^2 - 4*d*f, 0] && EqQ[c*e - b*f, 0] && NeQ[h*e - 2*g*f, 0]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.40, size = 146, normalized size = 1.92 \[ \frac {1}{32} \left (8 \left (\frac {\sqrt {x^2+2 x+4} (x-3)}{x^2+2 x+3}-2 \log \left (\left (x^2+2 x+3\right )^2\right )+2 \log \left (\left (x^2+2 x+3\right ) \left (x^2+2 \sqrt {x^2+2 x+4}+2 x+5\right )\right )\right )-4 \sqrt {2} \tan ^{-1}\left (\frac {\sqrt {2} \left (5 x^2+10 x+4\right )}{4 x^2+\left (11 \sqrt {x^2+2 x+4}+8\right ) x+11 \sqrt {x^2+2 x+4}+12}\right )\right ) \]

Antiderivative was successfully verified.

[In]

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

[Out]

(-4*Sqrt[2]*ArcTan[(Sqrt[2]*(4 + 10*x + 5*x^2))/(12 + 4*x^2 + 11*Sqrt[4 + 2*x + x^2] + x*(8 + 11*Sqrt[4 + 2*x
+ x^2]))] + 8*(((-3 + x)*Sqrt[4 + 2*x + x^2])/(3 + 2*x + x^2) - 2*Log[(3 + 2*x + x^2)^2] + 2*Log[(3 + 2*x + x^
2)*(5 + 2*x + x^2 + 2*Sqrt[4 + 2*x + x^2])]))/32

________________________________________________________________________________________

IntegrateAlgebraic [C]  time = 1.68, size = 244, normalized size = 3.21 \[ \frac {\sqrt {x^2+2 x+4} (x-3)}{4 \left (x^2+2 x+3\right )}-i \tan ^{-1}\left (-\sqrt {\frac {1}{9}-\frac {2 i \sqrt {2}}{9}} \sqrt {x^2+2 x+4}+\sqrt {\frac {1}{9}-\frac {2 i \sqrt {2}}{9}} x+\sqrt {\frac {1}{9}-\frac {2 i \sqrt {2}}{9}}\right )+i \tan ^{-1}\left (-\sqrt {\frac {1}{9}+\frac {2 i \sqrt {2}}{9}} \sqrt {x^2+2 x+4}+\sqrt {\frac {1}{9}+\frac {2 i \sqrt {2}}{9}} x+\sqrt {\frac {1}{9}+\frac {2 i \sqrt {2}}{9}}\right )+\frac {\tan ^{-1}\left (\frac {x^2}{\sqrt {2}}-\frac {(x+1) \sqrt {x^2+2 x+4}}{\sqrt {2}}+\sqrt {2} x+\frac {3}{\sqrt {2}}\right )}{4 \sqrt {2}} \]

Warning: Unable to verify antiderivative.

[In]

IntegrateAlgebraic[(3 + 2*x)/((3 + 2*x + x^2)^2*Sqrt[4 + 2*x + x^2]),x]

[Out]

((-3 + x)*Sqrt[4 + 2*x + x^2])/(4*(3 + 2*x + x^2)) - I*ArcTan[Sqrt[1/9 - ((2*I)/9)*Sqrt[2]] + Sqrt[1/9 - ((2*I
)/9)*Sqrt[2]]*x - Sqrt[1/9 - ((2*I)/9)*Sqrt[2]]*Sqrt[4 + 2*x + x^2]] + I*ArcTan[Sqrt[1/9 + ((2*I)/9)*Sqrt[2]]
+ Sqrt[1/9 + ((2*I)/9)*Sqrt[2]]*x - Sqrt[1/9 + ((2*I)/9)*Sqrt[2]]*Sqrt[4 + 2*x + x^2]] + ArcTan[3/Sqrt[2] + Sq
rt[2]*x + x^2/Sqrt[2] - ((1 + x)*Sqrt[4 + 2*x + x^2])/Sqrt[2]]/(4*Sqrt[2])

________________________________________________________________________________________

fricas [B]  time = 0.57, size = 174, normalized size = 2.29 \[ \frac {\sqrt {2} {\left (x^{2} + 2 \, x + 3\right )} \arctan \left (-\frac {1}{2} \, \sqrt {2} {\left (x + 2\right )} + \frac {1}{2} \, \sqrt {2} \sqrt {x^{2} + 2 \, x + 4}\right ) - \sqrt {2} {\left (x^{2} + 2 \, x + 3\right )} \arctan \left (-\frac {1}{2} \, \sqrt {2} x + \frac {1}{2} \, \sqrt {2} \sqrt {x^{2} + 2 \, x + 4}\right ) + 2 \, x^{2} - 4 \, {\left (x^{2} + 2 \, x + 3\right )} \log \left (x^{2} - \sqrt {x^{2} + 2 \, x + 4} {\left (x + 2\right )} + 3 \, x + 5\right ) + 4 \, {\left (x^{2} + 2 \, x + 3\right )} \log \left (x^{2} - \sqrt {x^{2} + 2 \, x + 4} x + x + 3\right ) + 2 \, \sqrt {x^{2} + 2 \, x + 4} {\left (x - 3\right )} + 4 \, x + 6}{8 \, {\left (x^{2} + 2 \, x + 3\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/8*(sqrt(2)*(x^2 + 2*x + 3)*arctan(-1/2*sqrt(2)*(x + 2) + 1/2*sqrt(2)*sqrt(x^2 + 2*x + 4)) - sqrt(2)*(x^2 + 2
*x + 3)*arctan(-1/2*sqrt(2)*x + 1/2*sqrt(2)*sqrt(x^2 + 2*x + 4)) + 2*x^2 - 4*(x^2 + 2*x + 3)*log(x^2 - sqrt(x^
2 + 2*x + 4)*(x + 2) + 3*x + 5) + 4*(x^2 + 2*x + 3)*log(x^2 - sqrt(x^2 + 2*x + 4)*x + x + 3) + 2*sqrt(x^2 + 2*
x + 4)*(x - 3) + 4*x + 6)/(x^2 + 2*x + 3)

________________________________________________________________________________________

giac [B]  time = 0.66, size = 235, normalized size = 3.09 \[ \frac {1}{8} \, \sqrt {2} \arctan \left (-\frac {1}{2} \, \sqrt {2} {\left (x - \sqrt {x^{2} + 2 \, x + 4} + 2\right )}\right ) - \frac {1}{8} \, \sqrt {2} \arctan \left (-\frac {1}{2} \, \sqrt {2} {\left (x - \sqrt {x^{2} + 2 \, x + 4}\right )}\right ) + \frac {4 \, {\left (x - \sqrt {x^{2} + 2 \, x + 4}\right )}^{3} + 13 \, {\left (x - \sqrt {x^{2} + 2 \, x + 4}\right )}^{2} + 26 \, x - 26 \, \sqrt {x^{2} + 2 \, x + 4} + 26}{2 \, {\left ({\left (x - \sqrt {x^{2} + 2 \, x + 4}\right )}^{4} + 4 \, {\left (x - \sqrt {x^{2} + 2 \, x + 4}\right )}^{3} + 8 \, {\left (x - \sqrt {x^{2} + 2 \, x + 4}\right )}^{2} + 8 \, x - 8 \, \sqrt {x^{2} + 2 \, x + 4} + 12\right )}} - \frac {1}{2} \, \log \left ({\left (x - \sqrt {x^{2} + 2 \, x + 4}\right )}^{2} + 4 \, x - 4 \, \sqrt {x^{2} + 2 \, x + 4} + 6\right ) + \frac {1}{2} \, \log \left ({\left (x - \sqrt {x^{2} + 2 \, x + 4}\right )}^{2} + 2\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/8*sqrt(2)*arctan(-1/2*sqrt(2)*(x - sqrt(x^2 + 2*x + 4) + 2)) - 1/8*sqrt(2)*arctan(-1/2*sqrt(2)*(x - sqrt(x^2
 + 2*x + 4))) + 1/2*(4*(x - sqrt(x^2 + 2*x + 4))^3 + 13*(x - sqrt(x^2 + 2*x + 4))^2 + 26*x - 26*sqrt(x^2 + 2*x
 + 4) + 26)/((x - sqrt(x^2 + 2*x + 4))^4 + 4*(x - sqrt(x^2 + 2*x + 4))^3 + 8*(x - sqrt(x^2 + 2*x + 4))^2 + 8*x
 - 8*sqrt(x^2 + 2*x + 4) + 12) - 1/2*log((x - sqrt(x^2 + 2*x + 4))^2 + 4*x - 4*sqrt(x^2 + 2*x + 4) + 6) + 1/2*
log((x - sqrt(x^2 + 2*x + 4))^2 + 2)

________________________________________________________________________________________

maple [A]  time = 0.72, size = 64, normalized size = 0.84




method result size



risch \(\frac {\left (-3+x \right ) \sqrt {x^{2}+2 x +4}}{4 x^{2}+8 x +12}+\arctanh \left (\sqrt {x^{2}+2 x +4}\right )-\frac {\sqrt {2}\, \arctan \left (\frac {\sqrt {2}\, \left (2 x +2\right )}{4 \sqrt {x^{2}+2 x +4}}\right )}{8}\) \(64\)
default \(-\frac {1}{2 \left (\sqrt {x^{2}+2 x +4}-1\right )}-\frac {\ln \left (\sqrt {x^{2}+2 x +4}-1\right )}{2}-\frac {1}{2 \left (\sqrt {x^{2}+2 x +4}+1\right )}+\frac {\ln \left (\sqrt {x^{2}+2 x +4}+1\right )}{2}+\frac {\frac {3}{4}+\frac {3 x}{4}}{\sqrt {x^{2}+2 x +4}\, \left (\frac {\left (1+x \right )^{2}}{x^{2}+2 x +4}+2\right )}-\frac {\arctan \left (\frac {\left (1+x \right ) \sqrt {2}}{2 \sqrt {x^{2}+2 x +4}}\right ) \sqrt {2}}{8}\) \(123\)
trager \(\frac {\left (-3+x \right ) \sqrt {x^{2}+2 x +4}}{4 x^{2}+8 x +12}-3 \ln \left (\frac {48384 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right )^{2} x +960 \sqrt {x^{2}+2 x +4}\, \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right )-15312 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right ) x -143 \sqrt {x^{2}+2 x +4}+3696 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right )+1210 x -605}{48 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right ) x -7 x +3}\right ) \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right )+3 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right ) \ln \left (-\frac {-16128 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right )^{2} x +320 \sqrt {x^{2}+2 x +4}\, \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right )+5648 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right ) x -59 \sqrt {x^{2}+2 x +4}+1232 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right )-494 x -209}{16 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right ) x -3 x -1}\right )+\ln \left (\frac {48384 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right )^{2} x +960 \sqrt {x^{2}+2 x +4}\, \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right )-15312 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right ) x -143 \sqrt {x^{2}+2 x +4}+3696 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right )+1210 x -605}{48 \RootOf \left (384 \textit {\_Z}^{2}-128 \textit {\_Z} +11\right ) x -7 x +3}\right )\) \(372\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*(-3+x)/(x^2+2*x+3)*(x^2+2*x+4)^(1/2)+arctanh((x^2+2*x+4)^(1/2))-1/8*2^(1/2)*arctan(1/4*2^(1/2)/(x^2+2*x+4)
^(1/2)*(2*x+2))

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________