3.64 \(\int \frac {\sinh ^2(x)}{i+\text {csch}(x)} \, dx\)

Optimal. Leaf size=36 \[ \frac {3 i x}{2}+2 \cosh (x)-\frac {3}{2} i \sinh (x) \cosh (x)-\frac {\sinh (x) \cosh (x)}{\text {csch}(x)+i} \]

[Out]

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

________________________________________________________________________________________

Rubi [A]  time = 0.06, antiderivative size = 36, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, integrand size = 13, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.385, Rules used = {3819, 3787, 2635, 8, 2638} \[ \frac {3 i x}{2}+2 \cosh (x)-\frac {3}{2} i \sinh (x) \cosh (x)-\frac {\sinh (x) \cosh (x)}{\text {csch}(x)+i} \]

Antiderivative was successfully verified.

[In]

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

[Out]

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

Rule 8

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

Rule 2635

Int[((b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> -Simp[(b*Cos[c + d*x]*(b*Sin[c + d*x])^(n - 1))/(d*n),
x] + Dist[(b^2*(n - 1))/n, Int[(b*Sin[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1] && Integer
Q[2*n]

Rule 2638

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

Rule 3787

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 3819

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*} \int \frac {\sinh ^2(x)}{i+\text {csch}(x)} \, dx &=-\frac {\cosh (x) \sinh (x)}{i+\text {csch}(x)}+\int (-3 i+2 \text {csch}(x)) \sinh ^2(x) \, dx\\ &=-\frac {\cosh (x) \sinh (x)}{i+\text {csch}(x)}-3 i \int \sinh ^2(x) \, dx+2 \int \sinh (x) \, dx\\ &=2 \cosh (x)-\frac {3}{2} i \cosh (x) \sinh (x)-\frac {\cosh (x) \sinh (x)}{i+\text {csch}(x)}+\frac {3}{2} i \int 1 \, dx\\ &=\frac {3 i x}{2}+2 \cosh (x)-\frac {3}{2} i \cosh (x) \sinh (x)-\frac {\cosh (x) \sinh (x)}{i+\text {csch}(x)}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.13, size = 46, normalized size = 1.28 \[ \cosh (x)+\frac {1}{4} i \left (6 x-\sinh (2 x)-\frac {8 \sinh \left (\frac {x}{2}\right )}{\cosh \left (\frac {x}{2}\right )+i \sinh \left (\frac {x}{2}\right )}\right ) \]

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

fricas [B]  time = 0.41, size = 55, normalized size = 1.53 \[ \frac {{\left (12 i \, x - 4 i\right )} e^{\left (3 \, x\right )} + 4 \, {\left (3 \, x + 5\right )} e^{\left (2 \, x\right )} - i \, e^{\left (5 \, x\right )} + 3 \, e^{\left (4 \, x\right )} - 3 i \, e^{x} + 1}{8 \, e^{\left (3 \, x\right )} - 8 i \, e^{\left (2 \, x\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

giac [A]  time = 0.13, size = 40, normalized size = 1.11 \[ \frac {3}{2} i \, x + \frac {{\left (-20 i \, e^{\left (2 \, x\right )} - 3 \, e^{x} - i\right )} e^{\left (-2 \, x\right )}}{8 \, {\left (-i \, e^{x} - 1\right )}} - \frac {1}{8} i \, e^{\left (2 \, x\right )} + \frac {1}{2} \, e^{x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

maple [B]  time = 0.21, size = 96, normalized size = 2.67 \[ -\frac {3 i \ln \left (\tanh \left (\frac {x}{2}\right )-1\right )}{2}-\frac {i}{2 \left (\tanh \left (\frac {x}{2}\right )-1\right )^{2}}-\frac {1}{\tanh \left (\frac {x}{2}\right )-1}-\frac {i}{2 \left (\tanh \left (\frac {x}{2}\right )-1\right )}+\frac {i}{2 \left (\tanh \left (\frac {x}{2}\right )+1\right )^{2}}+\frac {3 i \ln \left (\tanh \left (\frac {x}{2}\right )+1\right )}{2}+\frac {1}{\tanh \left (\frac {x}{2}\right )+1}-\frac {i}{2 \left (\tanh \left (\frac {x}{2}\right )+1\right )}-\frac {2 i}{\tanh \left (\frac {x}{2}\right )-i} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sinh(x)^2/(I+csch(x)),x)

[Out]

-3/2*I*ln(tanh(1/2*x)-1)-1/2*I/(tanh(1/2*x)-1)^2-1/(tanh(1/2*x)-1)-1/2*I/(tanh(1/2*x)-1)+1/2*I/(tanh(1/2*x)+1)
^2+3/2*I*ln(tanh(1/2*x)+1)+1/(tanh(1/2*x)+1)-1/2*I/(tanh(1/2*x)+1)-2*I/(tanh(1/2*x)-I)

________________________________________________________________________________________

maxima [A]  time = 0.31, size = 47, normalized size = 1.31 \[ \frac {3}{2} i \, x + \frac {3 i \, e^{\left (-x\right )} + 20 \, e^{\left (-2 \, x\right )} + 1}{4 \, {\left (2 i \, e^{\left (-2 \, x\right )} + 2 \, e^{\left (-3 \, x\right )}\right )}} + \frac {1}{2} \, e^{\left (-x\right )} + \frac {1}{8} i \, e^{\left (-2 \, x\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

3/2*I*x + 1/4*(3*I*e^(-x) + 20*e^(-2*x) + 1)/(2*I*e^(-2*x) + 2*e^(-3*x)) + 1/2*e^(-x) + 1/8*I*e^(-2*x)

________________________________________________________________________________________

mupad [B]  time = 1.47, size = 38, normalized size = 1.06 \[ \frac {x\,3{}\mathrm {i}}{2}+\frac {{\mathrm {e}}^{-x}}{2}+\frac {{\mathrm {e}}^{-2\,x}\,1{}\mathrm {i}}{8}-\frac {{\mathrm {e}}^{2\,x}\,1{}\mathrm {i}}{8}+\frac {{\mathrm {e}}^x}{2}+\frac {2}{{\mathrm {e}}^x-\mathrm {i}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

(x*3i)/2 + exp(-x)/2 + (exp(-2*x)*1i)/8 - (exp(2*x)*1i)/8 + exp(x)/2 + 2/(exp(x) - 1i)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\sinh ^{2}{\relax (x )}}{\operatorname {csch}{\relax (x )} + i}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________