\(\int \frac {\text {sech}^{-1}(a+b x)}{x^2} \, dx\) [6]

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

Optimal result

Integrand size = 10, antiderivative size = 70 \[ \int \frac {\text {sech}^{-1}(a+b x)}{x^2} \, dx=-\frac {b \text {sech}^{-1}(a+b x)}{a}-\frac {\text {sech}^{-1}(a+b x)}{x}+\frac {2 b \text {arctanh}\left (\frac {\sqrt {1+a} \tanh \left (\frac {1}{2} \text {sech}^{-1}(a+b x)\right )}{\sqrt {1-a}}\right )}{a \sqrt {1-a^2}} \] Output:

-b*arcsech(b*x+a)/a-arcsech(b*x+a)/x+2*b*arctanh((1+a)^(1/2)*tanh(1/2*arcs 
ech(b*x+a))/(1-a)^(1/2))/a/(-a^2+1)^(1/2)
 

Mathematica [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(244\) vs. \(2(70)=140\).

Time = 0.17 (sec) , antiderivative size = 244, normalized size of antiderivative = 3.49 \[ \int \frac {\text {sech}^{-1}(a+b x)}{x^2} \, dx=-\frac {\text {sech}^{-1}(a+b x)}{x}+\frac {b \left (-\log (x)+\sqrt {1-a^2} \log (a+b x)-\sqrt {1-a^2} \log \left (1+\sqrt {-\frac {-1+a+b x}{1+a+b x}}+a \sqrt {-\frac {-1+a+b x}{1+a+b x}}+b x \sqrt {-\frac {-1+a+b x}{1+a+b x}}\right )+\log \left (1-a^2-a b x+\sqrt {1-a^2} \sqrt {-\frac {-1+a+b x}{1+a+b x}}+a \sqrt {1-a^2} \sqrt {-\frac {-1+a+b x}{1+a+b x}}+\sqrt {1-a^2} b x \sqrt {-\frac {-1+a+b x}{1+a+b x}}\right )\right )}{a \sqrt {1-a^2}} \] Input:

Integrate[ArcSech[a + b*x]/x^2,x]
 

Output:

-(ArcSech[a + b*x]/x) + (b*(-Log[x] + Sqrt[1 - a^2]*Log[a + b*x] - Sqrt[1 
- a^2]*Log[1 + Sqrt[-((-1 + a + b*x)/(1 + a + b*x))] + a*Sqrt[-((-1 + a + 
b*x)/(1 + a + b*x))] + b*x*Sqrt[-((-1 + a + b*x)/(1 + a + b*x))]] + Log[1 
- a^2 - a*b*x + Sqrt[1 - a^2]*Sqrt[-((-1 + a + b*x)/(1 + a + b*x))] + a*Sq 
rt[1 - a^2]*Sqrt[-((-1 + a + b*x)/(1 + a + b*x))] + Sqrt[1 - a^2]*b*x*Sqrt 
[-((-1 + a + b*x)/(1 + a + b*x))]]))/(a*Sqrt[1 - a^2])
 

Rubi [A] (verified)

Time = 0.42 (sec) , antiderivative size = 72, normalized size of antiderivative = 1.03, number of steps used = 8, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.700, Rules used = {6875, 5991, 3042, 4270, 3042, 3138, 221}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {\text {sech}^{-1}(a+b x)}{x^2} \, dx\)

\(\Big \downarrow \) 6875

\(\displaystyle -b \int \frac {(a+b x) \sqrt {\frac {-a-b x+1}{a+b x+1}} (a+b x+1) \text {sech}^{-1}(a+b x)}{b^2 x^2}d\text {sech}^{-1}(a+b x)\)

\(\Big \downarrow \) 5991

\(\displaystyle -b \left (\int -\frac {1}{b x}d\text {sech}^{-1}(a+b x)+\frac {\text {sech}^{-1}(a+b x)}{b x}\right )\)

\(\Big \downarrow \) 3042

