\(\int e^x \text {sech}(2 x) \tanh ^2(2 x) \, dx\) [89]

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

Optimal result

Integrand size = 14, antiderivative size = 105 \[ \int e^x \text {sech}(2 x) \tanh ^2(2 x) \, dx=\frac {e^{3 x}}{\left (1+e^{4 x}\right )^2}-\frac {3 e^{3 x}}{4 \left (1+e^{4 x}\right )}-\frac {5 \arctan \left (1-\sqrt {2} e^x\right )}{8 \sqrt {2}}+\frac {5 \arctan \left (1+\sqrt {2} e^x\right )}{8 \sqrt {2}}-\frac {5 \text {arctanh}\left (\frac {\sqrt {2} e^x}{1+e^{2 x}}\right )}{8 \sqrt {2}} \] Output:

exp(3*x)/(1+exp(4*x))^2-3*exp(3*x)/(4+4*exp(4*x))+5/16*arctan(-1+2^(1/2)*e 
xp(x))*2^(1/2)+5/16*arctan(1+2^(1/2)*exp(x))*2^(1/2)-5/16*arctanh(2^(1/2)* 
exp(x)/(1+exp(2*x)))*2^(1/2)
 

Mathematica [C] (verified)

Result contains higher order function than in optimal. Order 9 vs. order 3 in optimal.

Time = 0.05 (sec) , antiderivative size = 58, normalized size of antiderivative = 0.55 \[ \int e^x \text {sech}(2 x) \tanh ^2(2 x) \, dx=\frac {e^{3 x}-3 e^{7 x}}{4 \left (1+e^{4 x}\right )^2}-\frac {5}{16} \text {RootSum}\left [1+\text {$\#$1}^4\&,\frac {x-\log \left (e^x-\text {$\#$1}\right )}{\text {$\#$1}}\&\right ] \] Input:

Integrate[E^x*Sech[2*x]*Tanh[2*x]^2,x]
 

Output:

(E^(3*x) - 3*E^(7*x))/(4*(1 + E^(4*x))^2) - (5*RootSum[1 + #1^4 & , (x - L 
og[E^x - #1])/#1 & ])/16
 

Rubi [A] (verified)

Time = 0.37 (sec) , antiderivative size = 150, normalized size of antiderivative = 1.43, number of steps used = 14, number of rules used = 13, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.929, Rules used = {2720, 27, 963, 27, 957, 826, 1476, 1082, 217, 1479, 25, 27, 1103}

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 e^x \tanh ^2(2 x) \text {sech}(2 x) \, dx\)

\(\Big \downarrow \) 2720

\(\displaystyle \int \frac {2 e^{2 x} \left (1-e^{4 x}\right )^2}{\left (e^{4 x}+1\right )^3}de^x\)

\(\Big \downarrow \) 27

\(\displaystyle 2 \int \frac {e^{2 x} \left (1-e^{4 x}\right )^2}{\left (1+e^{4 x}\right )^3}de^x\)

\(\Big \downarrow \) 963

\(\displaystyle 2 \left (\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}-\frac {1}{8} \int \frac {4 e^{2 x} \left (1-2 e^{4 x}\right )}{\left (1+e^{4 x}\right )^2}de^x\right )\)

\(\Big \downarrow \) 27

\(\displaystyle 2 \left (\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}-\frac {1}{2} \int \frac {e^{2 x} \left (1-2 e^{4 x}\right )}{\left (1+e^{4 x}\right )^2}de^x\right )\)

\(\Big \downarrow \) 957

\(\displaystyle 2 \left (\frac {1}{2} \left (\frac {5}{4} \int \frac {e^{2 x}}{1+e^{4 x}}de^x-\frac {3 e^{3 x}}{4 \left (e^{4 x}+1\right )}\right )+\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}\right )\)

\(\Big \downarrow \) 826

\(\displaystyle 2 \left (\frac {1}{2} \left (\frac {5}{4} \left (\frac {1}{2} \int \frac {1+e^{2 x}}{1+e^{4 x}}de^x-\frac {1}{2} \int \frac {1-e^{2 x}}{1+e^{4 x}}de^x\right )-\frac {3 e^{3 x}}{4 \left (e^{4 x}+1\right )}\right )+\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}\right )\)

\(\Big \downarrow \) 1476

\(\displaystyle 2 \left (\frac {1}{2} \left (\frac {5}{4} \left (\frac {1}{2} \left (\frac {1}{2} \int \frac {1}{1-\sqrt {2} e^x+e^{2 x}}de^x+\frac {1}{2} \int \frac {1}{1+\sqrt {2} e^x+e^{2 x}}de^x\right )-\frac {1}{2} \int \frac {1-e^{2 x}}{1+e^{4 x}}de^x\right )-\frac {3 e^{3 x}}{4 \left (e^{4 x}+1\right )}\right )+\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}\right )\)

