Integrand size = 11, antiderivative size = 57 \[ \int \frac {\sinh (x)}{a+b \text {csch}(x)} \, dx=-\frac {b x}{a^2}-\frac {2 b^2 \text {arctanh}\left (\frac {a-b \tanh \left (\frac {x}{2}\right )}{\sqrt {a^2+b^2}}\right )}{a^2 \sqrt {a^2+b^2}}+\frac {\cosh (x)}{a} \]
Time = 0.29 (sec) , antiderivative size = 61, normalized size of antiderivative = 1.07 \[ \int \frac {\sinh (x)}{a+b \text {csch}(x)} \, dx=\frac {b \left (-x+\frac {2 b \arctan \left (\frac {a-b \tanh \left (\frac {x}{2}\right )}{\sqrt {-a^2-b^2}}\right )}{\sqrt {-a^2-b^2}}\right )+a \cosh (x)}{a^2} \]
(b*(-x + (2*b*ArcTan[(a - b*Tanh[x/2])/Sqrt[-a^2 - b^2]])/Sqrt[-a^2 - b^2] ) + a*Cosh[x])/a^2
Result contains complex when optimal does not.
Time = 0.38 (sec) , antiderivative size = 77, normalized size of antiderivative = 1.35, number of steps used = 12, number of rules used = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 1.000, Rules used = {3042, 26, 4340, 26, 27, 3042, 4270, 3042, 3139, 1083, 219}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {\sinh (x)}{a+b \text {csch}(x)} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int -\frac {i}{\csc (i x) (a+i b \csc (i x))}dx\) |
\(\Big \downarrow \) 26 |
\(\displaystyle -i \int \frac {1}{\csc (i x) (a+i b \csc (i x))}dx\) |
\(\Big \downarrow \) 4340 |
\(\displaystyle -i \left (\frac {\int -\frac {i b}{a+b \text {csch}(x)}dx}{a}+\frac {i \cosh (x)}{a}\right )\) |
\(\Big \downarrow \) 26 |
\(\displaystyle -i \left (\frac {i \cosh (x)}{a}-\frac {i \int \frac {b}{a+b \text {csch}(x)}dx}{a}\right )\) |
\(\Big \downarrow \) 27 |
\(\displaystyle -i \left (\frac {i \cosh (x)}{a}-\frac {i b \int \frac {1}{a+b \text {csch}(x)}dx}{a}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -i \left (\frac {i \cosh (x)}{a}-\frac {i b \int \frac {1}{a+i b \csc (i x)}dx}{a}\right )\) |
\(\Big \downarrow \) 4270 |
\(\displaystyle -i \left (\frac {i \cosh (x)}{a}-\frac {i b \left (\frac {x}{a}-\frac {\int \frac {1}{\frac {a \sinh (x)}{b}+1}dx}{a}\right )}{a}\right )\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -i \left (\frac {i \cosh (x)}{a}-\frac {i b \left (\frac {x}{a}-\frac {\int \frac {1}{1-\frac {i a \sin (i x)}{b}}dx}{a}\right )}{a}\right )\) |
\(\Big \downarrow \) 3139 |
\(\displaystyle -i \left (\frac {i \cosh (x)}{a}-\frac {i b \left (\frac {x}{a}-\frac {2 \int \frac {1}{-\tanh ^2\left (\frac {x}{2}\right )+\frac {2 a \tanh \left (\frac {x}{2}\right )}{b}+1}d\tanh \left (\frac {x}{2}\right )}{a}\right )}{a}\right )\) |
\(\Big \downarrow \) 1083 |
\(\displaystyle -i \left (\frac {i \cosh (x)}{a}-\frac {i b \left (\frac {4 \int \frac {1}{4 \left (\frac {a^2}{b^2}+1\right )-\left (\frac {2 a}{b}-2 \tanh \left (\frac {x}{2}\right )\right )^2}d\left (\frac {2 a}{b}-2 \tanh \left (\frac {x}{2}\right )\right )}{a}+\frac {x}{a}\right )}{a}\right )\) |
\(\Big \downarrow \) 219 |
\(\displaystyle -i \left (\frac {i \cosh (x)}{a}-\frac {i b \left (\frac {2 b \text {arctanh}\left (\frac {b \left (\frac {2 a}{b}-2 \tanh \left (\frac {x}{2}\right )\right )}{2 \sqrt {a^2+b^2}}\right )}{a \sqrt {a^2+b^2}}+\frac {x}{a}\right )}{a}\right )\) |
(-I)*(((-I)*b*(x/a + (2*b*ArcTanh[(b*((2*a)/b - 2*Tanh[x/2]))/(2*Sqrt[a^2 + b^2])])/(a*Sqrt[a^2 + b^2])))/a + (I*Cosh[x])/a)
3.1.79.3.1 Defintions of rubi rules used
Int[(Complex[0, a_])*(Fx_), x_Symbol] :> Simp[(Complex[Identity[0], a]) I nt[Fx, x], x] /; FreeQ[a, x] && EqQ[a^2, 1]
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))* ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && NegQ[a/b] && (Gt Q[a, 0] || LtQ[b, 0])
Int[((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(-1), x_Symbol] :> Simp[-2 Subst[I nt[1/Simp[b^2 - 4*a*c - x^2, x], x], x, b + 2*c*x], x] /; FreeQ[{a, b, c}, x]
Int[((a_) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> With[{e = Fre eFactors[Tan[(c + d*x)/2], x]}, Simp[2*(e/d) Subst[Int[1/(a + 2*b*e*x + a *e^2*x^2), x], x, Tan[(c + d*x)/2]/e], x]] /; FreeQ[{a, b, c, d}, x] && NeQ [a^2 - b^2, 0]
Int[(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_))^(-1), x_Symbol] :> Simp[x/a, x] - Simp[1/a Int[1/(1 + (a/b)*Sin[c + d*x]), x], x] /; FreeQ[{a, b, c, d}, x] && NeQ[a^2 - b^2, 0]
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/(a*f*n)), x] - Sim p[1/(a*d*n) Int[((d*Csc[e + f*x])^(n + 1)/(a + b*Csc[e + f*x]))*Simp[b*n - a*(n + 1)*Csc[e + f*x] - b*(n + 1)*Csc[e + f*x]^2, x], x], x] /; FreeQ[{a , b, d, e, f}, x] && NeQ[a^2 - b^2, 0] && LeQ[n, -1] && IntegerQ[2*n]
Time = 0.28 (sec) , antiderivative size = 92, normalized size of antiderivative = 1.61
method | result | size |
default | \(\frac {1}{a \left (\tanh \left (\frac {x}{2}\right )+1\right )}-\frac {b \ln \left (\tanh \left (\frac {x}{2}\right )+1\right )}{a^{2}}-\frac {2 b^{2} \operatorname {arctanh}\left (\frac {-2 b \tanh \left (\frac {x}{2}\right )+2 a}{2 \sqrt {a^{2}+b^{2}}}\right )}{a^{2} \sqrt {a^{2}+b^{2}}}-\frac {1}{a \left (\tanh \left (\frac {x}{2}\right )-1\right )}+\frac {b \ln \left (\tanh \left (\frac {x}{2}\right )-1\right )}{a^{2}}\) | \(92\) |
risch | \(-\frac {b x}{a^{2}}+\frac {{\mathrm e}^{x}}{2 a}+\frac {{\mathrm e}^{-x}}{2 a}+\frac {b^{2} \ln \left ({\mathrm e}^{x}+\frac {b \sqrt {a^{2}+b^{2}}-a^{2}-b^{2}}{\sqrt {a^{2}+b^{2}}\, a}\right )}{\sqrt {a^{2}+b^{2}}\, a^{2}}-\frac {b^{2} \ln \left ({\mathrm e}^{x}+\frac {b \sqrt {a^{2}+b^{2}}+a^{2}+b^{2}}{\sqrt {a^{2}+b^{2}}\, a}\right )}{\sqrt {a^{2}+b^{2}}\, a^{2}}\) | \(132\) |
1/a/(tanh(1/2*x)+1)-1/a^2*b*ln(tanh(1/2*x)+1)-2*b^2/a^2/(a^2+b^2)^(1/2)*ar ctanh(1/2*(-2*b*tanh(1/2*x)+2*a)/(a^2+b^2)^(1/2))-1/a/(tanh(1/2*x)-1)+1/a^ 2*b*ln(tanh(1/2*x)-1)
Leaf count of result is larger than twice the leaf count of optimal. 238 vs. \(2 (53) = 106\).
Time = 0.26 (sec) , antiderivative size = 238, normalized size of antiderivative = 4.18 \[ \int \frac {\sinh (x)}{a+b \text {csch}(x)} \, dx=\frac {a^{3} + a b^{2} - 2 \, {\left (a^{2} b + b^{3}\right )} x \cosh \left (x\right ) + {\left (a^{3} + a b^{2}\right )} \cosh \left (x\right )^{2} + {\left (a^{3} + a b^{2}\right )} \sinh \left (x\right )^{2} + 2 \, {\left (b^{2} \cosh \left (x\right ) + b^{2} \sinh \left (x\right )\right )} \sqrt {a^{2} + b^{2}} \log \left (\frac {a^{2} \cosh \left (x\right )^{2} + a^{2} \sinh \left (x\right )^{2} + 2 \, a b \cosh \left (x\right ) + a^{2} + 2 \, b^{2} + 2 \, {\left (a^{2} \cosh \left (x\right ) + a b\right )} \sinh \left (x\right ) - 2 \, \sqrt {a^{2} + b^{2}} {\left (a \cosh \left (x\right ) + a \sinh \left (x\right ) + b\right )}}{a \cosh \left (x\right )^{2} + a \sinh \left (x\right )^{2} + 2 \, b \cosh \left (x\right ) + 2 \, {\left (a \cosh \left (x\right ) + b\right )} \sinh \left (x\right ) - a}\right ) - 2 \, {\left ({\left (a^{2} b + b^{3}\right )} x - {\left (a^{3} + a b^{2}\right )} \cosh \left (x\right )\right )} \sinh \left (x\right )}{2 \, {\left ({\left (a^{4} + a^{2} b^{2}\right )} \cosh \left (x\right ) + {\left (a^{4} + a^{2} b^{2}\right )} \sinh \left (x\right )\right )}} \]
1/2*(a^3 + a*b^2 - 2*(a^2*b + b^3)*x*cosh(x) + (a^3 + a*b^2)*cosh(x)^2 + ( a^3 + a*b^2)*sinh(x)^2 + 2*(b^2*cosh(x) + b^2*sinh(x))*sqrt(a^2 + b^2)*log ((a^2*cosh(x)^2 + a^2*sinh(x)^2 + 2*a*b*cosh(x) + a^2 + 2*b^2 + 2*(a^2*cos h(x) + a*b)*sinh(x) - 2*sqrt(a^2 + b^2)*(a*cosh(x) + a*sinh(x) + b))/(a*co sh(x)^2 + a*sinh(x)^2 + 2*b*cosh(x) + 2*(a*cosh(x) + b)*sinh(x) - a)) - 2* ((a^2*b + b^3)*x - (a^3 + a*b^2)*cosh(x))*sinh(x))/((a^4 + a^2*b^2)*cosh(x ) + (a^4 + a^2*b^2)*sinh(x))
\[ \int \frac {\sinh (x)}{a+b \text {csch}(x)} \, dx=\int \frac {\sinh {\left (x \right )}}{a + b \operatorname {csch}{\left (x \right )}}\, dx \]
Time = 0.27 (sec) , antiderivative size = 84, normalized size of antiderivative = 1.47 \[ \int \frac {\sinh (x)}{a+b \text {csch}(x)} \, dx=\frac {b^{2} \log \left (\frac {a e^{\left (-x\right )} - b - \sqrt {a^{2} + b^{2}}}{a e^{\left (-x\right )} - b + \sqrt {a^{2} + b^{2}}}\right )}{\sqrt {a^{2} + b^{2}} a^{2}} - \frac {b x}{a^{2}} + \frac {e^{\left (-x\right )}}{2 \, a} + \frac {e^{x}}{2 \, a} \]
b^2*log((a*e^(-x) - b - sqrt(a^2 + b^2))/(a*e^(-x) - b + sqrt(a^2 + b^2))) /(sqrt(a^2 + b^2)*a^2) - b*x/a^2 + 1/2*e^(-x)/a + 1/2*e^x/a
Time = 0.29 (sec) , antiderivative size = 86, normalized size of antiderivative = 1.51 \[ \int \frac {\sinh (x)}{a+b \text {csch}(x)} \, dx=\frac {b^{2} \log \left (\frac {{\left | 2 \, a e^{x} + 2 \, b - 2 \, \sqrt {a^{2} + b^{2}} \right |}}{{\left | 2 \, a e^{x} + 2 \, b + 2 \, \sqrt {a^{2} + b^{2}} \right |}}\right )}{\sqrt {a^{2} + b^{2}} a^{2}} - \frac {b x}{a^{2}} + \frac {e^{\left (-x\right )}}{2 \, a} + \frac {e^{x}}{2 \, a} \]
b^2*log(abs(2*a*e^x + 2*b - 2*sqrt(a^2 + b^2))/abs(2*a*e^x + 2*b + 2*sqrt( a^2 + b^2)))/(sqrt(a^2 + b^2)*a^2) - b*x/a^2 + 1/2*e^(-x)/a + 1/2*e^x/a
Time = 2.36 (sec) , antiderivative size = 129, normalized size of antiderivative = 2.26 \[ \int \frac {\sinh (x)}{a+b \text {csch}(x)} \, dx=\frac {{\mathrm {e}}^{-x}}{2\,a}+\frac {{\mathrm {e}}^x}{2\,a}-\frac {b\,x}{a^2}-\frac {b^2\,\ln \left (-\frac {2\,b^2\,{\mathrm {e}}^x}{a^3}-\frac {2\,b^2\,\left (a-b\,{\mathrm {e}}^x\right )}{a^3\,\sqrt {a^2+b^2}}\right )}{a^2\,\sqrt {a^2+b^2}}+\frac {b^2\,\ln \left (\frac {2\,b^2\,\left (a-b\,{\mathrm {e}}^x\right )}{a^3\,\sqrt {a^2+b^2}}-\frac {2\,b^2\,{\mathrm {e}}^x}{a^3}\right )}{a^2\,\sqrt {a^2+b^2}} \]