\(\displaystyle -b \left (\frac {\text {sech}^{-1}(a+b x)}{b x}+\int \frac {1}{a-\csc \left (i \text {sech}^{-1}(a+b x)+\frac {\pi }{2}\right )}d\text {sech}^{-1}(a+b x)\right )\)

\(\Big \downarrow \) 4270

\(\displaystyle -b \left (-\frac {\int \frac {1}{1-\frac {a}{a+b x}}d\text {sech}^{-1}(a+b x)}{a}+\frac {\text {sech}^{-1}(a+b x)}{a}+\frac {\text {sech}^{-1}(a+b x)}{b x}\right )\)

\(\Big \downarrow \) 3042

\(\displaystyle -b \left (-\frac {\int \frac {1}{1-a \sin \left (i \text {sech}^{-1}(a+b x)+\frac {\pi }{2}\right )}d\text {sech}^{-1}(a+b x)}{a}+\frac {\text {sech}^{-1}(a+b x)}{a}+\frac {\text {sech}^{-1}(a+b x)}{b x}\right )\)

\(\Big \downarrow \) 3138

\(\displaystyle -b \left (-\frac {2 \int \frac {1}{-\left ((a+1) \tanh ^2\left (\frac {1}{2} \text {sech}^{-1}(a+b x)\right )\right )-a+1}d\tanh \left (\frac {1}{2} \text {sech}^{-1}(a+b x)\right )}{a}+\frac {\text {sech}^{-1}(a+b x)}{a}+\frac {\text {sech}^{-1}(a+b x)}{b x}\right )\)

\(\Big \downarrow \) 221

\(\displaystyle -b \left (-\frac {2 \text {arctanh}\left (\frac {\sqrt {a+1} \tanh \left (\frac {1}{2} \text {sech}^{-1}(a+b x)\right )}{\sqrt {1-a}}\right )}{a \sqrt {1-a^2}}+\frac {\text {sech}^{-1}(a+b x)}{a}+\frac {\text {sech}^{-1}(a+b x)}{b x}\right )\)

Input:

Int[ArcSech[a + b*x]/x^2,x]
 

Output:

-(b*(ArcSech[a + b*x]/a + ArcSech[a + b*x]/(b*x) - (2*ArcTanh[(Sqrt[1 + a] 
*Tanh[ArcSech[a + b*x]/2])/Sqrt[1 - a]])/(a*Sqrt[1 - a^2])))
 

Defintions of rubi rules used

