Integrand size = 8, antiderivative size = 97 \[ \int e^x \tanh (3 x) \, dx=e^x-\frac {2 \arctan \left (e^x\right )}{3}+\frac {1}{3} \arctan \left (\sqrt {3}-2 e^x\right )-\frac {1}{3} \arctan \left (\sqrt {3}+2 e^x\right )+\frac {\log \left (1-\sqrt {3} e^x+e^{2 x}\right )}{2 \sqrt {3}}-\frac {\log \left (1+\sqrt {3} e^x+e^{2 x}\right )}{2 \sqrt {3}} \]
[Out]
Time = 0.14 (sec) , antiderivative size = 97, normalized size of antiderivative = 1.00, number of steps used = 12, number of rules used = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 1.000, Rules used = {2320, 396, 215, 648, 632, 210, 642, 209} \[ \int e^x \tanh (3 x) \, dx=-\frac {2}{3} \arctan \left (e^x\right )+\frac {1}{3} \arctan \left (\sqrt {3}-2 e^x\right )-\frac {1}{3} \arctan \left (2 e^x+\sqrt {3}\right )+e^x+\frac {\log \left (-\sqrt {3} e^x+e^{2 x}+1\right )}{2 \sqrt {3}}-\frac {\log \left (\sqrt {3} e^x+e^{2 x}+1\right )}{2 \sqrt {3}} \]
[In]
[Out]
Rule 209
Rule 210
Rule 215
Rule 396
Rule 632
Rule 642
Rule 648
Rule 2320
Rubi steps \begin{align*} \text {integral}& = \text {Subst}\left (\int \frac {-1+x^6}{1+x^6} \, dx,x,e^x\right ) \\ & = e^x-2 \text {Subst}\left (\int \frac {1}{1+x^6} \, dx,x,e^x\right ) \\ & = e^x-\frac {2}{3} \text {Subst}\left (\int \frac {1}{1+x^2} \, dx,x,e^x\right )-\frac {2}{3} \text {Subst}\left (\int \frac {1-\frac {\sqrt {3} x}{2}}{1-\sqrt {3} x+x^2} \, dx,x,e^x\right )-\frac {2}{3} \text {Subst}\left (\int \frac {1+\frac {\sqrt {3} x}{2}}{1+\sqrt {3} x+x^2} \, dx,x,e^x\right ) \\ & = e^x-\frac {2 \arctan \left (e^x\right )}{3}-\frac {1}{6} \text {Subst}\left (\int \frac {1}{1-\sqrt {3} x+x^2} \, dx,x,e^x\right )-\frac {1}{6} \text {Subst}\left (\int \frac {1}{1+\sqrt {3} x+x^2} \, dx,x,e^x\right )+\frac {\text {Subst}\left (\int \frac {-\sqrt {3}+2 x}{1-\sqrt {3} x+x^2} \, dx,x,e^x\right )}{2 \sqrt {3}}-\frac {\text {Subst}\left (\int \frac {\sqrt {3}+2 x}{1+\sqrt {3} x+x^2} \, dx,x,e^x\right )}{2 \sqrt {3}} \\ & = e^x-\frac {2 \arctan \left (e^x\right )}{3}+\frac {\log \left (1-\sqrt {3} e^x+e^{2 x}\right )}{2 \sqrt {3}}-\frac {\log \left (1+\sqrt {3} e^x+e^{2 x}\right )}{2 \sqrt {3}}+\frac {1}{3} \text {Subst}\left (\int \frac {1}{-1-x^2} \, dx,x,-\sqrt {3}+2 e^x\right )+\frac {1}{3} \text {Subst}\left (\int \frac {1}{-1-x^2} \, dx,x,\sqrt {3}+2 e^x\right ) \\ & = e^x-\frac {2 \arctan \left (e^x\right )}{3}+\frac {1}{3} \arctan \left (\sqrt {3}-2 e^x\right )-\frac {1}{3} \arctan \left (\sqrt {3}+2 e^x\right )+\frac {\log \left (1-\sqrt {3} e^x+e^{2 x}\right )}{2 \sqrt {3}}-\frac {\log \left (1+\sqrt {3} e^x+e^{2 x}\right )}{2 \sqrt {3}} \\ \end{align*}
Result contains higher order function than in optimal. Order 5 vs. order 3 in optimal.
Time = 0.02 (sec) , antiderivative size = 24, normalized size of antiderivative = 0.25 \[ \int e^x \tanh (3 x) \, dx=e^x-2 e^x \operatorname {Hypergeometric2F1}\left (\frac {1}{6},1,\frac {7}{6},-e^{6 x}\right ) \]
[In]
[Out]
Result contains higher order function than in optimal. Order 9 vs. order 3.
Time = 0.16 (sec) , antiderivative size = 47, normalized size of antiderivative = 0.48
method | result | size |
risch | \({\mathrm e}^{x}+\left (\munderset {\textit {\_R} =\operatorname {RootOf}\left (81 \textit {\_Z}^{4}-9 \textit {\_Z}^{2}+1\right )}{\sum }\textit {\_R} \ln \left ({\mathrm e}^{x}-3 \textit {\_R} \right )\right )+\frac {i \ln \left ({\mathrm e}^{x}-i\right )}{3}-\frac {i \ln \left ({\mathrm e}^{x}+i\right )}{3}\) | \(47\) |
[In]
[Out]
Result contains complex when optimal does not.
Time = 0.27 (sec) , antiderivative size = 137, normalized size of antiderivative = 1.41 \[ \int e^x \tanh (3 x) \, dx=-\frac {1}{6} \, \sqrt {2 i \, \sqrt {3} + 2} \log \left (\sqrt {2 i \, \sqrt {3} + 2} + 2 \, \cosh \left (x\right ) + 2 \, \sinh \left (x\right )\right ) + \frac {1}{6} \, \sqrt {2 i \, \sqrt {3} + 2} \log \left (-\sqrt {2 i \, \sqrt {3} + 2} + 2 \, \cosh \left (x\right ) + 2 \, \sinh \left (x\right )\right ) - \frac {1}{6} \, \sqrt {-2 i \, \sqrt {3} + 2} \log \left (\sqrt {-2 i \, \sqrt {3} + 2} + 2 \, \cosh \left (x\right ) + 2 \, \sinh \left (x\right )\right ) + \frac {1}{6} \, \sqrt {-2 i \, \sqrt {3} + 2} \log \left (-\sqrt {-2 i \, \sqrt {3} + 2} + 2 \, \cosh \left (x\right ) + 2 \, \sinh \left (x\right )\right ) - \frac {2}{3} \, \arctan \left (\cosh \left (x\right ) + \sinh \left (x\right )\right ) + \cosh \left (x\right ) + \sinh \left (x\right ) \]
[In]
[Out]
\[ \int e^x \tanh (3 x) \, dx=\int e^{x} \tanh {\left (3 x \right )}\, dx \]
[In]
[Out]
none
Time = 0.28 (sec) , antiderivative size = 69, normalized size of antiderivative = 0.71 \[ \int e^x \tanh (3 x) \, dx=-\frac {1}{6} \, \sqrt {3} \log \left (\sqrt {3} e^{x} + e^{\left (2 \, x\right )} + 1\right ) + \frac {1}{6} \, \sqrt {3} \log \left (-\sqrt {3} e^{x} + e^{\left (2 \, x\right )} + 1\right ) - \frac {1}{3} \, \arctan \left (\sqrt {3} + 2 \, e^{x}\right ) - \frac {1}{3} \, \arctan \left (-\sqrt {3} + 2 \, e^{x}\right ) - \frac {2}{3} \, \arctan \left (e^{x}\right ) + e^{x} \]
[In]
[Out]
none
Time = 0.27 (sec) , antiderivative size = 69, normalized size of antiderivative = 0.71 \[ \int e^x \tanh (3 x) \, dx=-\frac {1}{6} \, \sqrt {3} \log \left (\sqrt {3} e^{x} + e^{\left (2 \, x\right )} + 1\right ) + \frac {1}{6} \, \sqrt {3} \log \left (-\sqrt {3} e^{x} + e^{\left (2 \, x\right )} + 1\right ) - \frac {1}{3} \, \arctan \left (\sqrt {3} + 2 \, e^{x}\right ) - \frac {1}{3} \, \arctan \left (-\sqrt {3} + 2 \, e^{x}\right ) - \frac {2}{3} \, \arctan \left (e^{x}\right ) + e^{x} \]
[In]
[Out]
Time = 0.25 (sec) , antiderivative size = 70, normalized size of antiderivative = 0.72 \[ \int e^x \tanh (3 x) \, dx={\mathrm {e}}^x-\frac {\mathrm {atan}\left (2\,{\mathrm {e}}^x+\sqrt {3}\right )}{3}-\frac {\mathrm {atan}\left (2\,{\mathrm {e}}^x-\sqrt {3}\right )}{3}-\frac {2\,\mathrm {atan}\left ({\mathrm {e}}^x\right )}{3}+\frac {\sqrt {3}\,\ln \left ({\left (2\,{\mathrm {e}}^x-\sqrt {3}\right )}^2+1\right )}{6}-\frac {\sqrt {3}\,\ln \left ({\left (2\,{\mathrm {e}}^x+\sqrt {3}\right )}^2+1\right )}{6} \]
[In]
[Out]