Optimal. Leaf size=39 \[ \frac {3 x}{4}-\frac {e^{-2 x}}{8}+\frac {e^{-x}}{4}+\frac {e^x}{4}-\log \left (e^x+1\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.05, antiderivative size = 39, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {2282, 12, 894} \[ \frac {3 x}{4}-\frac {e^{-2 x}}{8}+\frac {e^{-x}}{4}+\frac {e^x}{4}-\log \left (e^x+1\right ) \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 894
Rule 2282
Rubi steps
\begin {align*} \int \frac {\cosh ^2(x)}{1+e^x} \, dx &=\operatorname {Subst}\left (\int \frac {\left (1+x^2\right )^2}{4 x^3 (1+x)} \, dx,x,e^x\right )\\ &=\frac {1}{4} \operatorname {Subst}\left (\int \frac {\left (1+x^2\right )^2}{x^3 (1+x)} \, dx,x,e^x\right )\\ &=\frac {1}{4} \operatorname {Subst}\left (\int \left (1+\frac {1}{x^3}-\frac {1}{x^2}+\frac {3}{x}-\frac {4}{1+x}\right ) \, dx,x,e^x\right )\\ &=-\frac {1}{8} e^{-2 x}+\frac {e^{-x}}{4}+\frac {e^x}{4}+\frac {3 x}{4}-\log \left (1+e^x\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.03, size = 33, normalized size = 0.85 \[ \frac {1}{4} \left (3 x-\frac {e^{-2 x}}{2}+e^{-x}+e^x-4 \log \left (e^x+1\right )\right ) \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 0.42, size = 95, normalized size = 2.44 \[ \frac {6 \, x \cosh \relax (x)^{2} + 2 \, \cosh \relax (x)^{3} + 6 \, {\left (x + \cosh \relax (x)\right )} \sinh \relax (x)^{2} + 2 \, \sinh \relax (x)^{3} - 8 \, {\left (\cosh \relax (x)^{2} + 2 \, \cosh \relax (x) \sinh \relax (x) + \sinh \relax (x)^{2}\right )} \log \left (\cosh \relax (x) + \sinh \relax (x) + 1\right ) + 2 \, {\left (6 \, x \cosh \relax (x) + 3 \, \cosh \relax (x)^{2} + 1\right )} \sinh \relax (x) + 2 \, \cosh \relax (x) - 1}{8 \, {\left (\cosh \relax (x)^{2} + 2 \, \cosh \relax (x) \sinh \relax (x) + \sinh \relax (x)^{2}\right )}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.11, size = 27, normalized size = 0.69 \[ \frac {1}{8} \, {\left (2 \, e^{x} - 1\right )} e^{\left (-2 \, x\right )} + \frac {3}{4} \, x + \frac {1}{4} \, e^{x} - \log \left (e^{x} + 1\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.08, size = 48, normalized size = 1.23 \[ -\frac {1}{2 \left (\tanh \left (\frac {x}{2}\right )-1\right )}+\frac {\ln \left (\tanh \left (\frac {x}{2}\right )-1\right )}{4}-\frac {1}{2 \left (\tanh \left (\frac {x}{2}\right )+1\right )^{2}}+\frac {1}{\tanh \left (\frac {x}{2}\right )+1}+\frac {3 \ln \left (\tanh \left (\frac {x}{2}\right )+1\right )}{4} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.31, size = 27, normalized size = 0.69 \[ \frac {1}{8} \, {\left (2 \, e^{x} - 1\right )} e^{\left (-2 \, x\right )} + \frac {3}{4} \, x + \frac {1}{4} \, e^{x} - \log \left (e^{x} + 1\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.06, size = 27, normalized size = 0.69 \[ \frac {3\,x}{4}+\frac {{\mathrm {e}}^{-x}}{4}-\frac {{\mathrm {e}}^{-2\,x}}{8}-\ln \left ({\mathrm {e}}^x+1\right )+\frac {{\mathrm {e}}^x}{4} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\cosh ^{2}{\relax (x )}}{e^{x} + 1}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________