3.921 \(\int \frac{\sqrt{a+\frac{c}{x^2}+\frac{b}{x}}}{d+e x} \, dx\)

Optimal. Leaf size=181 \[ -\frac{\sqrt{a d^2-e (b d-c e)} \tanh ^{-1}\left (\frac{2 a d+\frac{b d-2 c e}{x}-b e}{2 \sqrt{a+\frac{b}{x}+\frac{c}{x^2}} \sqrt{a d^2-e (b d-c e)}}\right )}{d e}-\frac{\sqrt{c} \tanh ^{-1}\left (\frac{b+\frac{2 c}{x}}{2 \sqrt{c} \sqrt{a+\frac{b}{x}+\frac{c}{x^2}}}\right )}{d}+\frac{\sqrt{a} \tanh ^{-1}\left (\frac{2 a+\frac{b}{x}}{2 \sqrt{a} \sqrt{a+\frac{b}{x}+\frac{c}{x^2}}}\right )}{e} \]

[Out]

(Sqrt[a]*ArcTanh[(2*a + b/x)/(2*Sqrt[a]*Sqrt[a + c/x^2 + b/x])])/e - (Sqrt[c]*ArcTanh[(b + (2*c)/x)/(2*Sqrt[c]
*Sqrt[a + c/x^2 + b/x])])/d - (Sqrt[a*d^2 - e*(b*d - c*e)]*ArcTanh[(2*a*d - b*e + (b*d - 2*c*e)/x)/(2*Sqrt[a*d
^2 - e*(b*d - c*e)]*Sqrt[a + c/x^2 + b/x])])/(d*e)

________________________________________________________________________________________

Rubi [A]  time = 0.272594, antiderivative size = 181, normalized size of antiderivative = 1., number of steps used = 10, number of rules used = 7, integrand size = 24, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.292, Rules used = {1443, 1474, 895, 724, 206, 843, 621} \[ -\frac{\sqrt{a d^2-e (b d-c e)} \tanh ^{-1}\left (\frac{2 a d+\frac{b d-2 c e}{x}-b e}{2 \sqrt{a+\frac{b}{x}+\frac{c}{x^2}} \sqrt{a d^2-e (b d-c e)}}\right )}{d e}-\frac{\sqrt{c} \tanh ^{-1}\left (\frac{b+\frac{2 c}{x}}{2 \sqrt{c} \sqrt{a+\frac{b}{x}+\frac{c}{x^2}}}\right )}{d}+\frac{\sqrt{a} \tanh ^{-1}\left (\frac{2 a+\frac{b}{x}}{2 \sqrt{a} \sqrt{a+\frac{b}{x}+\frac{c}{x^2}}}\right )}{e} \]

Antiderivative was successfully verified.

[In]

Int[Sqrt[a + c/x^2 + b/x]/(d + e*x),x]

[Out]

(Sqrt[a]*ArcTanh[(2*a + b/x)/(2*Sqrt[a]*Sqrt[a + c/x^2 + b/x])])/e - (Sqrt[c]*ArcTanh[(b + (2*c)/x)/(2*Sqrt[c]
*Sqrt[a + c/x^2 + b/x])])/d - (Sqrt[a*d^2 - e*(b*d - c*e)]*ArcTanh[(2*a*d - b*e + (b*d - 2*c*e)/x)/(2*Sqrt[a*d
^2 - e*(b*d - c*e)]*Sqrt[a + c/x^2 + b/x])])/(d*e)

Rule 1443

Int[((d_) + (e_.)*(x_)^(mn_.))^(q_.)*((a_.) + (b_.)*(x_)^(n_.) + (c_.)*(x_)^(n2_.))^(p_.), x_Symbol] :> Int[((
e + d*x^n)^q*(a + b*x^n + c*x^(2*n))^p)/x^(n*q), x] /; FreeQ[{a, b, c, d, e, n, p}, x] && EqQ[n2, 2*n] && EqQ[
mn, -n] && IntegerQ[q] && (PosQ[n] ||  !IntegerQ[p])

Rule 1474

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

Rule 895