rule 221
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]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 3138
Int[((a_) + (b_.)*sin[Pi/2 + (c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> With[{ 
e = FreeFactors[Tan[(c + d*x)/2], x]}, Simp[2*(e/d)   Subst[Int[1/(a + b + 
(a - b)*e^2*x^2), x], x, Tan[(c + d*x)/2]/e], x]] /; FreeQ[{a, b, c, d}, x] 
 && NeQ[a^2 - b^2, 0]
 

rule 4270
Int[(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_))^(-1), x_Symbol] :> Simp[x/a, x] 
- Simp[1/a   Int[1/(1 + (a/b)*Sin[c + d*x]), x], x] /; FreeQ[{a, b, c, d}, 
x] && NeQ[a^2 - b^2, 0]
 

rule 5991
Int[((e_.) + (f_.)*(x_))^(m_.)*Sech[(c_.) + (d_.)*(x_)]*((a_) + (b_.)*Sech[ 
(c_.) + (d_.)*(x_)])^(n_.)*Tanh[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[(-(e 
 + f*x)^m)*((a + b*Sech[c + d*x])^(n + 1)/(b*d*(n + 1))), x] + Simp[f*(m/(b 
*d*(n + 1)))   Int[(e + f*x)^(m - 1)*(a + b*Sech[c + d*x])^(n + 1), x], x] 
/; FreeQ[{a, b, c, d, e, f, n}, x] && IGtQ[m, 0] && NeQ[n, -1]
 

rule 6875
Int[((a_.) + ArcSech[(c_) + (d_.)*(x_)]*(b_.))^(p_.)*((e_.) + (f_.)*(x_))^( 
m_.), x_Symbol] :> Simp[-(d^(m + 1))^(-1)   Subst[Int[(a + b*x)^p*Sech[x]*T 
anh[x]*(d*e - c*f + f*Sech[x])^m, x], x, ArcSech[c + d*x]], x] /; FreeQ[{a, 
 b, c, d, e, f}, x] && IGtQ[p, 0] && IntegerQ[m]
 
Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(170\) vs. \(2(62)=124\).

Time = 0.92 (sec) , antiderivative size = 171, normalized size of antiderivative = 2.44

method result size
derivativedivides \(b \left (-\frac {\operatorname {arcsech}\left (b x +a \right )}{b x}-\frac {\sqrt {-\frac {b x +a -1}{b x +a}}\, \left (b x +a \right ) \sqrt {\frac {b x +a +1}{b x +a}}\, \left (\operatorname {arctanh}\left (\frac {1}{\sqrt {1-\left (b x +a \right )^{2}}}\right ) a^{2}+\sqrt {-a^{2}+1}\, \ln \left (\frac {2 \sqrt {-a^{2}+1}\, \sqrt {1-\left (b x +a \right )^{2}}-2 \left (b x +a \right ) a +2}{b x}\right )-\operatorname {arctanh}\left (\frac {1}{\sqrt {1-\left (b x +a \right )^{2}}}\right )\right )}{\sqrt {1-\left (b x +a \right )^{2}}\, a \left (a -1\right ) \left (1+a \right )}\right )\) \(171\)
default \(b \left (-\frac {\operatorname {arcsech}\left (b x +a \right )}{b x}-\frac {\sqrt {-\frac {b x +a -1}{b x +a}}\, \left (b x +a \right ) \sqrt {\frac {b x +a +1}{b x +a}}\, \left (\operatorname {arctanh}\left (\frac {1}{\sqrt {1-\left (b x +a \right )^{2}}}\right ) a^{2}+\sqrt {-a^{2}+1}\, \ln \left (\frac {2 \sqrt {-a^{2}+1}\, \sqrt {1-\left (b x +a \right )^{2}}-2 \left (b x +a \right ) a +2}{b x}\right )-\operatorname {arctanh}\left (\frac {1}{\sqrt {1-\left (b x +a \right )^{2}}}\right )\right )}{\sqrt {1-\left (b x +a \right )^{2}}\, a \left (a -1\right ) \left (1+a \right )}\right )\) \(171\)
parts \(-\frac {\operatorname {arcsech}\left (b x +a \right )}{x}-\frac {b \sqrt {-\frac {b x +a -1}{b x +a}}\, \left (b x +a \right ) \sqrt {\frac {b x +a +1}{b x +a}}\, \left (\operatorname {arctanh}\left (\frac {1}{\sqrt {-b^{2} x^{2}-2 b x a -a^{2}+1}}\right ) a^{2}+\sqrt {-a^{2}+1}\, \ln \left (\frac {-2 a^{2}+2-2 b x a +2 \sqrt {-a^{2}+1}\, \sqrt {-b^{2} x^{2}-2 b x a -a^{2}+1}}{x}\right )-\operatorname {arctanh}\left (\frac {1}{\sqrt {-b^{2} x^{2}-2 b x a -a^{2}+1}}\right )\right ) \operatorname {csgn}\left (b \right )^{2}}{\sqrt {-b^{2} x^{2}-2 b x a -a^{2}+1}\, \left (1+a \right ) \left (a -1\right ) a}\) \(206\)

Input:

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

Output:

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

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 320 vs. \(2 (62) = 124\).

Time = 0.14 (sec) , antiderivative size = 651, normalized size of antiderivative = 9.30 \[ \int \frac {\text {sech}^{-1}(a+b x)}{x^2} \, dx=\left [-\frac {{\left (a^{2} - 1\right )} b x \log \left (\frac {{\left (b x + a\right )} \sqrt {-\frac {b^{2} x^{2} + 2 \, a b x + a^{2} - 1}{b^{2} x^{2} + 2 \, a b x + a^{2}}} + 1}{x}\right ) - {\left (a^{2} - 1\right )} b x \log \left (\frac {{\left (b x + a\right )} \sqrt {-\frac {b^{2} x^{2} + 2 \, a b x + a^{2} - 1}{b^{2} x^{2} + 2 \, a b x + a^{2}}} - 1}{x}\right ) + \sqrt {-a^{2} + 1} b x \log \left (\frac {{\left (2 \, a^{2} - 1\right )} b^{2} x^{2} + 2 \, a^{4} + 4 \, {\left (a^{3} - a\right )} b x - 4 \, a^{2} - 2 \, {\left (a b^{2} x^{2} + a^{3} + {\left (2 \, a^{2} - 1\right )} b x - a\right )} \sqrt {-a^{2} + 1} \sqrt {-\frac {b^{2} x^{2} + 2 \, a b x + a^{2} - 1}{b^{2} x^{2} + 2 \, a b x + a^{2}}} + 2}{x^{2}}\right ) + 2 \, {\left (a^{3} - a\right )} \log \left (\frac {{\left (b x + a\right )} \sqrt {-\frac {b^{2} x^{2} + 2 \, a b x + a^{2} - 1}{b^{2} x^{2} + 2 \, a b x + a^{2}}} + 1}{b x + a}\right )}{2 \, {\left (a^{3} - a\right )} x}, -\frac {{\left (a^{2} - 1\right )} b x \log \left (\frac {{\left (b x + a\right )} \sqrt {-\frac {b^{2} x^{2} + 2 \, a b x + a^{2} - 1}{b^{2} x^{2} + 2 \, a b x + a^{2}}} + 1}{x}\right ) - {\left (a^{2} - 1\right )} b x \log \left (\frac {{\left (b x + a\right )} \sqrt {-\frac {b^{2} x^{2} + 2 \, a b x + a^{2} - 1}{b^{2} x^{2} + 2 \, a b x + a^{2}}} - 1}{x}\right ) + 2 \, \sqrt {a^{2} - 1} b x \arctan \left (\frac {{\left (a b^{2} x^{2} + a^{3} + {\left (2 \, a^{2} - 1\right )} b x - a\right )} \sqrt {a^{2} - 1} \sqrt {-\frac {b^{2} x^{2} + 2 \, a b x + a^{2} - 1}{b^{2} x^{2} + 2 \, a b x + a^{2}}}}{{\left (a^{2} - 1\right )} b^{2} x^{2} + a^{4} + 2 \, {\left (a^{3} - a\right )} b x - 2 \, a^{2} + 1}\right ) + 2 \, {\left (a^{3} - a\right )} \log \left (\frac {{\left (b x + a\right )} \sqrt {-\frac {b^{2} x^{2} + 2 \, a b x + a^{2} - 1}{b^{2} x^{2} + 2 \, a b x + a^{2}}} + 1}{b x + a}\right )}{2 \, {\left (a^{3} - a\right )} x}\right ] \] Input:

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

Output:

[-1/2*((a^2 - 1)*b*x*log(((b*x + a)*sqrt(-(b^2*x^2 + 2*a*b*x + a^2 - 1)/(b 
^2*x^2 + 2*a*b*x + a^2)) + 1)/x) - (a^2 - 1)*b*x*log(((b*x + a)*sqrt(-(b^2 
*x^2 + 2*a*b*x + a^2 - 1)/(b^2*x^2 + 2*a*b*x + a^2)) - 1)/x) + sqrt(-a^2 + 
 1)*b*x*log(((2*a^2 - 1)*b^2*x^2 + 2*a^4 + 4*(a^3 - a)*b*x - 4*a^2 - 2*(a* 
b^2*x^2 + a^3 + (2*a^2 - 1)*b*x - a)*sqrt(-a^2 + 1)*sqrt(-(b^2*x^2 + 2*a*b 
*x + a^2 - 1)/(b^2*x^2 + 2*a*b*x + a^2)) + 2)/x^2) + 2*(a^3 - a)*log(((b*x 
 + a)*sqrt(-(b^2*x^2 + 2*a*b*x + a^2 - 1)/(b^2*x^2 + 2*a*b*x + a^2)) + 1)/ 
(b*x + a)))/((a^3 - a)*x), -1/2*((a^2 - 1)*b*x*log(((b*x + a)*sqrt(-(b^2*x 
^2 + 2*a*b*x + a^2 - 1)/(b^2*x^2 + 2*a*b*x + a^2)) + 1)/x) - (a^2 - 1)*b*x 
*log(((b*x + a)*sqrt(-(b^2*x^2 + 2*a*b*x + a^2 - 1)/(b^2*x^2 + 2*a*b*x + a 
^2)) - 1)/x) + 2*sqrt(a^2 - 1)*b*x*arctan((a*b^2*x^2 + a^3 + (2*a^2 - 1)*b 
*x - a)*sqrt(a^2 - 1)*sqrt(-(b^2*x^2 + 2*a*b*x + a^2 - 1)/(b^2*x^2 + 2*a*b 
*x + a^2))/((a^2 - 1)*b^2*x^2 + a^4 + 2*(a^3 - a)*b*x - 2*a^2 + 1)) + 2*(a 
^3 - a)*log(((b*x + a)*sqrt(-(b^2*x^2 + 2*a*b*x + a^2 - 1)/(b^2*x^2 + 2*a* 
b*x + a^2)) + 1)/(b*x + a)))/((a^3 - a)*x)]
 

Sympy [F]

\[ \int \frac {\text {sech}^{-1}(a+b x)}{x^2} \, dx=\int \frac {\operatorname {asech}{\left (a + b x \right )}}{x^{2}}\, dx \] Input:

integrate(asech(b*x+a)/x**2,x)
 

Output:

Integral(asech(a + b*x)/x**2, x)
 

Maxima [F]

\[ \int \frac {\text {sech}^{-1}(a+b x)}{x^2} \, dx=\int { \frac {\operatorname {arsech}\left (b x + a\right )}{x^{2}} \,d x } \] Input:

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

Output:

b*log(x)/(a^3 - a) - 1/2*((a^2*b - a*b)*x*log(b*x + a + 1) + (a^2*b + a*b) 
*x*log(-b*x - a + 1) + 2*(a^3 - a)*log(sqrt(b*x + a + 1)*sqrt(-b*x - a + 1 
)*b*x + sqrt(b*x + a + 1)*sqrt(-b*x - a + 1)*a + b*x + a) - 2*(a^3 + (a^2* 
b - b)*x - a)*log(b*x + a) - 2*(a^3 - a)*log(b*x + a))/((a^3 - a)*x) - int 
egrate((b^2*x + a*b)/(b^2*x^3 + 2*a*b*x^2 + (a^2 - 1)*x + (b^2*x^3 + 2*a*b 
*x^2 + (a^2 - 1)*x)*e^(1/2*log(b*x + a + 1) + 1/2*log(-b*x - a + 1))), x)
 

Giac [F]

\[ \int \frac {\text {sech}^{-1}(a+b x)}{x^2} \, dx=\int { \frac {\operatorname {arsech}\left (b x + a\right )}{x^{2}} \,d x } \] Input:

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

Output:

integrate(arcsech(b*x + a)/x^2, x)
 

Mupad [F(-1)]

Timed out. \[ \int \frac {\text {sech}^{-1}(a+b x)}{x^2} \, dx=\int \frac {\mathrm {acosh}\left (\frac {1}{a+b\,x}\right )}{x^2} \,d x \] Input:

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

Output:

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

Reduce [F]

\[ \int \frac {\text {sech}^{-1}(a+b x)}{x^2} \, dx=\int \frac {\mathit {asech} \left (b x +a \right )}{x^{2}}d x \] Input:

int(asech(b*x+a)/x^2,x)
 

Output:

int(asech(a + b*x)/x**2,x)