\(\int \frac {\text {sech}^4(x)}{a+b \sinh (x)} \, dx\) [197]

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

Optimal result

Integrand size = 13, antiderivative size = 100 \[ \int \frac {\text {sech}^4(x)}{a+b \sinh (x)} \, dx=-\frac {2 b^4 \text {arctanh}\left (\frac {b-a \tanh \left (\frac {x}{2}\right )}{\sqrt {a^2+b^2}}\right )}{\left (a^2+b^2\right )^{5/2}}+\frac {\text {sech}^3(x) (b+a \sinh (x))}{3 \left (a^2+b^2\right )}+\frac {\text {sech}(x) \left (3 b^3+a \left (2 a^2+5 b^2\right ) \sinh (x)\right )}{3 \left (a^2+b^2\right )^2} \] Output:

-2*b^4*arctanh((b-a*tanh(1/2*x))/(a^2+b^2)^(1/2))/(a^2+b^2)^(5/2)+sech(x)^ 
3*(b+a*sinh(x))/(3*a^2+3*b^2)+1/3*sech(x)*(3*b^3+a*(2*a^2+5*b^2)*sinh(x))/ 
(a^2+b^2)^2
 

Mathematica [A] (verified)

Time = 0.26 (sec) , antiderivative size = 102, normalized size of antiderivative = 1.02 \[ \int \frac {\text {sech}^4(x)}{a+b \sinh (x)} \, dx=\frac {\frac {6 b^4 \arctan \left (\frac {b-a \tanh \left (\frac {x}{2}\right )}{\sqrt {-a^2-b^2}}\right )}{\sqrt {-a^2-b^2}}+3 b^3 \text {sech}(x)+\left (a^2+b^2\right ) \text {sech}^3(x) (b+a \sinh (x))+a \left (2 a^2+5 b^2\right ) \tanh (x)}{3 \left (a^2+b^2\right )^2} \] Input:

Integrate[Sech[x]^4/(a + b*Sinh[x]),x]
 

Output:

((6*b^4*ArcTan[(b - a*Tanh[x/2])/Sqrt[-a^2 - b^2]])/Sqrt[-a^2 - b^2] + 3*b 
^3*Sech[x] + (a^2 + b^2)*Sech[x]^3*(b + a*Sinh[x]) + a*(2*a^2 + 5*b^2)*Tan 
h[x])/(3*(a^2 + b^2)^2)
 

Rubi [A] (verified)

Time = 0.69 (sec) , antiderivative size = 116, normalized size of antiderivative = 1.16, number of steps used = 11, number of rules used = 10, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.769, Rules used = {3042, 3175, 25, 3042, 3345, 27, 3042, 3139, 1083, 219}

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}^4(x)}{a+b \sinh (x)} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {1}{\cos (i x)^4 (a-i b \sin (i x))}dx\)

\(\Big \downarrow \) 3175

\(\displaystyle \frac {\text {sech}^3(x) (a \sinh (x)+b)}{3 \left (a^2+b^2\right )}-\frac {\int -\frac {\text {sech}^2(x) \left (2 a^2+2 b \sinh (x) a+3 b^2\right )}{a+b \sinh (x)}dx}{3 \left (a^2+b^2\right )}\)

\(\Big \downarrow \) 25

\(\displaystyle \frac {\int \frac {\text {sech}^2(x) \left (2 a^2+2 b \sinh (x) a+3 b^2\right )}{a+b \sinh (x)}dx}{3 \left (a^2+b^2\right )}+\frac {\text {sech}^3(x) (a \sinh (x)+b)}{3 \left (a^2+b^2\right )}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {\text {sech}^3(x) (a \sinh (x)+b)}{3 \left (a^2+b^2\right )}+\frac {\int \frac {2 a^2-2 i b \sin (i x) a+3 b^2}{\cos (i x)^2 (a-i b \sin (i x))}dx}{3 \left (a^2+b^2\right )}\)

\(\Big \downarrow \) 3345

