\(\int \coth ^2(c+d x) \sqrt {a+b \text {sech}(c+d x)} \, dx\) [132]

Optimal result
Mathematica [B] (verified)
Rubi [A] (verified)
Maple [F]
Fricas [F(-1)]
Sympy [F]
Maxima [F]
Giac [F]
Mupad [F(-1)]
Reduce [F]

Optimal result

Integrand size = 23, antiderivative size = 246 \[ \int \coth ^2(c+d x) \sqrt {a+b \text {sech}(c+d x)} \, dx=\frac {\sqrt {a+b} \coth (c+d x) \operatorname {EllipticF}\left (\arcsin \left (\frac {\sqrt {a+b \text {sech}(c+d x)}}{\sqrt {a+b}}\right ),\frac {a+b}{a-b}\right ) \sqrt {\frac {b (1-\text {sech}(c+d x))}{a+b}} \sqrt {-\frac {b (1+\text {sech}(c+d x))}{a-b}}}{d}-\frac {\coth (c+d x) \sqrt {a+b \text {sech}(c+d x)}}{d}+\frac {2 \coth (c+d x) \operatorname {EllipticPi}\left (\frac {a}{a+b},\arcsin \left (\frac {\sqrt {a+b}}{\sqrt {a+b \text {sech}(c+d x)}}\right ),\frac {a-b}{a+b}\right ) \sqrt {-\frac {b (1-\text {sech}(c+d x))}{a+b \text {sech}(c+d x)}} \sqrt {\frac {b (1+\text {sech}(c+d x))}{a+b \text {sech}(c+d x)}} (a+b \text {sech}(c+d x))}{\sqrt {a+b} d} \] Output:

(a+b)^(1/2)*coth(d*x+c)*EllipticF((a+b*sech(d*x+c))^(1/2)/(a+b)^(1/2),((a+ 
b)/(a-b))^(1/2))*(b*(1-sech(d*x+c))/(a+b))^(1/2)*(-b*(1+sech(d*x+c))/(a-b) 
)^(1/2)/d-coth(d*x+c)*(a+b*sech(d*x+c))^(1/2)/d+2*coth(d*x+c)*EllipticPi(( 
a+b)^(1/2)/(a+b*sech(d*x+c))^(1/2),a/(a+b),((a-b)/(a+b))^(1/2))*(-b*(1-sec 
h(d*x+c))/(a+b*sech(d*x+c)))^(1/2)*(b*(1+sech(d*x+c))/(a+b*sech(d*x+c)))^( 
1/2)*(a+b*sech(d*x+c))/(a+b)^(1/2)/d
 

