Optimal. Leaf size=133 \[ \sqrt {3} \tan ^{-1}\left (\frac {1+2 \sqrt [6]{1-3 \sec ^2(x)}}{\sqrt {3}}\right )+\frac {1}{4} \log \left (\sec ^2(x)\right )-\frac {3}{2} \log \left (1-\sqrt [6]{1-3 \sec ^2(x)}\right )+\frac {1}{3} \log \left (1-\sqrt {1-3 \sec ^2(x)}\right )-\sqrt [6]{1-3 \sec ^2(x)}-\frac {1}{4} \left (1-3 \sec ^2(x)\right )^{2/3}+\frac {1}{2 \left (1-\sqrt {1-3 \sec ^2(x)}\right )} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 3.37, antiderivative size = 174, normalized size of antiderivative = 1.31, number
of steps used = 29, number of rules used = 16, integrand size = 61, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.262, Rules
used = {4446, 6874, 6816, 267, 6829, 348, 59, 632, 210, 31, 6820, 272, 43, 65, 212, 25}
\begin {gather*} \sqrt {3} \text {ArcTan}\left (\frac {2 \sqrt [6]{1-3 \sec ^2(x)}+1}{\sqrt {3}}\right )+\frac {\cos ^2(x)}{6}-\frac {1}{4} \left (1-3 \sec ^2(x)\right )^{2/3}-\sqrt [6]{1-3 \sec ^2(x)}-\frac {3}{2} \log \left (1-\sqrt [6]{1-3 \sec ^2(x)}\right )+\frac {1}{2} \log \left (1-\sqrt {1-3 \sec ^2(x)}\right )+\frac {1}{6} \cos ^2(x) \sqrt {1-3 \sec ^2(x)}+\frac {1}{2} \tanh ^{-1}\left (\sqrt {1-3 \sec ^2(x)}\right )+\frac {1}{3} \log \left (1-\sqrt {-\left (\left (3-\cos ^2(x)\right ) \sec ^2(x)\right )}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 25
Rule 31
Rule 43
Rule 59
Rule 65
Rule 210
Rule 212
Rule 267
Rule 272
Rule 348
Rule 632
Rule 4446
Rule 6816
Rule 6820
Rule 6829
Rule 6874
Rubi steps
\begin {align*} \int \frac {\sec ^2(x) \tan (x) \left (\sqrt [3]{1-3 \sec ^2(x)} \sin ^2(x)+3 \tan ^2(x)\right )}{\left (1-3 \sec ^2(x)\right )^{5/6} \left (1-\sqrt {1-3 \sec ^2(x)}\right )} \, dx &=-\text {Subst}\left (\int \frac {\left (1-x^2\right ) \left (3+\sqrt [3]{1-\frac {3}{x^2}} x^2\right )}{\left (1-\sqrt {1-\frac {3}{x^2}}\right ) \left (1-\frac {3}{x^2}\right )^{5/6} x^5} \, dx,x,\cos (x)\right )\\ &=-\text {Subst}\left (\int \left (\frac {-3-x^2 \sqrt [3]{\frac {-3+x^2}{x^2}}}{\left (1-\frac {3}{x^2}\right )^{5/6} x^5 \left (-1+\sqrt {\frac {-3+x^2}{x^2}}\right )}+\frac {3+x^2 \sqrt [3]{\frac {-3+x^2}{x^2}}}{\left (1-\frac {3}{x^2}\right )^{5/6} x^3 \left (-1+\sqrt {\frac {-3+x^2}{x^2}}\right )}\right ) \, dx,x,\cos (x)\right )\\ &=-\text {Subst}\left (\int \frac {-3-x^2 \sqrt [3]{\frac {-3+x^2}{x^2}}}{\left (1-\frac {3}{x^2}\right )^{5/6} x^5 \left (-1+\sqrt {\frac {-3+x^2}{x^2}}\right )} \, dx,x,\cos (x)\right )-\text {Subst}\left (\int \frac {3+x^2 \sqrt [3]{\frac {-3+x^2}{x^2}}}{\left (1-\frac {3}{x^2}\right )^{5/6} x^3 \left (-1+\sqrt {\frac {-3+x^2}{x^2}}\right )} \, dx,x,\cos (x)\right )\\ &=-\text {Subst}\left (\int \left (\frac {1}{\sqrt {1-\frac {3}{x^2}} x^3 \left (1-\sqrt {\frac {-3+x^2}{x^2}}\right )}-\frac {3}{\left (1-\frac {3}{x^2}\right )^{5/6} x^5 \left (-1+\sqrt {\frac {-3+x^2}{x^2}}\right )}\right ) \, dx,x,\cos (x)\right )-\text {Subst}\left (\int \left (\frac {3}{\left (1-\frac {3}{x^2}\right )^{5/6} x^3 \left (-1+\sqrt {\frac {-3+x^2}{x^2}}\right )}+\frac {1}{\sqrt {1-\frac {3}{x^2}} x \left (-1+\sqrt {\frac {-3+x^2}{x^2}}\right )}\right ) \, dx,x,\cos (x)\right )\\ &=3 \text {Subst}\left (\int \frac {1}{\left (1-\frac {3}{x^2}\right )^{5/6} x^5 \left (-1+\sqrt {\frac {-3+x^2}{x^2}}\right )} \, dx,x,\cos (x)\right )-3 \text {Subst}\left (\int \frac {1}{\left (1-\frac {3}{x^2}\right )^{5/6} x^3 \left (-1+\sqrt {\frac {-3+x^2}{x^2}}\right )} \, dx,x,\cos (x)\right )-\text {Subst}\left (\int \frac {1}{\sqrt {1-\frac {3}{x^2}} x^3 \left (1-\sqrt {\frac {-3+x^2}{x^2}}\right )} \, dx,x,\cos (x)\right )-\text {Subst}\left (\int \frac {1}{\sqrt {1-\frac {3}{x^2}} x \left (-1+\sqrt {\frac {-3+x^2}{x^2}}\right )} \, dx,x,\cos (x)\right )\\ &=\frac {1}{3} \log \left (1-\sqrt {-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )-\frac {1}{2} \text {Subst}\left (\int \frac {1}{\left (-1+\sqrt {x}\right ) x^{5/6}} \, dx,x,\left (-3+\cos ^2(x)\right ) \sec ^2(x)\right )+3 \text {Subst}\left (\int \left (-\frac {1}{3 \left (1-\frac {3}{x^2}\right )^{5/6} x^3}-\frac {1}{3 \sqrt [3]{1-\frac {3}{x^2}} x^3}\right ) \, dx,x,\cos (x)\right )-\text {Subst}\left (\int \frac {1}{-\frac {3}{x}+x-\sqrt {1-\frac {3}{x^2}} x} \, dx,x,\cos (x)\right )\\ &=\frac {1}{3} \log \left (1-\sqrt {-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )-\text {Subst}\left (\int \frac {1}{\left (1-\frac {3}{x^2}\right )^{5/6} x^3} \, dx,x,\cos (x)\right )-\text {Subst}\left (\int \frac {1}{\sqrt [3]{1-\frac {3}{x^2}} x^3} \, dx,x,\cos (x)\right )-\text {Subst}\left (\int \frac {1}{(-1+x) x^{2/3}} \, dx,x,\sqrt {\left (-3+\cos ^2(x)\right ) \sec ^2(x)}\right )-\text {Subst}\left (\int \left (-\frac {x}{3}-\frac {1}{3} \sqrt {1-\frac {3}{x^2}} x+\frac {\sqrt {1-\frac {3}{x^2}} x}{3-x^2}\right ) \, dx,x,\cos (x)\right )\\ &=\frac {\cos ^2(x)}{6}+\frac {1}{3} \log \left (1-\sqrt {-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )+\frac {1}{2} \log \left (1-\sqrt {\left (-3+\cos ^2(x)\right ) \sec ^2(x)}\right )-\sqrt [6]{1-3 \sec ^2(x)}-\frac {1}{4} \left (1-3 \sec ^2(x)\right )^{2/3}+\frac {1}{3} \text {Subst}\left (\int \sqrt {1-\frac {3}{x^2}} x \, dx,x,\cos (x)\right )+\frac {3}{2} \text {Subst}\left (\int \frac {1}{1-x} \, dx,x,\sqrt [6]{\left (-3+\cos ^2(x)\right ) \sec ^2(x)}\right )+\frac {3}{2} \text {Subst}\left (\int \frac {1}{1+x+x^2} \, dx,x,\sqrt [6]{\left (-3+\cos ^2(x)\right ) \sec ^2(x)}\right )-\text {Subst}\left (\int \frac {\sqrt {1-\frac {3}{x^2}} x}{3-x^2} \, dx,x,\cos (x)\right )\\ &=\frac {\cos ^2(x)}{6}-\frac {3}{2} \log \left (1-\sqrt [6]{-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )+\frac {1}{3} \log \left (1-\sqrt {-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )+\frac {1}{2} \log \left (1-\sqrt {\left (-3+\cos ^2(x)\right ) \sec ^2(x)}\right )-\sqrt [6]{1-3 \sec ^2(x)}-\frac {1}{4} \left (1-3 \sec ^2(x)\right )^{2/3}-\frac {1}{6} \text {Subst}\left (\int \frac {\sqrt {1-3 x}}{x^2} \, dx,x,\sec ^2(x)\right )-3 \text {Subst}\left (\int \frac {1}{-3-x^2} \, dx,x,1+2 \sqrt [6]{\left (-3+\cos ^2(x)\right ) \sec ^2(x)}\right )+\text {Subst}\left (\int \frac {1}{\sqrt {1-\frac {3}{x^2}} x} \, dx,x,\cos (x)\right )\\ &=\sqrt {3} \tan ^{-1}\left (\frac {1+2 \sqrt [6]{-\left (3-\cos ^2(x)\right ) \sec ^2(x)}}{\sqrt {3}}\right )+\frac {\cos ^2(x)}{6}-\frac {3}{2} \log \left (1-\sqrt [6]{-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )+\frac {1}{3} \log \left (1-\sqrt {-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )+\frac {1}{2} \log \left (1-\sqrt {\left (-3+\cos ^2(x)\right ) \sec ^2(x)}\right )-\sqrt [6]{1-3 \sec ^2(x)}+\frac {1}{6} \cos ^2(x) \sqrt {1-3 \sec ^2(x)}-\frac {1}{4} \left (1-3 \sec ^2(x)\right )^{2/3}+\frac {1}{4} \text {Subst}\left (\int \frac {1}{\sqrt {1-3 x} x} \, dx,x,\sec ^2(x)\right )-\frac {1}{2} \text {Subst}\left (\int \frac {1}{\sqrt {1-3 x} x} \, dx,x,\sec ^2(x)\right )\\ &=\sqrt {3} \tan ^{-1}\left (\frac {1+2 \sqrt [6]{-\left (3-\cos ^2(x)\right ) \sec ^2(x)}}{\sqrt {3}}\right )+\frac {\cos ^2(x)}{6}-\frac {3}{2} \log \left (1-\sqrt [6]{-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )+\frac {1}{3} \log \left (1-\sqrt {-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )+\frac {1}{2} \log \left (1-\sqrt {\left (-3+\cos ^2(x)\right ) \sec ^2(x)}\right )-\sqrt [6]{1-3 \sec ^2(x)}+\frac {1}{6} \cos ^2(x) \sqrt {1-3 \sec ^2(x)}-\frac {1}{4} \left (1-3 \sec ^2(x)\right )^{2/3}-\frac {1}{6} \text {Subst}\left (\int \frac {1}{\frac {1}{3}-\frac {x^2}{3}} \, dx,x,\sqrt {1-3 \sec ^2(x)}\right )+\frac {1}{3} \text {Subst}\left (\int \frac {1}{\frac {1}{3}-\frac {x^2}{3}} \, dx,x,\sqrt {1-3 \sec ^2(x)}\right )\\ &=\sqrt {3} \tan ^{-1}\left (\frac {1+2 \sqrt [6]{-\left (3-\cos ^2(x)\right ) \sec ^2(x)}}{\sqrt {3}}\right )+\frac {1}{2} \tanh ^{-1}\left (\sqrt {1-3 \sec ^2(x)}\right )+\frac {\cos ^2(x)}{6}-\frac {3}{2} \log \left (1-\sqrt [6]{-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )+\frac {1}{3} \log \left (1-\sqrt {-\left (3-\cos ^2(x)\right ) \sec ^2(x)}\right )+\frac {1}{2} \log \left (1-\sqrt {\left (-3+\cos ^2(x)\right ) \sec ^2(x)}\right )-\sqrt [6]{1-3 \sec ^2(x)}+\frac {1}{6} \cos ^2(x) \sqrt {1-3 \sec ^2(x)}-\frac {1}{4} \left (1-3 \sec ^2(x)\right )^{2/3}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains higher order function than in optimal. Order 6 vs. order 3 in
optimal.
time = 42.30, size = 6084, normalized size = 45.74 \begin {gather*} \text {Result too large to show} \end {gather*}
Warning: Unable to verify antiderivative.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 180.00, size = 0, normalized size = 0.00 \[\int \frac {\tan \left (x \right ) \left (\left (1-3 \left (\sec ^{2}\left (x \right )\right )\right )^{\frac {1}{3}} \left (\sin ^{2}\left (x \right )\right )+3 \left (\tan ^{2}\left (x \right )\right )\right )}{\cos \left (x \right )^{2} \left (1-3 \left (\sec ^{2}\left (x \right )\right )\right )^{\frac {5}{6}} \left (1-\sqrt {1-3 \left (\sec ^{2}\left (x \right )\right )}\right )}\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} -\int \frac {\mathrm {tan}\left (x\right )\,\left ({\sin \left (x\right )}^2\,{\left (1-\frac {3}{{\cos \left (x\right )}^2}\right )}^{1/3}+3\,{\mathrm {tan}\left (x\right )}^2\right )}{{\cos \left (x\right )}^2\,\left (\sqrt {1-\frac {3}{{\cos \left (x\right )}^2}}-1\right )\,{\left (1-\frac {3}{{\cos \left (x\right )}^2}\right )}^{5/6}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________