Optimal. Leaf size=59 \[ -\frac{\log \left ((a+b x)^2+c\right )}{2 \left (a^2+c\right )}-\frac{a \tan ^{-1}\left (\frac{a+b x}{\sqrt{c}}\right )}{\sqrt{c} \left (a^2+c\right )}+\frac{\log (x)}{a^2+c} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0351043, antiderivative size = 59, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 6, integrand size = 15, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.4, Rules used = {371, 706, 31, 635, 203, 260} \[ -\frac{\log \left ((a+b x)^2+c\right )}{2 \left (a^2+c\right )}-\frac{a \tan ^{-1}\left (\frac{a+b x}{\sqrt{c}}\right )}{\sqrt{c} \left (a^2+c\right )}+\frac{\log (x)}{a^2+c} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 371
Rule 706
Rule 31
Rule 635
Rule 203
Rule 260
Rubi steps
\begin{align*} \int \frac{1}{x \left (c+(a+b x)^2\right )} \, dx &=\operatorname{Subst}\left (\int \frac{1}{(-a+x) \left (c+x^2\right )} \, dx,x,a+b x\right )\\ &=\frac{\operatorname{Subst}\left (\int \frac{1}{-a+x} \, dx,x,a+b x\right )}{a^2+c}+\frac{\operatorname{Subst}\left (\int \frac{-a-x}{c+x^2} \, dx,x,a+b x\right )}{a^2+c}\\ &=\frac{\log (x)}{a^2+c}-\frac{\operatorname{Subst}\left (\int \frac{x}{c+x^2} \, dx,x,a+b x\right )}{a^2+c}-\frac{a \operatorname{Subst}\left (\int \frac{1}{c+x^2} \, dx,x,a+b x\right )}{a^2+c}\\ &=-\frac{a \tan ^{-1}\left (\frac{a+b x}{\sqrt{c}}\right )}{\sqrt{c} \left (a^2+c\right )}+\frac{\log (x)}{a^2+c}-\frac{\log \left (c+(a+b x)^2\right )}{2 \left (a^2+c\right )}\\ \end{align*}
Mathematica [A] time = 0.0328941, size = 48, normalized size = 0.81 \[ -\frac{\log \left ((a+b x)^2+c\right )+\frac{2 a \tan ^{-1}\left (\frac{a+b x}{\sqrt{c}}\right )}{\sqrt{c}}-2 \log (b x)}{2 \left (a^2+c\right )} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.006, size = 72, normalized size = 1.2 \begin{align*}{\frac{\ln \left ( x \right ) }{{a}^{2}+c}}-{\frac{\ln \left ({b}^{2}{x}^{2}+2\,abx+{a}^{2}+c \right ) }{2\,{a}^{2}+2\,c}}-{\frac{a}{{a}^{2}+c}\arctan \left ({\frac{2\,{b}^{2}x+2\,ab}{2\,b}{\frac{1}{\sqrt{c}}}} \right ){\frac{1}{\sqrt{c}}}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.86333, size = 385, normalized size = 6.53 \begin{align*} \left [-\frac{a \sqrt{-c} \log \left (\frac{b^{2} x^{2} + 2 \, a b x + a^{2} + 2 \,{\left (b x + a\right )} \sqrt{-c} - c}{b^{2} x^{2} + 2 \, a b x + a^{2} + c}\right ) + c \log \left (b^{2} x^{2} + 2 \, a b x + a^{2} + c\right ) - 2 \, c \log \left (x\right )}{2 \,{\left (a^{2} c + c^{2}\right )}}, -\frac{2 \, a \sqrt{c} \arctan \left (\frac{b x + a}{\sqrt{c}}\right ) + c \log \left (b^{2} x^{2} + 2 \, a b x + a^{2} + c\right ) - 2 \, c \log \left (x\right )}{2 \,{\left (a^{2} c + c^{2}\right )}}\right ] \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] time = 1.70819, size = 738, normalized size = 12.51 \begin{align*} \text{result too large to display} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.12384, size = 84, normalized size = 1.42 \begin{align*} -\frac{a \arctan \left (\frac{b x + a}{\sqrt{c}}\right )}{{\left (a^{2} + c\right )} \sqrt{c}} - \frac{\log \left (b^{2} x^{2} + 2 \, a b x + a^{2} + c\right )}{2 \,{\left (a^{2} + c\right )}} + \frac{\log \left ({\left | x \right |}\right )}{a^{2} + c} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]