\(\int \frac {\cosh (x)}{i+\sinh (x)} \, dx\) [165]

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

Optimal result

Integrand size = 11, antiderivative size = 7 \[ \int \frac {\cosh (x)}{i+\sinh (x)} \, dx=\log (i+\sinh (x)) \]

[Out]

ln(I+sinh(x))

Rubi [A] (verified)

Time = 0.01 (sec) , antiderivative size = 7, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.182, Rules used = {2746, 31} \[ \int \frac {\cosh (x)}{i+\sinh (x)} \, dx=\log (\sinh (x)+i) \]

[In]

Int[Cosh[x]/(I + Sinh[x]),x]

[Out]

Log[I + Sinh[x]]

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rule 2746

Int[cos[(e_.) + (f_.)*(x_)]^(p_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.), x_Symbol] :> Dist[1/(b^p*f), S
ubst[Int[(a + x)^(m + (p - 1)/2)*(a - x)^((p - 1)/2), x], x, b*Sin[e + f*x]], x] /; FreeQ[{a, b, e, f, m}, x]
&& IntegerQ[(p - 1)/2] && EqQ[a^2 - b^2, 0] && (GeQ[p, -1] ||  !IntegerQ[m + 1/2])

Rubi steps \begin{align*} \text {integral}& = \text {Subst}\left (\int \frac {1}{i+x} \, dx,x,\sinh (x)\right ) \\ & = \log (i+\sinh (x)) \\ \end{align*}

Mathematica [A] (verified)

Time = 0.01 (sec) , antiderivative size = 7, normalized size of antiderivative = 1.00 \[ \int \frac {\cosh (x)}{i+\sinh (x)} \, dx=\log (i+\sinh (x)) \]

[In]

Integrate[Cosh[x]/(I + Sinh[x]),x]

[Out]

Log[I + Sinh[x]]

Maple [A] (verified)

Time = 3.33 (sec) , antiderivative size = 7, normalized size of antiderivative = 1.00

method result size
derivativedivides \(\ln \left (i+\sinh \left (x \right )\right )\) \(7\)
default \(\ln \left (i+\sinh \left (x \right )\right )\) \(7\)
risch \(-x +2 \ln \left ({\mathrm e}^{x}+i\right )\) \(13\)

[In]

int(cosh(x)/(I+sinh(x)),x,method=_RETURNVERBOSE)

[Out]

ln(I+sinh(x))

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. 11 vs. \(2 (5) = 10\).

Time = 0.28 (sec) , antiderivative size = 11, normalized size of antiderivative = 1.57 \[ \int \frac {\cosh (x)}{i+\sinh (x)} \, dx=-x + 2 \, \log \left (e^{x} + i\right ) \]

[In]

integrate(cosh(x)/(I+sinh(x)),x, algorithm="fricas")

[Out]

-x + 2*log(e^x + I)

Sympy [A] (verification not implemented)

Time = 0.04 (sec) , antiderivative size = 8, normalized size of antiderivative = 1.14 \[ \int \frac {\cosh (x)}{i+\sinh (x)} \, dx=- x + 2 \log {\left (e^{x} + i \right )} \]

[In]

integrate(cosh(x)/(I+sinh(x)),x)

[Out]

-x + 2*log(exp(x) + I)

Maxima [A] (verification not implemented)

none

Time = 0.20 (sec) , antiderivative size = 5, normalized size of antiderivative = 0.71 \[ \int \frac {\cosh (x)}{i+\sinh (x)} \, dx=\log \left (\sinh \left (x\right ) + i\right ) \]

[In]

integrate(cosh(x)/(I+sinh(x)),x, algorithm="maxima")

[Out]

log(sinh(x) + I)

Giac [B] (verification not implemented)

Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 11 vs. \(2 (5) = 10\).

Time = 0.27 (sec) , antiderivative size = 11, normalized size of antiderivative = 1.57 \[ \int \frac {\cosh (x)}{i+\sinh (x)} \, dx=-x + 2 \, \log \left (e^{x} + i\right ) \]

[In]

integrate(cosh(x)/(I+sinh(x)),x, algorithm="giac")

[Out]

-x + 2*log(e^x + I)

Mupad [B] (verification not implemented)

Time = 1.22 (sec) , antiderivative size = 10, normalized size of antiderivative = 1.43 \[ \int \frac {\cosh (x)}{i+\sinh (x)} \, dx=\ln \left (\mathrm {cosh}\left (x\right )\right )-\mathrm {atan}\left (\mathrm {sinh}\left (x\right )\right )\,1{}\mathrm {i} \]

[In]

int(cosh(x)/(sinh(x) + 1i),x)

[Out]

log(cosh(x)) - atan(sinh(x))*1i