Optimal. Leaf size=44 \[ \frac {x}{3}-\frac {1}{6} \log \left (3 e^x+e^{2 x}+3\right )-\frac {\tan ^{-1}\left (\frac {2 e^x+3}{\sqrt {3}}\right )}{\sqrt {3}} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.04, antiderivative size = 44, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 7, integrand size = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.500, Rules used = {2282, 705, 29, 634, 618, 204, 628} \[ \frac {x}{3}-\frac {1}{6} \log \left (3 e^x+e^{2 x}+3\right )-\frac {\tan ^{-1}\left (\frac {2 e^x+3}{\sqrt {3}}\right )}{\sqrt {3}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 29
Rule 204
Rule 618
Rule 628
Rule 634
Rule 705
Rule 2282
Rubi steps
\begin {align*} \int \frac {1}{3+3 e^x+e^{2 x}} \, dx &=\operatorname {Subst}\left (\int \frac {1}{x \left (3+3 x+x^2\right )} \, dx,x,e^x\right )\\ &=\frac {1}{3} \operatorname {Subst}\left (\int \frac {1}{x} \, dx,x,e^x\right )+\frac {1}{3} \operatorname {Subst}\left (\int \frac {-3-x}{3+3 x+x^2} \, dx,x,e^x\right )\\ &=\frac {x}{3}-\frac {1}{6} \operatorname {Subst}\left (\int \frac {3+2 x}{3+3 x+x^2} \, dx,x,e^x\right )-\frac {1}{2} \operatorname {Subst}\left (\int \frac {1}{3+3 x+x^2} \, dx,x,e^x\right )\\ &=\frac {x}{3}-\frac {1}{6} \log \left (3+3 e^x+e^{2 x}\right )+\operatorname {Subst}\left (\int \frac {1}{-3-x^2} \, dx,x,3+2 e^x\right )\\ &=\frac {x}{3}-\frac {\tan ^{-1}\left (\frac {3+2 e^x}{\sqrt {3}}\right )}{\sqrt {3}}-\frac {1}{6} \log \left (3+3 e^x+e^{2 x}\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.02, size = 44, normalized size = 1.00 \[ \frac {x}{3}-\frac {1}{6} \log \left (3 e^x+e^{2 x}+3\right )-\frac {\tan ^{-1}\left (\frac {2 e^x+3}{\sqrt {3}}\right )}{\sqrt {3}} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.44, size = 34, normalized size = 0.77 \[ -\frac {1}{3} \, \sqrt {3} \arctan \left (\frac {2}{3} \, \sqrt {3} e^{x} + \sqrt {3}\right ) + \frac {1}{3} \, x - \frac {1}{6} \, \log \left (e^{\left (2 \, x\right )} + 3 \, e^{x} + 3\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.29, size = 34, normalized size = 0.77 \[ -\frac {1}{3} \, \sqrt {3} \arctan \left (\frac {1}{3} \, \sqrt {3} {\left (2 \, e^{x} + 3\right )}\right ) + \frac {1}{3} \, x - \frac {1}{6} \, \log \left (e^{\left (2 \, x\right )} + 3 \, e^{x} + 3\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.02, size = 37, normalized size = 0.84 \[ -\frac {\sqrt {3}\, \arctan \left (\frac {\left (2 \,{\mathrm e}^{x}+3\right ) \sqrt {3}}{3}\right )}{3}-\frac {\ln \left (3 \,{\mathrm e}^{x}+{\mathrm e}^{2 x}+3\right )}{6}+\frac {\ln \left ({\mathrm e}^{x}\right )}{3} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 2.02, size = 34, normalized size = 0.77 \[ -\frac {1}{3} \, \sqrt {3} \arctan \left (\frac {1}{3} \, \sqrt {3} {\left (2 \, e^{x} + 3\right )}\right ) + \frac {1}{3} \, x - \frac {1}{6} \, \log \left (e^{\left (2 \, x\right )} + 3 \, e^{x} + 3\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 3.52, size = 34, normalized size = 0.77 \[ \frac {x}{3}-\frac {\ln \left ({\mathrm {e}}^{2\,x}+3\,{\mathrm {e}}^x+3\right )}{6}-\frac {\sqrt {3}\,\mathrm {atan}\left (\sqrt {3}+\frac {2\,\sqrt {3}\,{\mathrm {e}}^x}{3}\right )}{3} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.13, size = 24, normalized size = 0.55 \[ \frac {x}{3} + \operatorname {RootSum} {\left (9 z^{2} + 3 z + 1, \left (i \mapsto i \log {\left (- 3 i + e^{x} + 1 \right )} \right )\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________