\(\int \frac {\tanh ^3(x)}{(a+b \sinh (x))^2} \, dx\) [237]

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

Optimal result

Integrand size = 13, antiderivative size = 135 \[ \int \frac {\tanh ^3(x)}{(a+b \sinh (x))^2} \, dx=\frac {a b \left (3 a^2-b^2\right ) \arctan (\sinh (x))}{\left (a^2+b^2\right )^3}+\frac {a^2 \left (a^2-3 b^2\right ) \log (\cosh (x))}{\left (a^2+b^2\right )^3}-\frac {a^2 \left (a^2-3 b^2\right ) \log (a+b \sinh (x))}{\left (a^2+b^2\right )^3}+\frac {a^3}{\left (a^2+b^2\right )^2 (a+b \sinh (x))}+\frac {\text {sech}^2(x) \left (a^2-b^2-2 a b \sinh (x)\right )}{2 \left (a^2+b^2\right )^2} \] Output:

a*b*(3*a^2-b^2)*arctan(sinh(x))/(a^2+b^2)^3+a^2*(a^2-3*b^2)*ln(cosh(x))/(a 
^2+b^2)^3-a^2*(a^2-3*b^2)*ln(a+b*sinh(x))/(a^2+b^2)^3+a^3/(a^2+b^2)^2/(a+b 
*sinh(x))+1/2*sech(x)^2*(a^2-b^2-2*a*b*sinh(x))/(a^2+b^2)^2
 

Mathematica [C] (verified)

Result contains complex when optimal does not.

Time = 0.47 (sec) , antiderivative size = 150, normalized size of antiderivative = 1.11 \[ \int \frac {\tanh ^3(x)}{(a+b \sinh (x))^2} \, dx=\frac {-2 a b \left (a^2+b^2\right ) \arctan (\sinh (x))+a^2 (a-i b) (a-3 i b) \log (i-\sinh (x))+a^2 (a+i b) (a+3 i b) \log (i+\sinh (x))-2 a^2 \left (a^2-3 b^2\right ) \log (a+b \sinh (x))+\left (a^4-b^4\right ) \text {sech}^2(x)+\frac {2 a^3 \left (a^2+b^2\right )}{a+b \sinh (x)}-2 a b \left (a^2+b^2\right ) \text {sech}(x) \tanh (x)}{2 \left (a^2+b^2\right )^3} \] Input:

Integrate[Tanh[x]^3/(a + b*Sinh[x])^2,x]
 

Output:

(-2*a*b*(a^2 + b^2)*ArcTan[Sinh[x]] + a^2*(a - I*b)*(a - (3*I)*b)*Log[I - 
Sinh[x]] + a^2*(a + I*b)*(a + (3*I)*b)*Log[I + Sinh[x]] - 2*a^2*(a^2 - 3*b 
^2)*Log[a + b*Sinh[x]] + (a^4 - b^4)*Sech[x]^2 + (2*a^3*(a^2 + b^2))/(a + 
b*Sinh[x]) - 2*a*b*(a^2 + b^2)*Sech[x]*Tanh[x])/(2*(a^2 + b^2)^3)
 

Rubi [A] (verified)

Time = 0.67 (sec) , antiderivative size = 177, normalized size of antiderivative = 1.31, number of steps used = 8, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.538, Rules used = {3042, 26, 3200, 601, 27, 2160, 2009}

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

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {i \tan (i x)^3}{(a-i b \sin (i x))^2}dx\)

\(\Big \downarrow \) 26

\(\displaystyle i \int \frac {\tan (i x)^3}{(a-i b \sin (i x))^2}dx\)

\(\Big \downarrow \) 3200

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

\(\Big \downarrow \) 601

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

\(\Big \downarrow \) 27

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

\(\Big \downarrow \) 2160

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

\(\Big \downarrow \) 2009

\(\displaystyle \frac {b^2 \left (a^2-2 a b \sinh (x)-b^2\right )}{2 \left (a^2+b^2\right )^2 \left (b^2 \sinh ^2(x)+b^2\right )}+\frac {\frac {a b^3 \left (3 a^2-b^2\right ) \arctan (\sinh (x))}{\left (a^2+b^2\right )^3}+\frac {a^2 b^2 \left (a^2-3 b^2\right ) \log \left (b^2 \sinh ^2(x)+b^2\right )}{2 \left (a^2+b^2\right )^3}-\frac {a^2 b^2 \left (a^2-3 b^2\right ) \log (a+b \sinh (x))}{\left (a^2+b^2\right )^3}+\frac {a^3 b^2}{\left (a^2+b^2\right )^2 (a+b \sinh (x))}}{b^2}\)

