3.1.75 \(\int \frac {1}{5+3 \cosh (c+d x)} \, dx\) [75]

Optimal. Leaf size=31 \[ \frac {x}{4}-\frac {\tanh ^{-1}\left (\frac {\sinh (c+d x)}{3+\cosh (c+d x)}\right )}{2 d} \]

[Out]

1/4*x-1/2*arctanh(sinh(d*x+c)/(3+cosh(d*x+c)))/d

________________________________________________________________________________________

Rubi [A]
time = 0.01, antiderivative size = 31, normalized size of antiderivative = 1.00, number of steps used = 1, number of rules used = 1, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.083, Rules used = {2736} \begin {gather*} \frac {x}{4}-\frac {\tanh ^{-1}\left (\frac {\sinh (c+d x)}{\cosh (c+d x)+3}\right )}{2 d} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(5 + 3*Cosh[c + d*x])^(-1),x]

[Out]

x/4 - ArcTanh[Sinh[c + d*x]/(3 + Cosh[c + d*x])]/(2*d)

Rule 2736

Int[((a_) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> With[{q = Rt[a^2 - b^2, 2]}, Simp[x/q, x] + Simp
[(2/(d*q))*ArcTan[b*(Cos[c + d*x]/(a + q + b*Sin[c + d*x]))], x]] /; FreeQ[{a, b, c, d}, x] && GtQ[a^2 - b^2,
0] && PosQ[a]

Rubi steps

\begin {align*} \int \frac {1}{5+3 \cosh (c+d x)} \, dx &=\frac {x}{4}-\frac {\tanh ^{-1}\left (\frac {\sinh (c+d x)}{3+\cosh (c+d x)}\right )}{2 d}\\ \end {align*}

________________________________________________________________________________________

Mathematica [B] Leaf count is larger than twice the leaf count of optimal. \(77\) vs. \(2(31)=62\).
time = 0.02, size = 77, normalized size = 2.48 \begin {gather*} -\frac {\log \left (2 \cosh \left (\frac {c}{2}+\frac {d x}{2}\right )-\sinh \left (\frac {c}{2}+\frac {d x}{2}\right )\right )}{4 d}+\frac {\log \left (2 \cosh \left (\frac {c}{2}+\frac {d x}{2}\right )+\sinh \left (\frac {c}{2}+\frac {d x}{2}\right )\right )}{4 d} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(5 + 3*Cosh[c + d*x])^(-1),x]

[Out]

-1/4*Log[2*Cosh[c/2 + (d*x)/2] - Sinh[c/2 + (d*x)/2]]/d + Log[2*Cosh[c/2 + (d*x)/2] + Sinh[c/2 + (d*x)/2]]/(4*
d)

________________________________________________________________________________________

Maple [A]
time = 0.85, size = 34, normalized size = 1.10

method result size
risch \(-\frac {\ln \left (3+{\mathrm e}^{d x +c}\right )}{4 d}+\frac {\ln \left ({\mathrm e}^{d x +c}+\frac {1}{3}\right )}{4 d}\) \(30\)
derivativedivides \(\frac {\frac {\ln \left (\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )+2\right )}{4}-\frac {\ln \left (\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )-2\right )}{4}}{d}\) \(34\)
default \(\frac {\frac {\ln \left (\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )+2\right )}{4}-\frac {\ln \left (\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )-2\right )}{4}}{d}\) \(34\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(5+3*cosh(d*x+c)),x,method=_RETURNVERBOSE)

[Out]

1/d*(1/4*ln(tanh(1/2*d*x+1/2*c)+2)-1/4*ln(tanh(1/2*d*x+1/2*c)-2))

________________________________________________________________________________________

Maxima [A]
time = 0.27, size = 37, normalized size = 1.19 \begin {gather*} -\frac {\log \left (3 \, e^{\left (-d x - c\right )} + 1\right )}{4 \, d} + \frac {\log \left (e^{\left (-d x - c\right )} + 3\right )}{4 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(5+3*cosh(d*x+c)),x, algorithm="maxima")

[Out]

-1/4*log(3*e^(-d*x - c) + 1)/d + 1/4*log(e^(-d*x - c) + 3)/d

________________________________________________________________________________________

Fricas [A]
time = 0.44, size = 42, normalized size = 1.35 \begin {gather*} \frac {\log \left (3 \, \cosh \left (d x + c\right ) + 3 \, \sinh \left (d x + c\right ) + 1\right ) - \log \left (\cosh \left (d x + c\right ) + \sinh \left (d x + c\right ) + 3\right )}{4 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(5+3*cosh(d*x+c)),x, algorithm="fricas")

[Out]

1/4*(log(3*cosh(d*x + c) + 3*sinh(d*x + c) + 1) - log(cosh(d*x + c) + sinh(d*x + c) + 3))/d

________________________________________________________________________________________

Sympy [A]
time = 0.35, size = 41, normalized size = 1.32 \begin {gather*} \begin {cases} - \frac {\log {\left (\tanh {\left (\frac {c}{2} + \frac {d x}{2} \right )} - 2 \right )}}{4 d} + \frac {\log {\left (\tanh {\left (\frac {c}{2} + \frac {d x}{2} \right )} + 2 \right )}}{4 d} & \text {for}\: d \neq 0 \\\frac {x}{3 \cosh {\left (c \right )} + 5} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(5+3*cosh(d*x+c)),x)

[Out]

Piecewise((-log(tanh(c/2 + d*x/2) - 2)/(4*d) + log(tanh(c/2 + d*x/2) + 2)/(4*d), Ne(d, 0)), (x/(3*cosh(c) + 5)
, True))

________________________________________________________________________________________

Giac [A]
time = 0.40, size = 28, normalized size = 0.90 \begin {gather*} \frac {\log \left (3 \, e^{\left (d x + c\right )} + 1\right ) - \log \left (e^{\left (d x + c\right )} + 3\right )}{4 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(5+3*cosh(d*x+c)),x, algorithm="giac")

[Out]

1/4*(log(3*e^(d*x + c) + 1) - log(e^(d*x + c) + 3))/d

________________________________________________________________________________________

Mupad [B]
time = 0.94, size = 40, normalized size = 1.29 \begin {gather*} -\frac {\mathrm {atan}\left (\frac {5\,\sqrt {-d^2}+3\,{\mathrm {e}}^{d\,x}\,{\mathrm {e}}^c\,\sqrt {-d^2}}{4\,d}\right )}{2\,\sqrt {-d^2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(3*cosh(c + d*x) + 5),x)

[Out]

-atan((5*(-d^2)^(1/2) + 3*exp(d*x)*exp(c)*(-d^2)^(1/2))/(4*d))/(2*(-d^2)^(1/2))

________________________________________________________________________________________