\(\int (a \coth (x)+b \text {csch}(x))^5 \, dx\) [404]

Optimal result
Mathematica [A] (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 = 11, antiderivative size = 124 \[ \int (a \coth (x)+b \text {csch}(x))^5 \, dx=-\frac {1}{8} b \left (15 a^4-10 a^2 b^2+3 b^4\right ) \text {arctanh}(\cosh (x))+\frac {1}{8} a^2 b \left (7 a^2-3 b^2\right ) \cosh (x)-\frac {1}{8} (b+a \cosh (x))^2 \left (2 a \left (2 a^2-b^2\right )+b \left (5 a^2-3 b^2\right ) \cosh (x)\right ) \text {csch}^2(x)-\frac {1}{4} (b+a \cosh (x))^4 (a+b \cosh (x)) \text {csch}^4(x)+a^5 \log (\sinh (x)) \] Output:

-1/8*b*(15*a^4-10*a^2*b^2+3*b^4)*arctanh(cosh(x))+1/8*a^2*b*(7*a^2-3*b^2)* 
cosh(x)-1/8*(b+a*cosh(x))^2*(2*a*(2*a^2-b^2)+b*(5*a^2-3*b^2)*cosh(x))*csch 
(x)^2-1/4*(b+a*cosh(x))^4*(a+b*cosh(x))*csch(x)^4+a^5*ln(sinh(x))
 

Mathematica [A] (verified)

Time = 0.83 (sec) , antiderivative size = 143, normalized size of antiderivative = 1.15 \[ \int (a \coth (x)+b \text {csch}(x))^5 \, dx=\frac {1}{64} \left (-2 (7 a-3 b) (a+b)^4 \text {csch}^2\left (\frac {x}{2}\right )-(a+b)^5 \text {csch}^4\left (\frac {x}{2}\right )+8 (a-b)^3 \left (8 a^2+9 a b+3 b^2\right ) \log \left (\cosh \left (\frac {x}{2}\right )\right )+8 (a+b)^3 \left (8 a^2-9 a b+3 b^2\right ) \log \left (\sinh \left (\frac {x}{2}\right )\right )+2 (a-b)^4 (7 a+3 b) \text {sech}^2\left (\frac {x}{2}\right )-(a-b)^5 \text {sech}^4\left (\frac {x}{2}\right )\right ) \] Input:

Integrate[(a*Coth[x] + b*Csch[x])^5,x]
 

Output:

(-2*(7*a - 3*b)*(a + b)^4*Csch[x/2]^2 - (a + b)^5*Csch[x/2]^4 + 8*(a - b)^ 
3*(8*a^2 + 9*a*b + 3*b^2)*Log[Cosh[x/2]] + 8*(a + b)^3*(8*a^2 - 9*a*b + 3* 
b^2)*Log[Sinh[x/2]] + 2*(a - b)^4*(7*a + 3*b)*Sech[x/2]^2 - (a - b)^5*Sech 
[x/2]^4)/64
 

Rubi [A] (verified)

Time = 0.54 (sec) , antiderivative size = 173, normalized size of antiderivative = 1.40, number of steps used = 10, number of rules used = 9, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.818, Rules used = {3042, 4892, 26, 26, 3042, 26, 3147, 477, 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 (a \coth (x)+b \text {csch}(x))^5 \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int (i a \cot (i x)+i b \csc (i x))^5dx\)

\(\Big \downarrow \) 4892

\(\displaystyle \int -i \text {csch}^5(x) (i a \cosh (x)+i b)^5dx\)

\(\Big \downarrow \) 26

\(\displaystyle -i \int i (b+a \cosh (x))^5 \text {csch}^5(x)dx\)

\(\Big \downarrow \) 26

\(\displaystyle \int \text {csch}^5(x) (a \cosh (x)+b)^5dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {i \left (b-a \sin \left (-\frac {\pi }{2}+i x\right )\right )^5}{\cos \left (-\frac {\pi }{2}+i x\right )^5}dx\)

\(\Big \downarrow \) 26

\(\displaystyle i \int \frac {\left (b-a \sin \left (i x-\frac {\pi }{2}\right )\right )^5}{\cos \left (i x-\frac {\pi }{2}\right )^5}dx\)

\(\Big \downarrow \) 3147

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

\(\Big \downarrow \) 477

\(\displaystyle -\frac {\int \left (-\frac {a^3 (a-b)^5}{8 (\cosh (x) a+a)^3}+\frac {a^2 (7 a+3 b) (a-b)^4}{16 (\cosh (x) a+a)^2}-\frac {a \left (8 a^2+9 b a+3 b^2\right ) (a-b)^3}{16 (\cosh (x) a+a)}+\frac {a (a+b)^3 \left (8 a^2-9 b a+3 b^2\right )}{16 (a-a \cosh (x))}-\frac {a^2 (7 a-3 b) (a+b)^4}{16 (a-a \cosh (x))^2}+\frac {a^3 (a+b)^5}{8 (a-a \cosh (x))^3}\right )d(a \cosh (x))}{a}\)

\(\Big \downarrow \) 2009

\(\displaystyle -\frac {\frac {a^3 (a-b)^5}{16 (a \cosh (x)+a)^2}+\frac {a^3 (a+b)^5}{16 (a-a \cosh (x))^2}-\frac {1}{16} a \left (8 a^2+9 a b+3 b^2\right ) (a-b)^3 \log (a \cosh (x)+a)-\frac {1}{16} a (a+b)^3 \left (8 a^2-9 a b+3 b^2\right ) \log (a-a \cosh (x))-\frac {a^2 (7 a+3 b) (a-b)^4}{16 (a \cosh (x)+a)}-\frac {a^2 (7 a-3 b) (a+b)^4}{16 (a-a \cosh (x))}}{a}\)

Input:

Int[(a*Coth[x] + b*Csch[x])^5,x]
 

Output:

-(((a^3*(a + b)^5)/(16*(a - a*Cosh[x])^2) - (a^2*(7*a - 3*b)*(a + b)^4)/(1 
6*(a - a*Cosh[x])) + (a^3*(a - b)^5)/(16*(a + a*Cosh[x])^2) - (a^2*(a - b) 
^4*(7*a + 3*b))/(16*(a + a*Cosh[x])) - (a*(a + b)^3*(8*a^2 - 9*a*b + 3*b^2 
)*Log[a - a*Cosh[x]])/16 - (a*(a - b)^3*(8*a^2 + 9*a*b + 3*b^2)*Log[a + a* 
Cosh[x]])/16)/a)
 

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 477
Int[((c_) + (d_.)*(x_))^(n_)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> Simp[ 
a^p   Int[ExpandIntegrand[(c + d*x)^n*(1 - Rt[-b/a, 2]*x)^p*(1 + Rt[-b/a, 2 
]*x)^p, x], x], x] /; FreeQ[{a, b, c, d}, x] && ILtQ[p, 0] && IntegerQ[n] & 
& NiceSqrtQ[-b/a] &&  !FractionalPowerFactorQ[Rt[-b/a, 2]]
 

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

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

rule 3147
Int[cos[(e_.) + (f_.)*(x_)]^(p_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m 
_.), x_Symbol] :> Simp[1/(b^p*f)   Subst[Int[(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] && IntegerQ[(p 
 - 1)/2] && NeQ[a^2 - b^2, 0]
 

rule 4892
Int[(cot[(c_.) + (d_.)*(x_)]^(n_.)*(a_.) + csc[(c_.) + (d_.)*(x_)]^(n_.)*(b 
_.))^(p_)*(u_.), x_Symbol] :> Int[ActivateTrig[u]*Csc[c + d*x]^(n*p)*(b + a 
*Cos[c + d*x]^n)^p, x] /; FreeQ[{a, b, c, d}, x] && IntegersQ[n, p]
 
Maple [A] (verified)

Time = 59.40 (sec) , antiderivative size = 159, normalized size of antiderivative = 1.28

method result size
parts \(a^{5} \left (-\frac {\coth \left (x \right )^{4}}{4}-\frac {\coth \left (x \right )^{2}}{2}-\frac {\ln \left (\coth \left (x \right )-1\right )}{2}-\frac {\ln \left (\coth \left (x \right )+1\right )}{2}\right )+b^{5} \left (\left (-\frac {\operatorname {csch}\left (x \right )^{3}}{4}+\frac {3 \,\operatorname {csch}\left (x \right )}{8}\right ) \coth \left (x \right )-\frac {3 \,\operatorname {arctanh}\left ({\mathrm e}^{x}\right )}{4}\right )+5 a^{4} b \left (-\frac {\cosh \left (x \right )^{3}}{\sinh \left (x \right )^{4}}+\frac {\cosh \left (x \right )}{\sinh \left (x \right )^{4}}+\left (-\frac {\operatorname {csch}\left (x \right )^{3}}{4}+\frac {3 \,\operatorname {csch}\left (x \right )}{8}\right ) \coth \left (x \right )-\frac {3 \,\operatorname {arctanh}\left ({\mathrm e}^{x}\right )}{4}\right )-\frac {5 a^{3} b^{2} \coth \left (x \right )^{4}}{2}+10 a^{2} b^{3} \left (-\frac {\cosh \left (x \right )}{3 \sinh \left (x \right )^{4}}-\frac {\left (-\frac {\operatorname {csch}\left (x \right )^{3}}{4}+\frac {3 \,\operatorname {csch}\left (x \right )}{8}\right ) \coth \left (x \right )}{3}+\frac {\operatorname {arctanh}\left ({\mathrm e}^{x}\right )}{4}\right )-\frac {5 b^{4} \operatorname {csch}\left (x \right )^{4} a}{4}\) \(159\)
default \(a^{5} \left (\ln \left (\sinh \left (x \right )\right )-\frac {\coth \left (x \right )^{2}}{2}-\frac {\coth \left (x \right )^{4}}{4}\right )+5 a^{4} b \left (-\frac {\cosh \left (x \right )^{3}}{\sinh \left (x \right )^{4}}+\frac {\cosh \left (x \right )}{\sinh \left (x \right )^{4}}+\left (-\frac {\operatorname {csch}\left (x \right )^{3}}{4}+\frac {3 \,\operatorname {csch}\left (x \right )}{8}\right ) \coth \left (x \right )-\frac {3 \,\operatorname {arctanh}\left ({\mathrm e}^{x}\right )}{4}\right )+10 a^{3} b^{2} \left (-\frac {\cosh \left (x \right )^{2}}{2 \sinh \left (x \right )^{4}}+\frac {1}{4 \sinh \left (x \right )^{4}}\right )+10 a^{2} b^{3} \left (-\frac {\cosh \left (x \right )}{3 \sinh \left (x \right )^{4}}-\frac {\left (-\frac {\operatorname {csch}\left (x \right )^{3}}{4}+\frac {3 \,\operatorname {csch}\left (x \right )}{8}\right ) \coth \left (x \right )}{3}+\frac {\operatorname {arctanh}\left ({\mathrm e}^{x}\right )}{4}\right )-\frac {5 a \,b^{4}}{4 \sinh \left (x \right )^{4}}+b^{5} \left (\left (-\frac {\operatorname {csch}\left (x \right )^{3}}{4}+\frac {3 \,\operatorname {csch}\left (x \right )}{8}\right ) \coth \left (x \right )-\frac {3 \,\operatorname {arctanh}\left ({\mathrm e}^{x}\right )}{4}\right )\) \(161\)
risch \(-a^{5} x -\frac {{\mathrm e}^{x} \left (25 a^{4} b \,{\mathrm e}^{6 x}+10 a^{2} b^{3} {\mathrm e}^{6 x}-3 b^{5} {\mathrm e}^{6 x}+16 a^{5} {\mathrm e}^{5 x}+80 a^{3} b^{2} {\mathrm e}^{5 x}+15 a^{4} b \,{\mathrm e}^{4 x}+70 a^{2} b^{3} {\mathrm e}^{4 x}+11 b^{5} {\mathrm e}^{4 x}-16 a^{5} {\mathrm e}^{3 x}+80 a \,b^{4} {\mathrm e}^{3 x}+15 a^{4} b \,{\mathrm e}^{2 x}+70 a^{2} b^{3} {\mathrm e}^{2 x}+11 b^{5} {\mathrm e}^{2 x}+16 a^{5} {\mathrm e}^{x}+80 a^{3} b^{2} {\mathrm e}^{x}+25 a^{4} b +10 a^{2} b^{3}-3 b^{5}\right )}{4 \left ({\mathrm e}^{2 x}-1\right )^{4}}+\ln \left (1+{\mathrm e}^{x}\right ) a^{5}-\frac {15 \ln \left (1+{\mathrm e}^{x}\right ) a^{4} b}{8}+\frac {5 \ln \left (1+{\mathrm e}^{x}\right ) a^{2} b^{3}}{4}-\frac {3 \ln \left (1+{\mathrm e}^{x}\right ) b^{5}}{8}+\ln \left (-1+{\mathrm e}^{x}\right ) a^{5}+\frac {15 \ln \left (-1+{\mathrm e}^{x}\right ) a^{4} b}{8}-\frac {5 \ln \left (-1+{\mathrm e}^{x}\right ) a^{2} b^{3}}{4}+\frac {3 \ln \left (-1+{\mathrm e}^{x}\right ) b^{5}}{8}\) \(276\)

Input:

int((a*coth(x)+b*csch(x))^5,x,method=_RETURNVERBOSE)
 

Output:

a^5*(-1/4*coth(x)^4-1/2*coth(x)^2-1/2*ln(coth(x)-1)-1/2*ln(coth(x)+1))+b^5 
*((-1/4*csch(x)^3+3/8*csch(x))*coth(x)-3/4*arctanh(exp(x)))+5*a^4*b*(-1/si 
nh(x)^4*cosh(x)^3+1/sinh(x)^4*cosh(x)+(-1/4*csch(x)^3+3/8*csch(x))*coth(x) 
-3/4*arctanh(exp(x)))-5/2*a^3*b^2*coth(x)^4+10*a^2*b^3*(-1/3/sinh(x)^4*cos 
h(x)-1/3*(-1/4*csch(x)^3+3/8*csch(x))*coth(x)+1/4*arctanh(exp(x)))-5/4*b^4 
*csch(x)^4*a
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 2716 vs. \(2 (116) = 232\).

Time = 0.11 (sec) , antiderivative size = 2716, normalized size of antiderivative = 21.90 \[ \int (a \coth (x)+b \text {csch}(x))^5 \, dx=\text {Too large to display} \] Input:

integrate((a*coth(x)+b*csch(x))^5,x, algorithm="fricas")
 

Output:

-1/8*(8*a^5*x*cosh(x)^8 + 8*a^5*x*sinh(x)^8 + 2*(25*a^4*b + 10*a^2*b^3 - 3 
*b^5)*cosh(x)^7 + 2*(32*a^5*x*cosh(x) + 25*a^4*b + 10*a^2*b^3 - 3*b^5)*sin 
h(x)^7 - 32*(a^5*x - a^5 - 5*a^3*b^2)*cosh(x)^6 + 2*(112*a^5*x*cosh(x)^2 - 
 16*a^5*x + 16*a^5 + 80*a^3*b^2 + 7*(25*a^4*b + 10*a^2*b^3 - 3*b^5)*cosh(x 
))*sinh(x)^6 + 8*a^5*x + 2*(15*a^4*b + 70*a^2*b^3 + 11*b^5)*cosh(x)^5 + 2* 
(224*a^5*x*cosh(x)^3 + 15*a^4*b + 70*a^2*b^3 + 11*b^5 + 21*(25*a^4*b + 10* 
a^2*b^3 - 3*b^5)*cosh(x)^2 - 96*(a^5*x - a^5 - 5*a^3*b^2)*cosh(x))*sinh(x) 
^5 + 16*(3*a^5*x - 2*a^5 + 10*a*b^4)*cosh(x)^4 + 2*(280*a^5*x*cosh(x)^4 + 
24*a^5*x - 16*a^5 + 80*a*b^4 + 35*(25*a^4*b + 10*a^2*b^3 - 3*b^5)*cosh(x)^ 
3 - 240*(a^5*x - a^5 - 5*a^3*b^2)*cosh(x)^2 + 5*(15*a^4*b + 70*a^2*b^3 + 1 
1*b^5)*cosh(x))*sinh(x)^4 + 2*(15*a^4*b + 70*a^2*b^3 + 11*b^5)*cosh(x)^3 + 
 2*(224*a^5*x*cosh(x)^5 + 15*a^4*b + 70*a^2*b^3 + 11*b^5 + 35*(25*a^4*b + 
10*a^2*b^3 - 3*b^5)*cosh(x)^4 - 320*(a^5*x - a^5 - 5*a^3*b^2)*cosh(x)^3 + 
10*(15*a^4*b + 70*a^2*b^3 + 11*b^5)*cosh(x)^2 + 32*(3*a^5*x - 2*a^5 + 10*a 
*b^4)*cosh(x))*sinh(x)^3 - 32*(a^5*x - a^5 - 5*a^3*b^2)*cosh(x)^2 + 2*(112 
*a^5*x*cosh(x)^6 - 16*a^5*x + 21*(25*a^4*b + 10*a^2*b^3 - 3*b^5)*cosh(x)^5 
 + 16*a^5 + 80*a^3*b^2 - 240*(a^5*x - a^5 - 5*a^3*b^2)*cosh(x)^4 + 10*(15* 
a^4*b + 70*a^2*b^3 + 11*b^5)*cosh(x)^3 + 48*(3*a^5*x - 2*a^5 + 10*a*b^4)*c 
osh(x)^2 + 3*(15*a^4*b + 70*a^2*b^3 + 11*b^5)*cosh(x))*sinh(x)^2 + 2*(25*a 
^4*b + 10*a^2*b^3 - 3*b^5)*cosh(x) - ((8*a^5 - 15*a^4*b + 10*a^2*b^3 - ...
 

Sympy [F]

\[ \int (a \coth (x)+b \text {csch}(x))^5 \, dx=\int \left (a \coth {\left (x \right )} + b \operatorname {csch}{\left (x \right )}\right )^{5}\, dx \] Input:

integrate((a*coth(x)+b*csch(x))**5,x)
 

Output:

Integral((a*coth(x) + b*csch(x))**5, x)
 

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 330 vs. \(2 (116) = 232\).

Time = 0.05 (sec) , antiderivative size = 330, normalized size of antiderivative = 2.66 \[ \int (a \coth (x)+b \text {csch}(x))^5 \, dx=-\frac {5}{2} \, a^{3} b^{2} \coth \left (x\right )^{4} + a^{5} {\left (x + \frac {4 \, {\left (e^{\left (-2 \, x\right )} - e^{\left (-4 \, x\right )} + e^{\left (-6 \, x\right )}\right )}}{4 \, e^{\left (-2 \, x\right )} - 6 \, e^{\left (-4 \, x\right )} + 4 \, e^{\left (-6 \, x\right )} - e^{\left (-8 \, x\right )} - 1} + \log \left (e^{\left (-x\right )} + 1\right ) + \log \left (e^{\left (-x\right )} - 1\right )\right )} + \frac {5}{8} \, a^{4} b {\left (\frac {2 \, {\left (5 \, e^{\left (-x\right )} + 3 \, e^{\left (-3 \, x\right )} + 3 \, e^{\left (-5 \, x\right )} + 5 \, e^{\left (-7 \, x\right )}\right )}}{4 \, e^{\left (-2 \, x\right )} - 6 \, e^{\left (-4 \, x\right )} + 4 \, e^{\left (-6 \, x\right )} - e^{\left (-8 \, x\right )} - 1} - 3 \, \log \left (e^{\left (-x\right )} + 1\right ) + 3 \, \log \left (e^{\left (-x\right )} - 1\right )\right )} - \frac {1}{8} \, b^{5} {\left (\frac {2 \, {\left (3 \, e^{\left (-x\right )} - 11 \, e^{\left (-3 \, x\right )} - 11 \, e^{\left (-5 \, x\right )} + 3 \, e^{\left (-7 \, x\right )}\right )}}{4 \, e^{\left (-2 \, x\right )} - 6 \, e^{\left (-4 \, x\right )} + 4 \, e^{\left (-6 \, x\right )} - e^{\left (-8 \, x\right )} - 1} + 3 \, \log \left (e^{\left (-x\right )} + 1\right ) - 3 \, \log \left (e^{\left (-x\right )} - 1\right )\right )} + \frac {5}{4} \, a^{2} b^{3} {\left (\frac {2 \, {\left (e^{\left (-x\right )} + 7 \, e^{\left (-3 \, x\right )} + 7 \, e^{\left (-5 \, x\right )} + e^{\left (-7 \, x\right )}\right )}}{4 \, e^{\left (-2 \, x\right )} - 6 \, e^{\left (-4 \, x\right )} + 4 \, e^{\left (-6 \, x\right )} - e^{\left (-8 \, x\right )} - 1} + \log \left (e^{\left (-x\right )} + 1\right ) - \log \left (e^{\left (-x\right )} - 1\right )\right )} - \frac {20 \, a b^{4}}{{\left (e^{\left (-x\right )} - e^{x}\right )}^{4}} \] Input:

integrate((a*coth(x)+b*csch(x))^5,x, algorithm="maxima")
                                                                                    
                                                                                    
 

Output:

-5/2*a^3*b^2*coth(x)^4 + a^5*(x + 4*(e^(-2*x) - e^(-4*x) + e^(-6*x))/(4*e^ 
(-2*x) - 6*e^(-4*x) + 4*e^(-6*x) - e^(-8*x) - 1) + log(e^(-x) + 1) + log(e 
^(-x) - 1)) + 5/8*a^4*b*(2*(5*e^(-x) + 3*e^(-3*x) + 3*e^(-5*x) + 5*e^(-7*x 
))/(4*e^(-2*x) - 6*e^(-4*x) + 4*e^(-6*x) - e^(-8*x) - 1) - 3*log(e^(-x) + 
1) + 3*log(e^(-x) - 1)) - 1/8*b^5*(2*(3*e^(-x) - 11*e^(-3*x) - 11*e^(-5*x) 
 + 3*e^(-7*x))/(4*e^(-2*x) - 6*e^(-4*x) + 4*e^(-6*x) - e^(-8*x) - 1) + 3*l 
og(e^(-x) + 1) - 3*log(e^(-x) - 1)) + 5/4*a^2*b^3*(2*(e^(-x) + 7*e^(-3*x) 
+ 7*e^(-5*x) + e^(-7*x))/(4*e^(-2*x) - 6*e^(-4*x) + 4*e^(-6*x) - e^(-8*x) 
- 1) + log(e^(-x) + 1) - log(e^(-x) - 1)) - 20*a*b^4/(e^(-x) - e^x)^4
 

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 234 vs. \(2 (116) = 232\).

Time = 0.13 (sec) , antiderivative size = 234, normalized size of antiderivative = 1.89 \[ \int (a \coth (x)+b \text {csch}(x))^5 \, dx=\frac {1}{16} \, {\left (8 \, a^{5} - 15 \, a^{4} b + 10 \, a^{2} b^{3} - 3 \, b^{5}\right )} \log \left (e^{\left (-x\right )} + e^{x} + 2\right ) + \frac {1}{16} \, {\left (8 \, a^{5} + 15 \, a^{4} b - 10 \, a^{2} b^{3} + 3 \, b^{5}\right )} \log \left (e^{\left (-x\right )} + e^{x} - 2\right ) - \frac {3 \, a^{5} {\left (e^{\left (-x\right )} + e^{x}\right )}^{4} + 25 \, a^{4} b {\left (e^{\left (-x\right )} + e^{x}\right )}^{3} + 10 \, a^{2} b^{3} {\left (e^{\left (-x\right )} + e^{x}\right )}^{3} - 3 \, b^{5} {\left (e^{\left (-x\right )} + e^{x}\right )}^{3} - 8 \, a^{5} {\left (e^{\left (-x\right )} + e^{x}\right )}^{2} + 80 \, a^{3} b^{2} {\left (e^{\left (-x\right )} + e^{x}\right )}^{2} - 60 \, a^{4} b {\left (e^{\left (-x\right )} + e^{x}\right )} + 40 \, a^{2} b^{3} {\left (e^{\left (-x\right )} + e^{x}\right )} + 20 \, b^{5} {\left (e^{\left (-x\right )} + e^{x}\right )} - 160 \, a^{3} b^{2} + 80 \, a b^{4}}{4 \, {\left ({\left (e^{\left (-x\right )} + e^{x}\right )}^{2} - 4\right )}^{2}} \] Input:

integrate((a*coth(x)+b*csch(x))^5,x, algorithm="giac")
 

Output:

1/16*(8*a^5 - 15*a^4*b + 10*a^2*b^3 - 3*b^5)*log(e^(-x) + e^x + 2) + 1/16* 
(8*a^5 + 15*a^4*b - 10*a^2*b^3 + 3*b^5)*log(e^(-x) + e^x - 2) - 1/4*(3*a^5 
*(e^(-x) + e^x)^4 + 25*a^4*b*(e^(-x) + e^x)^3 + 10*a^2*b^3*(e^(-x) + e^x)^ 
3 - 3*b^5*(e^(-x) + e^x)^3 - 8*a^5*(e^(-x) + e^x)^2 + 80*a^3*b^2*(e^(-x) + 
 e^x)^2 - 60*a^4*b*(e^(-x) + e^x) + 40*a^2*b^3*(e^(-x) + e^x) + 20*b^5*(e^ 
(-x) + e^x) - 160*a^3*b^2 + 80*a*b^4)/((e^(-x) + e^x)^2 - 4)^2
 

Mupad [B] (verification not implemented)

Time = 0.22 (sec) , antiderivative size = 392, normalized size of antiderivative = 3.16 \[ \int (a \coth (x)+b \text {csch}(x))^5 \, dx=\ln \left (\frac {15\,a^4\,b}{4}+\frac {3\,b^5}{4}-\frac {5\,a^2\,b^3}{2}-\frac {3\,b^5\,{\mathrm {e}}^x}{4}-\frac {15\,a^4\,b\,{\mathrm {e}}^x}{4}+\frac {5\,a^2\,b^3\,{\mathrm {e}}^x}{2}\right )\,\left (a^5+\frac {15\,a^4\,b}{8}-\frac {5\,a^2\,b^3}{4}+\frac {3\,b^5}{8}\right )-\frac {{\mathrm {e}}^x\,\left (20\,a^4\,b+40\,a^2\,b^3+4\,b^5\right )+20\,a\,b^4+4\,a^5+40\,a^3\,b^2}{6\,{\mathrm {e}}^{4\,x}-4\,{\mathrm {e}}^{2\,x}-4\,{\mathrm {e}}^{6\,x}+{\mathrm {e}}^{8\,x}+1}-\frac {{\mathrm {e}}^x\,\left (30\,a^4\,b+60\,a^2\,b^3+6\,b^5\right )+40\,a\,b^4+8\,a^5+80\,a^3\,b^2}{3\,{\mathrm {e}}^{2\,x}-3\,{\mathrm {e}}^{4\,x}+{\mathrm {e}}^{6\,x}-1}-a^5\,x-\ln \left (\frac {5\,a^2\,b^3}{2}-\frac {3\,b^5}{4}-\frac {15\,a^4\,b}{4}-\frac {3\,b^5\,{\mathrm {e}}^x}{4}-\frac {15\,a^4\,b\,{\mathrm {e}}^x}{4}+\frac {5\,a^2\,b^3\,{\mathrm {e}}^x}{2}\right )\,\left (-a^5+\frac {15\,a^4\,b}{8}-\frac {5\,a^2\,b^3}{4}+\frac {3\,b^5}{8}\right )-\frac {{\mathrm {e}}^x\,\left (\frac {25\,a^4\,b}{4}+\frac {5\,a^2\,b^3}{2}-\frac {3\,b^5}{4}\right )+4\,a^5+20\,a^3\,b^2}{{\mathrm {e}}^{2\,x}-1}-\frac {{\mathrm {e}}^x\,\left (\frac {45\,a^4\,b}{2}+25\,a^2\,b^3+\frac {b^5}{2}\right )+20\,a\,b^4+8\,a^5+60\,a^3\,b^2}{{\mathrm {e}}^{4\,x}-2\,{\mathrm {e}}^{2\,x}+1} \] Input:

int((b/sinh(x) + a*coth(x))^5,x)
 

Output:

log((15*a^4*b)/4 + (3*b^5)/4 - (5*a^2*b^3)/2 - (3*b^5*exp(x))/4 - (15*a^4* 
b*exp(x))/4 + (5*a^2*b^3*exp(x))/2)*((15*a^4*b)/8 + a^5 + (3*b^5)/8 - (5*a 
^2*b^3)/4) - (exp(x)*(20*a^4*b + 4*b^5 + 40*a^2*b^3) + 20*a*b^4 + 4*a^5 + 
40*a^3*b^2)/(6*exp(4*x) - 4*exp(2*x) - 4*exp(6*x) + exp(8*x) + 1) - (exp(x 
)*(30*a^4*b + 6*b^5 + 60*a^2*b^3) + 40*a*b^4 + 8*a^5 + 80*a^3*b^2)/(3*exp( 
2*x) - 3*exp(4*x) + exp(6*x) - 1) - a^5*x - log((5*a^2*b^3)/2 - (3*b^5)/4 
- (15*a^4*b)/4 - (3*b^5*exp(x))/4 - (15*a^4*b*exp(x))/4 + (5*a^2*b^3*exp(x 
))/2)*((15*a^4*b)/8 - a^5 + (3*b^5)/8 - (5*a^2*b^3)/4) - (exp(x)*((25*a^4* 
b)/4 - (3*b^5)/4 + (5*a^2*b^3)/2) + 4*a^5 + 20*a^3*b^2)/(exp(2*x) - 1) - ( 
exp(x)*((45*a^4*b)/2 + b^5/2 + 25*a^2*b^3) + 20*a*b^4 + 8*a^5 + 60*a^3*b^2 
)/(exp(4*x) - 2*exp(2*x) + 1)
 

Reduce [B] (verification not implemented)

Time = 0.23 (sec) , antiderivative size = 924, normalized size of antiderivative = 7.45 \[ \int (a \coth (x)+b \text {csch}(x))^5 \, dx =\text {Too large to display} \] Input:

int((a*coth(x)+b*csch(x))^5,x)
 

Output:

(8*e**(8*x)*log(e**x - 1)*a**5 + 15*e**(8*x)*log(e**x - 1)*a**4*b - 10*e** 
(8*x)*log(e**x - 1)*a**2*b**3 + 3*e**(8*x)*log(e**x - 1)*b**5 + 8*e**(8*x) 
*log(e**x + 1)*a**5 - 15*e**(8*x)*log(e**x + 1)*a**4*b + 10*e**(8*x)*log(e 
**x + 1)*a**2*b**3 - 3*e**(8*x)*log(e**x + 1)*b**5 - 8*e**(8*x)*a**5*x - 8 
*e**(8*x)*a**5 - 40*e**(8*x)*a**3*b**2 - 50*e**(7*x)*a**4*b - 20*e**(7*x)* 
a**2*b**3 + 6*e**(7*x)*b**5 - 32*e**(6*x)*log(e**x - 1)*a**5 - 60*e**(6*x) 
*log(e**x - 1)*a**4*b + 40*e**(6*x)*log(e**x - 1)*a**2*b**3 - 12*e**(6*x)* 
log(e**x - 1)*b**5 - 32*e**(6*x)*log(e**x + 1)*a**5 + 60*e**(6*x)*log(e**x 
 + 1)*a**4*b - 40*e**(6*x)*log(e**x + 1)*a**2*b**3 + 12*e**(6*x)*log(e**x 
+ 1)*b**5 + 32*e**(6*x)*a**5*x - 30*e**(5*x)*a**4*b - 140*e**(5*x)*a**2*b* 
*3 - 22*e**(5*x)*b**5 + 48*e**(4*x)*log(e**x - 1)*a**5 + 90*e**(4*x)*log(e 
**x - 1)*a**4*b - 60*e**(4*x)*log(e**x - 1)*a**2*b**3 + 18*e**(4*x)*log(e* 
*x - 1)*b**5 + 48*e**(4*x)*log(e**x + 1)*a**5 - 90*e**(4*x)*log(e**x + 1)* 
a**4*b + 60*e**(4*x)*log(e**x + 1)*a**2*b**3 - 18*e**(4*x)*log(e**x + 1)*b 
**5 - 48*e**(4*x)*a**5*x - 16*e**(4*x)*a**5 - 240*e**(4*x)*a**3*b**2 - 160 
*e**(4*x)*a*b**4 - 30*e**(3*x)*a**4*b - 140*e**(3*x)*a**2*b**3 - 22*e**(3* 
x)*b**5 - 32*e**(2*x)*log(e**x - 1)*a**5 - 60*e**(2*x)*log(e**x - 1)*a**4* 
b + 40*e**(2*x)*log(e**x - 1)*a**2*b**3 - 12*e**(2*x)*log(e**x - 1)*b**5 - 
 32*e**(2*x)*log(e**x + 1)*a**5 + 60*e**(2*x)*log(e**x + 1)*a**4*b - 40*e* 
*(2*x)*log(e**x + 1)*a**2*b**3 + 12*e**(2*x)*log(e**x + 1)*b**5 + 32*e*...