\(\int \frac {\sinh (x)}{i+\text {csch}(x)} \, dx\) [65]

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

Optimal result

Integrand size = 11, antiderivative size = 20 \[ \int \frac {\sinh (x)}{i+\text {csch}(x)} \, dx=x-2 i \cosh (x)-\frac {\cosh (x)}{i+\text {csch}(x)} \]

[Out]

x-2*I*cosh(x)-cosh(x)/(I+csch(x))

Rubi [A] (verified)

Time = 0.03 (sec) , antiderivative size = 20, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.364, Rules used = {3904, 3872, 2718, 8} \[ \int \frac {\sinh (x)}{i+\text {csch}(x)} \, dx=x-2 i \cosh (x)-\frac {\cosh (x)}{\text {csch}(x)+i} \]

[In]

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

[Out]

x - (2*I)*Cosh[x] - Cosh[x]/(I + Csch[x])

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rule 2718

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

Rule 3872

Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)), x_Symbol] :> Dist[a, Int[(d*
Csc[e + f*x])^n, x], x] + Dist[b/d, Int[(d*Csc[e + f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, n}, x]

Rule 3904

Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_)/(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)), x_Symbol] :> Simp[Cot[e + f*x
]*((d*Csc[e + f*x])^n/(f*(a + b*Csc[e + f*x]))), x] - Dist[1/a^2, Int[(d*Csc[e + f*x])^n*(a*(n - 1) - b*n*Csc[
e + f*x]), x], x] /; FreeQ[{a, b, d, e, f}, x] && EqQ[a^2 - b^2, 0] && LtQ[n, 0]

Rubi steps \begin{align*} \text {integral}& = -\frac {\cosh (x)}{i+\text {csch}(x)}+\int (-2 i+\text {csch}(x)) \sinh (x) \, dx \\ & = -\frac {\cosh (x)}{i+\text {csch}(x)}-2 i \int \sinh (x) \, dx+\int 1 \, dx \\ & = x-2 i \cosh (x)-\frac {\cosh (x)}{i+\text {csch}(x)} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.09 (sec) , antiderivative size = 35, normalized size of antiderivative = 1.75 \[ \int \frac {\sinh (x)}{i+\text {csch}(x)} \, dx=x-i \cosh (x)-\frac {2 \sinh \left (\frac {x}{2}\right )}{\cosh \left (\frac {x}{2}\right )+i \sinh \left (\frac {x}{2}\right )} \]

[In]

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

[Out]

x - I*Cosh[x] - (2*Sinh[x/2])/(Cosh[x/2] + I*Sinh[x/2])

Maple [A] (verified)

Time = 0.64 (sec) , antiderivative size = 25, normalized size of antiderivative = 1.25

method result size
risch \(x -\frac {i {\mathrm e}^{x}}{2}-\frac {i {\mathrm e}^{-x}}{2}-\frac {2 i}{{\mathrm e}^{x}-i}\) \(25\)
parallelrisch \(\frac {i \cosh \left (2 x \right )+\sinh \left (2 x \right )+\left (2 i x +6\right ) \sinh \left (x \right )-2 x \cosh \left (x \right )-i+2 x}{2 i \sinh \left (x \right )-2 \cosh \left (x \right )+2}\) \(46\)
default \(-\frac {2}{\tanh \left (\frac {x}{2}\right )-i}-\frac {i}{\tanh \left (\frac {x}{2}\right )+1}+\ln \left (\tanh \left (\frac {x}{2}\right )+1\right )+\frac {i}{\tanh \left (\frac {x}{2}\right )-1}-\ln \left (\tanh \left (\frac {x}{2}\right )-1\right )\) \(51\)

[In]

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

[Out]

x-1/2*I*exp(x)-1/2*I/exp(x)-2*I/(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. 39 vs. \(2 (16) = 32\).

Time = 0.26 (sec) , antiderivative size = 39, normalized size of antiderivative = 1.95 \[ \int \frac {\sinh (x)}{i+\text {csch}(x)} \, dx=\frac {{\left (2 \, x - 1\right )} e^{\left (2 \, x\right )} + {\left (-2 i \, x - 5 i\right )} e^{x} - i \, e^{\left (3 \, x\right )} - 1}{2 \, {\left (e^{\left (2 \, x\right )} - i \, e^{x}\right )}} \]

[In]

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

[Out]

1/2*((2*x - 1)*e^(2*x) + (-2*I*x - 5*I)*e^x - I*e^(3*x) - 1)/(e^(2*x) - I*e^x)

Sympy [F]

\[ \int \frac {\sinh (x)}{i+\text {csch}(x)} \, dx=\int \frac {\sinh {\left (x \right )}}{\operatorname {csch}{\left (x \right )} + i}\, dx \]

[In]

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

[Out]

Integral(sinh(x)/(csch(x) + I), x)

Maxima [A] (verification not implemented)

none

Time = 0.18 (sec) , antiderivative size = 31, normalized size of antiderivative = 1.55 \[ \int \frac {\sinh (x)}{i+\text {csch}(x)} \, dx=x - \frac {5 i \, e^{\left (-x\right )} - 1}{2 \, {\left (i \, e^{\left (-x\right )} + e^{\left (-2 \, x\right )}\right )}} - \frac {1}{2} i \, e^{\left (-x\right )} \]

[In]

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

[Out]

x - 1/2*(5*I*e^(-x) - 1)/(I*e^(-x) + e^(-2*x)) - 1/2*I*e^(-x)

Giac [A] (verification not implemented)

none

Time = 0.27 (sec) , antiderivative size = 24, normalized size of antiderivative = 1.20 \[ \int \frac {\sinh (x)}{i+\text {csch}(x)} \, dx=x + \frac {{\left (-5 i \, e^{x} - 1\right )} e^{\left (-x\right )}}{2 \, {\left (e^{x} - i\right )}} - \frac {1}{2} i \, e^{x} \]

[In]

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

[Out]

x + 1/2*(-5*I*e^x - 1)*e^(-x)/(e^x - I) - 1/2*I*e^x

Mupad [B] (verification not implemented)

Time = 2.32 (sec) , antiderivative size = 24, normalized size of antiderivative = 1.20 \[ \int \frac {\sinh (x)}{i+\text {csch}(x)} \, dx=x-\frac {{\mathrm {e}}^{-x}\,1{}\mathrm {i}}{2}-\frac {{\mathrm {e}}^x\,1{}\mathrm {i}}{2}-\frac {2{}\mathrm {i}}{{\mathrm {e}}^x-\mathrm {i}} \]

[In]

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

[Out]

x - (exp(-x)*1i)/2 - (exp(x)*1i)/2 - 2i/(exp(x) - 1i)