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

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

[Out]

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

________________________________________________________________________________________

Rubi [A]  time = 0.247173, antiderivative size = 88, normalized size of antiderivative = 1., number of steps used = 7, number of rules used = 6, integrand size = 29, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.207, Rules used = {2155, 706, 31, 635, 207, 260} \[ -\frac{c \log \left (c \sqrt{a+b x^2}+d\right )}{a c^2-d^2}+\frac{d \tanh ^{-1}\left (\frac{\sqrt{a+b x^2}}{\sqrt{a}}\right )}{\sqrt{a} \left (a c^2-d^2\right )}+\frac{c \log (x)}{a c^2-d^2} \]

Antiderivative was successfully verified.

[In]

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

[Out]

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

Rule 2155

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

Rule 706

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

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rule 635

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

Rule 207

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

Rule 260

Int[(x_)^(m_.)/((a_) + (b_.)*(x_)^(n_)), x_Symbol] :> Simp[Log[RemoveContent[a + b*x^n, x]]/(b*n), x] /; FreeQ
[{a, b, m, n}, x] && EqQ[m, n - 1]

Rubi steps

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

Mathematica [A]  time = 0.129352, size = 107, normalized size = 1.22 \[ \frac{\left (\sqrt{a} c-d\right ) \log \left (\sqrt{a}-\sqrt{a+b x^2}\right )+\left (\sqrt{a} c+d\right ) \log \left (\sqrt{a+b x^2}+\sqrt{a}\right )-2 \sqrt{a} c \log \left (c \sqrt{a+b x^2}+d\right )}{2 \sqrt{a} \left (a c^2-d^2\right )} \]

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

Maple [B]  time = 0.027, size = 2175, normalized size = 24.7 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-1/2*a*c^3/(a*c^2-d^2)/d^2*ln(b*c^2*x^2+a*c^2-d^2)+c*ln(x)/(a*c^2-d^2)+1/2*c/d^2*ln(b*c^2*x^2+a*c^2-d^2)+1/2*d
*c^2*b/a/((-a*b)^(1/2)*c^2+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a*b)^(1/2)*c^2+(-c^2*b*(a*c^2-d^2))^(1/2))/((-a*b)^(1/2)
*c^2-(-c^2*b*(a*c^2-d^2))^(1/2))*d^3/(1/c^2*d^2)^(1/2)*ln((2/c^2*d^2-2*(-c^2*b*(a*c^2-d^2))^(1/2)/c^2*(x+(-c^2
*b*(a*c^2-d^2))^(1/2)/c^2/b)+2*(1/c^2*d^2)^(1/2)*((x+(-c^2*b*(a*c^2-d^2))^(1/2)/c^2/b)^2*b-2*(-c^2*b*(a*c^2-d^
2))^(1/2)/c^2*(x+(-c^2*b*(a*c^2-d^2))^(1/2)/c^2/b)+1/c^2*d^2)^(1/2))/(x+(-c^2*b*(a*c^2-d^2))^(1/2)/c^2/b))+1/2
*d*c^2*b/a/((-a*b)^(1/2)*c^2+(-c^2*b*(a*c^2-d^2))^(1/2))/((-a*b)^(1/2)*c^2-(-c^2*b*(a*c^2-d^2))^(1/2))*((x-(-a
*b)^(1/2)/b)^2*b+2*(-a*b)^(1/2)*(x-(-a*b)^(1/2)/b))^(1/2)+1/2*d*c^2*b^(1/2)/a/((-a*b)^(1/2)*c^2+(-c^2*b*(a*c^2
-d^2))^(1/2))/((-a*b)^(1/2)*c^2-(-c^2*b*(a*c^2-d^2))^(1/2))*(-a*b)^(1/2)*ln((b*(x-(-a*b)^(1/2)/b)+(-a*b)^(1/2)
)/b^(1/2)+((x-(-a*b)^(1/2)/b)^2*b+2*(-a*b)^(1/2)*(x-(-a*b)^(1/2)/b))^(1/2))

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Fricas [A]  time = 1.90406, size = 721, normalized size = 8.19 \begin{align*} \left [-\frac{2 \, a c \log \left (b c^{2} x^{2} + a c^{2} - d^{2}\right ) - 4 \, a c \log \left (x\right ) + a c \log \left (-\frac{b c^{2} x^{2} + a c^{2} + 2 \, \sqrt{b x^{2} + a} c d + d^{2}}{x^{2}}\right ) - a c \log \left (-\frac{b c^{2} x^{2} + a c^{2} - 2 \, \sqrt{b x^{2} + a} c d + d^{2}}{x^{2}}\right ) + 2 \, \sqrt{a} d \log \left (-\frac{b x^{2} - 2 \, \sqrt{b x^{2} + a} \sqrt{a} + 2 \, a}{x^{2}}\right )}{4 \,{\left (a^{2} c^{2} - a d^{2}\right )}}, -\frac{2 \, a c \log \left (b c^{2} x^{2} + a c^{2} - d^{2}\right ) - 4 \, a c \log \left (x\right ) + a c \log \left (-\frac{b c^{2} x^{2} + a c^{2} + 2 \, \sqrt{b x^{2} + a} c d + d^{2}}{x^{2}}\right ) - a c \log \left (-\frac{b c^{2} x^{2} + a c^{2} - 2 \, \sqrt{b x^{2} + a} c d + d^{2}}{x^{2}}\right ) + 4 \, \sqrt{-a} d \arctan \left (\frac{\sqrt{-a}}{\sqrt{b x^{2} + a}}\right )}{4 \,{\left (a^{2} c^{2} - a d^{2}\right )}}\right ] \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

