\(\int \frac {1}{1-(c+d x)^2} \, dx\) [92]

   Optimal result
   Rubi [A] (verified)
   Mathematica [B] (verified)
   Maple [B] (verified)
   Fricas [B] (verification not implemented)
   Sympy [B] (verification not implemented)
   Maxima [B] (verification not implemented)
   Giac [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 13, antiderivative size = 10 \[ \int \frac {1}{1-(c+d x)^2} \, dx=\frac {\text {arctanh}(c+d x)}{d} \]

[Out]

arctanh(d*x+c)/d

Rubi [A] (verified)

Time = 0.00 (sec) , antiderivative size = 10, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.154, Rules used = {253, 212} \[ \int \frac {1}{1-(c+d x)^2} \, dx=\frac {\text {arctanh}(c+d x)}{d} \]

[In]

Int[(1 - (c + d*x)^2)^(-1),x]

[Out]

ArcTanh[c + d*x]/d

Rule 212

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

Rule 253

Int[((a_.) + (b_.)*(v_)^(n_))^(p_), x_Symbol] :> Dist[1/Coefficient[v, x, 1], Subst[Int[(a + b*x^n)^p, x], x,
v], x] /; FreeQ[{a, b, n, p}, x] && LinearQ[v, x] && NeQ[v, x]

Rubi steps \begin{align*} \text {integral}& = \frac {\text {Subst}\left (\int \frac {1}{1-x^2} \, dx,x,c+d x\right )}{d} \\ & = \frac {\tanh ^{-1}(c+d x)}{d} \\ \end{align*}

Mathematica [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(32\) vs. \(2(10)=20\).

Time = 0.00 (sec) , antiderivative size = 32, normalized size of antiderivative = 3.20 \[ \int \frac {1}{1-(c+d x)^2} \, dx=-\frac {\log (1-c-d x)}{2 d}+\frac {\log (1+c+d x)}{2 d} \]

[In]

Integrate[(1 - (c + d*x)^2)^(-1),x]

[Out]

-1/2*Log[1 - c - d*x]/d + Log[1 + c + d*x]/(2*d)

Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(22\) vs. \(2(10)=20\).

Time = 0.88 (sec) , antiderivative size = 23, normalized size of antiderivative = 2.30

method result size
parallelrisch \(-\frac {\ln \left (d x +c -1\right )-\ln \left (d x +c +1\right )}{2 d}\) \(23\)
default \(-\frac {\ln \left (d x +c -1\right )}{2 d}+\frac {\ln \left (d x +c +1\right )}{2 d}\) \(26\)
norman \(-\frac {\ln \left (d x +c -1\right )}{2 d}+\frac {\ln \left (d x +c +1\right )}{2 d}\) \(26\)
risch \(-\frac {\ln \left (d x +c -1\right )}{2 d}+\frac {\ln \left (-d x -c -1\right )}{2 d}\) \(29\)

[In]

int(1/(1-(d*x+c)^2),x,method=_RETURNVERBOSE)

[Out]

-1/2*(ln(d*x+c-1)-ln(d*x+c+1))/d

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 22 vs. \(2 (10) = 20\).

Time = 0.29 (sec) , antiderivative size = 22, normalized size of antiderivative = 2.20 \[ \int \frac {1}{1-(c+d x)^2} \, dx=\frac {\log \left (d x + c + 1\right ) - \log \left (d x + c - 1\right )}{2 \, d} \]

[In]

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

[Out]

1/2*(log(d*x + c + 1) - log(d*x + c - 1))/d

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 22 vs. \(2 (7) = 14\).

Time = 0.08 (sec) , antiderivative size = 22, normalized size of antiderivative = 2.20 \[ \int \frac {1}{1-(c+d x)^2} \, dx=- \frac {\frac {\log {\left (x + \frac {c - 1}{d} \right )}}{2} - \frac {\log {\left (x + \frac {c + 1}{d} \right )}}{2}}{d} \]

[In]

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

[Out]

-(log(x + (c - 1)/d)/2 - log(x + (c + 1)/d)/2)/d

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 25 vs. \(2 (10) = 20\).

Time = 0.19 (sec) , antiderivative size = 25, normalized size of antiderivative = 2.50 \[ \int \frac {1}{1-(c+d x)^2} \, dx=\frac {\log \left (d x + c + 1\right )}{2 \, d} - \frac {\log \left (d x + c - 1\right )}{2 \, d} \]

[In]

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

[Out]

1/2*log(d*x + c + 1)/d - 1/2*log(d*x + c - 1)/d

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 27 vs. \(2 (10) = 20\).

Time = 0.30 (sec) , antiderivative size = 27, normalized size of antiderivative = 2.70 \[ \int \frac {1}{1-(c+d x)^2} \, dx=\frac {\log \left ({\left | d x + c + 1 \right |}\right )}{2 \, d} - \frac {\log \left ({\left | d x + c - 1 \right |}\right )}{2 \, d} \]

[In]

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

[Out]

1/2*log(abs(d*x + c + 1))/d - 1/2*log(abs(d*x + c - 1))/d

Mupad [B] (verification not implemented)

Time = 10.47 (sec) , antiderivative size = 10, normalized size of antiderivative = 1.00 \[ \int \frac {1}{1-(c+d x)^2} \, dx=\frac {\mathrm {atanh}\left (c+d\,x\right )}{d} \]

[In]

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

[Out]

atanh(c + d*x)/d