3.116 \(\int \frac{A+B \sinh (x)}{(i+\sinh (x))^2} \, dx\)

Optimal. Leaf size=43 \[ -\frac{(A+2 i B) \cosh (x)}{3 (\sinh (x)+i)}-\frac{(B+i A) \cosh (x)}{3 (\sinh (x)+i)^2} \]

[Out]

-((I*A + B)*Cosh[x])/(3*(I + Sinh[x])^2) - ((A + (2*I)*B)*Cosh[x])/(3*(I + Sinh[x]))

________________________________________________________________________________________

Rubi [A]  time = 0.0422746, antiderivative size = 43, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 15, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.133, Rules used = {2750, 2648} \[ -\frac{(A+2 i B) \cosh (x)}{3 (\sinh (x)+i)}-\frac{(B+i A) \cosh (x)}{3 (\sinh (x)+i)^2} \]

Antiderivative was successfully verified.

[In]

Int[(A + B*Sinh[x])/(I + Sinh[x])^2,x]

[Out]

-((I*A + B)*Cosh[x])/(3*(I + Sinh[x])^2) - ((A + (2*I)*B)*Cosh[x])/(3*(I + Sinh[x]))

Rule 2750

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[((b
*c - a*d)*Cos[e + f*x]*(a + b*Sin[e + f*x])^m)/(a*f*(2*m + 1)), x] + Dist[(a*d*m + b*c*(m + 1))/(a*b*(2*m + 1)
), Int[(a + b*Sin[e + f*x])^(m + 1), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 -
b^2, 0] && LtQ[m, -2^(-1)]

Rule 2648

Int[((a_) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> -Simp[Cos[c + d*x]/(d*(b + a*Sin[c + d*x])), x]
/; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0]

Rubi steps

\begin{align*} \int \frac{A+B \sinh (x)}{(i+\sinh (x))^2} \, dx &=-\frac{(i A+B) \cosh (x)}{3 (i+\sinh (x))^2}+\frac{1}{3} (-i A+2 B) \int \frac{1}{i+\sinh (x)} \, dx\\ &=-\frac{(i A+B) \cosh (x)}{3 (i+\sinh (x))^2}-\frac{(A+2 i B) \cosh (x)}{3 (i+\sinh (x))}\\ \end{align*}

Mathematica [A]  time = 0.030382, size = 32, normalized size = 0.74 \[ \frac{\cosh (x) (-(A+2 i B) \sinh (x)-2 i A+B)}{3 (\sinh (x)+i)^2} \]

Antiderivative was successfully verified.

[In]

Integrate[(A + B*Sinh[x])/(I + Sinh[x])^2,x]

[Out]

(Cosh[x]*((-2*I)*A + B - (A + (2*I)*B)*Sinh[x]))/(3*(I + Sinh[x])^2)

________________________________________________________________________________________

Maple [A]  time = 0.024, size = 52, normalized size = 1.2 \begin{align*} -2\,{\frac{A}{\tanh \left ( x/2 \right ) +i}}-{(-2\,iA-2\,B) \left ( \tanh \left ({\frac{x}{2}} \right ) +i \right ) ^{-2}}-{\frac{4\,iB-4\,A}{3} \left ( \tanh \left ({\frac{x}{2}} \right ) +i \right ) ^{-3}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((A+B*sinh(x))/(I+sinh(x))^2,x)

[Out]

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

________________________________________________________________________________________

Maxima [B]  time = 1.16712, size = 190, normalized size = 4.42 \begin{align*} -2 \, A{\left (\frac{3 \, e^{\left (-x\right )}}{9 \, e^{\left (-x\right )} + 9 i \, e^{\left (-2 \, x\right )} - 3 \, e^{\left (-3 \, x\right )} - 3 i} - \frac{i}{9 \, e^{\left (-x\right )} + 9 i \, e^{\left (-2 \, x\right )} - 3 \, e^{\left (-3 \, x\right )} - 3 i}\right )} + \frac{1}{2} \, B{\left (-\frac{12 i \, e^{\left (-x\right )}}{9 \, e^{\left (-x\right )} + 9 i \, e^{\left (-2 \, x\right )} - 3 \, e^{\left (-3 \, x\right )} - 3 i} + \frac{12 \, e^{\left (-2 \, x\right )}}{9 \, e^{\left (-x\right )} + 9 i \, e^{\left (-2 \, x\right )} - 3 \, e^{\left (-3 \, x\right )} - 3 i} - \frac{8}{9 \, e^{\left (-x\right )} + 9 i \, e^{\left (-2 \, x\right )} - 3 \, e^{\left (-3 \, x\right )} - 3 i}\right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*sinh(x))/(I+sinh(x))^2,x, algorithm="maxima")

[Out]

-2*A*(3*e^(-x)/(9*e^(-x) + 9*I*e^(-2*x) - 3*e^(-3*x) - 3*I) - I/(9*e^(-x) + 9*I*e^(-2*x) - 3*e^(-3*x) - 3*I))
+ 1/2*B*(-12*I*e^(-x)/(9*e^(-x) + 9*I*e^(-2*x) - 3*e^(-3*x) - 3*I) + 12*e^(-2*x)/(9*e^(-x) + 9*I*e^(-2*x) - 3*
e^(-3*x) - 3*I) - 8/(9*e^(-x) + 9*I*e^(-2*x) - 3*e^(-3*x) - 3*I))

________________________________________________________________________________________

Fricas [A]  time = 1.70625, size = 119, normalized size = 2.77 \begin{align*} -\frac{6 \, B e^{\left (2 \, x\right )} + 6 \,{\left (A + i \, B\right )} e^{x} + 2 i \, A - 4 \, B}{3 \, e^{\left (3 \, x\right )} + 9 i \, e^{\left (2 \, x\right )} - 9 \, e^{x} - 3 i} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*sinh(x))/(I+sinh(x))^2,x, algorithm="fricas")

[Out]

-(6*B*e^(2*x) + 6*(A + I*B)*e^x + 2*I*A - 4*B)/(3*e^(3*x) + 9*I*e^(2*x) - 9*e^x - 3*I)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*sinh(x))/(I+sinh(x))**2,x)

[Out]

Timed out

________________________________________________________________________________________

Giac [A]  time = 1.26339, size = 43, normalized size = 1. \begin{align*} -\frac{6 \, B e^{\left (2 \, x\right )} + 6 \, A e^{x} + 6 i \, B e^{x} + 2 i \, A - 4 \, B}{3 \,{\left (e^{x} + i\right )}^{3}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*sinh(x))/(I+sinh(x))^2,x, algorithm="giac")

[Out]

-1/3*(6*B*e^(2*x) + 6*A*e^x + 6*I*B*e^x + 2*I*A - 4*B)/(e^x + I)^3