\(\int \text {sech}(x) \, dx\) [574]

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

Optimal result

Integrand size = 2, antiderivative size = 3 \[ \int \text {sech}(x) \, dx=\arctan (\sinh (x)) \]

[Out]

arctan(sinh(x))

Rubi [A] (verified)

Time = 0.00 (sec) , antiderivative size = 3, normalized size of antiderivative = 1.00, number of steps used = 1, number of rules used = 1, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.500, Rules used = {3855} \[ \int \text {sech}(x) \, dx=\arctan (\sinh (x)) \]

[In]

Int[Sech[x],x]

[Out]

ArcTan[Sinh[x]]

Rule 3855

Int[csc[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-ArcTanh[Cos[c + d*x]]/d, x] /; FreeQ[{c, d}, x]

Rubi steps \begin{align*} \text {integral}& = \arctan (\sinh (x)) \\ \end{align*}

Mathematica [A] (verified)

Time = 0.00 (sec) , antiderivative size = 3, normalized size of antiderivative = 1.00 \[ \int \text {sech}(x) \, dx=\arctan (\sinh (x)) \]

[In]

Integrate[Sech[x],x]

[Out]

ArcTan[Sinh[x]]

Maple [A] (verified)

Time = 0.20 (sec) , antiderivative size = 4, normalized size of antiderivative = 1.33

method result size
lookup \(\arctan \left (\sinh \left (x \right )\right )\) \(4\)
default \(\arctan \left (\sinh \left (x \right )\right )\) \(4\)
risch \(i \ln \left ({\mathrm e}^{x}+i\right )-i \ln \left ({\mathrm e}^{x}-i\right )\) \(20\)
parallelrisch \(-i \left (\ln \left (\tanh \left (\frac {x}{2}\right )-i\right )-\ln \left (\tanh \left (\frac {x}{2}\right )+i\right )\right )\) \(23\)

[In]

int(sech(x),x,method=_RETURNVERBOSE)

[Out]

arctan(sinh(x))

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 8 vs. \(2 (3) = 6\).

Time = 0.24 (sec) , antiderivative size = 8, normalized size of antiderivative = 2.67 \[ \int \text {sech}(x) \, dx=2 \, \arctan \left (\cosh \left (x\right ) + \sinh \left (x\right )\right ) \]

[In]

integrate(sech(x),x, algorithm="fricas")

[Out]

2*arctan(cosh(x) + sinh(x))

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 7 vs. \(2 (3) = 6\).

Time = 0.18 (sec) , antiderivative size = 7, normalized size of antiderivative = 2.33 \[ \int \text {sech}(x) \, dx=2 \operatorname {atan}{\left (\tanh {\left (\frac {x}{2} \right )} \right )} \]

[In]

integrate(sech(x),x)

[Out]

2*atan(tanh(x/2))

Maxima [A] (verification not implemented)

none

Time = 0.19 (sec) , antiderivative size = 3, normalized size of antiderivative = 1.00 \[ \int \text {sech}(x) \, dx=\arctan \left (\sinh \left (x\right )\right ) \]

[In]

integrate(sech(x),x, algorithm="maxima")

[Out]

arctan(sinh(x))

Giac [A] (verification not implemented)

none

Time = 0.33 (sec) , antiderivative size = 5, normalized size of antiderivative = 1.67 \[ \int \text {sech}(x) \, dx=2 \, \arctan \left (e^{x}\right ) \]

[In]

integrate(sech(x),x, algorithm="giac")

[Out]

2*arctan(e^x)

Mupad [B] (verification not implemented)

Time = 0.02 (sec) , antiderivative size = 5, normalized size of antiderivative = 1.67 \[ \int \text {sech}(x) \, dx=2\,\mathrm {atan}\left ({\mathrm {e}}^x\right ) \]

[In]

int(1/cosh(x),x)

[Out]

2*atan(exp(x))