\(\int \frac {\text {sech}^8(x)}{a+b \tanh (x)} \, dx\) [102]

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

Optimal result

Integrand size = 13, antiderivative size = 140 \[ \int \frac {\text {sech}^8(x)}{a+b \tanh (x)} \, dx=-\frac {\left (a^2-b^2\right )^3 \log (a+b \tanh (x))}{b^7}+\frac {a \left (a^4-3 a^2 b^2+3 b^4\right ) \tanh (x)}{b^6}-\frac {\left (a^4-3 a^2 b^2+3 b^4\right ) \tanh ^2(x)}{2 b^5}+\frac {a \left (a^2-3 b^2\right ) \tanh ^3(x)}{3 b^4}-\frac {\left (a^2-3 b^2\right ) \tanh ^4(x)}{4 b^3}+\frac {a \tanh ^5(x)}{5 b^2}-\frac {\tanh ^6(x)}{6 b} \]

[Out]

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

Rubi [A] (verified)

Time = 0.11 (sec) , antiderivative size = 140, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.154, Rules used = {3587, 711} \[ \int \frac {\text {sech}^8(x)}{a+b \tanh (x)} \, dx=-\frac {\left (a^2-b^2\right )^3 \log (a+b \tanh (x))}{b^7}+\frac {a \left (a^2-3 b^2\right ) \tanh ^3(x)}{3 b^4}-\frac {\left (a^2-3 b^2\right ) \tanh ^4(x)}{4 b^3}+\frac {a \left (a^4-3 a^2 b^2+3 b^4\right ) \tanh (x)}{b^6}-\frac {\left (a^4-3 a^2 b^2+3 b^4\right ) \tanh ^2(x)}{2 b^5}+\frac {a \tanh ^5(x)}{5 b^2}-\frac {\tanh ^6(x)}{6 b} \]

[In]

Int[Sech[x]^8/(a + b*Tanh[x]),x]

[Out]

-(((a^2 - b^2)^3*Log[a + b*Tanh[x]])/b^7) + (a*(a^4 - 3*a^2*b^2 + 3*b^4)*Tanh[x])/b^6 - ((a^4 - 3*a^2*b^2 + 3*
b^4)*Tanh[x]^2)/(2*b^5) + (a*(a^2 - 3*b^2)*Tanh[x]^3)/(3*b^4) - ((a^2 - 3*b^2)*Tanh[x]^4)/(4*b^3) + (a*Tanh[x]
^5)/(5*b^2) - Tanh[x]^6/(6*b)

Rule 711

Int[((d_) + (e_.)*(x_))^(m_)*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ExpandIntegrand[(d + e*x)^m*(a + c*
x^2)^p, x], x] /; FreeQ[{a, c, d, e, m}, x] && NeQ[c*d^2 + a*e^2, 0] && IGtQ[p, 0]

Rule 3587

