\(\int \frac {\tanh ^5(x)}{i+\text {csch}(x)} \, dx\) [102]

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 [F]

Optimal result

Integrand size = 13, antiderivative size = 109 \[ \int \frac {\tanh ^5(x)}{i+\text {csch}(x)} \, dx=-\frac {21}{32} i \log (i-\sinh (x))-\frac {11}{32} i \log (i+\sinh (x))+\frac {i}{32 (1-i \sinh (x))^2}-\frac {i}{4 (1-i \sinh (x))}-\frac {i}{24 (1+i \sinh (x))^3}+\frac {9 i}{32 (1+i \sinh (x))^2}-\frac {15 i}{16 (1+i \sinh (x))} \] Output:

-21/32*I*ln(I-sinh(x))-11/32*I*ln(I+sinh(x))+1/32*I/(1-I*sinh(x))^2-1/4*I/ 
(1-I*sinh(x))-1/24*I/(1+I*sinh(x))^3+9/32*I/(1+I*sinh(x))^2-15/16*I/(1+I*s 
inh(x))
 

Mathematica [A] (verified)

Time = 0.14 (sec) , antiderivative size = 75, normalized size of antiderivative = 0.69 \[ \int \frac {\tanh ^5(x)}{i+\text {csch}(x)} \, dx=\frac {1}{96} \left (-63 i \log (i-\sinh (x))-33 i \log (i+\sinh (x))-\frac {2 \left (44+29 i \sinh (x)+79 \sinh ^2(x)+39 i \sinh ^3(x)+33 \sinh ^4(x)\right )}{(-i+\sinh (x))^3 (i+\sinh (x))^2}\right ) \] Input:

Integrate[Tanh[x]^5/(I + Csch[x]),x]
 

Output:

((-63*I)*Log[I - Sinh[x]] - (33*I)*Log[I + Sinh[x]] - (2*(44 + (29*I)*Sinh 
[x] + 79*Sinh[x]^2 + (39*I)*Sinh[x]^3 + 33*Sinh[x]^4))/((-I + Sinh[x])^3*( 
I + Sinh[x])^2))/96
 

Rubi [A] (verified)

Time = 0.29 (sec) , antiderivative size = 101, normalized size of antiderivative = 0.93, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.462, Rules used = {3042, 26, 26, 4367, 99, 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 ^5(x)}{\text {csch}(x)+i} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int -\frac {i}{\cot (i x)^5 (i \csc (i x)+i)}dx\)

\(\Big \downarrow \) 26

\(\displaystyle -i \int -\frac {i}{\cot (i x)^5 (\csc (i x)+1)}dx\)

\(\Big \downarrow \) 26

\(\displaystyle -\int \frac {1}{\cot (i x)^5 (\csc (i x)+1)}dx\)

\(\Big \downarrow \) 4367

\(\displaystyle i \int -\frac {\sinh ^6(x)}{(1-i \sinh (x))^3 (i \sinh (x)+1)^4}d(i \sinh (x))\)

\(\Big \downarrow \) 99

\(\displaystyle i \int \left (-\frac {21}{32 (i \sinh (x)+1)}+\frac {15}{16 (i \sinh (x)+1)^2}-\frac {9}{16 (i \sinh (x)+1)^3}+\frac {1}{8 (i \sinh (x)+1)^4}-\frac {11}{32 (i \sinh (x)-1)}-\frac {1}{4 (i \sinh (x)-1)^2}-\frac {1}{16 (i \sinh (x)-1)^3}\right )d(i \sinh (x))\)

\(\Big \downarrow \) 2009

\(\displaystyle i \left (-\frac {1}{4 (1-i \sinh (x))}-\frac {15}{16 (1+i \sinh (x))}+\frac {1}{32 (1-i \sinh (x))^2}+\frac {9}{32 (1+i \sinh (x))^2}-\frac {1}{24 (1+i \sinh (x))^3}-\frac {11}{32} \log (1-i \sinh (x))-\frac {21}{32} \log (1+i \sinh (x))\right )\)

Input:

Int[Tanh[x]^5/(I + Csch[x]),x]
 

Output:

