Optimal. Leaf size=61 \[ \frac{\log \left (\sqrt{2} \cos (3 x+2)-\sin (3 x+2)\right )}{6 \sqrt{2}}-\frac{\log \left (\sin (3 x+2)+\sqrt{2} \cos (3 x+2)\right )}{6 \sqrt{2}} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0429416, antiderivative size = 61, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 21, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.095, Rules used = {3675, 207} \[ \frac{\log \left (\sqrt{2} \cos (3 x+2)-\sin (3 x+2)\right )}{6 \sqrt{2}}-\frac{\log \left (\sin (3 x+2)+\sqrt{2} \cos (3 x+2)\right )}{6 \sqrt{2}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3675
Rule 207
Rubi steps
\begin{align*} \int \frac{\sec ^2(2+3 x)}{-2+\tan ^2(2+3 x)} \, dx &=\frac{1}{3} \operatorname{Subst}\left (\int \frac{1}{-2+x^2} \, dx,x,\tan (2+3 x)\right )\\ &=\frac{\log \left (\sqrt{2} \cos (2+3 x)-\sin (2+3 x)\right )}{6 \sqrt{2}}-\frac{\log \left (\sqrt{2} \cos (2+3 x)+\sin (2+3 x)\right )}{6 \sqrt{2}}\\ \end{align*}
Mathematica [A] time = 0.0210346, size = 22, normalized size = 0.36 \[ -\frac{\tanh ^{-1}\left (\frac{\tan (3 x+2)}{\sqrt{2}}\right )}{3 \sqrt{2}} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.059, size = 18, normalized size = 0.3 \begin{align*} -{\frac{\sqrt{2}}{6}{\it Artanh} \left ({\frac{\tan \left ( 2+3\,x \right ) \sqrt{2}}{2}} \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 1.64842, size = 43, normalized size = 0.7 \begin{align*} \frac{1}{12} \, \sqrt{2} \log \left (-\frac{\sqrt{2} - \tan \left (3 \, x + 2\right )}{\sqrt{2} + \tan \left (3 \, x + 2\right )}\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 1.72201, size = 230, normalized size = 3.77 \begin{align*} \frac{1}{24} \, \sqrt{2} \log \left (-\frac{7 \, \cos \left (3 \, x + 2\right )^{4} - 10 \, \cos \left (3 \, x + 2\right )^{2} + 4 \,{\left (\sqrt{2} \cos \left (3 \, x + 2\right )^{3} + \sqrt{2} \cos \left (3 \, x + 2\right )\right )} \sin \left (3 \, x + 2\right ) - 1}{9 \, \cos \left (3 \, x + 2\right )^{4} - 6 \, \cos \left (3 \, x + 2\right )^{2} + 1}\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\sec ^{2}{\left (3 x + 2 \right )}}{\tan ^{2}{\left (3 x + 2 \right )} - 2}\, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.87334, size = 53, normalized size = 0.87 \begin{align*} \frac{1}{12} \, \sqrt{2} \log \left (\frac{{\left | -2 \, \sqrt{2} + 2 \, \tan \left (3 \, x + 2\right ) \right |}}{{\left | 2 \, \sqrt{2} + 2 \, \tan \left (3 \, x + 2\right ) \right |}}\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]