Mathematica [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(539\) vs. \(2(246)=492\).

Time = 15.18 (sec) , antiderivative size = 539, normalized size of antiderivative = 2.19 \[ \int \coth ^2(c+d x) \sqrt {a+b \text {sech}(c+d x)} \, dx=-\frac {\coth (c+d x) \sqrt {a+b \text {sech}(c+d x)}}{d}+\frac {\sqrt {a+b \text {sech}(c+d x)} \left (\frac {2 \sqrt {b} (a-a \cosh (c+d x))^{3/2} \sqrt {\frac {(a+b) (a+a \cosh (c+d x))}{(a-b) (a-a \cosh (c+d x))}} \operatorname {EllipticF}\left (\arcsin \left (\frac {\sqrt {a} \sqrt {b+a \cosh (c+d x)}}{\sqrt {b} \sqrt {a-a \cosh (c+d x)}}\right ),-\frac {2 b}{a-b}\right ) \sinh (c+d x)}{a^{3/2} \sqrt {-1+\cosh (c+d x)} \sqrt {1+\cosh (c+d x)} \sqrt {-\frac {a (a+b) \cosh (c+d x)}{b (a-a \cosh (c+d x))}} \left (-\frac {a-a \cosh (c+d x)}{a}\right )^{3/2} \sqrt {\frac {a+a \cosh (c+d x)}{a}} \sqrt {\text {sech}(c+d x)}}-\frac {4 b (a-a \cosh (c+d x)) \operatorname {EllipticPi}\left (\frac {a+b}{a},\arcsin \left (\frac {\sqrt {a} \sqrt {b+a \cosh (c+d x)}}{\sqrt {a+b} \sqrt {a \cosh (c+d x)}}\right ),\frac {a+b}{a-b}\right ) \sqrt {-\frac {b (a+a \cosh (c+d x)) \text {sech}(c+d x)}{a (a-b)}} \sinh (c+d x)}{\sqrt {a} \sqrt {a+b} \sqrt {-1+\cosh (c+d x)} \sqrt {a \cosh (c+d x)} \sqrt {1+\cosh (c+d x)} \sqrt {-\frac {a-a \cosh (c+d x)}{a}} \sqrt {\frac {a+a \cosh (c+d x)}{a}} \sqrt {\text {sech}(c+d x)} \sqrt {-\frac {b (a-a \cosh (c+d x)) \text {sech}(c+d x)}{a (a+b)}}}\right )}{2 d \sqrt {b+a \cosh (c+d x)} \sqrt {\text {sech}(c+d x)}} \] Input:

Integrate[Coth[c + d*x]^2*Sqrt[a + b*Sech[c + d*x]],x]
 

Output:

-((Coth[c + d*x]*Sqrt[a + b*Sech[c + d*x]])/d) + (Sqrt[a + b*Sech[c + d*x] 
]*((2*Sqrt[b]*(a - a*Cosh[c + d*x])^(3/2)*Sqrt[((a + b)*(a + a*Cosh[c + d* 
x]))/((a - b)*(a - a*Cosh[c + d*x]))]*EllipticF[ArcSin[(Sqrt[a]*Sqrt[b + a 
*Cosh[c + d*x]])/(Sqrt[b]*Sqrt[a - a*Cosh[c + d*x]])], (-2*b)/(a - b)]*Sin 
h[c + d*x])/(a^(3/2)*Sqrt[-1 + Cosh[c + d*x]]*Sqrt[1 + Cosh[c + d*x]]*Sqrt 
[-((a*(a + b)*Cosh[c + d*x])/(b*(a - a*Cosh[c + d*x])))]*(-((a - a*Cosh[c 
+ d*x])/a))^(3/2)*Sqrt[(a + a*Cosh[c + d*x])/a]*Sqrt[Sech[c + d*x]]) - (4* 
b*(a - a*Cosh[c + d*x])*EllipticPi[(a + b)/a, ArcSin[(Sqrt[a]*Sqrt[b + a*C 
osh[c + d*x]])/(Sqrt[a + b]*Sqrt[a*Cosh[c + d*x]])], (a + b)/(a - b)]*Sqrt 
[-((b*(a + a*Cosh[c + d*x])*Sech[c + d*x])/(a*(a - b)))]*Sinh[c + d*x])/(S 
qrt[a]*Sqrt[a + b]*Sqrt[-1 + Cosh[c + d*x]]*Sqrt[a*Cosh[c + d*x]]*Sqrt[1 + 
 Cosh[c + d*x]]*Sqrt[-((a - a*Cosh[c + d*x])/a)]*Sqrt[(a + a*Cosh[c + d*x] 
)/a]*Sqrt[Sech[c + d*x]]*Sqrt[-((b*(a - a*Cosh[c + d*x])*Sech[c + d*x])/(a 
*(a + b)))])))/(2*d*Sqrt[b + a*Cosh[c + d*x]]*Sqrt[Sech[c + d*x]])
 

Rubi [A] (verified)

Time = 0.77 (sec) , antiderivative size = 246, 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.174, Rules used = {3042, 25, 4384, 2009}

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 \coth ^2(c+d x) \sqrt {a+b \text {sech}(c+d x)} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int -\frac {\sqrt {a+b \csc \left (i c+i d x+\frac {\pi }{2}\right )}}{\cot \left (i c+i d x+\frac {\pi }{2}\right )^2}dx\)

\(\Big \downarrow \) 25

\(\displaystyle -\int \frac {\sqrt {a+b \csc \left (\frac {1}{2} (2 i c+\pi )+i d x\right )}}{\cot \left (\frac {1}{2} (2 i c+\pi )+i d x\right )^2}dx\)

\(\Big \downarrow \) 4384

\(\displaystyle -\int \left (-\sqrt {a+b \csc \left (\frac {1}{2} (2 i c+\pi )+i d x\right )} \text {csch}^2(c+d x)-\sqrt {a+b \csc \left (\frac {1}{2} (2 i c+\pi )+i d x\right )}\right )dx\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {\sqrt {a+b} \coth (c+d x) \sqrt {\frac {b (1-\text {sech}(c+d x))}{a+b}} \sqrt {-\frac {b (\text {sech}(c+d x)+1)}{a-b}} \operatorname {EllipticF}\left (\arcsin \left (\frac {\sqrt {a+b \text {sech}(c+d x)}}{\sqrt {a+b}}\right ),\frac {a+b}{a-b}\right )}{d}+\frac {2 \coth (c+d x) \sqrt {-\frac {b (1-\text {sech}(c+d x))}{a+b \text {sech}(c+d x)}} \sqrt {\frac {b (\text {sech}(c+d x)+1)}{a+b \text {sech}(c+d x)}} (a+b \text {sech}(c+d x)) \operatorname {EllipticPi}\left (\frac {a}{a+b},\arcsin \left (\frac {\sqrt {a+b}}{\sqrt {a+b \text {sech}(c+d x)}}\right ),\frac {a-b}{a+b}\right )}{d \sqrt {a+b}}-\frac {\coth (c+d x) \sqrt {a+b \text {sech}(c+d x)}}{d}\)

Input:

Int[Coth[c + d*x]^2*Sqrt[a + b*Sech[c + d*x]],x]
 