I*((-11*Log[1 - I*Sinh[x]])/32 - (21*Log[1 + I*Sinh[x]])/32 + 1/(32*(1 - I 
*Sinh[x])^2) - 1/(4*(1 - I*Sinh[x])) - 1/(24*(1 + I*Sinh[x])^3) + 9/(32*(1 
 + I*Sinh[x])^2) - 15/(16*(1 + I*Sinh[x])))
 

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 99
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_) 
)^(p_), x_] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d*x)^n*(e + f*x)^p, x], 
 x] /; FreeQ[{a, b, c, d, e, f, p}, x] && IntegersQ[m, n] && (IntegerQ[p] | 
| (GtQ[m, 0] && GeQ[n, -1]))
 

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 4367
Int[cot[(c_.) + (d_.)*(x_)]^(m_.)*(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_))^(n 
_.), x_Symbol] :> Simp[1/(a^(m - n - 1)*b^n*d)   Subst[Int[(a - b*x)^((m - 
1)/2)*((a + b*x)^((m - 1)/2 + n)/x^(m + n)), x], x, Sin[c + d*x]], x] /; Fr 
eeQ[{a, b, c, d}, x] && IntegerQ[(m - 1)/2] && EqQ[a^2 - b^2, 0] && Integer 
Q[n]
 
Maple [A] (verified)

Time = 1.86 (sec) , antiderivative size = 97, normalized size of antiderivative = 0.89

method result size
risch \(i x -\frac {-78 i {\mathrm e}^{2 x}+184 \,{\mathrm e}^{3 x}+2 i {\mathrm e}^{4 x}+270 \,{\mathrm e}^{5 x}+33 \,{\mathrm e}^{x}-2 i {\mathrm e}^{6 x}+184 \,{\mathrm e}^{7 x}+78 i {\mathrm e}^{8 x}+33 \,{\mathrm e}^{9 x}}{24 \left ({\mathrm e}^{x}-i\right )^{6} \left ({\mathrm e}^{x}+i\right )^{4}}-\frac {21 i \ln \left ({\mathrm e}^{x}-i\right )}{16}-\frac {11 i \ln \left ({\mathrm e}^{x}+i\right )}{16}\) \(97\)
default \(-\frac {21 i \ln \left (\tanh \left (\frac {x}{2}\right )-i\right )}{16}+\frac {3 i}{8 \left (\tanh \left (\frac {x}{2}\right )-i\right )^{2}}+\frac {i}{3 \left (\tanh \left (\frac {x}{2}\right )-i\right )^{6}}-\frac {3 i}{8 \left (\tanh \left (\frac {x}{2}\right )-i\right )^{4}}+\frac {1}{\left (\tanh \left (\frac {x}{2}\right )-i\right )^{5}}+\frac {11}{12 \left (\tanh \left (\frac {x}{2}\right )-i\right )^{3}}+\frac {1}{\tanh \left (\frac {x}{2}\right )-i}+i \ln \left (\tanh \left (\frac {x}{2}\right )-1\right )+i \ln \left (\tanh \left (\frac {x}{2}\right )+1\right )-\frac {11 i \ln \left (\tanh \left (\frac {x}{2}\right )+i\right )}{16}+\frac {i}{8 \left (\tanh \left (\frac {x}{2}\right )+i\right )^{4}}+\frac {i}{4 \left (\tanh \left (\frac {x}{2}\right )+i\right )^{2}}-\frac {1}{4 \left (\tanh \left (\frac {x}{2}\right )+i\right )^{3}}-\frac {3}{8 \left (\tanh \left (\frac {x}{2}\right )+i\right )}\) \(155\)

Input:

int(tanh(x)^5/(I+csch(x)),x,method=_RETURNVERBOSE)
 

Output:

I*x-1/24*(-78*I*exp(x)^2+184*exp(x)^3+2*I*exp(x)^4+270*exp(x)^5+33*exp(x)- 
2*I*exp(x)^6+184*exp(x)^7+78*I*exp(x)^8+33*exp(x)^9)/(exp(x)-I)^6/(exp(x)+ 
I)^4-21/16*I*ln(exp(x)-I)-11/16*I*ln(exp(x)+I)
 

Fricas [B] (verification not implemented)

Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 304 vs. \(2 (67) = 134\).

