Integrand size = 13, antiderivative size = 56 \[ \int \frac {\text {sech}^4(x)}{a+a \cosh (x)} \, dx=-\frac {3 \arctan (\sinh (x))}{2 a}+\frac {4 \tanh (x)}{a}-\frac {3 \text {sech}(x) \tanh (x)}{2 a}-\frac {\text {sech}^2(x) \tanh (x)}{a+a \cosh (x)}-\frac {4 \tanh ^3(x)}{3 a} \] Output:
-3/2*arctan(sinh(x))/a+4*tanh(x)/a-3/2*sech(x)*tanh(x)/a-sech(x)^2*tanh(x) /(a+a*cosh(x))-4/3*tanh(x)^3/a
Time = 0.22 (sec) , antiderivative size = 60, normalized size of antiderivative = 1.07 \[ \int \frac {\text {sech}^4(x)}{a+a \cosh (x)} \, dx=\frac {\cosh \left (\frac {x}{2}\right ) \left (6 \sinh \left (\frac {x}{2}\right )+\cosh \left (\frac {x}{2}\right ) \left (-18 \arctan \left (\tanh \left (\frac {x}{2}\right )\right )+\left (10-3 \text {sech}(x)+2 \text {sech}^2(x)\right ) \tanh (x)\right )\right )}{3 a (1+\cosh (x))} \] Input:
Integrate[Sech[x]^4/(a + a*Cosh[x]),x]
Output:
(Cosh[x/2]*(6*Sinh[x/2] + Cosh[x/2]*(-18*ArcTan[Tanh[x/2]] + (10 - 3*Sech[ x] + 2*Sech[x]^2)*Tanh[x])))/(3*a*(1 + Cosh[x]))
Result contains complex when optimal does not.
Time = 0.52 (sec) , antiderivative size = 63, normalized size of antiderivative = 1.12, number of steps used = 12, number of rules used = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.846, Rules used = {3042, 3247, 25, 3042, 3227, 3042, 4254, 2009, 4255, 3042, 4257}
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 {\text {sech}^4(x)}{a \cosh (x)+a} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {1}{\sin \left (\frac {\pi }{2}+i x\right )^4 \left (a+a \sin \left (\frac {\pi }{2}+i x\right )\right )}dx\) |
\(\Big \downarrow \) 3247 |
\(\displaystyle -\frac {\int -\left ((4 a-3 a \cosh (x)) \text {sech}^4(x)\right )dx}{a^2}-\frac {\tanh (x) \text {sech}^2(x)}{a \cosh (x)+a}\) |
\(\Big \downarrow \) 25 |
\(\displaystyle \frac {\int (4 a-3 a \cosh (x)) \text {sech}^4(x)dx}{a^2}-\frac {\tanh (x) \text {sech}^2(x)}{a \cosh (x)+a}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\tanh (x) \text {sech}^2(x)}{a \cosh (x)+a}+\frac {\int \frac {4 a-3 a \sin \left (i x+\frac {\pi }{2}\right )}{\sin \left (i x+\frac {\pi }{2}\right )^4}dx}{a^2}\) |
\(\Big \downarrow \) 3227 |
\(\displaystyle \frac {4 a \int \text {sech}^4(x)dx-3 a \int \text {sech}^3(x)dx}{a^2}-\frac {\tanh (x) \text {sech}^2(x)}{a \cosh (x)+a}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\tanh (x) \text {sech}^2(x)}{a \cosh (x)+a}+\frac {4 a \int \csc \left (i x+\frac {\pi }{2}\right )^4dx-3 a \int \csc \left (i x+\frac {\pi }{2}\right )^3dx}{a^2}\) |
\(\Big \downarrow \) 4254 |
\(\displaystyle -\frac {\tanh (x) \text {sech}^2(x)}{a \cosh (x)+a}+\frac {4 i a \int \left (1-\tanh ^2(x)\right )d(-i \tanh (x))-3 a \int \csc \left (i x+\frac {\pi }{2}\right )^3dx}{a^2}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {\tanh (x) \text {sech}^2(x)}{a \cosh (x)+a}+\frac {4 i a \left (\frac {1}{3} i \tanh ^3(x)-i \tanh (x)\right )-3 a \int \csc \left (i x+\frac {\pi }{2}\right )^3dx}{a^2}\) |
\(\Big \downarrow \) 4255 |
\(\displaystyle -\frac {\tanh (x) \text {sech}^2(x)}{a \cosh (x)+a}+\frac {-3 a \left (\frac {\int \text {sech}(x)dx}{2}+\frac {1}{2} \tanh (x) \text {sech}(x)\right )+4 i a \left (\frac {1}{3} i \tanh ^3(x)-i \tanh (x)\right )}{a^2}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle -\frac {\tanh (x) \text {sech}^2(x)}{a \cosh (x)+a}+\frac {4 i a \left (\frac {1}{3} i \tanh ^3(x)-i \tanh (x)\right )-3 a \left (\frac {1}{2} \tanh (x) \text {sech}(x)+\frac {1}{2} \int \csc \left (i x+\frac {\pi }{2}\right )dx\right )}{a^2}\) |
\(\Big \downarrow \) 4257 |
\(\displaystyle -\frac {\tanh (x) \text {sech}^2(x)}{a \cosh (x)+a}+\frac {-3 a \left (\frac {1}{2} \arctan (\sinh (x))+\frac {1}{2} \tanh (x) \text {sech}(x)\right )+4 i a \left (\frac {1}{3} i \tanh ^3(x)-i \tanh (x)\right )}{a^2}\) |
Input:
Int[Sech[x]^4/(a + a*Cosh[x]),x]
Output:
-((Sech[x]^2*Tanh[x])/(a + a*Cosh[x])) + (-3*a*(ArcTan[Sinh[x]]/2 + (Sech[ x]*Tanh[x])/2) + (4*I)*a*((-I)*Tanh[x] + (I/3)*Tanh[x]^3))/a^2
Int[((b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*sin[(e_.) + (f_.)*(x _)]), x_Symbol] :> Simp[c Int[(b*Sin[e + f*x])^m, x], x] + Simp[d/b Int [(b*Sin[e + f*x])^(m + 1), x], x] /; FreeQ[{b, c, d, e, f, m}, x]
Int[((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])^(n_)/((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[(-b^2)*Cos[e + f*x]*((c + d*Sin[e + f*x])^( n + 1)/(a*f*(b*c - a*d)*(a + b*Sin[e + f*x]))), x] + Simp[d/(a*(b*c - a*d)) Int[(c + d*Sin[e + f*x])^n*(a*n - b*(n + 1)*Sin[e + f*x]), x], x] /; Fre eQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0] && NeQ[ c^2 - d^2, 0] && LtQ[n, 0] && (IntegerQ[2*n] || EqQ[c, 0])
Int[csc[(c_.) + (d_.)*(x_)]^(n_), x_Symbol] :> Simp[-d^(-1) Subst[Int[Exp andIntegrand[(1 + x^2)^(n/2 - 1), x], x], x, Cot[c + d*x]], x] /; FreeQ[{c, d}, x] && IGtQ[n/2, 0]
Int[(csc[(c_.) + (d_.)*(x_)]*(b_.))^(n_), x_Symbol] :> Simp[(-b)*Cos[c + d* x]*((b*Csc[c + d*x])^(n - 1)/(d*(n - 1))), x] + Simp[b^2*((n - 2)/(n - 1)) Int[(b*Csc[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1] && IntegerQ[2*n]
Int[csc[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-ArcTanh[Cos[c + d*x]]/d, x] /; FreeQ[{c, d}, x]
Time = 0.84 (sec) , antiderivative size = 52, normalized size of antiderivative = 0.93
method | result | size |
default | \(\frac {\tanh \left (\frac {x}{2}\right )-\frac {8 \left (-\frac {5 \tanh \left (\frac {x}{2}\right )^{5}}{8}-\frac {2 \tanh \left (\frac {x}{2}\right )^{3}}{3}-\frac {3 \tanh \left (\frac {x}{2}\right )}{8}\right )}{\left (\tanh \left (\frac {x}{2}\right )^{2}+1\right )^{3}}-3 \arctan \left (\tanh \left (\frac {x}{2}\right )\right )}{a}\) | \(52\) |
risch | \(-\frac {9 \,{\mathrm e}^{6 x}+9 \,{\mathrm e}^{5 x}+24 \,{\mathrm e}^{4 x}+24 \,{\mathrm e}^{3 x}+39 \,{\mathrm e}^{2 x}+7 \,{\mathrm e}^{x}+16}{3 \left ({\mathrm e}^{2 x}+1\right )^{3} a \left ({\mathrm e}^{x}+1\right )}+\frac {3 i \ln \left ({\mathrm e}^{x}-i\right )}{2 a}-\frac {3 i \ln \left ({\mathrm e}^{x}+i\right )}{2 a}\) | \(81\) |
parallelrisch | \(\frac {9 i \left (\cosh \left (3 x \right )+3 \cosh \left (x \right )\right ) \ln \left (\tanh \left (\frac {x}{2}\right )-i\right )+9 i \left (-\cosh \left (3 x \right )-3 \cosh \left (x \right )\right ) \ln \left (\tanh \left (\frac {x}{2}\right )+i\right )+44 \left (\cosh \left (x \right )+\frac {7 \cosh \left (2 x \right )}{22}+\frac {4 \cosh \left (3 x \right )}{11}+\frac {1}{2}\right ) \tanh \left (\frac {x}{2}\right )}{6 a \left (\cosh \left (3 x \right )+3 \cosh \left (x \right )\right )}\) | \(82\) |
Input:
int(sech(x)^4/(a+cosh(x)*a),x,method=_RETURNVERBOSE)
Output:
1/a*(tanh(1/2*x)-8*(-5/8*tanh(1/2*x)^5-2/3*tanh(1/2*x)^3-3/8*tanh(1/2*x))/ (tanh(1/2*x)^2+1)^3-3*arctan(tanh(1/2*x)))
Leaf count of result is larger than twice the leaf count of optimal. 600 vs. \(2 (50) = 100\).
Time = 0.10 (sec) , antiderivative size = 600, normalized size of antiderivative = 10.71 \[ \int \frac {\text {sech}^4(x)}{a+a \cosh (x)} \, dx=\text {Too large to display} \] Input:
integrate(sech(x)^4/(a+a*cosh(x)),x, algorithm="fricas")
Output:
-1/3*(9*cosh(x)^6 + 9*(6*cosh(x) + 1)*sinh(x)^5 + 9*sinh(x)^6 + 9*cosh(x)^ 5 + 3*(45*cosh(x)^2 + 15*cosh(x) + 8)*sinh(x)^4 + 24*cosh(x)^4 + 6*(30*cos h(x)^3 + 15*cosh(x)^2 + 16*cosh(x) + 4)*sinh(x)^3 + 24*cosh(x)^3 + 3*(45*c osh(x)^4 + 30*cosh(x)^3 + 48*cosh(x)^2 + 24*cosh(x) + 13)*sinh(x)^2 + 9*(c osh(x)^7 + (7*cosh(x) + 1)*sinh(x)^6 + sinh(x)^7 + cosh(x)^6 + 3*(7*cosh(x )^2 + 2*cosh(x) + 1)*sinh(x)^5 + 3*cosh(x)^5 + (35*cosh(x)^3 + 15*cosh(x)^ 2 + 15*cosh(x) + 3)*sinh(x)^4 + 3*cosh(x)^4 + (35*cosh(x)^4 + 20*cosh(x)^3 + 30*cosh(x)^2 + 12*cosh(x) + 3)*sinh(x)^3 + 3*cosh(x)^3 + 3*(7*cosh(x)^5 + 5*cosh(x)^4 + 10*cosh(x)^3 + 6*cosh(x)^2 + 3*cosh(x) + 1)*sinh(x)^2 + 3 *cosh(x)^2 + (7*cosh(x)^6 + 6*cosh(x)^5 + 15*cosh(x)^4 + 12*cosh(x)^3 + 9* cosh(x)^2 + 6*cosh(x) + 1)*sinh(x) + cosh(x) + 1)*arctan(cosh(x) + sinh(x) ) + 39*cosh(x)^2 + (54*cosh(x)^5 + 45*cosh(x)^4 + 96*cosh(x)^3 + 72*cosh(x )^2 + 78*cosh(x) + 7)*sinh(x) + 7*cosh(x) + 16)/(a*cosh(x)^7 + a*sinh(x)^7 + a*cosh(x)^6 + (7*a*cosh(x) + a)*sinh(x)^6 + 3*a*cosh(x)^5 + 3*(7*a*cosh (x)^2 + 2*a*cosh(x) + a)*sinh(x)^5 + 3*a*cosh(x)^4 + (35*a*cosh(x)^3 + 15* a*cosh(x)^2 + 15*a*cosh(x) + 3*a)*sinh(x)^4 + 3*a*cosh(x)^3 + (35*a*cosh(x )^4 + 20*a*cosh(x)^3 + 30*a*cosh(x)^2 + 12*a*cosh(x) + 3*a)*sinh(x)^3 + 3* a*cosh(x)^2 + 3*(7*a*cosh(x)^5 + 5*a*cosh(x)^4 + 10*a*cosh(x)^3 + 6*a*cosh (x)^2 + 3*a*cosh(x) + a)*sinh(x)^2 + a*cosh(x) + (7*a*cosh(x)^6 + 6*a*cosh (x)^5 + 15*a*cosh(x)^4 + 12*a*cosh(x)^3 + 9*a*cosh(x)^2 + 6*a*cosh(x) +...
\[ \int \frac {\text {sech}^4(x)}{a+a \cosh (x)} \, dx=\frac {\int \frac {\operatorname {sech}^{4}{\left (x \right )}}{\cosh {\left (x \right )} + 1}\, dx}{a} \] Input:
integrate(sech(x)**4/(a+a*cosh(x)),x)
Output:
Integral(sech(x)**4/(cosh(x) + 1), x)/a
Leaf count of result is larger than twice the leaf count of optimal. 101 vs. \(2 (50) = 100\).
Time = 0.11 (sec) , antiderivative size = 101, normalized size of antiderivative = 1.80 \[ \int \frac {\text {sech}^4(x)}{a+a \cosh (x)} \, dx=\frac {7 \, e^{\left (-x\right )} + 39 \, e^{\left (-2 \, x\right )} + 24 \, e^{\left (-3 \, x\right )} + 24 \, e^{\left (-4 \, x\right )} + 9 \, e^{\left (-5 \, x\right )} + 9 \, e^{\left (-6 \, x\right )} + 16}{3 \, {\left (a e^{\left (-x\right )} + 3 \, a e^{\left (-2 \, x\right )} + 3 \, a e^{\left (-3 \, x\right )} + 3 \, a e^{\left (-4 \, x\right )} + 3 \, a e^{\left (-5 \, x\right )} + a e^{\left (-6 \, x\right )} + a e^{\left (-7 \, x\right )} + a\right )}} + \frac {3 \, \arctan \left (e^{\left (-x\right )}\right )}{a} \] Input:
integrate(sech(x)^4/(a+a*cosh(x)),x, algorithm="maxima")
Output:
1/3*(7*e^(-x) + 39*e^(-2*x) + 24*e^(-3*x) + 24*e^(-4*x) + 9*e^(-5*x) + 9*e ^(-6*x) + 16)/(a*e^(-x) + 3*a*e^(-2*x) + 3*a*e^(-3*x) + 3*a*e^(-4*x) + 3*a *e^(-5*x) + a*e^(-6*x) + a*e^(-7*x) + a) + 3*arctan(e^(-x))/a
Time = 0.12 (sec) , antiderivative size = 57, normalized size of antiderivative = 1.02 \[ \int \frac {\text {sech}^4(x)}{a+a \cosh (x)} \, dx=-\frac {3 \, \arctan \left (e^{x}\right )}{a} - \frac {2}{a {\left (e^{x} + 1\right )}} - \frac {3 \, e^{\left (5 \, x\right )} + 6 \, e^{\left (4 \, x\right )} + 24 \, e^{\left (2 \, x\right )} - 3 \, e^{x} + 10}{3 \, a {\left (e^{\left (2 \, x\right )} + 1\right )}^{3}} \] Input:
integrate(sech(x)^4/(a+a*cosh(x)),x, algorithm="giac")
Output:
-3*arctan(e^x)/a - 2/(a*(e^x + 1)) - 1/3*(3*e^(5*x) + 6*e^(4*x) + 24*e^(2* x) - 3*e^x + 10)/(a*(e^(2*x) + 1)^3)
Time = 2.09 (sec) , antiderivative size = 107, normalized size of antiderivative = 1.91 \[ \int \frac {\text {sech}^4(x)}{a+a \cosh (x)} \, dx=\frac {8}{3\,a\,\left (3\,{\mathrm {e}}^{2\,x}+3\,{\mathrm {e}}^{4\,x}+{\mathrm {e}}^{6\,x}+1\right )}-\frac {\frac {4}{a}-\frac {2\,{\mathrm {e}}^x}{a}}{2\,{\mathrm {e}}^{2\,x}+{\mathrm {e}}^{4\,x}+1}-\frac {2}{a\,\left ({\mathrm {e}}^x+1\right )}-\frac {\frac {2}{a}+\frac {{\mathrm {e}}^x}{a}}{{\mathrm {e}}^{2\,x}+1}-\frac {3\,\mathrm {atan}\left (\frac {{\mathrm {e}}^x\,\sqrt {a^2}}{a}\right )}{\sqrt {a^2}} \] Input:
int(1/(cosh(x)^4*(a + a*cosh(x))),x)
Output:
8/(3*a*(3*exp(2*x) + 3*exp(4*x) + exp(6*x) + 1)) - (4/a - (2*exp(x))/a)/(2 *exp(2*x) + exp(4*x) + 1) - 2/(a*(exp(x) + 1)) - (2/a + exp(x)/a)/(exp(2*x ) + 1) - (3*atan((exp(x)*(a^2)^(1/2))/a))/(a^2)^(1/2)
Time = 0.21 (sec) , antiderivative size = 173, normalized size of antiderivative = 3.09 \[ \int \frac {\text {sech}^4(x)}{a+a \cosh (x)} \, dx=\frac {-9 e^{7 x} \mathit {atan} \left (e^{x}\right )-9 e^{6 x} \mathit {atan} \left (e^{x}\right )-27 e^{5 x} \mathit {atan} \left (e^{x}\right )-27 e^{4 x} \mathit {atan} \left (e^{x}\right )-27 e^{3 x} \mathit {atan} \left (e^{x}\right )-27 e^{2 x} \mathit {atan} \left (e^{x}\right )-9 e^{x} \mathit {atan} \left (e^{x}\right )-9 \mathit {atan} \left (e^{x}\right )+9 e^{7 x}+18 e^{5 x}+3 e^{4 x}+3 e^{3 x}-12 e^{2 x}+2 e^{x}-7}{3 a \left (e^{7 x}+e^{6 x}+3 e^{5 x}+3 e^{4 x}+3 e^{3 x}+3 e^{2 x}+e^{x}+1\right )} \] Input:
int(sech(x)^4/(a+a*cosh(x)),x)
Output:
( - 9*e**(7*x)*atan(e**x) - 9*e**(6*x)*atan(e**x) - 27*e**(5*x)*atan(e**x) - 27*e**(4*x)*atan(e**x) - 27*e**(3*x)*atan(e**x) - 27*e**(2*x)*atan(e**x ) - 9*e**x*atan(e**x) - 9*atan(e**x) + 9*e**(7*x) + 18*e**(5*x) + 3*e**(4* x) + 3*e**(3*x) - 12*e**(2*x) + 2*e**x - 7)/(3*a*(e**(7*x) + e**(6*x) + 3* e**(5*x) + 3*e**(4*x) + 3*e**(3*x) + 3*e**(2*x) + e**x + 1))