Input:

Int[Tanh[x]^3/(a + b*Sinh[x])^2,x]
 

Output:

(b^2*(a^2 - b^2 - 2*a*b*Sinh[x]))/(2*(a^2 + b^2)^2*(b^2 + b^2*Sinh[x]^2)) 
+ ((a*b^3*(3*a^2 - b^2)*ArcTan[Sinh[x]])/(a^2 + b^2)^3 - (a^2*b^2*(a^2 - 3 
*b^2)*Log[a + b*Sinh[x]])/(a^2 + b^2)^3 + (a^2*b^2*(a^2 - 3*b^2)*Log[b^2 + 
 b^2*Sinh[x]^2])/(2*(a^2 + b^2)^3) + (a^3*b^2)/((a^2 + b^2)^2*(a + b*Sinh[ 
x])))/b^2
 

Defintions of rubi rules used

rule 26
Int[(Complex[0, a_])*(Fx_), x_Symbol] :> Simp[(Complex[Identity[0], a])   I 
nt[Fx, x], x] /; FreeQ[a, x] && EqQ[a^2, 1]
 

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 601
Int[(x_)^(m_)*((c_) + (d_.)*(x_))^(n_.)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbo 
l] :> With[{Qx = PolynomialQuotient[x^m*(c + d*x)^n, a + b*x^2, x], e = Coe 
ff[PolynomialRemainder[x^m*(c + d*x)^n, a + b*x^2, x], x, 0], f = Coeff[Pol 
ynomialRemainder[x^m*(c + d*x)^n, a + b*x^2, x], x, 1]}, Simp[(a*f - b*e*x) 
*((a + b*x^2)^(p + 1)/(2*a*b*(p + 1))), x] + Simp[1/(2*a*(p + 1))   Int[(c 
+ d*x)^n*(a + b*x^2)^(p + 1)*ExpandToSum[(2*a*(p + 1)*Qx)/(c + d*x)^n + (e* 
(2*p + 3))/(c + d*x)^n, x], x], x]] /; FreeQ[{a, b, c, d}, x] && IGtQ[m, 1] 
 && LtQ[p, -1] && ILtQ[n, 0] && NeQ[b*c^2 + a*d^2, 0]
 

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 2160
Int[(Pq_)*((d_) + (e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^2)^(p_.), x_Symbol] 
:> Int[ExpandIntegrand[(d + e*x)^m*Pq*(a + b*x^2)^p, x], x] /; FreeQ[{a, b, 
 d, e, m}, x] && PolyQ[Pq, x] && IGtQ[p, -2]
 

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

rule 3200
Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*tan[(e_.) + (f_.)*(x_)]^(p 
_.), x_Symbol] :> Simp[1/f   Subst[Int[(x^p*(a + x)^m)/(b^2 - x^2)^((p + 1) 
/2), x], x, b*Sin[e + f*x]], x] /; FreeQ[{a, b, e, f, m}, x] && NeQ[a^2 - b 
^2, 0] && IntegerQ[(p + 1)/2]
 
Maple [A] (verified)

Time = 2.18 (sec) , antiderivative size = 237, normalized size of antiderivative = 1.76