Time = 0.09 (sec) , antiderivative size = 304, normalized size of antiderivative = 2.79 \[ \int \frac {\tanh ^5(x)}{i+\text {csch}(x)} \, dx=\frac {48 i \, x e^{\left (10 \, x\right )} + 6 \, {\left (16 \, x - 11\right )} e^{\left (9 \, x\right )} - 12 \, {\left (-12 i \, x + 13 i\right )} e^{\left (8 \, x\right )} + 16 \, {\left (24 \, x - 23\right )} e^{\left (7 \, x\right )} - 4 \, {\left (-24 i \, x - i\right )} e^{\left (6 \, x\right )} + 36 \, {\left (16 \, x - 15\right )} e^{\left (5 \, x\right )} - 4 \, {\left (24 i \, x + i\right )} e^{\left (4 \, x\right )} + 16 \, {\left (24 \, x - 23\right )} e^{\left (3 \, x\right )} - 12 \, {\left (12 i \, x - 13 i\right )} e^{\left (2 \, x\right )} + 6 \, {\left (16 \, x - 11\right )} e^{x} - 33 \, {\left (i \, e^{\left (10 \, x\right )} + 2 \, e^{\left (9 \, x\right )} + 3 i \, e^{\left (8 \, x\right )} + 8 \, e^{\left (7 \, x\right )} + 2 i \, e^{\left (6 \, x\right )} + 12 \, e^{\left (5 \, x\right )} - 2 i \, e^{\left (4 \, x\right )} + 8 \, e^{\left (3 \, x\right )} - 3 i \, e^{\left (2 \, x\right )} + 2 \, e^{x} - i\right )} \log \left (e^{x} + i\right ) - 63 \, {\left (i \, e^{\left (10 \, x\right )} + 2 \, e^{\left (9 \, x\right )} + 3 i \, e^{\left (8 \, x\right )} + 8 \, e^{\left (7 \, x\right )} + 2 i \, e^{\left (6 \, x\right )} + 12 \, e^{\left (5 \, x\right )} - 2 i \, e^{\left (4 \, x\right )} + 8 \, e^{\left (3 \, x\right )} - 3 i \, e^{\left (2 \, x\right )} + 2 \, e^{x} - i\right )} \log \left (e^{x} - i\right ) - 48 i \, x}{48 \, {\left (e^{\left (10 \, x\right )} - 2 i \, e^{\left (9 \, x\right )} + 3 \, e^{\left (8 \, x\right )} - 8 i \, e^{\left (7 \, x\right )} + 2 \, e^{\left (6 \, x\right )} - 12 i \, e^{\left (5 \, x\right )} - 2 \, e^{\left (4 \, x\right )} - 8 i \, e^{\left (3 \, x\right )} - 3 \, e^{\left (2 \, x\right )} - 2 i \, e^{x} - 1\right )}} \] Input:

integrate(tanh(x)^5/(I+csch(x)),x, algorithm="fricas")
 

Output:

1/48*(48*I*x*e^(10*x) + 6*(16*x - 11)*e^(9*x) - 12*(-12*I*x + 13*I)*e^(8*x 
) + 16*(24*x - 23)*e^(7*x) - 4*(-24*I*x - I)*e^(6*x) + 36*(16*x - 15)*e^(5 
*x) - 4*(24*I*x + I)*e^(4*x) + 16*(24*x - 23)*e^(3*x) - 12*(12*I*x - 13*I) 
*e^(2*x) + 6*(16*x - 11)*e^x - 33*(I*e^(10*x) + 2*e^(9*x) + 3*I*e^(8*x) + 
8*e^(7*x) + 2*I*e^(6*x) + 12*e^(5*x) - 2*I*e^(4*x) + 8*e^(3*x) - 3*I*e^(2* 
x) + 2*e^x - I)*log(e^x + I) - 63*(I*e^(10*x) + 2*e^(9*x) + 3*I*e^(8*x) + 
8*e^(7*x) + 2*I*e^(6*x) + 12*e^(5*x) - 2*I*e^(4*x) + 8*e^(3*x) - 3*I*e^(2* 
x) + 2*e^x - I)*log(e^x - I) - 48*I*x)/(e^(10*x) - 2*I*e^(9*x) + 3*e^(8*x) 
 - 8*I*e^(7*x) + 2*e^(6*x) - 12*I*e^(5*x) - 2*e^(4*x) - 8*I*e^(3*x) - 3*e^ 
(2*x) - 2*I*e^x - 1)
 

Sympy [F]

\[ \int \frac {\tanh ^5(x)}{i+\text {csch}(x)} \, dx=\int \frac {\tanh ^{5}{\left (x \right )}}{\operatorname {csch}{\left (x \right )} + i}\, dx \] Input:

integrate(tanh(x)**5/(I+csch(x)),x)
 

Output:

Integral(tanh(x)**5/(csch(x) + I), x)
 

Maxima [B] (verification not implemented)

Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 144 vs. \(2 (67) = 134\).

