3.2.2 \(\int \cot ^{-1}(a+b x) \, dx\) [102]

Optimal. Leaf size=33 \[ \frac {(a+b x) \cot ^{-1}(a+b x)}{b}+\frac {\log \left (1+(a+b x)^2\right )}{2 b} \]

[Out]

(b*x+a)*arccot(b*x+a)/b+1/2*ln(1+(b*x+a)^2)/b

________________________________________________________________________________________

Rubi [A]
time = 0.01, antiderivative size = 33, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.500, Rules used = {5148, 4931, 266} \begin {gather*} \frac {\log \left ((a+b x)^2+1\right )}{2 b}+\frac {(a+b x) \cot ^{-1}(a+b x)}{b} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[ArcCot[a + b*x],x]

[Out]

((a + b*x)*ArcCot[a + b*x])/b + Log[1 + (a + b*x)^2]/(2*b)

Rule 266

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]

Rule 4931

Int[((a_.) + ArcCot[(c_.)*(x_)^(n_.)]*(b_.))^(p_.), x_Symbol] :> Simp[x*(a + b*ArcCot[c*x^n])^p, x] + Dist[b*c
*n*p, Int[x^n*((a + b*ArcCot[c*x^n])^(p - 1)/(1 + c^2*x^(2*n))), x], x] /; FreeQ[{a, b, c, n}, x] && IGtQ[p, 0
] && (EqQ[n, 1] || EqQ[p, 1])

Rule 5148

Int[((a_.) + ArcCot[(c_) + (d_.)*(x_)]*(b_.))^(p_.), x_Symbol] :> Dist[1/d, Subst[Int[(a + b*ArcCot[x])^p, x],
 x, c + d*x], x] /; FreeQ[{a, b, c, d}, x] && IGtQ[p, 0]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]
time = 0.01, size = 44, normalized size = 1.33 \begin {gather*} x \cot ^{-1}(a+b x)+\frac {-2 a \text {ArcTan}(a+b x)+\log \left (1+a^2+2 a b x+b^2 x^2\right )}{2 b} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[ArcCot[a + b*x],x]

[Out]

x*ArcCot[a + b*x] + (-2*a*ArcTan[a + b*x] + Log[1 + a^2 + 2*a*b*x + b^2*x^2])/(2*b)

________________________________________________________________________________________

Maple [A]
time = 0.05, size = 30, normalized size = 0.91

method result size
derivativedivides \(\frac {\left (b x +a \right ) \mathrm {arccot}\left (b x +a \right )+\frac {\ln \left (1+\left (b x +a \right )^{2}\right )}{2}}{b}\) \(30\)
default \(\frac {\left (b x +a \right ) \mathrm {arccot}\left (b x +a \right )+\frac {\ln \left (1+\left (b x +a \right )^{2}\right )}{2}}{b}\) \(30\)
risch \(\frac {i x \ln \left (1+i \left (b x +a \right )\right )}{2}-\frac {i x \ln \left (1-i \left (b x +a \right )\right )}{2}+\frac {\pi x}{2}-\frac {a \arctan \left (b x +a \right )}{b}+\frac {\ln \left (b^{2} x^{2}+2 a b x +a^{2}+1\right )}{2 b}\) \(71\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(arccot(b*x+a),x,method=_RETURNVERBOSE)

[Out]

1/b*((b*x+a)*arccot(b*x+a)+1/2*ln(1+(b*x+a)^2))

________________________________________________________________________________________

Maxima [A]
time = 0.26, size = 29, normalized size = 0.88 \begin {gather*} \frac {2 \, {\left (b x + a\right )} \operatorname {arccot}\left (b x + a\right ) + \log \left ({\left (b x + a\right )}^{2} + 1\right )}{2 \, b} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(arccot(b*x+a),x, algorithm="maxima")

[Out]

1/2*(2*(b*x + a)*arccot(b*x + a) + log((b*x + a)^2 + 1))/b

________________________________________________________________________________________

Fricas [A]
time = 6.18, size = 43, normalized size = 1.30 \begin {gather*} \frac {2 \, b x \operatorname {arccot}\left (b x + a\right ) - 2 \, a \arctan \left (b x + a\right ) + \log \left (b^{2} x^{2} + 2 \, a b x + a^{2} + 1\right )}{2 \, b} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(arccot(b*x+a),x, algorithm="fricas")

[Out]

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

________________________________________________________________________________________

Sympy [A]
time = 0.21, size = 46, normalized size = 1.39 \begin {gather*} \begin {cases} \frac {a \operatorname {acot}{\left (a + b x \right )}}{b} + x \operatorname {acot}{\left (a + b x \right )} + \frac {\log {\left (a^{2} + 2 a b x + b^{2} x^{2} + 1 \right )}}{2 b} & \text {for}\: b \neq 0 \\x \operatorname {acot}{\left (a \right )} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(acot(b*x+a),x)

[Out]

Piecewise((a*acot(a + b*x)/b + x*acot(a + b*x) + log(a**2 + 2*a*b*x + b**2*x**2 + 1)/(2*b), Ne(b, 0)), (x*acot
(a), True))

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 111 vs. \(2 (31) = 62\).
time = 0.44, size = 111, normalized size = 3.36 \begin {gather*} -\frac {\arctan \left (\frac {1}{b x + a}\right ) \tan \left (\frac {1}{2} \, \arctan \left (\frac {1}{b x + a}\right )\right )^{2} + \log \left (\frac {16 \, \tan \left (\frac {1}{2} \, \arctan \left (\frac {1}{b x + a}\right )\right )^{2}}{\tan \left (\frac {1}{2} \, \arctan \left (\frac {1}{b x + a}\right )\right )^{4} + 2 \, \tan \left (\frac {1}{2} \, \arctan \left (\frac {1}{b x + a}\right )\right )^{2} + 1}\right ) \tan \left (\frac {1}{2} \, \arctan \left (\frac {1}{b x + a}\right )\right ) - \arctan \left (\frac {1}{b x + a}\right )}{2 \, b \tan \left (\frac {1}{2} \, \arctan \left (\frac {1}{b x + a}\right )\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(arccot(b*x+a),x, algorithm="giac")

[Out]

-1/2*(arctan(1/(b*x + a))*tan(1/2*arctan(1/(b*x + a)))^2 + log(16*tan(1/2*arctan(1/(b*x + a)))^2/(tan(1/2*arct
an(1/(b*x + a)))^4 + 2*tan(1/2*arctan(1/(b*x + a)))^2 + 1))*tan(1/2*arctan(1/(b*x + a))) - arctan(1/(b*x + a))
)/(b*tan(1/2*arctan(1/(b*x + a))))

________________________________________________________________________________________

Mupad [B]
time = 1.20, size = 42, normalized size = 1.27 \begin {gather*} \frac {\frac {\ln \left (a^2+2\,a\,b\,x+b^2\,x^2+1\right )}{2}+a\,\mathrm {acot}\left (a+b\,x\right )}{b}+x\,\mathrm {acot}\left (a+b\,x\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(acot(a + b*x),x)

[Out]

(log(a^2 + b^2*x^2 + 2*a*b*x + 1)/2 + a*acot(a + b*x))/b + x*acot(a + b*x)

________________________________________________________________________________________