3.27 \(\int \frac{\cosh (x)}{a+a \cosh (x)} \, dx\)

Optimal. Leaf size=18 \[ \frac{x}{a}-\frac{\sinh (x)}{a \cosh (x)+a} \]

[Out]

x/a - Sinh[x]/(a + a*Cosh[x])

________________________________________________________________________________________

Rubi [A]  time = 0.0315345, antiderivative size = 18, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 11, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.182, Rules used = {2735, 2648} \[ \frac{x}{a}-\frac{\sinh (x)}{a \cosh (x)+a} \]

Antiderivative was successfully verified.

[In]

Int[Cosh[x]/(a + a*Cosh[x]),x]

[Out]

x/a - Sinh[x]/(a + a*Cosh[x])

Rule 2735

Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])/((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[(b*x)/d
, x] - Dist[(b*c - a*d)/d, Int[1/(c + d*Sin[e + f*x]), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d
, 0]

Rule 2648

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

Rubi steps

\begin{align*} \int \frac{\cosh (x)}{a+a \cosh (x)} \, dx &=\frac{x}{a}-\int \frac{1}{a+a \cosh (x)} \, dx\\ &=\frac{x}{a}-\frac{\sinh (x)}{a+a \cosh (x)}\\ \end{align*}

Mathematica [A]  time = 0.0239296, size = 14, normalized size = 0.78 \[ \frac{x-\tanh \left (\frac{x}{2}\right )}{a} \]

Antiderivative was successfully verified.

[In]

Integrate[Cosh[x]/(a + a*Cosh[x]),x]

[Out]

(x - Tanh[x/2])/a

________________________________________________________________________________________

Maple [A]  time = 0.011, size = 34, normalized size = 1.9 \begin{align*} -{\frac{1}{a}\tanh \left ({\frac{x}{2}} \right ) }-{\frac{1}{a}\ln \left ( \tanh \left ({\frac{x}{2}} \right ) -1 \right ) }+{\frac{1}{a}\ln \left ( \tanh \left ({\frac{x}{2}} \right ) +1 \right ) } \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cosh(x)/(a+a*cosh(x)),x)

[Out]

-1/a*tanh(1/2*x)-1/a*ln(tanh(1/2*x)-1)+1/a*ln(tanh(1/2*x)+1)

________________________________________________________________________________________

Maxima [A]  time = 1.26951, size = 24, normalized size = 1.33 \begin{align*} \frac{x}{a} - \frac{2}{a e^{\left (-x\right )} + a} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cosh(x)/(a+a*cosh(x)),x, algorithm="maxima")

[Out]

x/a - 2/(a*e^(-x) + a)

________________________________________________________________________________________

Fricas [A]  time = 1.92144, size = 82, normalized size = 4.56 \begin{align*} \frac{x \cosh \left (x\right ) + x \sinh \left (x\right ) + x + 2}{a \cosh \left (x\right ) + a \sinh \left (x\right ) + a} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cosh(x)/(a+a*cosh(x)),x, algorithm="fricas")

[Out]

(x*cosh(x) + x*sinh(x) + x + 2)/(a*cosh(x) + a*sinh(x) + a)

________________________________________________________________________________________

Sympy [A]  time = 0.414297, size = 8, normalized size = 0.44 \begin{align*} \frac{x}{a} - \frac{\tanh{\left (\frac{x}{2} \right )}}{a} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cosh(x)/(a+a*cosh(x)),x)

[Out]

x/a - tanh(x/2)/a

________________________________________________________________________________________

Giac [A]  time = 1.16483, size = 23, normalized size = 1.28 \begin{align*} \frac{x}{a} + \frac{2}{a{\left (e^{x} + 1\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cosh(x)/(a+a*cosh(x)),x, algorithm="giac")

[Out]

x/a + 2/(a*(e^x + 1))