3.787 \(\int \frac {\text {csch}(x)}{a+b \coth (x)+c \text {csch}(x)} \, dx\)

Optimal. Leaf size=50 \[ -\frac {2 \tanh ^{-1}\left (\frac {a+(b-c) \tanh \left (\frac {x}{2}\right )}{\sqrt {a^2-b^2+c^2}}\right )}{\sqrt {a^2-b^2+c^2}} \]

[Out]

-2*arctanh((a+(b-c)*tanh(1/2*x))/(a^2-b^2+c^2)^(1/2))/(a^2-b^2+c^2)^(1/2)

________________________________________________________________________________________

Rubi [A]  time = 0.09, antiderivative size = 50, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 15, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.267, Rules used = {3166, 3124, 618, 204} \[ -\frac {2 \tanh ^{-1}\left (\frac {a+(b-c) \tanh \left (\frac {x}{2}\right )}{\sqrt {a^2-b^2+c^2}}\right )}{\sqrt {a^2-b^2+c^2}} \]

Antiderivative was successfully verified.

[In]

Int[Csch[x]/(a + b*Coth[x] + c*Csch[x]),x]

[Out]

(-2*ArcTanh[(a + (b - c)*Tanh[x/2])/Sqrt[a^2 - b^2 + c^2]])/Sqrt[a^2 - b^2 + c^2]

Rule 204

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> -Simp[ArcTan[(Rt[-b, 2]*x)/Rt[-a, 2]]/(Rt[-a, 2]*Rt[-b, 2]), x] /
; FreeQ[{a, b}, x] && PosQ[a/b] && (LtQ[a, 0] || LtQ[b, 0])

Rule 618