Time = 0.04 (sec) , antiderivative size = 144, normalized size of antiderivative = 1.32 \[ \int \frac {\tanh ^5(x)}{i+\text {csch}(x)} \, dx=-i \, x + \frac {33 \, e^{\left (-x\right )} + 78 i \, e^{\left (-2 \, x\right )} + 184 \, e^{\left (-3 \, x\right )} - 2 i \, e^{\left (-4 \, x\right )} + 270 \, e^{\left (-5 \, x\right )} + 2 i \, e^{\left (-6 \, x\right )} + 184 \, e^{\left (-7 \, x\right )} - 78 i \, e^{\left (-8 \, x\right )} + 33 \, e^{\left (-9 \, x\right )}}{48 i \, e^{\left (-x\right )} - 72 \, e^{\left (-2 \, x\right )} + 192 i \, e^{\left (-3 \, x\right )} - 48 \, e^{\left (-4 \, x\right )} + 288 i \, e^{\left (-5 \, x\right )} + 48 \, e^{\left (-6 \, x\right )} + 192 i \, e^{\left (-7 \, x\right )} + 72 \, e^{\left (-8 \, x\right )} + 48 i \, e^{\left (-9 \, x\right )} + 24 \, e^{\left (-10 \, x\right )} - 24} - \frac {11}{16} i \, \log \left (e^{\left (-x\right )} - i\right ) - \frac {21}{16} i \, \log \left (i \, e^{\left (-x\right )} - 1\right ) \] Input:

integrate(tanh(x)^5/(I+csch(x)),x, algorithm="maxima")
 

Output:

-I*x + (33*e^(-x) + 78*I*e^(-2*x) + 184*e^(-3*x) - 2*I*e^(-4*x) + 270*e^(- 
5*x) + 2*I*e^(-6*x) + 184*e^(-7*x) - 78*I*e^(-8*x) + 33*e^(-9*x))/(48*I*e^ 
(-x) - 72*e^(-2*x) + 192*I*e^(-3*x) - 48*e^(-4*x) + 288*I*e^(-5*x) + 48*e^ 
(-6*x) + 192*I*e^(-7*x) + 72*e^(-8*x) + 48*I*e^(-9*x) + 24*e^(-10*x) - 24) 
 - 11/16*I*log(e^(-x) - I) - 21/16*I*log(I*e^(-x) - 1)
 

Giac [A] (verification not implemented)

Time = 0.12 (sec) , antiderivative size = 120, normalized size of antiderivative = 1.10 \[ \int \frac {\tanh ^5(x)}{i+\text {csch}(x)} \, dx=-\frac {33 i \, {\left (e^{\left (-x\right )} - e^{x}\right )}^{2} + 100 \, e^{\left (-x\right )} - 100 \, e^{x} - 76 i}{64 \, {\left (-i \, e^{\left (-x\right )} + i \, e^{x} - 2\right )}^{2}} - \frac {-231 i \, {\left (e^{\left (-x\right )} - e^{x}\right )}^{3} + 1026 \, {\left (e^{\left (-x\right )} - e^{x}\right )}^{2} + 1548 i \, e^{\left (-x\right )} - 1548 i \, e^{x} - 776}{192 \, {\left (e^{\left (-x\right )} - e^{x} + 2 i\right )}^{3}} - \frac {11}{32} i \, \log \left (-e^{\left (-x\right )} + e^{x} + 2 i\right ) - \frac {21}{32} i \, \log \left (-e^{\left (-x\right )} + e^{x} - 2 i\right ) \] Input:

integrate(tanh(x)^5/(I+csch(x)),x, algorithm="giac")
 

Output:

-1/64*(33*I*(e^(-x) - e^x)^2 + 100*e^(-x) - 100*e^x - 76*I)/(-I*e^(-x) + I 
*e^x - 2)^2 - 1/192*(-231*I*(e^(-x) - e^x)^3 + 1026*(e^(-x) - e^x)^2 + 154 
8*I*e^(-x) - 1548*I*e^x - 776)/(e^(-x) - e^x + 2*I)^3 - 11/32*I*log(-e^(-x 
) + e^x + 2*I) - 21/32*I*log(-e^(-x) + e^x - 2*I)
 

Mupad [B] (verification not implemented)

