Integrand size = 23, antiderivative size = 72 \[ \int \text {csch}^4(c+d x) \left (a+b \tanh ^2(c+d x)\right )^2 \, dx=\frac {a (a-2 b) \coth (c+d x)}{d}-\frac {a^2 \coth ^3(c+d x)}{3 d}-\frac {(2 a-b) b \tanh (c+d x)}{d}-\frac {b^2 \tanh ^3(c+d x)}{3 d} \] Output:
a*(a-2*b)*coth(d*x+c)/d-1/3*a^2*coth(d*x+c)^3/d-(2*a-b)*b*tanh(d*x+c)/d-1/ 3*b^2*tanh(d*x+c)^3/d
Time = 1.45 (sec) , antiderivative size = 59, normalized size of antiderivative = 0.82 \[ \int \text {csch}^4(c+d x) \left (a+b \tanh ^2(c+d x)\right )^2 \, dx=\frac {-a \coth (c+d x) \left (-2 a+6 b+a \text {csch}^2(c+d x)\right )+b \left (-6 a+2 b+b \text {sech}^2(c+d x)\right ) \tanh (c+d x)}{3 d} \] Input:
Integrate[Csch[c + d*x]^4*(a + b*Tanh[c + d*x]^2)^2,x]
Output:
(-(a*Coth[c + d*x]*(-2*a + 6*b + a*Csch[c + d*x]^2)) + b*(-6*a + 2*b + b*S ech[c + d*x]^2)*Tanh[c + d*x])/(3*d)
Time = 0.37 (sec) , antiderivative size = 64, normalized size of antiderivative = 0.89, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.174, Rules used = {3042, 4146, 355, 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 \text {csch}^4(c+d x) \left (a+b \tanh ^2(c+d x)\right )^2 \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\left (a-b \tan (i c+i d x)^2\right )^2}{\sin (i c+i d x)^4}dx\) |
\(\Big \downarrow \) 4146 |
\(\displaystyle \frac {\int \coth ^4(c+d x) \left (1-\tanh ^2(c+d x)\right ) \left (b \tanh ^2(c+d x)+a\right )^2d\tanh (c+d x)}{d}\) |
\(\Big \downarrow \) 355 |
\(\displaystyle \frac {\int \left (a^2 \coth ^4(c+d x)-a (a-2 b) \coth ^2(c+d x)-b^2 \tanh ^2(c+d x)+b (b-2 a)\right )d\tanh (c+d x)}{d}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {-\frac {1}{3} a^2 \coth ^3(c+d x)-b (2 a-b) \tanh (c+d x)+a (a-2 b) \coth (c+d x)-\frac {1}{3} b^2 \tanh ^3(c+d x)}{d}\) |
Input:
Int[Csch[c + d*x]^4*(a + b*Tanh[c + d*x]^2)^2,x]
Output:
(a*(a - 2*b)*Coth[c + d*x] - (a^2*Coth[c + d*x]^3)/3 - (2*a - b)*b*Tanh[c + d*x] - (b^2*Tanh[c + d*x]^3)/3)/d
Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^2)^(p_.)*((c_) + (d_.)*(x_)^2)^(q _.), x_Symbol] :> Int[ExpandIntegrand[(e*x)^m*(a + b*x^2)^p*(c + d*x^2)^q, x], x] /; FreeQ[{a, b, c, d, e, m}, x] && NeQ[b*c - a*d, 0] && IGtQ[p, 0] & & IGtQ[q, 0]
Int[sin[(e_.) + (f_.)*(x_)]^(m_)*((a_) + (b_.)*((c_.)*tan[(e_.) + (f_.)*(x_ )])^(n_))^(p_.), x_Symbol] :> With[{ff = FreeFactors[Tan[e + f*x], x]}, Sim p[c*(ff^(m + 1)/f) Subst[Int[x^m*((a + b*(ff*x)^n)^p/(c^2 + ff^2*x^2)^(m/ 2 + 1)), x], x, c*(Tan[e + f*x]/ff)], x]] /; FreeQ[{a, b, c, e, f, n, p}, x ] && IntegerQ[m/2]
Time = 16.88 (sec) , antiderivative size = 81, normalized size of antiderivative = 1.12
method | result | size |
derivativedivides | \(\frac {a^{2} \left (\frac {2}{3}-\frac {\operatorname {csch}\left (d x +c \right )^{2}}{3}\right ) \coth \left (d x +c \right )+2 a b \left (-\frac {1}{\sinh \left (d x +c \right ) \cosh \left (d x +c \right )}-2 \tanh \left (d x +c \right )\right )+b^{2} \left (\frac {2}{3}+\frac {\operatorname {sech}\left (d x +c \right )^{2}}{3}\right ) \tanh \left (d x +c \right )}{d}\) | \(81\) |
default | \(\frac {a^{2} \left (\frac {2}{3}-\frac {\operatorname {csch}\left (d x +c \right )^{2}}{3}\right ) \coth \left (d x +c \right )+2 a b \left (-\frac {1}{\sinh \left (d x +c \right ) \cosh \left (d x +c \right )}-2 \tanh \left (d x +c \right )\right )+b^{2} \left (\frac {2}{3}+\frac {\operatorname {sech}\left (d x +c \right )^{2}}{3}\right ) \tanh \left (d x +c \right )}{d}\) | \(81\) |
risch | \(-\frac {4 \left (3 \,{\mathrm e}^{8 d x +8 c} a^{2}+6 \,{\mathrm e}^{8 d x +8 c} a b +3 \,{\mathrm e}^{8 d x +8 c} b^{2}+8 \,{\mathrm e}^{6 d x +6 c} a^{2}-8 \,{\mathrm e}^{6 d x +6 c} b^{2}+6 \,{\mathrm e}^{4 d x +4 c} a^{2}-12 \,{\mathrm e}^{4 d x +4 c} a b +6 \,{\mathrm e}^{4 d x +4 c} b^{2}-a^{2}+6 a b -b^{2}\right )}{3 d \left ({\mathrm e}^{2 d x +2 c}-1\right )^{3} \left ({\mathrm e}^{2 d x +2 c}+1\right )^{3}}\) | \(157\) |
Input:
int(csch(d*x+c)^4*(a+tanh(d*x+c)^2*b)^2,x,method=_RETURNVERBOSE)
Output:
1/d*(a^2*(2/3-1/3*csch(d*x+c)^2)*coth(d*x+c)+2*a*b*(-1/sinh(d*x+c)/cosh(d* x+c)-2*tanh(d*x+c))+b^2*(2/3+1/3*sech(d*x+c)^2)*tanh(d*x+c))
Leaf count of result is larger than twice the leaf count of optimal. 393 vs. \(2 (68) = 136\).
Time = 0.07 (sec) , antiderivative size = 393, normalized size of antiderivative = 5.46 \[ \int \text {csch}^4(c+d x) \left (a+b \tanh ^2(c+d x)\right )^2 \, dx=-\frac {8 \, {\left ({\left (a^{2} + 6 \, a b + b^{2}\right )} \cosh \left (d x + c\right )^{4} + 8 \, {\left (a^{2} + b^{2}\right )} \cosh \left (d x + c\right ) \sinh \left (d x + c\right )^{3} + {\left (a^{2} + 6 \, a b + b^{2}\right )} \sinh \left (d x + c\right )^{4} + 4 \, {\left (a^{2} - b^{2}\right )} \cosh \left (d x + c\right )^{2} + 2 \, {\left (3 \, {\left (a^{2} + 6 \, a b + b^{2}\right )} \cosh \left (d x + c\right )^{2} + 2 \, a^{2} - 2 \, b^{2}\right )} \sinh \left (d x + c\right )^{2} + 3 \, a^{2} - 6 \, a b + 3 \, b^{2} + 8 \, {\left ({\left (a^{2} + b^{2}\right )} \cosh \left (d x + c\right )^{3} + {\left (a^{2} - b^{2}\right )} \cosh \left (d x + c\right )\right )} \sinh \left (d x + c\right )\right )}}{3 \, {\left (d \cosh \left (d x + c\right )^{8} + 56 \, d \cosh \left (d x + c\right )^{3} \sinh \left (d x + c\right )^{5} + 28 \, d \cosh \left (d x + c\right )^{2} \sinh \left (d x + c\right )^{6} + 8 \, d \cosh \left (d x + c\right ) \sinh \left (d x + c\right )^{7} + d \sinh \left (d x + c\right )^{8} - 4 \, d \cosh \left (d x + c\right )^{4} + 2 \, {\left (35 \, d \cosh \left (d x + c\right )^{4} - 2 \, d\right )} \sinh \left (d x + c\right )^{4} + 8 \, {\left (7 \, d \cosh \left (d x + c\right )^{5} - d \cosh \left (d x + c\right )\right )} \sinh \left (d x + c\right )^{3} + 4 \, {\left (7 \, d \cosh \left (d x + c\right )^{6} - 6 \, d \cosh \left (d x + c\right )^{2}\right )} \sinh \left (d x + c\right )^{2} + 8 \, {\left (d \cosh \left (d x + c\right )^{7} - d \cosh \left (d x + c\right )^{3}\right )} \sinh \left (d x + c\right ) + 3 \, d\right )}} \] Input:
integrate(csch(d*x+c)^4*(a+b*tanh(d*x+c)^2)^2,x, algorithm="fricas")
Output:
-8/3*((a^2 + 6*a*b + b^2)*cosh(d*x + c)^4 + 8*(a^2 + b^2)*cosh(d*x + c)*si nh(d*x + c)^3 + (a^2 + 6*a*b + b^2)*sinh(d*x + c)^4 + 4*(a^2 - b^2)*cosh(d *x + c)^2 + 2*(3*(a^2 + 6*a*b + b^2)*cosh(d*x + c)^2 + 2*a^2 - 2*b^2)*sinh (d*x + c)^2 + 3*a^2 - 6*a*b + 3*b^2 + 8*((a^2 + b^2)*cosh(d*x + c)^3 + (a^ 2 - b^2)*cosh(d*x + c))*sinh(d*x + c))/(d*cosh(d*x + c)^8 + 56*d*cosh(d*x + c)^3*sinh(d*x + c)^5 + 28*d*cosh(d*x + c)^2*sinh(d*x + c)^6 + 8*d*cosh(d *x + c)*sinh(d*x + c)^7 + d*sinh(d*x + c)^8 - 4*d*cosh(d*x + c)^4 + 2*(35* d*cosh(d*x + c)^4 - 2*d)*sinh(d*x + c)^4 + 8*(7*d*cosh(d*x + c)^5 - d*cosh (d*x + c))*sinh(d*x + c)^3 + 4*(7*d*cosh(d*x + c)^6 - 6*d*cosh(d*x + c)^2) *sinh(d*x + c)^2 + 8*(d*cosh(d*x + c)^7 - d*cosh(d*x + c)^3)*sinh(d*x + c) + 3*d)
\[ \int \text {csch}^4(c+d x) \left (a+b \tanh ^2(c+d x)\right )^2 \, dx=\int \left (a + b \tanh ^{2}{\left (c + d x \right )}\right )^{2} \operatorname {csch}^{4}{\left (c + d x \right )}\, dx \] Input:
integrate(csch(d*x+c)**4*(a+b*tanh(d*x+c)**2)**2,x)
Output:
Integral((a + b*tanh(c + d*x)**2)**2*csch(c + d*x)**4, x)
Leaf count of result is larger than twice the leaf count of optimal. 210 vs. \(2 (68) = 136\).
Time = 0.04 (sec) , antiderivative size = 210, normalized size of antiderivative = 2.92 \[ \int \text {csch}^4(c+d x) \left (a+b \tanh ^2(c+d x)\right )^2 \, dx=\frac {4}{3} \, b^{2} {\left (\frac {3 \, e^{\left (-2 \, d x - 2 \, c\right )}}{d {\left (3 \, e^{\left (-2 \, d x - 2 \, c\right )} + 3 \, e^{\left (-4 \, d x - 4 \, c\right )} + e^{\left (-6 \, d x - 6 \, c\right )} + 1\right )}} + \frac {1}{d {\left (3 \, e^{\left (-2 \, d x - 2 \, c\right )} + 3 \, e^{\left (-4 \, d x - 4 \, c\right )} + e^{\left (-6 \, d x - 6 \, c\right )} + 1\right )}}\right )} + \frac {4}{3} \, a^{2} {\left (\frac {3 \, e^{\left (-2 \, d x - 2 \, c\right )}}{d {\left (3 \, e^{\left (-2 \, d x - 2 \, c\right )} - 3 \, e^{\left (-4 \, d x - 4 \, c\right )} + e^{\left (-6 \, d x - 6 \, c\right )} - 1\right )}} - \frac {1}{d {\left (3 \, e^{\left (-2 \, d x - 2 \, c\right )} - 3 \, e^{\left (-4 \, d x - 4 \, c\right )} + e^{\left (-6 \, d x - 6 \, c\right )} - 1\right )}}\right )} + \frac {8 \, a b}{d {\left (e^{\left (-4 \, d x - 4 \, c\right )} - 1\right )}} \] Input:
integrate(csch(d*x+c)^4*(a+b*tanh(d*x+c)^2)^2,x, algorithm="maxima")
Output:
4/3*b^2*(3*e^(-2*d*x - 2*c)/(d*(3*e^(-2*d*x - 2*c) + 3*e^(-4*d*x - 4*c) + e^(-6*d*x - 6*c) + 1)) + 1/(d*(3*e^(-2*d*x - 2*c) + 3*e^(-4*d*x - 4*c) + e ^(-6*d*x - 6*c) + 1))) + 4/3*a^2*(3*e^(-2*d*x - 2*c)/(d*(3*e^(-2*d*x - 2*c ) - 3*e^(-4*d*x - 4*c) + e^(-6*d*x - 6*c) - 1)) - 1/(d*(3*e^(-2*d*x - 2*c) - 3*e^(-4*d*x - 4*c) + e^(-6*d*x - 6*c) - 1))) + 8*a*b/(d*(e^(-4*d*x - 4* c) - 1))
Leaf count of result is larger than twice the leaf count of optimal. 143 vs. \(2 (68) = 136\).
Time = 0.16 (sec) , antiderivative size = 143, normalized size of antiderivative = 1.99 \[ \int \text {csch}^4(c+d x) \left (a+b \tanh ^2(c+d x)\right )^2 \, dx=-\frac {4 \, {\left (3 \, a^{2} e^{\left (8 \, d x + 8 \, c\right )} + 6 \, a b e^{\left (8 \, d x + 8 \, c\right )} + 3 \, b^{2} e^{\left (8 \, d x + 8 \, c\right )} + 8 \, a^{2} e^{\left (6 \, d x + 6 \, c\right )} - 8 \, b^{2} e^{\left (6 \, d x + 6 \, c\right )} + 6 \, a^{2} e^{\left (4 \, d x + 4 \, c\right )} - 12 \, a b e^{\left (4 \, d x + 4 \, c\right )} + 6 \, b^{2} e^{\left (4 \, d x + 4 \, c\right )} - a^{2} + 6 \, a b - b^{2}\right )}}{3 \, d {\left (e^{\left (4 \, d x + 4 \, c\right )} - 1\right )}^{3}} \] Input:
integrate(csch(d*x+c)^4*(a+b*tanh(d*x+c)^2)^2,x, algorithm="giac")
Output:
-4/3*(3*a^2*e^(8*d*x + 8*c) + 6*a*b*e^(8*d*x + 8*c) + 3*b^2*e^(8*d*x + 8*c ) + 8*a^2*e^(6*d*x + 6*c) - 8*b^2*e^(6*d*x + 6*c) + 6*a^2*e^(4*d*x + 4*c) - 12*a*b*e^(4*d*x + 4*c) + 6*b^2*e^(4*d*x + 4*c) - a^2 + 6*a*b - b^2)/(d*( e^(4*d*x + 4*c) - 1)^3)
Time = 2.31 (sec) , antiderivative size = 143, normalized size of antiderivative = 1.99 \[ \int \text {csch}^4(c+d x) \left (a+b \tanh ^2(c+d x)\right )^2 \, dx=-\frac {4\,\left (6\,a\,b-a^2-b^2+6\,a^2\,{\mathrm {e}}^{4\,c+4\,d\,x}+8\,a^2\,{\mathrm {e}}^{6\,c+6\,d\,x}+3\,a^2\,{\mathrm {e}}^{8\,c+8\,d\,x}+6\,b^2\,{\mathrm {e}}^{4\,c+4\,d\,x}-8\,b^2\,{\mathrm {e}}^{6\,c+6\,d\,x}+3\,b^2\,{\mathrm {e}}^{8\,c+8\,d\,x}-12\,a\,b\,{\mathrm {e}}^{4\,c+4\,d\,x}+6\,a\,b\,{\mathrm {e}}^{8\,c+8\,d\,x}\right )}{3\,d\,{\left ({\mathrm {e}}^{4\,c+4\,d\,x}-1\right )}^3} \] Input:
int((a + b*tanh(c + d*x)^2)^2/sinh(c + d*x)^4,x)
Output:
-(4*(6*a*b - a^2 - b^2 + 6*a^2*exp(4*c + 4*d*x) + 8*a^2*exp(6*c + 6*d*x) + 3*a^2*exp(8*c + 8*d*x) + 6*b^2*exp(4*c + 4*d*x) - 8*b^2*exp(6*c + 6*d*x) + 3*b^2*exp(8*c + 8*d*x) - 12*a*b*exp(4*c + 4*d*x) + 6*a*b*exp(8*c + 8*d*x )))/(3*d*(exp(4*c + 4*d*x) - 1)^3)
Time = 0.28 (sec) , antiderivative size = 176, normalized size of antiderivative = 2.44 \[ \int \text {csch}^4(c+d x) \left (a+b \tanh ^2(c+d x)\right )^2 \, dx=\frac {-\frac {4 e^{12 d x +12 c} a^{2}}{3}-\frac {8 e^{12 d x +12 c} a b}{3}-\frac {4 e^{12 d x +12 c} b^{2}}{3}-\frac {32 e^{6 d x +6 c} a^{2}}{3}+\frac {32 e^{6 d x +6 c} b^{2}}{3}-12 e^{4 d x +4 c} a^{2}+8 e^{4 d x +4 c} a b -12 e^{4 d x +4 c} b^{2}+\frac {8 a^{2}}{3}-\frac {16 a b}{3}+\frac {8 b^{2}}{3}}{d \left (e^{12 d x +12 c}-3 e^{8 d x +8 c}+3 e^{4 d x +4 c}-1\right )} \] Input:
int(csch(d*x+c)^4*(a+b*tanh(d*x+c)^2)^2,x)
Output:
(4*( - e**(12*c + 12*d*x)*a**2 - 2*e**(12*c + 12*d*x)*a*b - e**(12*c + 12* d*x)*b**2 - 8*e**(6*c + 6*d*x)*a**2 + 8*e**(6*c + 6*d*x)*b**2 - 9*e**(4*c + 4*d*x)*a**2 + 6*e**(4*c + 4*d*x)*a*b - 9*e**(4*c + 4*d*x)*b**2 + 2*a**2 - 4*a*b + 2*b**2))/(3*d*(e**(12*c + 12*d*x) - 3*e**(8*c + 8*d*x) + 3*e**(4 *c + 4*d*x) - 1))