\(\Big \downarrow \) 1082

\(\displaystyle 2 \left (\frac {1}{2} \left (\frac {5}{4} \left (\frac {1}{2} \left (\frac {\int \frac {1}{-1-e^{2 x}}d\left (1-\sqrt {2} e^x\right )}{\sqrt {2}}-\frac {\int \frac {1}{-1-e^{2 x}}d\left (1+\sqrt {2} e^x\right )}{\sqrt {2}}\right )-\frac {1}{2} \int \frac {1-e^{2 x}}{1+e^{4 x}}de^x\right )-\frac {3 e^{3 x}}{4 \left (e^{4 x}+1\right )}\right )+\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}\right )\)

\(\Big \downarrow \) 217

\(\displaystyle 2 \left (\frac {1}{2} \left (\frac {5}{4} \left (\frac {1}{2} \left (\frac {\arctan \left (\sqrt {2} e^x+1\right )}{\sqrt {2}}-\frac {\arctan \left (1-\sqrt {2} e^x\right )}{\sqrt {2}}\right )-\frac {1}{2} \int \frac {1-e^{2 x}}{1+e^{4 x}}de^x\right )-\frac {3 e^{3 x}}{4 \left (e^{4 x}+1\right )}\right )+\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}\right )\)

\(\Big \downarrow \) 1479

\(\displaystyle 2 \left (\frac {1}{2} \left (\frac {5}{4} \left (\frac {1}{2} \left (\frac {\int -\frac {\sqrt {2}-2 e^x}{1-\sqrt {2} e^x+e^{2 x}}de^x}{2 \sqrt {2}}+\frac {\int -\frac {\sqrt {2} \left (1+\sqrt {2} e^x\right )}{1+\sqrt {2} e^x+e^{2 x}}de^x}{2 \sqrt {2}}\right )+\frac {1}{2} \left (\frac {\arctan \left (\sqrt {2} e^x+1\right )}{\sqrt {2}}-\frac {\arctan \left (1-\sqrt {2} e^x\right )}{\sqrt {2}}\right )\right )-\frac {3 e^{3 x}}{4 \left (e^{4 x}+1\right )}\right )+\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}\right )\)

\(\Big \downarrow \) 25

\(\displaystyle 2 \left (\frac {1}{2} \left (\frac {5}{4} \left (\frac {1}{2} \left (-\frac {\int \frac {\sqrt {2}-2 e^x}{1-\sqrt {2} e^x+e^{2 x}}de^x}{2 \sqrt {2}}-\frac {\int \frac {\sqrt {2} \left (1+\sqrt {2} e^x\right )}{1+\sqrt {2} e^x+e^{2 x}}de^x}{2 \sqrt {2}}\right )+\frac {1}{2} \left (\frac {\arctan \left (\sqrt {2} e^x+1\right )}{\sqrt {2}}-\frac {\arctan \left (1-\sqrt {2} e^x\right )}{\sqrt {2}}\right )\right )-\frac {3 e^{3 x}}{4 \left (e^{4 x}+1\right )}\right )+\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}\right )\)

\(\Big \downarrow \) 27

