3.1.65 \(\int \frac {1}{4+6 \tanh (c+d x)} \, dx\) [65]

Optimal. Leaf size=31 \[ -\frac {x}{5}+\frac {3 \log (2 \cosh (c+d x)+3 \sinh (c+d x))}{10 d} \]

[Out]

-1/5*x+3/10*ln(2*cosh(d*x+c)+3*sinh(d*x+c))/d

________________________________________________________________________________________

Rubi [A]
time = 0.03, antiderivative size = 31, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {3565, 3611} \begin {gather*} \frac {3 \log (3 \sinh (c+d x)+2 \cosh (c+d x))}{10 d}-\frac {x}{5} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(4 + 6*Tanh[c + d*x])^(-1),x]

[Out]

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

Rule 3565

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

Rule 3611

Int[((c_) + (d_.)*tan[(e_.) + (f_.)*(x_)])/((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[(c/(b*f))
*Log[RemoveContent[a*Cos[e + f*x] + b*Sin[e + f*x], x]], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d,
0] && NeQ[a^2 + b^2, 0] && EqQ[a*c + b*d, 0]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]
time = 0.03, size = 55, normalized size = 1.77 \begin {gather*} -\frac {\log (6-6 \tanh (c+d x))}{20 d}+\frac {3 \log (4+6 \tanh (c+d x))}{10 d}-\frac {\log (6+6 \tanh (c+d x))}{4 d} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(4 + 6*Tanh[c + d*x])^(-1),x]

[Out]

-1/20*Log[6 - 6*Tanh[c + d*x]]/d + (3*Log[4 + 6*Tanh[c + d*x]])/(10*d) - Log[6 + 6*Tanh[c + d*x]]/(4*d)

________________________________________________________________________________________

Maple [A]
time = 0.63, size = 42, normalized size = 1.35

method result size
risch \(-\frac {x}{2}-\frac {3 c}{5 d}+\frac {3 \ln \left ({\mathrm e}^{2 d x +2 c}-\frac {1}{5}\right )}{10 d}\) \(28\)
derivativedivides \(\frac {\frac {3 \ln \left (2+3 \tanh \left (d x +c \right )\right )}{5}-\frac {\ln \left (\tanh \left (d x +c \right )-1\right )}{10}-\frac {\ln \left (\tanh \left (d x +c \right )+1\right )}{2}}{2 d}\) \(42\)
default \(\frac {\frac {3 \ln \left (2+3 \tanh \left (d x +c \right )\right )}{5}-\frac {\ln \left (\tanh \left (d x +c \right )-1\right )}{10}-\frac {\ln \left (\tanh \left (d x +c \right )+1\right )}{2}}{2 d}\) \(42\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(4+6*tanh(d*x+c)),x,method=_RETURNVERBOSE)

[Out]

1/2/d*(3/5*ln(2+3*tanh(d*x+c))-1/10*ln(tanh(d*x+c)-1)-1/2*ln(tanh(d*x+c)+1))

________________________________________________________________________________________

Maxima [A]
time = 0.26, size = 28, normalized size = 0.90 \begin {gather*} \frac {d x + c}{10 \, d} + \frac {3 \, \log \left (e^{\left (-2 \, d x - 2 \, c\right )} - 5\right )}{10 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(4+6*tanh(d*x+c)),x, algorithm="maxima")

[Out]

1/10*(d*x + c)/d + 3/10*log(e^(-2*d*x - 2*c) - 5)/d

________________________________________________________________________________________

Fricas [A]
time = 0.44, size = 49, normalized size = 1.58 \begin {gather*} -\frac {5 \, d x - 3 \, \log \left (\frac {2 \, {\left (2 \, \cosh \left (d x + c\right ) + 3 \, \sinh \left (d x + c\right )\right )}}{\cosh \left (d x + c\right ) - \sinh \left (d x + c\right )}\right )}{10 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(4+6*tanh(d*x+c)),x, algorithm="fricas")

[Out]

-1/10*(5*d*x - 3*log(2*(2*cosh(d*x + c) + 3*sinh(d*x + c))/(cosh(d*x + c) - sinh(d*x + c))))/d

________________________________________________________________________________________

Sympy [A]
time = 0.23, size = 42, normalized size = 1.35 \begin {gather*} \begin {cases} \frac {x}{10} - \frac {3 \log {\left (\tanh {\left (c + d x \right )} + 1 \right )}}{10 d} + \frac {3 \log {\left (3 \tanh {\left (c + d x \right )} + 2 \right )}}{10 d} & \text {for}\: d \neq 0 \\\frac {x}{6 \tanh {\left (c \right )} + 4} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(4+6*tanh(d*x+c)),x)

[Out]

Piecewise((x/10 - 3*log(tanh(c + d*x) + 1)/(10*d) + 3*log(3*tanh(c + d*x) + 2)/(10*d), Ne(d, 0)), (x/(6*tanh(c
) + 4), True))

________________________________________________________________________________________

Giac [A]
time = 0.41, size = 30, normalized size = 0.97 \begin {gather*} -\frac {5 \, d x + 5 \, c - 3 \, \log \left ({\left | 5 \, e^{\left (2 \, d x + 2 \, c\right )} - 1 \right |}\right )}{10 \, d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(4+6*tanh(d*x+c)),x, algorithm="giac")

[Out]

-1/10*(5*d*x + 5*c - 3*log(abs(5*e^(2*d*x + 2*c) - 1)))/d

________________________________________________________________________________________

Mupad [B]
time = 0.13, size = 34, normalized size = 1.10 \begin {gather*} \frac {x}{10}-\frac {\frac {3\,\ln \left (\mathrm {tanh}\left (c+d\,x\right )+1\right )}{10}-\frac {3\,\ln \left (3\,\mathrm {tanh}\left (c+d\,x\right )+2\right )}{10}}{d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(6*tanh(c + d*x) + 4),x)

[Out]

x/10 - ((3*log(tanh(c + d*x) + 1))/10 - (3*log(3*tanh(c + d*x) + 2))/10)/d

________________________________________________________________________________________