3.675 \(\int (\text {csch}(x)+\sinh (x))^2 \, dx\)

Optimal. Leaf size=22 \[ \frac {3 x}{2}-\frac {3 \coth (x)}{2}+\frac {1}{2} \cosh ^2(x) \coth (x) \]

[Out]

3/2*x-3/2*coth(x)+1/2*cosh(x)^2*coth(x)

________________________________________________________________________________________

Rubi [A]  time = 0.02, antiderivative size = 22, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.429, Rules used = {290, 325, 206} \[ \frac {3 x}{2}-\frac {3 \coth (x)}{2}+\frac {1}{2} \cosh ^2(x) \coth (x) \]

Antiderivative was successfully verified.

[In]

Int[(Csch[x] + Sinh[x])^2,x]

[Out]

(3*x)/2 - (3*Coth[x])/2 + (Cosh[x]^2*Coth[x])/2

Rule 206

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

Rule 290

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> -Simp[((c*x)^(m + 1)*(a + b*x^n)^(p + 1))/(
a*c*n*(p + 1)), x] + Dist[(m + n*(p + 1) + 1)/(a*n*(p + 1)), Int[(c*x)^m*(a + b*x^n)^(p + 1), x], x] /; FreeQ[
{a, b, c, m}, x] && IGtQ[n, 0] && LtQ[p, -1] && IntBinomialQ[a, b, c, n, m, p, x]

Rule 325

Int[((c_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[((c*x)^(m + 1)*(a + b*x^n)^(p + 1))/(a*
c*(m + 1)), x] - Dist[(b*(m + n*(p + 1) + 1))/(a*c^n*(m + 1)), Int[(c*x)^(m + n)*(a + b*x^n)^p, x], x] /; Free
Q[{a, b, c, p}, x] && IGtQ[n, 0] && LtQ[m, -1] && IntBinomialQ[a, b, c, n, m, p, x]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.00, size = 18, normalized size = 0.82 \[ \frac {3 x}{2}+\frac {1}{4} \sinh (2 x)-\coth (x) \]

Antiderivative was successfully verified.

[In]

Integrate[(Csch[x] + Sinh[x])^2,x]

[Out]

(3*x)/2 - Coth[x] + Sinh[2*x]/4

________________________________________________________________________________________

fricas [A]  time = 0.41, size = 32, normalized size = 1.45 \[ \frac {\cosh \relax (x)^{3} + 3 \, \cosh \relax (x) \sinh \relax (x)^{2} + 4 \, {\left (3 \, x + 2\right )} \sinh \relax (x) - 9 \, \cosh \relax (x)}{8 \, \sinh \relax (x)} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((csch(x)+sinh(x))^2,x, algorithm="fricas")

[Out]

1/8*(cosh(x)^3 + 3*cosh(x)*sinh(x)^2 + 4*(3*x + 2)*sinh(x) - 9*cosh(x))/sinh(x)

________________________________________________________________________________________

giac [B]  time = 0.11, size = 39, normalized size = 1.77 \[ \frac {3}{2} \, x - \frac {3 \, e^{\left (4 \, x\right )} + 14 \, e^{\left (2 \, x\right )} - 1}{8 \, {\left (e^{\left (4 \, x\right )} - e^{\left (2 \, x\right )}\right )}} + \frac {1}{8} \, e^{\left (2 \, x\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((csch(x)+sinh(x))^2,x, algorithm="giac")

[Out]

3/2*x - 1/8*(3*e^(4*x) + 14*e^(2*x) - 1)/(e^(4*x) - e^(2*x)) + 1/8*e^(2*x)

________________________________________________________________________________________

maple [A]  time = 0.40, size = 15, normalized size = 0.68 \[ -\coth \relax (x )+\frac {3 x}{2}+\frac {\cosh \relax (x ) \sinh \relax (x )}{2} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((csch(x)+sinh(x))^2,x)

[Out]

-coth(x)+3/2*x+1/2*cosh(x)*sinh(x)

________________________________________________________________________________________

maxima [A]  time = 0.36, size = 26, normalized size = 1.18 \[ \frac {3}{2} \, x + \frac {2}{e^{\left (-2 \, x\right )} - 1} + \frac {1}{8} \, e^{\left (2 \, x\right )} - \frac {1}{8} \, e^{\left (-2 \, x\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((csch(x)+sinh(x))^2,x, algorithm="maxima")

[Out]

3/2*x + 2/(e^(-2*x) - 1) + 1/8*e^(2*x) - 1/8*e^(-2*x)

________________________________________________________________________________________

mupad [B]  time = 1.58, size = 26, normalized size = 1.18 \[ \frac {3\,x}{2}-\frac {{\mathrm {e}}^{-2\,x}}{8}+\frac {{\mathrm {e}}^{2\,x}}{8}-\frac {2}{{\mathrm {e}}^{2\,x}-1} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((sinh(x) + 1/sinh(x))^2,x)

[Out]

(3*x)/2 - exp(-2*x)/8 + exp(2*x)/8 - 2/(exp(2*x) - 1)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \left (\sinh {\relax (x )} + \operatorname {csch}{\relax (x )}\right )^{2}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((csch(x)+sinh(x))**2,x)

[Out]

Integral((sinh(x) + csch(x))**2, x)

________________________________________________________________________________________