\(\displaystyle 2 \left (\frac {1}{2} \left (\frac {5}{4} \left (\frac {1}{2} \left (-\frac {\int \frac {\sqrt {2}-2 e^x}{1-\sqrt {2} e^x+e^{2 x}}de^x}{2 \sqrt {2}}-\frac {1}{2} \int \frac {1+\sqrt {2} e^x}{1+\sqrt {2} e^x+e^{2 x}}de^x\right )+\frac {1}{2} \left (\frac {\arctan \left (\sqrt {2} e^x+1\right )}{\sqrt {2}}-\frac {\arctan \left (1-\sqrt {2} e^x\right )}{\sqrt {2}}\right )\right )-\frac {3 e^{3 x}}{4 \left (e^{4 x}+1\right )}\right )+\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}\right )\)

\(\Big \downarrow \) 1103

\(\displaystyle 2 \left (\frac {1}{2} \left (\frac {5}{4} \left (\frac {1}{2} \left (\frac {\arctan \left (\sqrt {2} e^x+1\right )}{\sqrt {2}}-\frac {\arctan \left (1-\sqrt {2} e^x\right )}{\sqrt {2}}\right )+\frac {1}{2} \left (\frac {\log \left (-\sqrt {2} e^x+e^{2 x}+1\right )}{2 \sqrt {2}}-\frac {\log \left (\sqrt {2} e^x+e^{2 x}+1\right )}{2 \sqrt {2}}\right )\right )-\frac {3 e^{3 x}}{4 \left (e^{4 x}+1\right )}\right )+\frac {e^{3 x}}{2 \left (e^{4 x}+1\right )^2}\right )\)

Input:

Int[E^x*Sech[2*x]*Tanh[2*x]^2,x]
 

Output:

2*(E^(3*x)/(2*(1 + E^(4*x))^2) + ((-3*E^(3*x))/(4*(1 + E^(4*x))) + (5*((-( 
ArcTan[1 - Sqrt[2]*E^x]/Sqrt[2]) + ArcTan[1 + Sqrt[2]*E^x]/Sqrt[2])/2 + (L 
og[1 - Sqrt[2]*E^x + E^(2*x)]/(2*Sqrt[2]) - Log[1 + Sqrt[2]*E^x + E^(2*x)] 
/(2*Sqrt[2]))/2))/4)/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 217
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(-(Rt[-a, 2]*Rt[-b, 2])^( 
-1))*ArcTan[Rt[-b, 2]*(x/Rt[-a, 2])], x] /; FreeQ[{a, b}, x] && PosQ[a/b] & 
& (LtQ[a, 0] || LtQ[b, 0])
 

rule 826
Int[(x_)^2/((a_) + (b_.)*(x_)^4), x_Symbol] :> With[{r = Numerator[Rt[a/b, 
2]], s = Denominator[Rt[a/b, 2]]}, Simp[1/(2*s)   Int[(r + s*x^2)/(a + b*x^ 
4), x], x] - Simp[1/(2*s)   Int[(r - s*x^2)/(a + b*x^4), x], x]] /; FreeQ[{ 
a, b}, x] && (GtQ[a/b, 0] || (PosQ[a/b] && AtomQ[SplitProduct[SumBaseQ, a]] 
 && AtomQ[SplitProduct[SumBaseQ, b]]))
 

rule 957
Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.)*((c_) + (d_.)*(x_)^(n 
_)), x_Symbol] :> Simp[(-(b*c - a*d))*(e*x)^(m + 1)*((a + b*x^n)^(p + 1)/(a 
*b*e*n*(p + 1))), x] - Simp[(a*d*(m + 1) - b*c*(m + n*(p + 1) + 1))/(a*b*n* 
(p + 1))   Int[(e*x)^m*(a + b*x^n)^(p + 1), x], x] /; FreeQ[{a, b, c, d, e, 
 m, n}, x] && NeQ[b*c - a*d, 0] && LtQ[p, -1] && (( !IntegerQ[p + 1/2] && N 
eQ[p, -5/4]) ||  !RationalQ[m] || (IGtQ[n, 0] && ILtQ[p + 1/2, 0] && LeQ[-1 
, m, (-n)*(p + 1)]))
 