method result size
default \(-\frac {2 a^{2} \left (\frac {\left (-a^{2} b -b^{3}\right ) \tanh \left (\frac {x}{2}\right )}{\tanh \left (\frac {x}{2}\right )^{2} a -2 b \tanh \left (\frac {x}{2}\right )-a}+\frac {\left (a^{2}-3 b^{2}\right ) \ln \left (\tanh \left (\frac {x}{2}\right )^{2} a -2 b \tanh \left (\frac {x}{2}\right )-a \right )}{2}\right )}{\left (a^{4}+2 a^{2} b^{2}+b^{4}\right ) \left (a^{2}+b^{2}\right )}+\frac {\frac {2 \left (\left (a^{3} b +a \,b^{3}\right ) \tanh \left (\frac {x}{2}\right )^{3}+\left (-a^{4}+b^{4}\right ) \tanh \left (\frac {x}{2}\right )^{2}+\left (-a^{3} b -a \,b^{3}\right ) \tanh \left (\frac {x}{2}\right )\right )}{\left (1+\tanh \left (\frac {x}{2}\right )^{2}\right )^{2}}+2 a \left (\frac {\left (a^{3}-3 a \,b^{2}\right ) \ln \left (1+\tanh \left (\frac {x}{2}\right )^{2}\right )}{2}+\left (3 a^{2} b -b^{3}\right ) \arctan \left (\tanh \left (\frac {x}{2}\right )\right )\right )}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}\) \(237\)
risch \(\frac {2 \,{\mathrm e}^{x} \left ({\mathrm e}^{4 x} a^{3}-{\mathrm e}^{4 x} a \,b^{2}-a^{2} b \,{\mathrm e}^{3 x}-{\mathrm e}^{3 x} b^{3}+4 a^{3} {\mathrm e}^{2 x}+{\mathrm e}^{x} a^{2} b +b^{3} {\mathrm e}^{x}+a^{3}-a \,b^{2}\right )}{\left ({\mathrm e}^{2 x}+1\right )^{2} \left (a^{4}+2 a^{2} b^{2}+b^{4}\right ) \left (b \,{\mathrm e}^{2 x}+2 \,{\mathrm e}^{x} a -b \right )}-\frac {3 i a^{3} \ln \left ({\mathrm e}^{x}-i\right ) b}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}+\frac {i a \ln \left ({\mathrm e}^{x}-i\right ) b^{3}}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}+\frac {\ln \left ({\mathrm e}^{x}-i\right ) a^{4}}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}-\frac {3 \ln \left ({\mathrm e}^{x}-i\right ) a^{2} b^{2}}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}+\frac {3 i a^{3} \ln \left ({\mathrm e}^{x}+i\right ) b}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}-\frac {i a \ln \left ({\mathrm e}^{x}+i\right ) b^{3}}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}+\frac {\ln \left ({\mathrm e}^{x}+i\right ) a^{4}}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}-\frac {3 \ln \left ({\mathrm e}^{x}+i\right ) a^{2} b^{2}}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}-\frac {a^{4} \ln \left ({\mathrm e}^{2 x}+\frac {2 a \,{\mathrm e}^{x}}{b}-1\right )}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}+\frac {3 a^{2} \ln \left ({\mathrm e}^{2 x}+\frac {2 a \,{\mathrm e}^{x}}{b}-1\right ) b^{2}}{a^{6}+3 a^{4} b^{2}+3 a^{2} b^{4}+b^{6}}\) \(510\)

Input:

int(tanh(x)^3/(a+b*sinh(x))^2,x,method=_RETURNVERBOSE)
 

Output:

-2*a^2/(a^4+2*a^2*b^2+b^4)/(a^2+b^2)*((-a^2*b-b^3)*tanh(1/2*x)/(tanh(1/2*x 
)^2*a-2*b*tanh(1/2*x)-a)+1/2*(a^2-3*b^2)*ln(tanh(1/2*x)^2*a-2*b*tanh(1/2*x 
)-a))+2/(a^6+3*a^4*b^2+3*a^2*b^4+b^6)*(((a^3*b+a*b^3)*tanh(1/2*x)^3+(-a^4+ 
b^4)*tanh(1/2*x)^2+(-a^3*b-a*b^3)*tanh(1/2*x))/(1+tanh(1/2*x)^2)^2+a*(1/2* 
(a^3-3*a*b^2)*ln(1+tanh(1/2*x)^2)+(3*a^2*b-b^3)*arctan(tanh(1/2*x))))
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 2850 vs. \(2 (133) = 266\).

Time = 0.13 (sec) , antiderivative size = 2850, normalized size of antiderivative = 21.11 \[ \int \frac {\tanh ^3(x)}{(a+b \sinh (x))^2} \, dx=\text {Too large to display} \] Input:

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

Output:

-(2*(a^5 - a*b^4)*cosh(x)^5 + 2*(a^5 - a*b^4)*sinh(x)^5 - 2*(a^4*b + 2*a^2 
*b^3 + b^5)*cosh(x)^4 - 2*(a^4*b + 2*a^2*b^3 + b^5 - 5*(a^5 - a*b^4)*cosh( 
x))*sinh(x)^4 + 8*(a^5 + a^3*b^2)*cosh(x)^3 + 4*(2*a^5 + 2*a^3*b^2 + 5*(a^ 
5 - a*b^4)*cosh(x)^2 - 2*(a^4*b + 2*a^2*b^3 + b^5)*cosh(x))*sinh(x)^3 + 2* 
(a^4*b + 2*a^2*b^3 + b^5)*cosh(x)^2 + 2*(a^4*b + 2*a^2*b^3 + b^5 + 10*(a^5 
 - a*b^4)*cosh(x)^3 - 6*(a^4*b + 2*a^2*b^3 + b^5)*cosh(x)^2 + 12*(a^5 + a^ 
3*b^2)*cosh(x))*sinh(x)^2 + 2*((3*a^3*b^2 - a*b^4)*cosh(x)^6 + (3*a^3*b^2 
- a*b^4)*sinh(x)^6 + 2*(3*a^4*b - a^2*b^3)*cosh(x)^5 + 2*(3*a^4*b - a^2*b^ 
3 + 3*(3*a^3*b^2 - a*b^4)*cosh(x))*sinh(x)^5 - 3*a^3*b^2 + a*b^4 + (3*a^3* 
b^2 - a*b^4)*cosh(x)^4 + (3*a^3*b^2 - a*b^4 + 15*(3*a^3*b^2 - a*b^4)*cosh( 
x)^2 + 10*(3*a^4*b - a^2*b^3)*cosh(x))*sinh(x)^4 + 4*(3*a^4*b - a^2*b^3)*c 
osh(x)^3 + 4*(3*a^4*b - a^2*b^3 + 5*(3*a^3*b^2 - a*b^4)*cosh(x)^3 + 5*(3*a 
^4*b - a^2*b^3)*cosh(x)^2 + (3*a^3*b^2 - a*b^4)*cosh(x))*sinh(x)^3 - (3*a^ 
3*b^2 - a*b^4)*cosh(x)^2 - (3*a^3*b^2 - a*b^4 - 15*(3*a^3*b^2 - a*b^4)*cos 
h(x)^4 - 20*(3*a^4*b - a^2*b^3)*cosh(x)^3 - 6*(3*a^3*b^2 - a*b^4)*cosh(x)^ 
2 - 12*(3*a^4*b - a^2*b^3)*cosh(x))*sinh(x)^2 + 2*(3*a^4*b - a^2*b^3)*cosh 
(x) + 2*(3*(3*a^3*b^2 - a*b^4)*cosh(x)^5 + 3*a^4*b - a^2*b^3 + 5*(3*a^4*b 
- a^2*b^3)*cosh(x)^4 + 2*(3*a^3*b^2 - a*b^4)*cosh(x)^3 + 6*(3*a^4*b - a^2* 
b^3)*cosh(x)^2 - (3*a^3*b^2 - a*b^4)*cosh(x))*sinh(x))*arctan(cosh(x) + si 
nh(x)) + 2*(a^5 - a*b^4)*cosh(x) - ((a^4*b - 3*a^2*b^3)*cosh(x)^6 + (a^...
 

Sympy [F]

\[ \int \frac {\tanh ^3(x)}{(a+b \sinh (x))^2} \, dx=\int \frac {\tanh ^{3}{\left (x \right )}}{\left (a + b \sinh {\left (x \right )}\right )^{2}}\, dx \] Input:

integrate(tanh(x)**3/(a+b*sinh(x))**2,x)
 

Output:

Integral(tanh(x)**3/(a + b*sinh(x))**2, x)
 

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 375 vs. \(2 (133) = 266\).

Time = 0.15 (sec) , antiderivative size = 375, normalized size of antiderivative = 2.78 \[ \int \frac {\tanh ^3(x)}{(a+b \sinh (x))^2} \, dx=-\frac {2 \, {\left (3 \, a^{3} b - a b^{3}\right )} \arctan \left (e^{\left (-x\right )}\right )}{a^{6} + 3 \, a^{4} b^{2} + 3 \, a^{2} b^{4} + b^{6}} - \frac {{\left (a^{4} - 3 \, a^{2} b^{2}\right )} \log \left (-2 \, a e^{\left (-x\right )} + b e^{\left (-2 \, x\right )} - b\right )}{a^{6} + 3 \, a^{4} b^{2} + 3 \, a^{2} b^{4} + b^{6}} + \frac {{\left (a^{4} - 3 \, a^{2} b^{2}\right )} \log \left (e^{\left (-2 \, x\right )} + 1\right )}{a^{6} + 3 \, a^{4} b^{2} + 3 \, a^{2} b^{4} + b^{6}} + \frac {2 \, {\left (4 \, a^{3} e^{\left (-3 \, x\right )} + {\left (a^{3} - a b^{2}\right )} e^{\left (-x\right )} - {\left (a^{2} b + b^{3}\right )} e^{\left (-2 \, x\right )} + {\left (a^{2} b + b^{3}\right )} e^{\left (-4 \, x\right )} + {\left (a^{3} - a b^{2}\right )} e^{\left (-5 \, x\right )}\right )}}{a^{4} b + 2 \, a^{2} b^{3} + b^{5} + 2 \, {\left (a^{5} + 2 \, a^{3} b^{2} + a b^{4}\right )} e^{\left (-x\right )} + {\left (a^{4} b + 2 \, a^{2} b^{3} + b^{5}\right )} e^{\left (-2 \, x\right )} + 4 \, {\left (a^{5} + 2 \, a^{3} b^{2} + a b^{4}\right )} e^{\left (-3 \, x\right )} - {\left (a^{4} b + 2 \, a^{2} b^{3} + b^{5}\right )} e^{\left (-4 \, x\right )} + 2 \, {\left (a^{5} + 2 \, a^{3} b^{2} + a b^{4}\right )} e^{\left (-5 \, x\right )} - {\left (a^{4} b + 2 \, a^{2} b^{3} + b^{5}\right )} e^{\left (-6 \, x\right )}} \] Input:

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

Output:

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

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 307 vs. \(2 (133) = 266\).

Time = 0.14 (sec) , antiderivative size = 307, normalized size of antiderivative = 2.27 \[ \int \frac {\tanh ^3(x)}{(a+b \sinh (x))^2} \, dx=\frac {{\left (\pi + 2 \, \arctan \left (\frac {1}{2} \, {\left (e^{\left (2 \, x\right )} - 1\right )} e^{\left (-x\right )}\right )\right )} {\left (3 \, a^{3} b - a b^{3}\right )}}{2 \, {\left (a^{6} + 3 \, a^{4} b^{2} + 3 \, a^{2} b^{4} + b^{6}\right )}} + \frac {{\left (a^{4} - 3 \, a^{2} b^{2}\right )} \log \left ({\left (e^{\left (-x\right )} - e^{x}\right )}^{2} + 4\right )}{2 \, {\left (a^{6} + 3 \, a^{4} b^{2} + 3 \, a^{2} b^{4} + b^{6}\right )}} - \frac {{\left (a^{4} b - 3 \, a^{2} b^{3}\right )} \log \left ({\left | -b {\left (e^{\left (-x\right )} - e^{x}\right )} + 2 \, a \right |}\right )}{a^{6} b + 3 \, a^{4} b^{3} + 3 \, a^{2} b^{5} + b^{7}} - \frac {2 \, {\left (a^{3} {\left (e^{\left (-x\right )} - e^{x}\right )}^{2} - a b^{2} {\left (e^{\left (-x\right )} - e^{x}\right )}^{2} + a^{2} b {\left (e^{\left (-x\right )} - e^{x}\right )} + b^{3} {\left (e^{\left (-x\right )} - e^{x}\right )} + 6 \, a^{3} - 2 \, a b^{2}\right )}}{{\left (a^{4} + 2 \, a^{2} b^{2} + b^{4}\right )} {\left (b {\left (e^{\left (-x\right )} - e^{x}\right )}^{3} - 2 \, a {\left (e^{\left (-x\right )} - e^{x}\right )}^{2} + 4 \, b {\left (e^{\left (-x\right )} - e^{x}\right )} - 8 \, a\right )}} \] Input:

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

Output:

1/2*(pi + 2*arctan(1/2*(e^(2*x) - 1)*e^(-x)))*(3*a^3*b - a*b^3)/(a^6 + 3*a 
^4*b^2 + 3*a^2*b^4 + b^6) + 1/2*(a^4 - 3*a^2*b^2)*log((e^(-x) - e^x)^2 + 4 
)/(a^6 + 3*a^4*b^2 + 3*a^2*b^4 + b^6) - (a^4*b - 3*a^2*b^3)*log(abs(-b*(e^ 
(-x) - e^x) + 2*a))/(a^6*b + 3*a^4*b^3 + 3*a^2*b^5 + b^7) - 2*(a^3*(e^(-x) 
 - e^x)^2 - a*b^2*(e^(-x) - e^x)^2 + a^2*b*(e^(-x) - e^x) + b^3*(e^(-x) - 
e^x) + 6*a^3 - 2*a*b^2)/((a^4 + 2*a^2*b^2 + b^4)*(b*(e^(-x) - e^x)^3 - 2*a 
*(e^(-x) - e^x)^2 + 4*b*(e^(-x) - e^x) - 8*a))
 

Mupad [B] (verification not implemented)

Time = 4.90 (sec) , antiderivative size = 501, normalized size of antiderivative = 3.71 \[ \int \frac {\tanh ^3(x)}{(a+b \sinh (x))^2} \, dx=\frac {\frac {2\,\left (a^8+2\,a^6\,b^2-2\,a^2\,b^6-b^8\right )}{\left (a^2+b^2\right )\,{\left (a^4+2\,a^2\,b^2+b^4\right )}^2}-\frac {2\,{\mathrm {e}}^x\,\left (a^7\,b+3\,a^5\,b^3+3\,a^3\,b^5+a\,b^7\right )}{\left (a^2+b^2\right )\,{\left (a^4+2\,a^2\,b^2+b^4\right )}^2}}{{\mathrm {e}}^{2\,x}+1}-\frac {\frac {2\,\left (a^2-b^2\right )}{a^4+2\,a^2\,b^2+b^4}-\frac {4\,a\,b\,{\mathrm {e}}^x}{a^4+2\,a^2\,b^2+b^4}}{2\,{\mathrm {e}}^{2\,x}+{\mathrm {e}}^{4\,x}+1}-\frac {a\,\ln \left ({\mathrm {e}}^x+1{}\mathrm {i}\right )}{-a^3+a^2\,b\,3{}\mathrm {i}+3\,a\,b^2-b^3\,1{}\mathrm {i}}-\frac {\ln \left (15\,a^6\,b^3-a^2\,b^7-30\,a^4\,b^5-4\,a^8\,b+8\,a^9\,{\mathrm {e}}^x+a^2\,b^7\,{\mathrm {e}}^{2\,x}+30\,a^4\,b^5\,{\mathrm {e}}^{2\,x}-15\,a^6\,b^3\,{\mathrm {e}}^{2\,x}+4\,a^8\,b\,{\mathrm {e}}^{2\,x}+2\,a^3\,b^6\,{\mathrm {e}}^x+60\,a^5\,b^4\,{\mathrm {e}}^x-30\,a^7\,b^2\,{\mathrm {e}}^x\right )\,\left (a^4-3\,a^2\,b^2\right )}{a^6+3\,a^4\,b^2+3\,a^2\,b^4+b^6}+\frac {2\,{\mathrm {e}}^x\,\left (a^7\,b^2+2\,a^5\,b^4+a^3\,b^6\right )}{b\,\left (a^2\,b+b^3\right )\,\left (a^2+b^2\right )\,\left (2\,a\,{\mathrm {e}}^x-b+b\,{\mathrm {e}}^{2\,x}\right )\,\left (a^4+2\,a^2\,b^2+b^4\right )}-\frac {a\,\ln \left (1+{\mathrm {e}}^x\,1{}\mathrm {i}\right )\,1{}\mathrm {i}}{-a^3\,1{}\mathrm {i}+3\,a^2\,b+a\,b^2\,3{}\mathrm {i}-b^3} \] Input:

int(tanh(x)^3/(a + b*sinh(x))^2,x)
 

Output:

((2*(a^8 - b^8 - 2*a^2*b^6 + 2*a^6*b^2))/((a^2 + b^2)*(a^4 + b^4 + 2*a^2*b 
^2)^2) - (2*exp(x)*(a*b^7 + a^7*b + 3*a^3*b^5 + 3*a^5*b^3))/((a^2 + b^2)*( 
a^4 + b^4 + 2*a^2*b^2)^2))/(exp(2*x) + 1) - ((2*(a^2 - b^2))/(a^4 + b^4 + 
2*a^2*b^2) - (4*a*b*exp(x))/(a^4 + b^4 + 2*a^2*b^2))/(2*exp(2*x) + exp(4*x 
) + 1) - (a*log(exp(x) + 1i))/(3*a*b^2 + a^2*b*3i - a^3 - b^3*1i) - (log(1 
5*a^6*b^3 - a^2*b^7 - 30*a^4*b^5 - 4*a^8*b + 8*a^9*exp(x) + a^2*b^7*exp(2* 
x) + 30*a^4*b^5*exp(2*x) - 15*a^6*b^3*exp(2*x) + 4*a^8*b*exp(2*x) + 2*a^3* 
b^6*exp(x) + 60*a^5*b^4*exp(x) - 30*a^7*b^2*exp(x))*(a^4 - 3*a^2*b^2))/(a^ 
6 + b^6 + 3*a^2*b^4 + 3*a^4*b^2) - (a*log(exp(x)*1i + 1)*1i)/(a*b^2*3i + 3 
*a^2*b - a^3*1i - b^3) + (2*exp(x)*(a^3*b^6 + 2*a^5*b^4 + a^7*b^2))/(b*(a^ 
2*b + b^3)*(a^2 + b^2)*(2*a*exp(x) - b + b*exp(2*x))*(a^4 + b^4 + 2*a^2*b^ 
2))
 

Reduce [B] (verification not implemented)

Time = 0.16 (sec) , antiderivative size = 1305, normalized size of antiderivative = 9.67 \[ \int \frac {\tanh ^3(x)}{(a+b \sinh (x))^2} \, dx =\text {Too large to display} \] Input:

int(tanh(x)^3/(a+b*sinh(x))^2,x)
 

Output:

(6*e**(6*x)*atan(e**x)*a**3*b**2 - 2*e**(6*x)*atan(e**x)*a*b**4 + 12*e**(5 
*x)*atan(e**x)*a**4*b - 4*e**(5*x)*atan(e**x)*a**2*b**3 + 6*e**(4*x)*atan( 
e**x)*a**3*b**2 - 2*e**(4*x)*atan(e**x)*a*b**4 + 24*e**(3*x)*atan(e**x)*a* 
*4*b - 8*e**(3*x)*atan(e**x)*a**2*b**3 - 6*e**(2*x)*atan(e**x)*a**3*b**2 + 
 2*e**(2*x)*atan(e**x)*a*b**4 + 12*e**x*atan(e**x)*a**4*b - 4*e**x*atan(e* 
*x)*a**2*b**3 - 6*atan(e**x)*a**3*b**2 + 2*atan(e**x)*a*b**4 + e**(6*x)*lo 
g(e**(2*x) + 1)*a**4*b - 3*e**(6*x)*log(e**(2*x) + 1)*a**2*b**3 - e**(6*x) 
*log(e**(2*x)*b + 2*e**x*a - b)*a**4*b + 3*e**(6*x)*log(e**(2*x)*b + 2*e** 
x*a - b)*a**2*b**3 - e**(6*x)*a**4*b + e**(6*x)*b**5 + 2*e**(5*x)*log(e**( 
2*x) + 1)*a**5 - 6*e**(5*x)*log(e**(2*x) + 1)*a**3*b**2 - 2*e**(5*x)*log(e 
**(2*x)*b + 2*e**x*a - b)*a**5 + 6*e**(5*x)*log(e**(2*x)*b + 2*e**x*a - b) 
*a**3*b**2 + e**(4*x)*log(e**(2*x) + 1)*a**4*b - 3*e**(4*x)*log(e**(2*x) + 
 1)*a**2*b**3 - e**(4*x)*log(e**(2*x)*b + 2*e**x*a - b)*a**4*b + 3*e**(4*x 
)*log(e**(2*x)*b + 2*e**x*a - b)*a**2*b**3 - 3*e**(4*x)*a**4*b - 4*e**(4*x 
)*a**2*b**3 - e**(4*x)*b**5 + 4*e**(3*x)*log(e**(2*x) + 1)*a**5 - 12*e**(3 
*x)*log(e**(2*x) + 1)*a**3*b**2 - 4*e**(3*x)*log(e**(2*x)*b + 2*e**x*a - b 
)*a**5 + 12*e**(3*x)*log(e**(2*x)*b + 2*e**x*a - b)*a**3*b**2 + 4*e**(3*x) 
*a**5 + 8*e**(3*x)*a**3*b**2 + 4*e**(3*x)*a*b**4 - e**(2*x)*log(e**(2*x) + 
 1)*a**4*b + 3*e**(2*x)*log(e**(2*x) + 1)*a**2*b**3 + e**(2*x)*log(e**(2*x 
)*b + 2*e**x*a - b)*a**4*b - 3*e**(2*x)*log(e**(2*x)*b + 2*e**x*a - b)*...