\(\displaystyle \frac {\frac {\text {sech}(x) \left (a \left (2 a^2+5 b^2\right ) \sinh (x)+3 b^3\right )}{a^2+b^2}-\frac {\int -\frac {3 b^4}{a+b \sinh (x)}dx}{a^2+b^2}}{3 \left (a^2+b^2\right )}+\frac {\text {sech}^3(x) (a \sinh (x)+b)}{3 \left (a^2+b^2\right )}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {\frac {3 b^4 \int \frac {1}{a+b \sinh (x)}dx}{a^2+b^2}+\frac {\text {sech}(x) \left (a \left (2 a^2+5 b^2\right ) \sinh (x)+3 b^3\right )}{a^2+b^2}}{3 \left (a^2+b^2\right )}+\frac {\text {sech}^3(x) (a \sinh (x)+b)}{3 \left (a^2+b^2\right )}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {\text {sech}^3(x) (a \sinh (x)+b)}{3 \left (a^2+b^2\right )}+\frac {\frac {\text {sech}(x) \left (a \left (2 a^2+5 b^2\right ) \sinh (x)+3 b^3\right )}{a^2+b^2}+\frac {3 b^4 \int \frac {1}{a-i b \sin (i x)}dx}{a^2+b^2}}{3 \left (a^2+b^2\right )}\)

\(\Big \downarrow \) 3139

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

\(\Big \downarrow \) 1083

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

\(\Big \downarrow \) 219

\(\displaystyle \frac {\frac {\text {sech}(x) \left (a \left (2 a^2+5 b^2\right ) \sinh (x)+3 b^3\right )}{a^2+b^2}-\frac {6 b^4 \text {arctanh}\left (\frac {2 b-2 a \tanh \left (\frac {x}{2}\right )}{2 \sqrt {a^2+b^2}}\right )}{\left (a^2+b^2\right )^{3/2}}}{3 \left (a^2+b^2\right )}+\frac {\text {sech}^3(x) (a \sinh (x)+b)}{3 \left (a^2+b^2\right )}\)

Input:

Int[Sech[x]^4/(a + b*Sinh[x]),x]
 

Output:

(Sech[x]^3*(b + a*Sinh[x]))/(3*(a^2 + b^2)) + ((-6*b^4*ArcTanh[(2*b - 2*a* 
Tanh[x/2])/(2*Sqrt[a^2 + b^2])])/(a^2 + b^2)^(3/2) + (Sech[x]*(3*b^3 + a*( 
2*a^2 + 5*b^2)*Sinh[x]))/(a^2 + b^2))/(3*(a^2 + b^2))
 

Defintions of rubi rules used

rule 25
Int[-(Fx_), x_Symbol] :> Simp[Identity[-1]   Int[Fx, x], x]
 

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

rule 219
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] && (Gt 
Q[a, 0] || LtQ[b, 0])
 

