3.1.1 \(\int \frac {1}{a^2-b^2 x^2} \, dx\) [1]

Optimal. Leaf size=14 \[ \frac {\tanh ^{-1}\left (\frac {b x}{a}\right )}{a b} \]

[Out]

arctanh(b*x/a)/a/b

________________________________________________________________________________________

Rubi [A]
time = 0.01, antiderivative size = 14, normalized size of antiderivative = 1.00, number of steps used = 1, number of rules used = 1, integrand size = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.071, Rules used = {214} \begin {gather*} \frac {\tanh ^{-1}\left (\frac {b x}{a}\right )}{a b} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(a^2 - b^2*x^2)^(-1),x]

[Out]

ArcTanh[(b*x)/a]/(a*b)

Rule 214

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

Rubi steps

\begin {align*} \int \frac {1}{a^2-b^2 x^2} \, dx &=\frac {\tanh ^{-1}\left (\frac {b x}{a}\right )}{a b}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.00, size = 14, normalized size = 1.00 \begin {gather*} \frac {\tanh ^{-1}\left (\frac {b x}{a}\right )}{a b} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(a^2 - b^2*x^2)^(-1),x]

[Out]

ArcTanh[(b*x)/a]/(a*b)

________________________________________________________________________________________

Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(30\) vs. \(2(14)=28\).
time = 0.05, size = 31, normalized size = 2.21

method result size
default \(-\frac {\ln \left (-b x +a \right )}{2 a b}+\frac {\ln \left (b x +a \right )}{2 a b}\) \(31\)
norman \(-\frac {\ln \left (-b x +a \right )}{2 a b}+\frac {\ln \left (b x +a \right )}{2 a b}\) \(31\)
risch \(-\frac {\ln \left (-b x +a \right )}{2 a b}+\frac {\ln \left (b x +a \right )}{2 a b}\) \(31\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(-b^2*x^2+a^2),x,method=_RETURNVERBOSE)

[Out]

-1/2/a/b*ln(-b*x+a)+1/2*ln(b*x+a)/a/b

________________________________________________________________________________________

Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 31 vs. \(2 (14) = 28\).
time = 3.27, size = 31, normalized size = 2.21 \begin {gather*} \frac {\log \left (b x + a\right )}{2 \, a b} - \frac {\log \left (b x - a\right )}{2 \, a b} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*log(b*x + a)/(a*b) - 1/2*log(b*x - a)/(a*b)

________________________________________________________________________________________

Fricas [A]
time = 0.49, size = 25, normalized size = 1.79 \begin {gather*} \frac {\log \left (b x + a\right ) - \log \left (b x - a\right )}{2 \, a b} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*(log(b*x + a) - log(b*x - a))/(a*b)

________________________________________________________________________________________

Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 20 vs. \(2 (8) = 16\).
time = 0.05, size = 20, normalized size = 1.43 \begin {gather*} - \frac {\frac {\log {\left (- \frac {a}{b} + x \right )}}{2} - \frac {\log {\left (\frac {a}{b} + x \right )}}{2}}{a b} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-(log(-a/b + x)/2 - log(a/b + x)/2)/(a*b)

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 33 vs. \(2 (14) = 28\).
time = 1.61, size = 33, normalized size = 2.36 \begin {gather*} \frac {\log \left ({\left | b x + a \right |}\right )}{2 \, a b} - \frac {\log \left ({\left | b x - a \right |}\right )}{2 \, a b} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*log(abs(b*x + a))/(a*b) - 1/2*log(abs(b*x - a))/(a*b)

________________________________________________________________________________________

Mupad [B]
time = 0.06, size = 14, normalized size = 1.00 \begin {gather*} \frac {\mathrm {atanh}\left (\frac {b\,x}{a}\right )}{a\,b} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(a^2 - b^2*x^2),x)

[Out]

atanh((b*x)/a)/(a*b)

________________________________________________________________________________________