Optimal. Leaf size=44 \[ \frac{\log \left (\sqrt{3} \sin (x)+\cos (x)\right )}{2 \sqrt{3}}-\frac{\log \left (\cos (x)-\sqrt{3} \sin (x)\right )}{2 \sqrt{3}} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0362144, antiderivative size = 44, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 7, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.143, Rules used = {206} \[ \frac{\log \left (\sqrt{3} \sin (x)+\cos (x)\right )}{2 \sqrt{3}}-\frac{\log \left (\cos (x)-\sqrt{3} \sin (x)\right )}{2 \sqrt{3}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 206
Rubi steps
\begin{align*} \int \cos (x) \sec (3 x) \, dx &=\operatorname{Subst}\left (\int \frac{1}{1-3 x^2} \, dx,x,\tan (x)\right )\\ &=-\frac{\log \left (\cos (x)-\sqrt{3} \sin (x)\right )}{2 \sqrt{3}}+\frac{\log \left (\cos (x)+\sqrt{3} \sin (x)\right )}{2 \sqrt{3}}\\ \end{align*}
Mathematica [A] time = 0.0165691, size = 15, normalized size = 0.34 \[ \frac{\tanh ^{-1}\left (\sqrt{3} \tan (x)\right )}{\sqrt{3}} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.054, size = 13, normalized size = 0.3 \begin{align*}{\frac{\sqrt{3}{\it Artanh} \left ( \tan \left ( x \right ) \sqrt{3} \right ) }{3}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] time = 1.54449, size = 103, normalized size = 2.34 \begin{align*} \frac{1}{12} \, \sqrt{3}{\left (\log \left (\frac{4}{3} \, \cos \left (2 \, x\right )^{2} + \frac{4}{3} \, \sin \left (2 \, x\right )^{2} + \frac{4}{3} \, \sqrt{3} \sin \left (2 \, x\right ) - \frac{4}{3} \, \cos \left (2 \, x\right ) + \frac{4}{3}\right ) - \log \left (\frac{4}{3} \, \cos \left (2 \, x\right )^{2} + \frac{4}{3} \, \sin \left (2 \, x\right )^{2} - \frac{4}{3} \, \sqrt{3} \sin \left (2 \, x\right ) - \frac{4}{3} \, \cos \left (2 \, x\right ) + \frac{4}{3}\right )\right )} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 2.48839, size = 162, normalized size = 3.68 \begin{align*} \frac{1}{12} \, \sqrt{3} \log \left (-\frac{8 \, \cos \left (x\right )^{4} + 4 \,{\left (2 \, \sqrt{3} \cos \left (x\right )^{3} - 3 \, \sqrt{3} \cos \left (x\right )\right )} \sin \left (x\right ) - 9}{16 \, \cos \left (x\right )^{4} - 24 \, \cos \left (x\right )^{2} + 9}\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 \cos{\left (x \right )} \sec{\left (3 x \right )}\, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.15658, size = 42, normalized size = 0.95 \begin{align*} -\frac{1}{6} \, \sqrt{3} \log \left (\frac{{\left | -2 \, \sqrt{3} + 6 \, \tan \left (x\right ) \right |}}{{\left | 2 \, \sqrt{3} + 6 \, \tan \left (x\right ) \right |}}\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]