Output:

(Sqrt[a + b]*Coth[c + d*x]*EllipticF[ArcSin[Sqrt[a + b*Sech[c + d*x]]/Sqrt 
[a + b]], (a + b)/(a - b)]*Sqrt[(b*(1 - Sech[c + d*x]))/(a + b)]*Sqrt[-((b 
*(1 + Sech[c + d*x]))/(a - b))])/d - (Coth[c + d*x]*Sqrt[a + b*Sech[c + d* 
x]])/d + (2*Coth[c + d*x]*EllipticPi[a/(a + b), ArcSin[Sqrt[a + b]/Sqrt[a 
+ b*Sech[c + d*x]]], (a - b)/(a + b)]*Sqrt[-((b*(1 - Sech[c + d*x]))/(a + 
b*Sech[c + d*x]))]*Sqrt[(b*(1 + Sech[c + d*x]))/(a + b*Sech[c + d*x])]*(a 
+ b*Sech[c + d*x]))/(Sqrt[a + b]*d)
 

Defintions of rubi rules used

rule 25
Int[-(Fx_), x_Symbol] :> Simp[Identity[-1]   Int[Fx, x], x]
 

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4384
Int[cot[(c_.) + (d_.)*(x_)]^(m_)*(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_))^(n_ 
), x_Symbol] :> Int[ExpandIntegrand[(a + b*Csc[c + d*x])^n, (-1 + Sec[c + d 
*x]^2)^(-m/2), x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[a^2 - b^2, 0] && 
ILtQ[m/2, 0] && IntegerQ[n - 1/2] && EqQ[m, -2]
 
Maple [F]

\[\int \coth \left (d x +c \right )^{2} \sqrt {a +b \,\operatorname {sech}\left (d x +c \right )}d x\]

Input:

int(coth(d*x+c)^2*(a+b*sech(d*x+c))^(1/2),x)
 

Output:

int(coth(d*x+c)^2*(a+b*sech(d*x+c))^(1/2),x)
 

Fricas [F(-1)]

Timed out. \[ \int \coth ^2(c+d x) \sqrt {a+b \text {sech}(c+d x)} \, dx=\text {Timed out} \] Input:

integrate(coth(d*x+c)^2*(a+b*sech(d*x+c))^(1/2),x, algorithm="fricas")
 

Output:

Timed out
 

Sympy [F]

\[ \int \coth ^2(c+d x) \sqrt {a+b \text {sech}(c+d x)} \, dx=\int \sqrt {a + b \operatorname {sech}{\left (c + d x \right )}} \coth ^{2}{\left (c + d x \right )}\, dx \] Input:

integrate(coth(d*x+c)**2*(a+b*sech(d*x+c))**(1/2),x)
 

Output:

Integral(sqrt(a + b*sech(c + d*x))*coth(c + d*x)**2, x)
 

Maxima [F]

\[ \int \coth ^2(c+d x) \sqrt {a+b \text {sech}(c+d x)} \, dx=\int { \sqrt {b \operatorname {sech}\left (d x + c\right ) + a} \coth \left (d x + c\right )^{2} \,d x } \] Input:

integrate(coth(d*x+c)^2*(a+b*sech(d*x+c))^(1/2),x, algorithm="maxima")
 

Output:

integrate(sqrt(b*sech(d*x + c) + a)*coth(d*x + c)^2, x)
 

Giac [F]

\[ \int \coth ^2(c+d x) \sqrt {a+b \text {sech}(c+d x)} \, dx=\int { \sqrt {b \operatorname {sech}\left (d x + c\right ) + a} \coth \left (d x + c\right )^{2} \,d x } \] Input:

integrate(coth(d*x+c)^2*(a+b*sech(d*x+c))^(1/2),x, algorithm="giac")
 

Output:

integrate(sqrt(b*sech(d*x + c) + a)*coth(d*x + c)^2, x)
 

Mupad [F(-1)]

Timed out. \[ \int \coth ^2(c+d x) \sqrt {a+b \text {sech}(c+d x)} \, dx=\int {\mathrm {coth}\left (c+d\,x\right )}^2\,\sqrt {a+\frac {b}{\mathrm {cosh}\left (c+d\,x\right )}} \,d x \] Input:

int(coth(c + d*x)^2*(a + b/cosh(c + d*x))^(1/2),x)
 

Output:

int(coth(c + d*x)^2*(a + b/cosh(c + d*x))^(1/2), x)
 

Reduce [F]

\[ \int \coth ^2(c+d x) \sqrt {a+b \text {sech}(c+d x)} \, dx=\int \sqrt {\mathrm {sech}\left (d x +c \right ) b +a}\, \coth \left (d x +c \right )^{2}d x \] Input:

int(coth(d*x+c)^2*(a+b*sech(d*x+c))^(1/2),x)
 

Output:

int(sqrt(sech(c + d*x)*b + a)*coth(c + d*x)**2,x)