[-1/4*(2*a*c*log(b*c^2*x^2 + a*c^2 - d^2) - 4*a*c*log(x) + a*c*log(-(b*c^2*x^2 + a*c^2 + 2*sqrt(b*x^2 + a)*c*d
 + d^2)/x^2) - a*c*log(-(b*c^2*x^2 + a*c^2 - 2*sqrt(b*x^2 + a)*c*d + d^2)/x^2) + 2*sqrt(a)*d*log(-(b*x^2 - 2*s
qrt(b*x^2 + a)*sqrt(a) + 2*a)/x^2))/(a^2*c^2 - a*d^2), -1/4*(2*a*c*log(b*c^2*x^2 + a*c^2 - d^2) - 4*a*c*log(x)
 + a*c*log(-(b*c^2*x^2 + a*c^2 + 2*sqrt(b*x^2 + a)*c*d + d^2)/x^2) - a*c*log(-(b*c^2*x^2 + a*c^2 - 2*sqrt(b*x^
2 + a)*c*d + d^2)/x^2) + 4*sqrt(-a)*d*arctan(sqrt(-a)/sqrt(b*x^2 + a)))/(a^2*c^2 - a*d^2)]

________________________________________________________________________________________

Sympy [A]  time = 4.75033, size = 88, normalized size = 1. \begin{align*} - \frac{c^{2} \left (\begin{cases} \frac{\sqrt{a + b x^{2}}}{d} & \text{for}\: c = 0 \\\frac{\log{\left (c \sqrt{a + b x^{2}} + d \right )}}{c} & \text{otherwise} \end{cases}\right )}{a c^{2} - d^{2}} - \frac{- \frac{c \log{\left (- b x^{2} \right )}}{2} + \frac{d \operatorname{atan}{\left (\frac{\sqrt{a + b x^{2}}}{\sqrt{- a}} \right )}}{\sqrt{- a}}}{a c^{2} - d^{2}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-c**2*Piecewise((sqrt(a + b*x**2)/d, Eq(c, 0)), (log(c*sqrt(a + b*x**2) + d)/c, True))/(a*c**2 - d**2) - (-c*l
og(-b*x**2)/2 + d*atan(sqrt(a + b*x**2)/sqrt(-a))/sqrt(-a))/(a*c**2 - d**2)

________________________________________________________________________________________

Giac [A]  time = 1.16565, size = 127, normalized size = 1.44 \begin{align*} -\frac{c^{2} \log \left ({\left | \sqrt{b x^{2} + a} c + d \right |}\right )}{a c^{3} - c d^{2}} + \frac{c \log \left (b x^{2}\right )}{2 \,{\left (a c^{2} - d^{2}\right )}} - \frac{d \arctan \left (\frac{\sqrt{b x^{2} + a}}{\sqrt{-a}}\right )}{{\left (a c^{2} - d^{2}\right )} \sqrt{-a}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-c^2*log(abs(sqrt(b*x^2 + a)*c + d))/(a*c^3 - c*d^2) + 1/2*c*log(b*x^2)/(a*c^2 - d^2) - d*arctan(sqrt(b*x^2 +
a)/sqrt(-a))/((a*c^2 - d^2)*sqrt(-a))