Int[((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(-1), x_Symbol] :> Dist[-2, Subst[Int[1/Simp[b^2 - 4*a*c - x^2, x], x]
, x, b + 2*c*x], x] /; FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*a*c, 0]

Rule 3124

Int[(cos[(d_.) + (e_.)*(x_)]*(b_.) + (a_) + (c_.)*sin[(d_.) + (e_.)*(x_)])^(-1), x_Symbol] :> Module[{f = Free
Factors[Tan[(d + e*x)/2], x]}, Dist[(2*f)/e, Subst[Int[1/(a + b + 2*c*f*x + (a - b)*f^2*x^2), x], x, Tan[(d +
e*x)/2]/f], x]] /; FreeQ[{a, b, c, d, e}, x] && NeQ[a^2 - b^2 - c^2, 0]

Rule 3166

Int[csc[(d_.) + (e_.)*(x_)]^(n_.)*((a_.) + csc[(d_.) + (e_.)*(x_)]*(b_.) + cot[(d_.) + (e_.)*(x_)]*(c_.))^(m_)
, x_Symbol] :> Int[1/(b + a*Sin[d + e*x] + c*Cos[d + e*x])^n, x] /; FreeQ[{a, b, c, d, e}, x] && EqQ[m + n, 0]
 && IntegerQ[n]

Rubi steps

\begin {align*} \int \frac {\text {csch}(x)}{a+b \coth (x)+c \text {csch}(x)} \, dx &=i \int \frac {1}{i c+i b \cosh (x)+i a \sinh (x)} \, dx\\ &=2 i \operatorname {Subst}\left (\int \frac {1}{i b+i c+2 i a x-(-i b+i c) x^2} \, dx,x,\tanh \left (\frac {x}{2}\right )\right )\\ &=-\left (4 i \operatorname {Subst}\left (\int \frac {1}{-4 \left (a^2-b^2+c^2\right )-x^2} \, dx,x,2 i a+2 (i b-i c) \tanh \left (\frac {x}{2}\right )\right )\right )\\ &=-\frac {2 \tanh ^{-1}\left (\frac {a+(b-c) \tanh \left (\frac {x}{2}\right )}{\sqrt {a^2-b^2+c^2}}\right )}{\sqrt {a^2-b^2+c^2}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.05, size = 54, normalized size = 1.08 \[ \frac {2 \tan ^{-1}\left (\frac {a+(b-c) \tanh \left (\frac {x}{2}\right )}{\sqrt {-a^2+b^2-c^2}}\right )}{\sqrt {-a^2+b^2-c^2}} \]

Antiderivative was successfully verified.

[In]

Integrate[Csch[x]/(a + b*Coth[x] + c*Csch[x]),x]

[Out]

(2*ArcTan[(a + (b - c)*Tanh[x/2])/Sqrt[-a^2 + b^2 - c^2]])/Sqrt[-a^2 + b^2 - c^2]

________________________________________________________________________________________

fricas [A]  time = 0.45, size = 244, normalized size = 4.88 \[ \left [\frac {\log \left (\frac {2 \, {\left (a + b\right )} c \cosh \relax (x) + {\left (a^{2} + 2 \, a b + b^{2}\right )} \cosh \relax (x)^{2} + {\left (a^{2} + 2 \, a b + b^{2}\right )} \sinh \relax (x)^{2} + a^{2} - b^{2} + 2 \, c^{2} + 2 \, {\left ({\left (a + b\right )} c + {\left (a^{2} + 2 \, a b + b^{2}\right )} \cosh \relax (x)\right )} \sinh \relax (x) - 2 \, \sqrt {a^{2} - b^{2} + c^{2}} {\left ({\left (a + b\right )} \cosh \relax (x) + {\left (a + b\right )} \sinh \relax (x) + c\right )}}{{\left (a + b\right )} \cosh \relax (x)^{2} + {\left (a + b\right )} \sinh \relax (x)^{2} + 2 \, c \cosh \relax (x) + 2 \, {\left ({\left (a + b\right )} \cosh \relax (x) + c\right )} \sinh \relax (x) - a + b}\right )}{\sqrt {a^{2} - b^{2} + c^{2}}}, \frac {2 \, \sqrt {-a^{2} + b^{2} - c^{2}} \arctan \left (\frac {\sqrt {-a^{2} + b^{2} - c^{2}} {\left ({\left (a + b\right )} \cosh \relax (x) + {\left (a + b\right )} \sinh \relax (x) + c\right )}}{a^{2} - b^{2} + c^{2}}\right )}{a^{2} - b^{2} + c^{2}}\right ] \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csch(x)/(a+b*coth(x)+c*csch(x)),x, algorithm="fricas")

[Out]

[log((2*(a + b)*c*cosh(x) + (a^2 + 2*a*b + b^2)*cosh(x)^2 + (a^2 + 2*a*b + b^2)*sinh(x)^2 + a^2 - b^2 + 2*c^2
+ 2*((a + b)*c + (a^2 + 2*a*b + b^2)*cosh(x))*sinh(x) - 2*sqrt(a^2 - b^2 + c^2)*((a + b)*cosh(x) + (a + b)*sin
h(x) + c))/((a + b)*cosh(x)^2 + (a + b)*sinh(x)^2 + 2*c*cosh(x) + 2*((a + b)*cosh(x) + c)*sinh(x) - a + b))/sq
rt(a^2 - b^2 + c^2), 2*sqrt(-a^2 + b^2 - c^2)*arctan(sqrt(-a^2 + b^2 - c^2)*((a + b)*cosh(x) + (a + b)*sinh(x)
 + c)/(a^2 - b^2 + c^2))/(a^2 - b^2 + c^2)]

________________________________________________________________________________________

giac [A]  time = 0.13, size = 46, normalized size = 0.92 \[ \frac {2 \, \arctan \left (\frac {a e^{x} + b e^{x} + c}{\sqrt {-a^{2} + b^{2} - c^{2}}}\right )}{\sqrt {-a^{2} + b^{2} - c^{2}}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csch(x)/(a+b*coth(x)+c*csch(x)),x, algorithm="giac")

[Out]

2*arctan((a*e^x + b*e^x + c)/sqrt(-a^2 + b^2 - c^2))/sqrt(-a^2 + b^2 - c^2)

________________________________________________________________________________________

maple [A]  time = 0.20, size = 53, normalized size = 1.06 \[ \frac {2 \arctan \left (\frac {2 \left (b -c \right ) \tanh \left (\frac {x}{2}\right )+2 a}{2 \sqrt {-a^{2}+b^{2}-c^{2}}}\right )}{\sqrt {-a^{2}+b^{2}-c^{2}}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(csch(x)/(a+b*coth(x)+c*csch(x)),x)

[Out]

2/(-a^2+b^2-c^2)^(1/2)*arctan(1/2*(2*(b-c)*tanh(1/2*x)+2*a)/(-a^2+b^2-c^2)^(1/2))

________________________________________________________________________________________

maxima [F(-2)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: ValueError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csch(x)/(a+b*coth(x)+c*csch(x)),x, algorithm="maxima")

[Out]

Exception raised: ValueError >> Computation failed since Maxima requested additional constraints; using the 'a
ssume' command before evaluation *may* help (example of legal syntax is 'assume(c^2-b^2+a^2>0)', see `assume?`
 for more details)Is c^2-b^2+a^2 positive or negative?

________________________________________________________________________________________

mupad [B]  time = 0.21, size = 78, normalized size = 1.56 \[ \frac {2\,\mathrm {atan}\left (\frac {c}{\sqrt {-a^2+b^2-c^2}}+\frac {a\,{\mathrm {e}}^x}{\sqrt {-a^2+b^2-c^2}}+\frac {b\,{\mathrm {e}}^x}{\sqrt {-a^2+b^2-c^2}}\right )}{\sqrt {-a^2+b^2-c^2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(sinh(x)*(a + c/sinh(x) + b*coth(x))),x)

[Out]

(2*atan(c/(b^2 - a^2 - c^2)^(1/2) + (a*exp(x))/(b^2 - a^2 - c^2)^(1/2) + (b*exp(x))/(b^2 - a^2 - c^2)^(1/2)))/
(b^2 - a^2 - c^2)^(1/2)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\operatorname {csch}{\relax (x )}}{a + b \coth {\relax (x )} + c \operatorname {csch}{\relax (x )}}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csch(x)/(a+b*coth(x)+c*csch(x)),x)

[Out]

Integral(csch(x)/(a + b*coth(x) + c*csch(x)), x)

________________________________________________________________________________________