rule 963
Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_)*((c_) + (d_.)*(x_)^(n_ 
))^2, x_Symbol] :> Simp[(-(b*c - a*d)^2)*(e*x)^(m + 1)*((a + b*x^n)^(p + 1) 
/(a*b^2*e*n*(p + 1))), x] + Simp[1/(a*b^2*n*(p + 1))   Int[(e*x)^m*(a + b*x 
^n)^(p + 1)*Simp[(b*c - a*d)^2*(m + 1) + b^2*c^2*n*(p + 1) + a*b*d^2*n*(p + 
 1)*x^n, x], x], x] /; FreeQ[{a, b, c, d, e, m, n}, x] && NeQ[b*c - a*d, 0] 
 && IGtQ[n, 0] && LtQ[p, -1]
 

rule 1082
Int[((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(-1), x_Symbol] :> With[{q = 1 - 4*S 
implify[a*(c/b^2)]}, Simp[-2/b   Subst[Int[1/(q - x^2), x], x, 1 + 2*c*(x/b 
)], x] /; RationalQ[q] && (EqQ[q^2, 1] ||  !RationalQ[b^2 - 4*a*c])] /; Fre 
eQ[{a, b, c}, x]
 

rule 1103
Int[((d_) + (e_.)*(x_))/((a_.) + (b_.)*(x_) + (c_.)*(x_)^2), x_Symbol] :> S 
imp[d*(Log[RemoveContent[a + b*x + c*x^2, x]]/b), x] /; FreeQ[{a, b, c, d, 
e}, x] && EqQ[2*c*d - b*e, 0]
 

rule 1476
Int[((d_) + (e_.)*(x_)^2)/((a_) + (c_.)*(x_)^4), x_Symbol] :> With[{q = Rt[ 
2*(d/e), 2]}, Simp[e/(2*c)   Int[1/Simp[d/e + q*x + x^2, x], x], x] + Simp[ 
e/(2*c)   Int[1/Simp[d/e - q*x + x^2, x], x], x]] /; FreeQ[{a, c, d, e}, x] 
 && EqQ[c*d^2 - a*e^2, 0] && PosQ[d*e]
 

rule 1479
Int[((d_) + (e_.)*(x_)^2)/((a_) + (c_.)*(x_)^4), x_Symbol] :> With[{q = Rt[ 
-2*(d/e), 2]}, Simp[e/(2*c*q)   Int[(q - 2*x)/Simp[d/e + q*x - x^2, x], x], 
 x] + Simp[e/(2*c*q)   Int[(q + 2*x)/Simp[d/e - q*x - x^2, x], x], x]] /; F 
reeQ[{a, c, d, e}, x] && EqQ[c*d^2 - a*e^2, 0] && NegQ[d*e]
 

rule 2720
Int[u_, x_Symbol] :> With[{v = FunctionOfExponential[u, x]}, Simp[v/D[v, x] 
   Subst[Int[FunctionOfExponentialFunction[u, x]/x, x], x, v], x]] /; Funct 
ionOfExponentialQ[u, x] &&  !MatchQ[u, (w_)*((a_.)*(v_)^(n_))^(m_) /; FreeQ 
[{a, m, n}, x] && IntegerQ[m*n]] &&  !MatchQ[u, E^((c_.)*((a_.) + (b_.)*x)) 
*(F_)[v_] /; FreeQ[{a, b, c}, x] && InverseFunctionQ[F[x]]]
 
Maple [C] (verified)

Result contains higher order function than in optimal. Order 9 vs. order 3.

Time = 2.36 (sec) , antiderivative size = 48, normalized size of antiderivative = 0.46

method result size
risch \(-\frac {{\mathrm e}^{3 x} \left (3 \,{\mathrm e}^{4 x}-1\right )}{4 \left ({\mathrm e}^{4 x}+1\right )^{2}}+2 \left (\munderset {\textit {\_R} =\operatorname {RootOf}\left (1048576 \textit {\_Z}^{4}+625\right )}{\sum }\textit {\_R} \ln \left ({\mathrm e}^{x}+\frac {32768 \textit {\_R}^{3}}{125}\right )\right )\) \(48\)
default \(\frac {\frac {5 \tanh \left (\frac {x}{2}\right )^{7}}{4}+\frac {5 \tanh \left (\frac {x}{2}\right )^{6}}{4}+\frac {9 \tanh \left (\frac {x}{2}\right )^{5}}{4}-\frac {19 \tanh \left (\frac {x}{2}\right )^{4}}{4}-\frac {9 \tanh \left (\frac {x}{2}\right )^{3}}{4}-\frac {17 \tanh \left (\frac {x}{2}\right )^{2}}{4}-\frac {5 \tanh \left (\frac {x}{2}\right )}{4}-\frac {1}{4}}{\left (\tanh \left (\frac {x}{2}\right )^{4}+6 \tanh \left (\frac {x}{2}\right )^{2}+1\right )^{2}}+\frac {5 \sqrt {2}\, \ln \left (\tanh \left (\frac {x}{2}\right )^{2}+3-2 \sqrt {2}\right )}{32}-\frac {5 \left (\sqrt {2}-2\right ) \arctan \left (\frac {2 \tanh \left (\frac {x}{2}\right )}{2 \sqrt {2}-2}\right )}{8 \left (2 \sqrt {2}-2\right )}-\frac {5 \sqrt {2}\, \ln \left (\tanh \left (\frac {x}{2}\right )^{2}+3+2 \sqrt {2}\right )}{32}+\frac {5 \left (2+\sqrt {2}\right ) \arctan \left (\frac {2 \tanh \left (\frac {x}{2}\right )}{2+2 \sqrt {2}}\right )}{8 \left (2+2 \sqrt {2}\right )}\) \(180\)

Input:

int(exp(x)*sech(2*x)*tanh(2*x)^2,x,method=_RETURNVERBOSE)
 

Output:

-1/4*exp(x)^3*(3*exp(x)^4-1)/(exp(x)^4+1)^2+2*sum(_R*ln(exp(x)+32768/125*_ 
R^3),_R=RootOf(1048576*_Z^4+625))
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 893 vs. \(2 (76) = 152\).

Time = 0.12 (sec) , antiderivative size = 893, normalized size of antiderivative = 8.50 \[ \int e^x \text {sech}(2 x) \tanh ^2(2 x) \, dx=\text {Too large to display} \] Input:

integrate(exp(x)*sech(2*x)*tanh(2*x)^2,x, algorithm="fricas")
 

Output:

-1/32*(24*cosh(x)^7 + 840*cosh(x)^3*sinh(x)^4 + 504*cosh(x)^2*sinh(x)^5 + 
168*cosh(x)*sinh(x)^6 + 24*sinh(x)^7 + 8*(105*cosh(x)^4 - 1)*sinh(x)^3 - 8 
*cosh(x)^3 + 24*(21*cosh(x)^5 - cosh(x))*sinh(x)^2 - 10*(sqrt(2)*cosh(x)^8 
 + 56*sqrt(2)*cosh(x)^3*sinh(x)^5 + 28*sqrt(2)*cosh(x)^2*sinh(x)^6 + 8*sqr 
t(2)*cosh(x)*sinh(x)^7 + sqrt(2)*sinh(x)^8 + 2*(35*sqrt(2)*cosh(x)^4 + sqr 
t(2))*sinh(x)^4 + 2*sqrt(2)*cosh(x)^4 + 8*(7*sqrt(2)*cosh(x)^5 + sqrt(2)*c 
osh(x))*sinh(x)^3 + 4*(7*sqrt(2)*cosh(x)^6 + 3*sqrt(2)*cosh(x)^2)*sinh(x)^ 
2 + 8*(sqrt(2)*cosh(x)^7 + sqrt(2)*cosh(x)^3)*sinh(x) + sqrt(2))*arctan(sq 
rt(2)*cosh(x) + sqrt(2)*sinh(x) + 1) - 10*(sqrt(2)*cosh(x)^8 + 56*sqrt(2)* 
cosh(x)^3*sinh(x)^5 + 28*sqrt(2)*cosh(x)^2*sinh(x)^6 + 8*sqrt(2)*cosh(x)*s 
inh(x)^7 + sqrt(2)*sinh(x)^8 + 2*(35*sqrt(2)*cosh(x)^4 + sqrt(2))*sinh(x)^ 
4 + 2*sqrt(2)*cosh(x)^4 + 8*(7*sqrt(2)*cosh(x)^5 + sqrt(2)*cosh(x))*sinh(x 
)^3 + 4*(7*sqrt(2)*cosh(x)^6 + 3*sqrt(2)*cosh(x)^2)*sinh(x)^2 + 8*(sqrt(2) 
*cosh(x)^7 + sqrt(2)*cosh(x)^3)*sinh(x) + sqrt(2))*arctan(sqrt(2)*cosh(x) 
+ sqrt(2)*sinh(x) - 1) + 5*(sqrt(2)*cosh(x)^8 + 56*sqrt(2)*cosh(x)^3*sinh( 
x)^5 + 28*sqrt(2)*cosh(x)^2*sinh(x)^6 + 8*sqrt(2)*cosh(x)*sinh(x)^7 + sqrt 
(2)*sinh(x)^8 + 2*(35*sqrt(2)*cosh(x)^4 + sqrt(2))*sinh(x)^4 + 2*sqrt(2)*c 
osh(x)^4 + 8*(7*sqrt(2)*cosh(x)^5 + sqrt(2)*cosh(x))*sinh(x)^3 + 4*(7*sqrt 
(2)*cosh(x)^6 + 3*sqrt(2)*cosh(x)^2)*sinh(x)^2 + 8*(sqrt(2)*cosh(x)^7 + sq 
rt(2)*cosh(x)^3)*sinh(x) + sqrt(2))*log((sqrt(2) + 2*cosh(x))/(cosh(x) ...
 

Sympy [F]

\[ \int e^x \text {sech}(2 x) \tanh ^2(2 x) \, dx=\int e^{x} \tanh ^{2}{\left (2 x \right )} \operatorname {sech}{\left (2 x \right )}\, dx \] Input:

integrate(exp(x)*sech(2*x)*tanh(2*x)**2,x)
 

Output:

Integral(exp(x)*tanh(2*x)**2*sech(2*x), x)
 

Maxima [A] (verification not implemented)

Time = 0.11 (sec) , antiderivative size = 105, normalized size of antiderivative = 1.00 \[ \int e^x \text {sech}(2 x) \tanh ^2(2 x) \, dx=\frac {5}{16} \, \sqrt {2} \arctan \left (\frac {1}{2} \, \sqrt {2} {\left (\sqrt {2} + 2 \, e^{x}\right )}\right ) + \frac {5}{16} \, \sqrt {2} \arctan \left (-\frac {1}{2} \, \sqrt {2} {\left (\sqrt {2} - 2 \, e^{x}\right )}\right ) - \frac {5}{32} \, \sqrt {2} \log \left (\sqrt {2} e^{x} + e^{\left (2 \, x\right )} + 1\right ) + \frac {5}{32} \, \sqrt {2} \log \left (-\sqrt {2} e^{x} + e^{\left (2 \, x\right )} + 1\right ) - \frac {3 \, e^{\left (7 \, x\right )} - e^{\left (3 \, x\right )}}{4 \, {\left (e^{\left (8 \, x\right )} + 2 \, e^{\left (4 \, x\right )} + 1\right )}} \] Input:

integrate(exp(x)*sech(2*x)*tanh(2*x)^2,x, algorithm="maxima")
 

Output:

5/16*sqrt(2)*arctan(1/2*sqrt(2)*(sqrt(2) + 2*e^x)) + 5/16*sqrt(2)*arctan(- 
1/2*sqrt(2)*(sqrt(2) - 2*e^x)) - 5/32*sqrt(2)*log(sqrt(2)*e^x + e^(2*x) + 
1) + 5/32*sqrt(2)*log(-sqrt(2)*e^x + e^(2*x) + 1) - 1/4*(3*e^(7*x) - e^(3* 
x))/(e^(8*x) + 2*e^(4*x) + 1)
 

Giac [A] (verification not implemented)

Time = 0.12 (sec) , antiderivative size = 99, normalized size of antiderivative = 0.94 \[ \int e^x \text {sech}(2 x) \tanh ^2(2 x) \, dx=\frac {5}{16} \, \sqrt {2} \arctan \left (\frac {1}{2} \, \sqrt {2} {\left (\sqrt {2} + 2 \, e^{x}\right )}\right ) + \frac {5}{16} \, \sqrt {2} \arctan \left (-\frac {1}{2} \, \sqrt {2} {\left (\sqrt {2} - 2 \, e^{x}\right )}\right ) - \frac {5}{32} \, \sqrt {2} \log \left (\sqrt {2} e^{x} + e^{\left (2 \, x\right )} + 1\right ) + \frac {5}{32} \, \sqrt {2} \log \left (-\sqrt {2} e^{x} + e^{\left (2 \, x\right )} + 1\right ) - \frac {3 \, e^{\left (7 \, x\right )} - e^{\left (3 \, x\right )}}{4 \, {\left (e^{\left (4 \, x\right )} + 1\right )}^{2}} \] Input:

integrate(exp(x)*sech(2*x)*tanh(2*x)^2,x, algorithm="giac")
 

Output:

5/16*sqrt(2)*arctan(1/2*sqrt(2)*(sqrt(2) + 2*e^x)) + 5/16*sqrt(2)*arctan(- 
1/2*sqrt(2)*(sqrt(2) - 2*e^x)) - 5/32*sqrt(2)*log(sqrt(2)*e^x + e^(2*x) + 
1) + 5/32*sqrt(2)*log(-sqrt(2)*e^x + e^(2*x) + 1) - 1/4*(3*e^(7*x) - e^(3* 
x))/(e^(4*x) + 1)^2
 

Mupad [B] (verification not implemented)

Time = 2.85 (sec) , antiderivative size = 112, normalized size of antiderivative = 1.07 \[ \int e^x \text {sech}(2 x) \tanh ^2(2 x) \, dx=\frac {{\mathrm {e}}^{3\,x}}{2\,{\mathrm {e}}^{4\,x}+{\mathrm {e}}^{8\,x}+1}-\frac {3\,{\mathrm {e}}^{3\,x}}{4\,\left ({\mathrm {e}}^{4\,x}+1\right )}+\sqrt {2}\,\ln \left (\frac {25}{16}+\sqrt {2}\,{\mathrm {e}}^x\,\left (-\frac {25}{32}-\frac {25}{32}{}\mathrm {i}\right )\right )\,\left (\frac {5}{32}+\frac {5}{32}{}\mathrm {i}\right )+\sqrt {2}\,\ln \left (\frac {25}{16}+\sqrt {2}\,{\mathrm {e}}^x\,\left (-\frac {25}{32}+\frac {25}{32}{}\mathrm {i}\right )\right )\,\left (\frac {5}{32}-\frac {5}{32}{}\mathrm {i}\right )+\sqrt {2}\,\ln \left (\frac {25}{16}+\sqrt {2}\,{\mathrm {e}}^x\,\left (\frac {25}{32}-\frac {25}{32}{}\mathrm {i}\right )\right )\,\left (-\frac {5}{32}+\frac {5}{32}{}\mathrm {i}\right )+\sqrt {2}\,\ln \left (\frac {25}{16}+\sqrt {2}\,{\mathrm {e}}^x\,\left (\frac {25}{32}+\frac {25}{32}{}\mathrm {i}\right )\right )\,\left (-\frac {5}{32}-\frac {5}{32}{}\mathrm {i}\right ) \] Input:

int((tanh(2*x)^2*exp(x))/cosh(2*x),x)
 

Output:

2^(1/2)*log(25/16 - 2^(1/2)*exp(x)*(25/32 + 25i/32))*(5/32 + 5i/32) + 2^(1 
/2)*log(25/16 - 2^(1/2)*exp(x)*(25/32 - 25i/32))*(5/32 - 5i/32) - 2^(1/2)* 
log(2^(1/2)*exp(x)*(25/32 - 25i/32) + 25/16)*(5/32 - 5i/32) - 2^(1/2)*log( 
2^(1/2)*exp(x)*(25/32 + 25i/32) + 25/16)*(5/32 + 5i/32) + exp(3*x)/(2*exp( 
4*x) + exp(8*x) + 1) - (3*exp(3*x))/(4*(exp(4*x) + 1))
 

Reduce [B] (verification not implemented)

Time = 0.21 (sec) , antiderivative size = 299, normalized size of antiderivative = 2.85 \[ \int e^x \text {sech}(2 x) \tanh ^2(2 x) \, dx=\frac {10 e^{8 x} \sqrt {2}\, \mathit {atan} \left (\frac {2 e^{x}-\sqrt {2}}{\sqrt {2}}\right )+20 e^{4 x} \sqrt {2}\, \mathit {atan} \left (\frac {2 e^{x}-\sqrt {2}}{\sqrt {2}}\right )+10 \sqrt {2}\, \mathit {atan} \left (\frac {2 e^{x}-\sqrt {2}}{\sqrt {2}}\right )+10 e^{8 x} \sqrt {2}\, \mathit {atan} \left (\frac {2 e^{x}+\sqrt {2}}{\sqrt {2}}\right )+20 e^{4 x} \sqrt {2}\, \mathit {atan} \left (\frac {2 e^{x}+\sqrt {2}}{\sqrt {2}}\right )+10 \sqrt {2}\, \mathit {atan} \left (\frac {2 e^{x}+\sqrt {2}}{\sqrt {2}}\right )+5 e^{8 x} \sqrt {2}\, \mathrm {log}\left (e^{2 x}-e^{x} \sqrt {2}+1\right )-5 e^{8 x} \sqrt {2}\, \mathrm {log}\left (e^{2 x}+e^{x} \sqrt {2}+1\right )-24 e^{7 x}+10 e^{4 x} \sqrt {2}\, \mathrm {log}\left (e^{2 x}-e^{x} \sqrt {2}+1\right )-10 e^{4 x} \sqrt {2}\, \mathrm {log}\left (e^{2 x}+e^{x} \sqrt {2}+1\right )+8 e^{3 x}+5 \sqrt {2}\, \mathrm {log}\left (e^{2 x}-e^{x} \sqrt {2}+1\right )-5 \sqrt {2}\, \mathrm {log}\left (e^{2 x}+e^{x} \sqrt {2}+1\right )}{32 e^{8 x}+64 e^{4 x}+32} \] Input:

int(exp(x)*sech(2*x)*tanh(2*x)^2,x)
 

Output:

(10*e**(8*x)*sqrt(2)*atan((2*e**x - sqrt(2))/sqrt(2)) + 20*e**(4*x)*sqrt(2 
)*atan((2*e**x - sqrt(2))/sqrt(2)) + 10*sqrt(2)*atan((2*e**x - sqrt(2))/sq 
rt(2)) + 10*e**(8*x)*sqrt(2)*atan((2*e**x + sqrt(2))/sqrt(2)) + 20*e**(4*x 
)*sqrt(2)*atan((2*e**x + sqrt(2))/sqrt(2)) + 10*sqrt(2)*atan((2*e**x + sqr 
t(2))/sqrt(2)) + 5*e**(8*x)*sqrt(2)*log(e**(2*x) - e**x*sqrt(2) + 1) - 5*e 
**(8*x)*sqrt(2)*log(e**(2*x) + e**x*sqrt(2) + 1) - 24*e**(7*x) + 10*e**(4* 
x)*sqrt(2)*log(e**(2*x) - e**x*sqrt(2) + 1) - 10*e**(4*x)*sqrt(2)*log(e**( 
2*x) + e**x*sqrt(2) + 1) + 8*e**(3*x) + 5*sqrt(2)*log(e**(2*x) - e**x*sqrt 
(2) + 1) - 5*sqrt(2)*log(e**(2*x) + e**x*sqrt(2) + 1))/(32*(e**(8*x) + 2*e 
**(4*x) + 1))