rule 1083
Int[((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(-1), x_Symbol] :> Simp[-2   Subst[I 
nt[1/Simp[b^2 - 4*a*c - x^2, x], x], x, b + 2*c*x], x] /; FreeQ[{a, b, c}, 
x]
 

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

rule 3139
Int[((a_) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> With[{e = Fre 
eFactors[Tan[(c + d*x)/2], x]}, Simp[2*(e/d)   Subst[Int[1/(a + 2*b*e*x + a 
*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 3175
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x 
_)])^(m_), x_Symbol] :> Simp[(g*Cos[e + f*x])^(p + 1)*(a + b*Sin[e + f*x])^ 
(m + 1)*((b - a*Sin[e + f*x])/(f*g*(a^2 - b^2)*(p + 1))), x] + Simp[1/(g^2* 
(a^2 - b^2)*(p + 1))   Int[(g*Cos[e + f*x])^(p + 2)*(a + b*Sin[e + f*x])^m* 
(a^2*(p + 2) - b^2*(m + p + 2) + a*b*(m + p + 3)*Sin[e + f*x]), x], x] /; F 
reeQ[{a, b, e, f, g, m}, x] && NeQ[a^2 - b^2, 0] && LtQ[p, -1] && IntegersQ 
[2*m, 2*p]
 

rule 3345
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x 
_)])^(m_.)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[(g*Co 
s[e + f*x])^(p + 1)*(a + b*Sin[e + f*x])^(m + 1)*((b*c - a*d - (a*c - b*d)* 
Sin[e + f*x])/(f*g*(a^2 - b^2)*(p + 1))), x] + Simp[1/(g^2*(a^2 - b^2)*(p + 
 1))   Int[(g*Cos[e + f*x])^(p + 2)*(a + b*Sin[e + f*x])^m*Simp[c*(a^2*(p + 
 2) - b^2*(m + p + 2)) + a*b*d*m + b*(a*c - b*d)*(m + p + 3)*Sin[e + f*x], 
x], x], x] /; FreeQ[{a, b, c, d, e, f, g, m}, x] && NeQ[a^2 - b^2, 0] && Lt 
Q[p, -1] && IntegerQ[2*m]
 
Maple [A] (verified)

Time = 39.14 (sec) , antiderivative size = 182, normalized size of antiderivative = 1.82

method result size
default \(\frac {2 b^{4} \operatorname {arctanh}\left (\frac {2 a \tanh \left (\frac {x}{2}\right )-2 b}{2 \sqrt {a^{2}+b^{2}}}\right )}{\left (a^{4}+2 a^{2} b^{2}+b^{4}\right ) \sqrt {a^{2}+b^{2}}}-\frac {2 \left (\left (-a^{3}-2 a \,b^{2}\right ) \tanh \left (\frac {x}{2}\right )^{5}+\left (-a^{2} b -2 b^{3}\right ) \tanh \left (\frac {x}{2}\right )^{4}+\left (-\frac {2}{3} a^{3}-\frac {8}{3} a \,b^{2}\right ) \tanh \left (\frac {x}{2}\right )^{3}-2 \tanh \left (\frac {x}{2}\right )^{2} b^{3}+\left (-a^{3}-2 a \,b^{2}\right ) \tanh \left (\frac {x}{2}\right )-\frac {a^{2} b}{3}-\frac {4 b^{3}}{3}\right )}{\left (a^{4}+2 a^{2} b^{2}+b^{4}\right ) \left (1+\tanh \left (\frac {x}{2}\right )^{2}\right )^{3}}\) \(182\)
risch \(-\frac {2 \left (-3 b^{3} {\mathrm e}^{5 x}+3 \,{\mathrm e}^{4 x} a \,b^{2}-4 a^{2} b \,{\mathrm e}^{3 x}-10 \,{\mathrm e}^{3 x} b^{3}+6 a^{3} {\mathrm e}^{2 x}+12 a \,{\mathrm e}^{2 x} b^{2}-3 b^{3} {\mathrm e}^{x}+2 a^{3}+5 a \,b^{2}\right )}{3 \left (a^{2}+b^{2}\right )^{2} \left ({\mathrm e}^{2 x}+1\right )^{3}}+\frac {b^{4} \ln \left ({\mathrm e}^{x}+\frac {\left (a^{2}+b^{2}\right )^{\frac {5}{2}} a -a^{6}-3 a^{4} b^{2}-3 a^{2} b^{4}-b^{6}}{b \left (a^{2}+b^{2}\right )^{\frac {5}{2}}}\right )}{\left (a^{2}+b^{2}\right )^{\frac {5}{2}}}-\frac {b^{4} \ln \left ({\mathrm e}^{x}+\frac {\left (a^{2}+b^{2}\right )^{\frac {5}{2}} a +a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}{b \left (a^{2}+b^{2}\right )^{\frac {5}{2}}}\right )}{\left (a^{2}+b^{2}\right )^{\frac {5}{2}}}\) \(230\)

Input:

int(sech(x)^4/(a+b*sinh(x)),x,method=_RETURNVERBOSE)
 

Output:

2*b^4/(a^4+2*a^2*b^2+b^4)/(a^2+b^2)^(1/2)*arctanh(1/2*(2*a*tanh(1/2*x)-2*b 
)/(a^2+b^2)^(1/2))-2/(a^4+2*a^2*b^2+b^4)*((-a^3-2*a*b^2)*tanh(1/2*x)^5+(-a 
^2*b-2*b^3)*tanh(1/2*x)^4+(-2/3*a^3-8/3*a*b^2)*tanh(1/2*x)^3-2*tanh(1/2*x) 
^2*b^3+(-a^3-2*a*b^2)*tanh(1/2*x)-1/3*a^2*b-4/3*b^3)/(1+tanh(1/2*x)^2)^3
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 1142 vs. \(2 (92) = 184\).

Time = 0.12 (sec) , antiderivative size = 1142, normalized size of antiderivative = 11.42 \[ \int \frac {\text {sech}^4(x)}{a+b \sinh (x)} \, dx=\text {Too large to display} \] Input:

integrate(sech(x)^4/(a+b*sinh(x)),x, algorithm="fricas")
 

Output:

1/3*(6*(a^2*b^3 + b^5)*cosh(x)^5 + 6*(a^2*b^3 + b^5)*sinh(x)^5 - 4*a^5 - 1 
4*a^3*b^2 - 10*a*b^4 - 6*(a^3*b^2 + a*b^4)*cosh(x)^4 - 6*(a^3*b^2 + a*b^4 
- 5*(a^2*b^3 + b^5)*cosh(x))*sinh(x)^4 + 4*(2*a^4*b + 7*a^2*b^3 + 5*b^5)*c 
osh(x)^3 + 4*(2*a^4*b + 7*a^2*b^3 + 5*b^5 + 15*(a^2*b^3 + b^5)*cosh(x)^2 - 
 6*(a^3*b^2 + a*b^4)*cosh(x))*sinh(x)^3 - 12*(a^5 + 3*a^3*b^2 + 2*a*b^4)*c 
osh(x)^2 - 12*(a^5 + 3*a^3*b^2 + 2*a*b^4 - 5*(a^2*b^3 + b^5)*cosh(x)^3 + 3 
*(a^3*b^2 + a*b^4)*cosh(x)^2 - (2*a^4*b + 7*a^2*b^3 + 5*b^5)*cosh(x))*sinh 
(x)^2 + 3*(b^4*cosh(x)^6 + 6*b^4*cosh(x)*sinh(x)^5 + b^4*sinh(x)^6 + 3*b^4 
*cosh(x)^4 + 3*b^4*cosh(x)^2 + 3*(5*b^4*cosh(x)^2 + b^4)*sinh(x)^4 + b^4 + 
 4*(5*b^4*cosh(x)^3 + 3*b^4*cosh(x))*sinh(x)^3 + 3*(5*b^4*cosh(x)^4 + 6*b^ 
4*cosh(x)^2 + b^4)*sinh(x)^2 + 6*(b^4*cosh(x)^5 + 2*b^4*cosh(x)^3 + b^4*co 
sh(x))*sinh(x))*sqrt(a^2 + b^2)*log((b^2*cosh(x)^2 + b^2*sinh(x)^2 + 2*a*b 
*cosh(x) + 2*a^2 + b^2 + 2*(b^2*cosh(x) + a*b)*sinh(x) - 2*sqrt(a^2 + b^2) 
*(b*cosh(x) + b*sinh(x) + a))/(b*cosh(x)^2 + b*sinh(x)^2 + 2*a*cosh(x) + 2 
*(b*cosh(x) + a)*sinh(x) - b)) + 6*(a^2*b^3 + b^5)*cosh(x) + 6*(a^2*b^3 + 
b^5 + 5*(a^2*b^3 + b^5)*cosh(x)^4 - 4*(a^3*b^2 + a*b^4)*cosh(x)^3 + 2*(2*a 
^4*b + 7*a^2*b^3 + 5*b^5)*cosh(x)^2 - 4*(a^5 + 3*a^3*b^2 + 2*a*b^4)*cosh(x 
))*sinh(x))/((a^6 + 3*a^4*b^2 + 3*a^2*b^4 + b^6)*cosh(x)^6 + 6*(a^6 + 3*a^ 
4*b^2 + 3*a^2*b^4 + b^6)*cosh(x)*sinh(x)^5 + (a^6 + 3*a^4*b^2 + 3*a^2*b^4 
+ b^6)*sinh(x)^6 + a^6 + 3*a^4*b^2 + 3*a^2*b^4 + b^6 + 3*(a^6 + 3*a^4*b...
 

Sympy [F]

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

integrate(sech(x)**4/(a+b*sinh(x)),x)
 

Output:

Integral(sech(x)**4/(a + b*sinh(x)), x)
 

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 230 vs. \(2 (92) = 184\).

Time = 0.15 (sec) , antiderivative size = 230, normalized size of antiderivative = 2.30 \[ \int \frac {\text {sech}^4(x)}{a+b \sinh (x)} \, dx=\frac {b^{4} \log \left (\frac {b e^{\left (-x\right )} - a - \sqrt {a^{2} + b^{2}}}{b e^{\left (-x\right )} - a + \sqrt {a^{2} + b^{2}}}\right )}{{\left (a^{4} + 2 \, a^{2} b^{2} + b^{4}\right )} \sqrt {a^{2} + b^{2}}} + \frac {2 \, {\left (3 \, b^{3} e^{\left (-x\right )} + 3 \, a b^{2} e^{\left (-4 \, x\right )} + 3 \, b^{3} e^{\left (-5 \, x\right )} + 2 \, a^{3} + 5 \, a b^{2} + 6 \, {\left (a^{3} + 2 \, a b^{2}\right )} e^{\left (-2 \, x\right )} + 2 \, {\left (2 \, a^{2} b + 5 \, b^{3}\right )} e^{\left (-3 \, x\right )}\right )}}{3 \, {\left (a^{4} + 2 \, a^{2} b^{2} + b^{4} + 3 \, {\left (a^{4} + 2 \, a^{2} b^{2} + b^{4}\right )} e^{\left (-2 \, x\right )} + 3 \, {\left (a^{4} + 2 \, a^{2} b^{2} + b^{4}\right )} e^{\left (-4 \, x\right )} + {\left (a^{4} + 2 \, a^{2} b^{2} + b^{4}\right )} e^{\left (-6 \, x\right )}\right )}} \] Input:

integrate(sech(x)^4/(a+b*sinh(x)),x, algorithm="maxima")
 

Output:

b^4*log((b*e^(-x) - a - sqrt(a^2 + b^2))/(b*e^(-x) - a + sqrt(a^2 + b^2))) 
/((a^4 + 2*a^2*b^2 + b^4)*sqrt(a^2 + b^2)) + 2/3*(3*b^3*e^(-x) + 3*a*b^2*e 
^(-4*x) + 3*b^3*e^(-5*x) + 2*a^3 + 5*a*b^2 + 6*(a^3 + 2*a*b^2)*e^(-2*x) + 
2*(2*a^2*b + 5*b^3)*e^(-3*x))/(a^4 + 2*a^2*b^2 + b^4 + 3*(a^4 + 2*a^2*b^2 
+ b^4)*e^(-2*x) + 3*(a^4 + 2*a^2*b^2 + b^4)*e^(-4*x) + (a^4 + 2*a^2*b^2 + 
b^4)*e^(-6*x))
 

Giac [A] (verification not implemented)

Time = 0.14 (sec) , antiderivative size = 180, normalized size of antiderivative = 1.80 \[ \int \frac {\text {sech}^4(x)}{a+b \sinh (x)} \, dx=\frac {b^{4} \log \left (\frac {{\left | 2 \, b e^{x} + 2 \, a - 2 \, \sqrt {a^{2} + b^{2}} \right |}}{{\left | 2 \, b e^{x} + 2 \, a + 2 \, \sqrt {a^{2} + b^{2}} \right |}}\right )}{{\left (a^{4} + 2 \, a^{2} b^{2} + b^{4}\right )} \sqrt {a^{2} + b^{2}}} + \frac {2 \, {\left (3 \, b^{3} e^{\left (5 \, x\right )} - 3 \, a b^{2} e^{\left (4 \, x\right )} + 4 \, a^{2} b e^{\left (3 \, x\right )} + 10 \, b^{3} e^{\left (3 \, x\right )} - 6 \, a^{3} e^{\left (2 \, x\right )} - 12 \, a b^{2} e^{\left (2 \, x\right )} + 3 \, b^{3} e^{x} - 2 \, a^{3} - 5 \, a b^{2}\right )}}{3 \, {\left (a^{4} + 2 \, a^{2} b^{2} + b^{4}\right )} {\left (e^{\left (2 \, x\right )} + 1\right )}^{3}} \] Input:

integrate(sech(x)^4/(a+b*sinh(x)),x, algorithm="giac")
 

Output:

b^4*log(abs(2*b*e^x + 2*a - 2*sqrt(a^2 + b^2))/abs(2*b*e^x + 2*a + 2*sqrt( 
a^2 + b^2)))/((a^4 + 2*a^2*b^2 + b^4)*sqrt(a^2 + b^2)) + 2/3*(3*b^3*e^(5*x 
) - 3*a*b^2*e^(4*x) + 4*a^2*b*e^(3*x) + 10*b^3*e^(3*x) - 6*a^3*e^(2*x) - 1 
2*a*b^2*e^(2*x) + 3*b^3*e^x - 2*a^3 - 5*a*b^2)/((a^4 + 2*a^2*b^2 + b^4)*(e 
^(2*x) + 1)^3)
 

Mupad [B] (verification not implemented)

Time = 2.54 (sec) , antiderivative size = 634, normalized size of antiderivative = 6.34 \[ \int \frac {\text {sech}^4(x)}{a+b \sinh (x)} \, dx=\frac {\frac {2\,b^3\,{\mathrm {e}}^x}{{\left (a^2+b^2\right )}^2}-\frac {2\,a\,b^2}{{\left (a^2+b^2\right )}^2}}{{\mathrm {e}}^{2\,x}+1}-\frac {\frac {4\,\left (a^3+a\,b^2\right )}{{\left (a^2+b^2\right )}^2}-\frac {8\,{\mathrm {e}}^x\,\left (a^2\,b+b^3\right )}{3\,{\left (a^2+b^2\right )}^2}}{2\,{\mathrm {e}}^{2\,x}+{\mathrm {e}}^{4\,x}+1}+\frac {\frac {8\,a}{3\,\left (a^2+b^2\right )}-\frac {8\,b\,{\mathrm {e}}^x}{3\,\left (a^2+b^2\right )}}{3\,{\mathrm {e}}^{2\,x}+3\,{\mathrm {e}}^{4\,x}+{\mathrm {e}}^{6\,x}+1}-\frac {2\,\mathrm {atan}\left (\left ({\mathrm {e}}^x\,\left (\frac {2\,b^2}{\sqrt {b^8}\,{\left (a^2+b^2\right )}^2\,\left (a^4+2\,a^2\,b^2+b^4\right )}+\frac {2\,a\,\left (a^5\,\sqrt {b^8}+2\,a^3\,b^2\,\sqrt {b^8}+a\,b^4\,\sqrt {b^8}\right )}{b^6\,\sqrt {-{\left (a^2+b^2\right )}^5}\,\left (a^4+2\,a^2\,b^2+b^4\right )\,\sqrt {-a^{10}-5\,a^8\,b^2-10\,a^6\,b^4-10\,a^4\,b^6-5\,a^2\,b^8-b^{10}}}\right )-\frac {2\,a\,\left (b^5\,\sqrt {b^8}+2\,a^2\,b^3\,\sqrt {b^8}+a^4\,b\,\sqrt {b^8}\right )}{b^6\,\sqrt {-{\left (a^2+b^2\right )}^5}\,\left (a^4+2\,a^2\,b^2+b^4\right )\,\sqrt {-a^{10}-5\,a^8\,b^2-10\,a^6\,b^4-10\,a^4\,b^6-5\,a^2\,b^8-b^{10}}}\right )\,\left (\frac {b^5\,\sqrt {-a^{10}-5\,a^8\,b^2-10\,a^6\,b^4-10\,a^4\,b^6-5\,a^2\,b^8-b^{10}}}{2}+\frac {a^4\,b\,\sqrt {-a^{10}-5\,a^8\,b^2-10\,a^6\,b^4-10\,a^4\,b^6-5\,a^2\,b^8-b^{10}}}{2}+a^2\,b^3\,\sqrt {-a^{10}-5\,a^8\,b^2-10\,a^6\,b^4-10\,a^4\,b^6-5\,a^2\,b^8-b^{10}}\right )\right )\,\sqrt {b^8}}{\sqrt {-a^{10}-5\,a^8\,b^2-10\,a^6\,b^4-10\,a^4\,b^6-5\,a^2\,b^8-b^{10}}} \] Input:

int(1/(cosh(x)^4*(a + b*sinh(x))),x)
 

Output:

((2*b^3*exp(x))/(a^2 + b^2)^2 - (2*a*b^2)/(a^2 + b^2)^2)/(exp(2*x) + 1) - 
((4*(a*b^2 + a^3))/(a^2 + b^2)^2 - (8*exp(x)*(a^2*b + b^3))/(3*(a^2 + b^2) 
^2))/(2*exp(2*x) + exp(4*x) + 1) + ((8*a)/(3*(a^2 + b^2)) - (8*b*exp(x))/( 
3*(a^2 + b^2)))/(3*exp(2*x) + 3*exp(4*x) + exp(6*x) + 1) - (2*atan((exp(x) 
*((2*b^2)/((b^8)^(1/2)*(a^2 + b^2)^2*(a^4 + b^4 + 2*a^2*b^2)) + (2*a*(a^5* 
(b^8)^(1/2) + 2*a^3*b^2*(b^8)^(1/2) + a*b^4*(b^8)^(1/2)))/(b^6*(-(a^2 + b^ 
2)^5)^(1/2)*(a^4 + b^4 + 2*a^2*b^2)*(- a^10 - b^10 - 5*a^2*b^8 - 10*a^4*b^ 
6 - 10*a^6*b^4 - 5*a^8*b^2)^(1/2))) - (2*a*(b^5*(b^8)^(1/2) + 2*a^2*b^3*(b 
^8)^(1/2) + a^4*b*(b^8)^(1/2)))/(b^6*(-(a^2 + b^2)^5)^(1/2)*(a^4 + b^4 + 2 
*a^2*b^2)*(- a^10 - b^10 - 5*a^2*b^8 - 10*a^4*b^6 - 10*a^6*b^4 - 5*a^8*b^2 
)^(1/2)))*((b^5*(- a^10 - b^10 - 5*a^2*b^8 - 10*a^4*b^6 - 10*a^6*b^4 - 5*a 
^8*b^2)^(1/2))/2 + (a^4*b*(- a^10 - b^10 - 5*a^2*b^8 - 10*a^4*b^6 - 10*a^6 
*b^4 - 5*a^8*b^2)^(1/2))/2 + a^2*b^3*(- a^10 - b^10 - 5*a^2*b^8 - 10*a^4*b 
^6 - 10*a^6*b^4 - 5*a^8*b^2)^(1/2)))*(b^8)^(1/2))/(- a^10 - b^10 - 5*a^2*b 
^8 - 10*a^4*b^6 - 10*a^6*b^4 - 5*a^8*b^2)^(1/2)
 

Reduce [B] (verification not implemented)

Time = 0.16 (sec) , antiderivative size = 480, normalized size of antiderivative = 4.80 \[ \int \frac {\text {sech}^4(x)}{a+b \sinh (x)} \, dx=\frac {6 e^{6 x} \sqrt {a^{2}+b^{2}}\, \mathit {atan} \left (\frac {e^{x} b i +a i}{\sqrt {a^{2}+b^{2}}}\right ) b^{4} i +18 e^{4 x} \sqrt {a^{2}+b^{2}}\, \mathit {atan} \left (\frac {e^{x} b i +a i}{\sqrt {a^{2}+b^{2}}}\right ) b^{4} i +18 e^{2 x} \sqrt {a^{2}+b^{2}}\, \mathit {atan} \left (\frac {e^{x} b i +a i}{\sqrt {a^{2}+b^{2}}}\right ) b^{4} i +6 \sqrt {a^{2}+b^{2}}\, \mathit {atan} \left (\frac {e^{x} b i +a i}{\sqrt {a^{2}+b^{2}}}\right ) b^{4} i +2 e^{6 x} a^{3} b^{2}+2 e^{6 x} a \,b^{4}+6 e^{5 x} a^{2} b^{3}+6 e^{5 x} b^{5}+8 e^{3 x} a^{4} b +28 e^{3 x} a^{2} b^{3}+20 e^{3 x} b^{5}-12 e^{2 x} a^{5}-30 e^{2 x} a^{3} b^{2}-18 e^{2 x} a \,b^{4}+6 e^{x} a^{2} b^{3}+6 e^{x} b^{5}-4 a^{5}-12 a^{3} b^{2}-8 a \,b^{4}}{3 e^{6 x} a^{6}+9 e^{6 x} a^{4} b^{2}+9 e^{6 x} a^{2} b^{4}+3 e^{6 x} b^{6}+9 e^{4 x} a^{6}+27 e^{4 x} a^{4} b^{2}+27 e^{4 x} a^{2} b^{4}+9 e^{4 x} b^{6}+9 e^{2 x} a^{6}+27 e^{2 x} a^{4} b^{2}+27 e^{2 x} a^{2} b^{4}+9 e^{2 x} b^{6}+3 a^{6}+9 a^{4} b^{2}+9 a^{2} b^{4}+3 b^{6}} \] Input:

int(sech(x)^4/(a+b*sinh(x)),x)
 

Output:

(2*(3*e**(6*x)*sqrt(a**2 + b**2)*atan((e**x*b*i + a*i)/sqrt(a**2 + b**2))* 
b**4*i + 9*e**(4*x)*sqrt(a**2 + b**2)*atan((e**x*b*i + a*i)/sqrt(a**2 + b* 
*2))*b**4*i + 9*e**(2*x)*sqrt(a**2 + b**2)*atan((e**x*b*i + a*i)/sqrt(a**2 
 + b**2))*b**4*i + 3*sqrt(a**2 + b**2)*atan((e**x*b*i + a*i)/sqrt(a**2 + b 
**2))*b**4*i + e**(6*x)*a**3*b**2 + e**(6*x)*a*b**4 + 3*e**(5*x)*a**2*b**3 
 + 3*e**(5*x)*b**5 + 4*e**(3*x)*a**4*b + 14*e**(3*x)*a**2*b**3 + 10*e**(3* 
x)*b**5 - 6*e**(2*x)*a**5 - 15*e**(2*x)*a**3*b**2 - 9*e**(2*x)*a*b**4 + 3* 
e**x*a**2*b**3 + 3*e**x*b**5 - 2*a**5 - 6*a**3*b**2 - 4*a*b**4))/(3*(e**(6 
*x)*a**6 + 3*e**(6*x)*a**4*b**2 + 3*e**(6*x)*a**2*b**4 + e**(6*x)*b**6 + 3 
*e**(4*x)*a**6 + 9*e**(4*x)*a**4*b**2 + 9*e**(4*x)*a**2*b**4 + 3*e**(4*x)* 
b**6 + 3*e**(2*x)*a**6 + 9*e**(2*x)*a**4*b**2 + 9*e**(2*x)*a**2*b**4 + 3*e 
**(2*x)*b**6 + a**6 + 3*a**4*b**2 + 3*a**2*b**4 + b**6))