Time = 5.38 (sec) , antiderivative size = 274, normalized size of antiderivative = 2.51 \[ \int \frac {\tanh ^5(x)}{i+\text {csch}(x)} \, dx=x\,1{}\mathrm {i}-\ln \left (\left (\frac {5\,{\mathrm {e}}^x}{8}-\frac {5}{8}{}\mathrm {i}\right )\,\left (\frac {5\,{\mathrm {e}}^x}{8}+\frac {5}{8}{}\mathrm {i}\right )\right )\,1{}\mathrm {i}+\frac {5\,\mathrm {atan}\left ({\mathrm {e}}^x\right )}{8}+\frac {1{}\mathrm {i}}{3\,\left (15\,{\mathrm {e}}^{4\,x}-15\,{\mathrm {e}}^{2\,x}-{\mathrm {e}}^{6\,x}+1-{\mathrm {e}}^{3\,x}\,20{}\mathrm {i}+{\mathrm {e}}^{5\,x}\,6{}\mathrm {i}+{\mathrm {e}}^x\,6{}\mathrm {i}\right )}-\frac {1}{{\mathrm {e}}^{2\,x}\,10{}\mathrm {i}-10\,{\mathrm {e}}^{3\,x}-{\mathrm {e}}^{4\,x}\,5{}\mathrm {i}+{\mathrm {e}}^{5\,x}+5\,{\mathrm {e}}^x-\mathrm {i}}-\frac {31}{12\,\left ({\mathrm {e}}^{2\,x}\,3{}\mathrm {i}-{\mathrm {e}}^{3\,x}+3\,{\mathrm {e}}^x-\mathrm {i}\right )}-\frac {5{}\mathrm {i}}{8\,\left ({\mathrm {e}}^{2\,x}-1+{\mathrm {e}}^x\,2{}\mathrm {i}\right )}+\frac {17{}\mathrm {i}}{8\,\left ({\mathrm {e}}^{4\,x}-6\,{\mathrm {e}}^{2\,x}+1-{\mathrm {e}}^{3\,x}\,4{}\mathrm {i}+{\mathrm {e}}^x\,4{}\mathrm {i}\right )}+\frac {1{}\mathrm {i}}{8\,\left ({\mathrm {e}}^{4\,x}-6\,{\mathrm {e}}^{2\,x}+1+{\mathrm {e}}^{3\,x}\,4{}\mathrm {i}-{\mathrm {e}}^x\,4{}\mathrm {i}\right )}+\frac {3{}\mathrm {i}}{1-{\mathrm {e}}^{2\,x}+{\mathrm {e}}^x\,2{}\mathrm {i}}-\frac {15}{8\,\left ({\mathrm {e}}^x-\mathrm {i}\right )}+\frac {1}{2\,\left ({\mathrm {e}}^x+1{}\mathrm {i}\right )}-\frac {1}{4\,\left ({\mathrm {e}}^{2\,x}\,3{}\mathrm {i}+{\mathrm {e}}^{3\,x}-3\,{\mathrm {e}}^x-\mathrm {i}\right )} \] Input:

int(tanh(x)^5/(1/sinh(x) + 1i),x)
 

Output:

x*1i - log(((5*exp(x))/8 - 5i/8)*((5*exp(x))/8 + 5i/8))*1i + (5*atan(exp(x 
)))/8 + 1i/(3*(15*exp(4*x) - exp(3*x)*20i - 15*exp(2*x) + exp(5*x)*6i - ex 
p(6*x) + exp(x)*6i + 1)) - 1/(exp(2*x)*10i - 10*exp(3*x) - exp(4*x)*5i + e 
xp(5*x) + 5*exp(x) - 1i) - 31/(12*(exp(2*x)*3i - exp(3*x) + 3*exp(x) - 1i) 
) - 5i/(8*(exp(2*x) + exp(x)*2i - 1)) + 17i/(8*(exp(4*x) - exp(3*x)*4i - 6 
*exp(2*x) + exp(x)*4i + 1)) + 1i/(8*(exp(3*x)*4i - 6*exp(2*x) + exp(4*x) - 
 exp(x)*4i + 1)) + 3i/(exp(x)*2i - exp(2*x) + 1) - 15/(8*(exp(x) - 1i)) + 
1/(2*(exp(x) + 1i)) - 1/(4*(exp(2*x)*3i + exp(3*x) - 3*exp(x) - 1i))
 

Reduce [F]

\[ \int \frac {\tanh ^5(x)}{i+\text {csch}(x)} \, dx=\int \frac {\tanh \left (x \right )^{5}}{\mathrm {csch}\left (x \right )+i}d x \] Input:

int(tanh(x)^5/(I+csch(x)),x)
 

Output:

int(tanh(x)**5/(csch(x) + i),x)