Int[sec[(e_.) + (f_.)*(x_)]^(m_)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Dist[1/(b*f), Subst
[Int[(a + x)^n*(1 + x^2/b^2)^(m/2 - 1), x], x, b*Tan[e + f*x]], x] /; FreeQ[{a, b, e, f, n}, x] && NeQ[a^2 + b
^2, 0] && IntegerQ[m/2]

Rubi steps \begin{align*} \text {integral}& = \frac {\text {Subst}\left (\int \frac {\left (1-\frac {x^2}{b^2}\right )^3}{a+x} \, dx,x,b \tanh (x)\right )}{b} \\ & = \frac {\text {Subst}\left (\int \left (\frac {a^5-3 a^3 b^2+3 a b^4}{b^6}-\frac {\left (a^4-3 a^2 b^2+3 b^4\right ) x}{b^6}+\frac {a \left (a^2-3 b^2\right ) x^2}{b^6}+\frac {\left (-a^2+3 b^2\right ) x^3}{b^6}+\frac {a x^4}{b^6}-\frac {x^5}{b^6}+\frac {\left (-a^2+b^2\right )^3}{b^6 (a+x)}\right ) \, dx,x,b \tanh (x)\right )}{b} \\ & = -\frac {\left (a^2-b^2\right )^3 \log (a+b \tanh (x))}{b^7}+\frac {a \left (a^4-3 a^2 b^2+3 b^4\right ) \tanh (x)}{b^6}-\frac {\left (a^4-3 a^2 b^2+3 b^4\right ) \tanh ^2(x)}{2 b^5}+\frac {a \left (a^2-3 b^2\right ) \tanh ^3(x)}{3 b^4}-\frac {\left (a^2-3 b^2\right ) \tanh ^4(x)}{4 b^3}+\frac {a \tanh ^5(x)}{5 b^2}-\frac {\tanh ^6(x)}{6 b} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.44 (sec) , antiderivative size = 127, normalized size of antiderivative = 0.91 \[ \int \frac {\text {sech}^8(x)}{a+b \tanh (x)} \, dx=\frac {-60 \left (a^2-b^2\right )^3 \log (a+b \tanh (x))+15 b^4 \left (-a^2+b^2\right ) \text {sech}^4(x)+10 b^6 \text {sech}^6(x)+60 a b \left (a^4-3 a^2 b^2+3 b^4\right ) \tanh (x)-30 b^2 \left (a^2-b^2\right )^2 \tanh ^2(x)+20 a b^3 \left (a^2-3 b^2\right ) \tanh ^3(x)+12 a b^5 \tanh ^5(x)}{60 b^7} \]

[In]

Integrate[Sech[x]^8/(a + b*Tanh[x]),x]

[Out]

(-60*(a^2 - b^2)^3*Log[a + b*Tanh[x]] + 15*b^4*(-a^2 + b^2)*Sech[x]^4 + 10*b^6*Sech[x]^6 + 60*a*b*(a^4 - 3*a^2
*b^2 + 3*b^4)*Tanh[x] - 30*b^2*(a^2 - b^2)^2*Tanh[x]^2 + 20*a*b^3*(a^2 - 3*b^2)*Tanh[x]^3 + 12*a*b^5*Tanh[x]^5
)/(60*b^7)

Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(412\) vs. \(2(130)=260\).

Time = 235.72 (sec) , antiderivative size = 413, normalized size of antiderivative = 2.95

method result size
default \(\frac {\frac {2 \left (\left (a^{5} b -3 a^{3} b^{3}+3 a \,b^{5}\right ) \tanh \left (\frac {x}{2}\right )^{11}+\left (-a^{4} b^{2}+3 a^{2} b^{4}-3 b^{6}\right ) \tanh \left (\frac {x}{2}\right )^{10}+\left (5 a^{5} b -\frac {41}{3} a^{3} b^{3}+11 a \,b^{5}\right ) \tanh \left (\frac {x}{2}\right )^{9}+\left (-4 a^{4} b^{2}+10 a^{2} b^{4}-6 b^{6}\right ) \tanh \left (\frac {x}{2}\right )^{8}+\left (10 a^{5} b -26 a^{3} b^{3}+\frac {106}{5} a \,b^{5}\right ) \tanh \left (\frac {x}{2}\right )^{7}+\left (-6 a^{4} b^{2}+14 a^{2} b^{4}-\frac {34}{3} b^{6}\right ) \tanh \left (\frac {x}{2}\right )^{6}+\left (10 a^{5} b -26 a^{3} b^{3}+\frac {106}{5} a \,b^{5}\right ) \tanh \left (\frac {x}{2}\right )^{5}+\left (-4 a^{4} b^{2}+10 a^{2} b^{4}-6 b^{6}\right ) \tanh \left (\frac {x}{2}\right )^{4}+\left (5 a^{5} b -\frac {41}{3} a^{3} b^{3}+11 a \,b^{5}\right ) \tanh \left (\frac {x}{2}\right )^{3}+\left (-a^{4} b^{2}+3 a^{2} b^{4}-3 b^{6}\right ) \tanh \left (\frac {x}{2}\right )^{2}+\left (a^{5} b -3 a^{3} b^{3}+3 a \,b^{5}\right ) \tanh \left (\frac {x}{2}\right )\right )}{\left (1+\tanh \left (\frac {x}{2}\right )^{2}\right )^{6}}+\left (a^{6}-3 a^{4} b^{2}+3 a^{2} b^{4}-b^{6}\right ) \ln \left (1+\tanh \left (\frac {x}{2}\right )^{2}\right )}{b^{7}}-\frac {\left (a^{6}-3 a^{4} b^{2}+3 a^{2} b^{4}-b^{6}\right ) \ln \left (\tanh \left (\frac {x}{2}\right )^{2} a +2 b \tanh \left (\frac {x}{2}\right )+a \right )}{b^{7}}\) \(413\)
risch \(-\frac {2 \left (330 a \,b^{4} {\mathrm e}^{6 x}+150 a^{5} {\mathrm e}^{4 x}+75 a^{5} {\mathrm e}^{2 x}-400 a^{3} b^{2} {\mathrm e}^{6 x}+105 a \,b^{4} {\mathrm e}^{8 x}+30 a^{2} b^{3} {\mathrm e}^{2 x}-15 a^{4} b \,{\mathrm e}^{10 x}-30 a^{3} b^{2} {\mathrm e}^{10 x}+30 a^{2} b^{3} {\mathrm e}^{10 x}+15 a \,b^{4} {\mathrm e}^{10 x}-60 a^{4} b \,{\mathrm e}^{8 x}+15 a^{5}-420 a^{3} b^{2} {\mathrm e}^{4 x}+390 a \,b^{4} {\mathrm e}^{4 x}-210 a^{3} b^{2} {\mathrm e}^{2 x}+183 a \,b^{4} {\mathrm e}^{2 x}-40 a^{3} b^{2}+33 a \,b^{4}-15 a^{4} b \,{\mathrm e}^{2 x}+15 a^{5} {\mathrm e}^{10 x}-15 b^{5} {\mathrm e}^{10 x}+75 a^{5} {\mathrm e}^{8 x}-90 b^{5} {\mathrm e}^{8 x}-180 a^{3} b^{2} {\mathrm e}^{8 x}+150 a^{2} b^{3} {\mathrm e}^{8 x}-90 a^{4} b \,{\mathrm e}^{6 x}+240 a^{2} b^{3} {\mathrm e}^{6 x}-60 a^{4} b \,{\mathrm e}^{4 x}+150 a^{2} b^{3} {\mathrm e}^{4 x}+150 a^{5} {\mathrm e}^{6 x}-230 b^{5} {\mathrm e}^{6 x}-90 b^{5} {\mathrm e}^{4 x}-15 b^{5} {\mathrm e}^{2 x}\right )}{15 b^{6} \left (1+{\mathrm e}^{2 x}\right )^{6}}+\frac {\ln \left (1+{\mathrm e}^{2 x}\right ) a^{6}}{b^{7}}-\frac {3 \ln \left (1+{\mathrm e}^{2 x}\right ) a^{4}}{b^{5}}+\frac {3 \ln \left (1+{\mathrm e}^{2 x}\right ) a^{2}}{b^{3}}-\frac {\ln \left (1+{\mathrm e}^{2 x}\right )}{b}-\frac {\ln \left ({\mathrm e}^{2 x}+\frac {a -b}{a +b}\right ) a^{6}}{b^{7}}+\frac {3 \ln \left ({\mathrm e}^{2 x}+\frac {a -b}{a +b}\right ) a^{4}}{b^{5}}-\frac {3 \ln \left ({\mathrm e}^{2 x}+\frac {a -b}{a +b}\right ) a^{2}}{b^{3}}+\frac {\ln \left ({\mathrm e}^{2 x}+\frac {a -b}{a +b}\right )}{b}\) \(497\)

[In]

int(sech(x)^8/(a+b*tanh(x)),x,method=_RETURNVERBOSE)

[Out]

2/b^7*(((a^5*b-3*a^3*b^3+3*a*b^5)*tanh(1/2*x)^11+(-a^4*b^2+3*a^2*b^4-3*b^6)*tanh(1/2*x)^10+(5*a^5*b-41/3*a^3*b
^3+11*a*b^5)*tanh(1/2*x)^9+(-4*a^4*b^2+10*a^2*b^4-6*b^6)*tanh(1/2*x)^8+(10*a^5*b-26*a^3*b^3+106/5*a*b^5)*tanh(
1/2*x)^7+(-6*a^4*b^2+14*a^2*b^4-34/3*b^6)*tanh(1/2*x)^6+(10*a^5*b-26*a^3*b^3+106/5*a*b^5)*tanh(1/2*x)^5+(-4*a^
4*b^2+10*a^2*b^4-6*b^6)*tanh(1/2*x)^4+(5*a^5*b-41/3*a^3*b^3+11*a*b^5)*tanh(1/2*x)^3+(-a^4*b^2+3*a^2*b^4-3*b^6)
*tanh(1/2*x)^2+(a^5*b-3*a^3*b^3+3*a*b^5)*tanh(1/2*x))/(1+tanh(1/2*x)^2)^6+1/2*(a^6-3*a^4*b^2+3*a^2*b^4-b^6)*ln
(1+tanh(1/2*x)^2))-(a^6-3*a^4*b^2+3*a^2*b^4-b^6)/b^7*ln(tanh(1/2*x)^2*a+2*b*tanh(1/2*x)+a)

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 5275 vs. \(2 (130) = 260\).

Time = 0.35 (sec) , antiderivative size = 5275, normalized size of antiderivative = 37.68 \[ \int \frac {\text {sech}^8(x)}{a+b \tanh (x)} \, dx=\text {Too large to display} \]

[In]

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

[Out]

Too large to include

Sympy [F]

\[ \int \frac {\text {sech}^8(x)}{a+b \tanh (x)} \, dx=\int \frac {\operatorname {sech}^{8}{\left (x \right )}}{a + b \tanh {\left (x \right )}}\, dx \]

[In]

integrate(sech(x)**8/(a+b*tanh(x)),x)

[Out]

Integral(sech(x)**8/(a + b*tanh(x)), x)

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 386 vs. \(2 (130) = 260\).

Time = 0.31 (sec) , antiderivative size = 386, normalized size of antiderivative = 2.76 \[ \int \frac {\text {sech}^8(x)}{a+b \tanh (x)} \, dx=\frac {2 \, {\left (15 \, a^{5} - 40 \, a^{3} b^{2} + 33 \, a b^{4} + 3 \, {\left (25 \, a^{5} + 5 \, a^{4} b - 70 \, a^{3} b^{2} - 10 \, a^{2} b^{3} + 61 \, a b^{4} + 5 \, b^{5}\right )} e^{\left (-2 \, x\right )} + 30 \, {\left (5 \, a^{5} + 2 \, a^{4} b - 14 \, a^{3} b^{2} - 5 \, a^{2} b^{3} + 13 \, a b^{4} + 3 \, b^{5}\right )} e^{\left (-4 \, x\right )} + 10 \, {\left (15 \, a^{5} + 9 \, a^{4} b - 40 \, a^{3} b^{2} - 24 \, a^{2} b^{3} + 33 \, a b^{4} + 23 \, b^{5}\right )} e^{\left (-6 \, x\right )} + 15 \, {\left (5 \, a^{5} + 4 \, a^{4} b - 12 \, a^{3} b^{2} - 10 \, a^{2} b^{3} + 7 \, a b^{4} + 6 \, b^{5}\right )} e^{\left (-8 \, x\right )} + 15 \, {\left (a^{5} + a^{4} b - 2 \, a^{3} b^{2} - 2 \, a^{2} b^{3} + a b^{4} + b^{5}\right )} e^{\left (-10 \, x\right )}\right )}}{15 \, {\left (6 \, b^{6} e^{\left (-2 \, x\right )} + 15 \, b^{6} e^{\left (-4 \, x\right )} + 20 \, b^{6} e^{\left (-6 \, x\right )} + 15 \, b^{6} e^{\left (-8 \, x\right )} + 6 \, b^{6} e^{\left (-10 \, x\right )} + b^{6} e^{\left (-12 \, x\right )} + b^{6}\right )}} - \frac {{\left (a^{6} - 3 \, a^{4} b^{2} + 3 \, a^{2} b^{4} - b^{6}\right )} \log \left (-{\left (a - b\right )} e^{\left (-2 \, x\right )} - a - b\right )}{b^{7}} + \frac {{\left (a^{6} - 3 \, a^{4} b^{2} + 3 \, a^{2} b^{4} - b^{6}\right )} \log \left (e^{\left (-2 \, x\right )} + 1\right )}{b^{7}} \]

[In]

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

[Out]

2/15*(15*a^5 - 40*a^3*b^2 + 33*a*b^4 + 3*(25*a^5 + 5*a^4*b - 70*a^3*b^2 - 10*a^2*b^3 + 61*a*b^4 + 5*b^5)*e^(-2
*x) + 30*(5*a^5 + 2*a^4*b - 14*a^3*b^2 - 5*a^2*b^3 + 13*a*b^4 + 3*b^5)*e^(-4*x) + 10*(15*a^5 + 9*a^4*b - 40*a^
3*b^2 - 24*a^2*b^3 + 33*a*b^4 + 23*b^5)*e^(-6*x) + 15*(5*a^5 + 4*a^4*b - 12*a^3*b^2 - 10*a^2*b^3 + 7*a*b^4 + 6
*b^5)*e^(-8*x) + 15*(a^5 + a^4*b - 2*a^3*b^2 - 2*a^2*b^3 + a*b^4 + b^5)*e^(-10*x))/(6*b^6*e^(-2*x) + 15*b^6*e^
(-4*x) + 20*b^6*e^(-6*x) + 15*b^6*e^(-8*x) + 6*b^6*e^(-10*x) + b^6*e^(-12*x) + b^6) - (a^6 - 3*a^4*b^2 + 3*a^2
*b^4 - b^6)*log(-(a - b)*e^(-2*x) - a - b)/b^7 + (a^6 - 3*a^4*b^2 + 3*a^2*b^4 - b^6)*log(e^(-2*x) + 1)/b^7

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 593 vs. \(2 (130) = 260\).

Time = 0.28 (sec) , antiderivative size = 593, normalized size of antiderivative = 4.24 \[ \int \frac {\text {sech}^8(x)}{a+b \tanh (x)} \, dx=-\frac {{\left (a^{7} + a^{6} b - 3 \, a^{5} b^{2} - 3 \, a^{4} b^{3} + 3 \, a^{3} b^{4} + 3 \, a^{2} b^{5} - a b^{6} - b^{7}\right )} \log \left ({\left | a e^{\left (2 \, x\right )} + b e^{\left (2 \, x\right )} + a - b \right |}\right )}{a b^{7} + b^{8}} + \frac {{\left (a^{6} - 3 \, a^{4} b^{2} + 3 \, a^{2} b^{4} - b^{6}\right )} \log \left (e^{\left (2 \, x\right )} + 1\right )}{b^{7}} - \frac {147 \, a^{6} e^{\left (12 \, x\right )} - 441 \, a^{4} b^{2} e^{\left (12 \, x\right )} + 441 \, a^{2} b^{4} e^{\left (12 \, x\right )} - 147 \, b^{6} e^{\left (12 \, x\right )} + 882 \, a^{6} e^{\left (10 \, x\right )} + 120 \, a^{5} b e^{\left (10 \, x\right )} - 2766 \, a^{4} b^{2} e^{\left (10 \, x\right )} - 240 \, a^{3} b^{3} e^{\left (10 \, x\right )} + 2886 \, a^{2} b^{4} e^{\left (10 \, x\right )} + 120 \, a b^{5} e^{\left (10 \, x\right )} - 1002 \, b^{6} e^{\left (10 \, x\right )} + 2205 \, a^{6} e^{\left (8 \, x\right )} + 600 \, a^{5} b e^{\left (8 \, x\right )} - 7095 \, a^{4} b^{2} e^{\left (8 \, x\right )} - 1440 \, a^{3} b^{3} e^{\left (8 \, x\right )} + 7815 \, a^{2} b^{4} e^{\left (8 \, x\right )} + 840 \, a b^{5} e^{\left (8 \, x\right )} - 2925 \, b^{6} e^{\left (8 \, x\right )} + 2940 \, a^{6} e^{\left (6 \, x\right )} + 1200 \, a^{5} b e^{\left (6 \, x\right )} - 9540 \, a^{4} b^{2} e^{\left (6 \, x\right )} - 3200 \, a^{3} b^{3} e^{\left (6 \, x\right )} + 10740 \, a^{2} b^{4} e^{\left (6 \, x\right )} + 2640 \, a b^{5} e^{\left (6 \, x\right )} - 4780 \, b^{6} e^{\left (6 \, x\right )} + 2205 \, a^{6} e^{\left (4 \, x\right )} + 1200 \, a^{5} b e^{\left (4 \, x\right )} - 7095 \, a^{4} b^{2} e^{\left (4 \, x\right )} - 3360 \, a^{3} b^{3} e^{\left (4 \, x\right )} + 7815 \, a^{2} b^{4} e^{\left (4 \, x\right )} + 3120 \, a b^{5} e^{\left (4 \, x\right )} - 2925 \, b^{6} e^{\left (4 \, x\right )} + 882 \, a^{6} e^{\left (2 \, x\right )} + 600 \, a^{5} b e^{\left (2 \, x\right )} - 2766 \, a^{4} b^{2} e^{\left (2 \, x\right )} - 1680 \, a^{3} b^{3} e^{\left (2 \, x\right )} + 2886 \, a^{2} b^{4} e^{\left (2 \, x\right )} + 1464 \, a b^{5} e^{\left (2 \, x\right )} - 1002 \, b^{6} e^{\left (2 \, x\right )} + 147 \, a^{6} + 120 \, a^{5} b - 441 \, a^{4} b^{2} - 320 \, a^{3} b^{3} + 441 \, a^{2} b^{4} + 264 \, a b^{5} - 147 \, b^{6}}{60 \, b^{7} {\left (e^{\left (2 \, x\right )} + 1\right )}^{6}} \]

[In]

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

[Out]

-(a^7 + a^6*b - 3*a^5*b^2 - 3*a^4*b^3 + 3*a^3*b^4 + 3*a^2*b^5 - a*b^6 - b^7)*log(abs(a*e^(2*x) + b*e^(2*x) + a
 - b))/(a*b^7 + b^8) + (a^6 - 3*a^4*b^2 + 3*a^2*b^4 - b^6)*log(e^(2*x) + 1)/b^7 - 1/60*(147*a^6*e^(12*x) - 441
*a^4*b^2*e^(12*x) + 441*a^2*b^4*e^(12*x) - 147*b^6*e^(12*x) + 882*a^6*e^(10*x) + 120*a^5*b*e^(10*x) - 2766*a^4
*b^2*e^(10*x) - 240*a^3*b^3*e^(10*x) + 2886*a^2*b^4*e^(10*x) + 120*a*b^5*e^(10*x) - 1002*b^6*e^(10*x) + 2205*a
^6*e^(8*x) + 600*a^5*b*e^(8*x) - 7095*a^4*b^2*e^(8*x) - 1440*a^3*b^3*e^(8*x) + 7815*a^2*b^4*e^(8*x) + 840*a*b^
5*e^(8*x) - 2925*b^6*e^(8*x) + 2940*a^6*e^(6*x) + 1200*a^5*b*e^(6*x) - 9540*a^4*b^2*e^(6*x) - 3200*a^3*b^3*e^(
6*x) + 10740*a^2*b^4*e^(6*x) + 2640*a*b^5*e^(6*x) - 4780*b^6*e^(6*x) + 2205*a^6*e^(4*x) + 1200*a^5*b*e^(4*x) -
 7095*a^4*b^2*e^(4*x) - 3360*a^3*b^3*e^(4*x) + 7815*a^2*b^4*e^(4*x) + 3120*a*b^5*e^(4*x) - 2925*b^6*e^(4*x) +
882*a^6*e^(2*x) + 600*a^5*b*e^(2*x) - 2766*a^4*b^2*e^(2*x) - 1680*a^3*b^3*e^(2*x) + 2886*a^2*b^4*e^(2*x) + 146
4*a*b^5*e^(2*x) - 1002*b^6*e^(2*x) + 147*a^6 + 120*a^5*b - 441*a^4*b^2 - 320*a^3*b^3 + 441*a^2*b^4 + 264*a*b^5
 - 147*b^6)/(b^7*(e^(2*x) + 1)^6)

Mupad [B] (verification not implemented)

Time = 2.04 (sec) , antiderivative size = 301, normalized size of antiderivative = 2.15 \[ \int \frac {\text {sech}^8(x)}{a+b \tanh (x)} \, dx=\frac {\ln \left ({\mathrm {e}}^{2\,x}+1\right )\,{\left (a+b\right )}^3\,{\left (a-b\right )}^3}{b^7}-\frac {32\,\left (a-5\,b\right )}{5\,b^2\,\left (5\,{\mathrm {e}}^{2\,x}+10\,{\mathrm {e}}^{4\,x}+10\,{\mathrm {e}}^{6\,x}+5\,{\mathrm {e}}^{8\,x}+{\mathrm {e}}^{10\,x}+1\right )}-\frac {4\,\left (a^2-4\,a\,b+7\,b^2\right )}{b^3\,\left (4\,{\mathrm {e}}^{2\,x}+6\,{\mathrm {e}}^{4\,x}+4\,{\mathrm {e}}^{6\,x}+{\mathrm {e}}^{8\,x}+1\right )}-\frac {\ln \left (a-b+a\,{\mathrm {e}}^{2\,x}+b\,{\mathrm {e}}^{2\,x}\right )\,{\left (a+b\right )}^3\,{\left (a-b\right )}^3}{b^7}-\frac {32}{3\,b\,\left (6\,{\mathrm {e}}^{2\,x}+15\,{\mathrm {e}}^{4\,x}+20\,{\mathrm {e}}^{6\,x}+15\,{\mathrm {e}}^{8\,x}+6\,{\mathrm {e}}^{10\,x}+{\mathrm {e}}^{12\,x}+1\right )}-\frac {8\,\left (a-b\right )\,\left (a^2-2\,a\,b+b^2\right )}{3\,b^4\,\left (3\,{\mathrm {e}}^{2\,x}+3\,{\mathrm {e}}^{4\,x}+{\mathrm {e}}^{6\,x}+1\right )}-\frac {2\,{\left (a+b\right )}^2\,\left (a-b\right )\,\left (a^2-2\,a\,b+b^2\right )}{b^6\,\left ({\mathrm {e}}^{2\,x}+1\right )}-\frac {2\,\left (a+b\right )\,\left (a-b\right )\,\left (a^2-2\,a\,b+b^2\right )}{b^5\,\left (2\,{\mathrm {e}}^{2\,x}+{\mathrm {e}}^{4\,x}+1\right )} \]

[In]

int(1/(cosh(x)^8*(a + b*tanh(x))),x)

[Out]

(log(exp(2*x) + 1)*(a + b)^3*(a - b)^3)/b^7 - (32*(a - 5*b))/(5*b^2*(5*exp(2*x) + 10*exp(4*x) + 10*exp(6*x) +
5*exp(8*x) + exp(10*x) + 1)) - (4*(a^2 - 4*a*b + 7*b^2))/(b^3*(4*exp(2*x) + 6*exp(4*x) + 4*exp(6*x) + exp(8*x)
 + 1)) - (log(a - b + a*exp(2*x) + b*exp(2*x))*(a + b)^3*(a - b)^3)/b^7 - 32/(3*b*(6*exp(2*x) + 15*exp(4*x) +
20*exp(6*x) + 15*exp(8*x) + 6*exp(10*x) + exp(12*x) + 1)) - (8*(a - b)*(a^2 - 2*a*b + b^2))/(3*b^4*(3*exp(2*x)
 + 3*exp(4*x) + exp(6*x) + 1)) - (2*(a + b)^2*(a - b)*(a^2 - 2*a*b + b^2))/(b^6*(exp(2*x) + 1)) - (2*(a + b)*(
a - b)*(a^2 - 2*a*b + b^2))/(b^5*(2*exp(2*x) + exp(4*x) + 1))