Int[((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_)/(((d_.) + (e_.)*(x_))*((f_.) + (g_.)*(x_))), x_Symbol] :> Dist[(c
*d^2 - b*d*e + a*e^2)/(e*(e*f - d*g)), Int[(a + b*x + c*x^2)^(p - 1)/(d + e*x), x], x] - Dist[1/(e*(e*f - d*g)
), Int[(Simp[c*d*f - b*e*f + a*e*g - c*(e*f - d*g)*x, x]*(a + b*x + c*x^2)^(p - 1))/(f + g*x), 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] && Fra
ctionQ[p] && GtQ[p, 0]

Rule 724

Int[1/(((d_.) + (e_.)*(x_))*Sqrt[(a_.) + (b_.)*(x_) + (c_.)*(x_)^2]), x_Symbol] :> Dist[-2, Subst[Int[1/(4*c*d
^2 - 4*b*d*e + 4*a*e^2 - x^2), x], x, (2*a*e - b*d - (2*c*d - b*e)*x)/Sqrt[a + b*x + c*x^2]], x] /; FreeQ[{a,
b, c, d, e}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[2*c*d - b*e, 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 843

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Dis
t[g/e, Int[(d + e*x)^(m + 1)*(a + b*x + c*x^2)^p, x], x] + Dist[(e*f - d*g)/e, Int[(d + e*x)^m*(a + b*x + c*x^
2)^p, x], x] /; FreeQ[{a, b, c, d, e, f, g, m, p}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - b*d*e + a*e^2, 0]
&&  !IGtQ[m, 0]

Rule 621

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

Rubi steps

\begin{align*} \int \frac{\sqrt{a+\frac{c}{x^2}+\frac{b}{x}}}{d+e x} \, dx &=\int \frac{\sqrt{a+\frac{c}{x^2}+\frac{b}{x}}}{\left (e+\frac{d}{x}\right ) x} \, dx\\ &=-\operatorname{Subst}\left (\int \frac{\sqrt{a+b x+c x^2}}{x (e+d x)} \, dx,x,\frac{1}{x}\right )\\ &=\frac{\operatorname{Subst}\left (\int \frac{a d-b e-c e x}{(e+d x) \sqrt{a+b x+c x^2}} \, dx,x,\frac{1}{x}\right )}{e}-\frac{a \operatorname{Subst}\left (\int \frac{1}{x \sqrt{a+b x+c x^2}} \, dx,x,\frac{1}{x}\right )}{e}\\ &=-\frac{c \operatorname{Subst}\left (\int \frac{1}{\sqrt{a+b x+c x^2}} \, dx,x,\frac{1}{x}\right )}{d}+\frac{(2 a) \operatorname{Subst}\left (\int \frac{1}{4 a-x^2} \, dx,x,\frac{2 a+\frac{b}{x}}{\sqrt{a+\frac{c}{x^2}+\frac{b}{x}}}\right )}{e}+\left (-b+\frac{a d}{e}+\frac{c e}{d}\right ) \operatorname{Subst}\left (\int \frac{1}{(e+d x) \sqrt{a+b x+c x^2}} \, dx,x,\frac{1}{x}\right )\\ &=\frac{\sqrt{a} \tanh ^{-1}\left (\frac{2 a+\frac{b}{x}}{2 \sqrt{a} \sqrt{a+\frac{c}{x^2}+\frac{b}{x}}}\right )}{e}-\frac{(2 c) \operatorname{Subst}\left (\int \frac{1}{4 c-x^2} \, dx,x,\frac{b+\frac{2 c}{x}}{\sqrt{a+\frac{c}{x^2}+\frac{b}{x}}}\right )}{d}+\left (2 \left (b-\frac{a d}{e}-\frac{c e}{d}\right )\right ) \operatorname{Subst}\left (\int \frac{1}{4 a d^2-4 b d e+4 c e^2-x^2} \, dx,x,\frac{2 a d-b e-\frac{-b d+2 c e}{x}}{\sqrt{a+\frac{c}{x^2}+\frac{b}{x}}}\right )\\ &=\frac{\sqrt{a} \tanh ^{-1}\left (\frac{2 a+\frac{b}{x}}{2 \sqrt{a} \sqrt{a+\frac{c}{x^2}+\frac{b}{x}}}\right )}{e}-\frac{\sqrt{c} \tanh ^{-1}\left (\frac{b+\frac{2 c}{x}}{2 \sqrt{c} \sqrt{a+\frac{c}{x^2}+\frac{b}{x}}}\right )}{d}-\frac{\sqrt{a d^2-e (b d-c e)} \tanh ^{-1}\left (\frac{2 a d-b e+\frac{b d-2 c e}{x}}{2 \sqrt{a d^2-e (b d-c e)} \sqrt{a+\frac{c}{x^2}+\frac{b}{x}}}\right )}{d e}\\ \end{align*}

Mathematica [A]  time = 0.275022, size = 189, normalized size = 1.04 \[ -\frac{x \sqrt{a+\frac{b x+c}{x^2}} \left (\sqrt{a d^2-b d e+c e^2} \tanh ^{-1}\left (\frac{2 a d x+b d-b e x-2 c e}{2 \sqrt{x (a x+b)+c} \sqrt{a d^2-b d e+c e^2}}\right )-\sqrt{a} d \tanh ^{-1}\left (\frac{2 a x+b}{2 \sqrt{a} \sqrt{x (a x+b)+c}}\right )+\sqrt{c} e \tanh ^{-1}\left (\frac{b x+2 c}{2 \sqrt{c} \sqrt{x (a x+b)+c}}\right )\right )}{d e \sqrt{x (a x+b)+c}} \]

Antiderivative was successfully verified.

[In]

Integrate[Sqrt[a + c/x^2 + b/x]/(d + e*x),x]

[Out]

-((x*Sqrt[a + (c + b*x)/x^2]*(-(Sqrt[a]*d*ArcTanh[(b + 2*a*x)/(2*Sqrt[a]*Sqrt[c + x*(b + a*x)])]) + Sqrt[c]*e*
ArcTanh[(2*c + b*x)/(2*Sqrt[c]*Sqrt[c + x*(b + a*x)])] + Sqrt[a*d^2 - b*d*e + c*e^2]*ArcTanh[(b*d - 2*c*e + 2*
a*d*x - b*e*x)/(2*Sqrt[a*d^2 - b*d*e + c*e^2]*Sqrt[c + x*(b + a*x)])]))/(d*e*Sqrt[c + x*(b + a*x)]))

________________________________________________________________________________________

Maple [B]  time = 0.03, size = 397, normalized size = 2.2 \begin{align*} -{\frac{x}{d{e}^{2}}\sqrt{{\frac{a{x}^{2}+bx+c}{{x}^{2}}}} \left ( \sqrt{c}\ln \left ({\frac{1}{x} \left ( 2\,c+bx+2\,\sqrt{c}\sqrt{a{x}^{2}+bx+c} \right ) } \right ) \sqrt{{\frac{a{d}^{2}-bde+c{e}^{2}}{{e}^{2}}}}\sqrt{a}{e}^{2}-\ln \left ({\frac{1}{2} \left ( 2\,\sqrt{a{x}^{2}+bx+c}\sqrt{a}+2\,ax+b \right ){\frac{1}{\sqrt{a}}}} \right ) \sqrt{{\frac{a{d}^{2}-bde+c{e}^{2}}{{e}^{2}}}}ade-\ln \left ({\frac{1}{ex+d} \left ( 2\,\sqrt{a{x}^{2}+bx+c}\sqrt{{\frac{a{d}^{2}-bde+c{e}^{2}}{{e}^{2}}}}e-2\,axd+xbe-bd+2\,ce \right ) } \right ){a}^{{\frac{3}{2}}}{d}^{2}+\ln \left ({\frac{1}{ex+d} \left ( 2\,\sqrt{a{x}^{2}+bx+c}\sqrt{{\frac{a{d}^{2}-bde+c{e}^{2}}{{e}^{2}}}}e-2\,axd+xbe-bd+2\,ce \right ) } \right ) \sqrt{a}bde-\ln \left ({\frac{1}{ex+d} \left ( 2\,\sqrt{a{x}^{2}+bx+c}\sqrt{{\frac{a{d}^{2}-bde+c{e}^{2}}{{e}^{2}}}}e-2\,axd+xbe-bd+2\,ce \right ) } \right ) \sqrt{a}c{e}^{2} \right ){\frac{1}{\sqrt{a{x}^{2}+bx+c}}}{\frac{1}{\sqrt{a}}}{\frac{1}{\sqrt{{\frac{a{d}^{2}-bde+c{e}^{2}}{{e}^{2}}}}}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+c/x^2+b/x)^(1/2)/(e*x+d),x)

[Out]

-((a*x^2+b*x+c)/x^2)^(1/2)*x*(c^(1/2)*ln((2*c+b*x+2*c^(1/2)*(a*x^2+b*x+c)^(1/2))/x)*((a*d^2-b*d*e+c*e^2)/e^2)^
(1/2)*a^(1/2)*e^2-ln(1/2*(2*(a*x^2+b*x+c)^(1/2)*a^(1/2)+2*a*x+b)/a^(1/2))*((a*d^2-b*d*e+c*e^2)/e^2)^(1/2)*a*d*
e-ln((2*(a*x^2+b*x+c)^(1/2)*((a*d^2-b*d*e+c*e^2)/e^2)^(1/2)*e-2*a*x*d+x*b*e-b*d+2*c*e)/(e*x+d))*a^(3/2)*d^2+ln
((2*(a*x^2+b*x+c)^(1/2)*((a*d^2-b*d*e+c*e^2)/e^2)^(1/2)*e-2*a*x*d+x*b*e-b*d+2*c*e)/(e*x+d))*a^(1/2)*b*d*e-ln((
2*(a*x^2+b*x+c)^(1/2)*((a*d^2-b*d*e+c*e^2)/e^2)^(1/2)*e-2*a*x*d+x*b*e-b*d+2*c*e)/(e*x+d))*a^(1/2)*c*e^2)/(a*x^
2+b*x+c)^(1/2)/d/e^2/a^(1/2)/((a*d^2-b*d*e+c*e^2)/e^2)^(1/2)

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\sqrt{a + \frac{b}{x} + \frac{c}{x^{2}}}}{e x + d}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+c/x^2+b/x)^(1/2)/(e*x+d),x, algorithm="maxima")

[Out]

integrate(sqrt(a + b/x + c/x^2)/(e*x + d), x)

________________________________________________________________________________________

Fricas [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+c/x^2+b/x)^(1/2)/(e*x+d),x, algorithm="fricas")

[Out]

Timed out

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+c/x**2+b/x)**(1/2)/(e*x+d),x)

[Out]

Integral(sqrt(a + b/x + c/x**2)/(d + e*x), x)

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+c/x^2+b/x)^(1/2)/(e*x+d),x, algorithm="giac")

[Out]

Exception raised: TypeError