Optimal. Leaf size=71 \[ -\cos (x)+\frac {1}{4} \sqrt {2-\sqrt {2}} \tanh ^{-1}\left (\frac {2 \cos (x)}{\sqrt {2-\sqrt {2}}}\right )+\frac {1}{4} \sqrt {2+\sqrt {2}} \tanh ^{-1}\left (\frac {2 \cos (x)}{\sqrt {2+\sqrt {2}}}\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.08, antiderivative size = 71, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 4, integrand size = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.571, Rules used = {12, 1279, 1166, 207} \[ -\cos (x)+\frac {1}{4} \sqrt {2-\sqrt {2}} \tanh ^{-1}\left (\frac {2 \cos (x)}{\sqrt {2-\sqrt {2}}}\right )+\frac {1}{4} \sqrt {2+\sqrt {2}} \tanh ^{-1}\left (\frac {2 \cos (x)}{\sqrt {2+\sqrt {2}}}\right ) \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 207
Rule 1166
Rule 1279
Rubi steps
\begin {align*} \int \cos (x) \tan (4 x) \, dx &=-\operatorname {Subst}\left (\int \frac {4 x^2 \left (-1+2 x^2\right )}{1-8 x^2+8 x^4} \, dx,x,\cos (x)\right )\\ &=-\left (4 \operatorname {Subst}\left (\int \frac {x^2 \left (-1+2 x^2\right )}{1-8 x^2+8 x^4} \, dx,x,\cos (x)\right )\right )\\ &=-\cos (x)+\frac {1}{2} \operatorname {Subst}\left (\int \frac {2-8 x^2}{1-8 x^2+8 x^4} \, dx,x,\cos (x)\right )\\ &=-\cos (x)+\left (-2+\sqrt {2}\right ) \operatorname {Subst}\left (\int \frac {1}{-4+2 \sqrt {2}+8 x^2} \, dx,x,\cos (x)\right )-\left (2+\sqrt {2}\right ) \operatorname {Subst}\left (\int \frac {1}{-4-2 \sqrt {2}+8 x^2} \, dx,x,\cos (x)\right )\\ &=\frac {1}{4} \sqrt {2-\sqrt {2}} \tanh ^{-1}\left (\frac {2 \cos (x)}{\sqrt {2-\sqrt {2}}}\right )+\frac {1}{4} \sqrt {2+\sqrt {2}} \tanh ^{-1}\left (\frac {2 \cos (x)}{\sqrt {2+\sqrt {2}}}\right )-\cos (x)\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] time = 59.55, size = 6196, normalized size = 87.27 \[ \text {Result too large to show} \]
Warning: Unable to verify antiderivative.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.94, size = 101, normalized size = 1.42 \[ \frac {1}{8} \, \sqrt {\sqrt {2} + 2} \log \left (\sqrt {\sqrt {2} + 2} + 2 \, \cos \relax (x)\right ) - \frac {1}{8} \, \sqrt {\sqrt {2} + 2} \log \left (\sqrt {\sqrt {2} + 2} - 2 \, \cos \relax (x)\right ) + \frac {1}{8} \, \sqrt {-\sqrt {2} + 2} \log \left (\sqrt {-\sqrt {2} + 2} + 2 \, \cos \relax (x)\right ) - \frac {1}{8} \, \sqrt {-\sqrt {2} + 2} \log \left (\sqrt {-\sqrt {2} + 2} - 2 \, \cos \relax (x)\right ) - \cos \relax (x) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \cos \relax (x) \tan \left (4 \, x\right )\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.08, size = 68, normalized size = 0.96 \[ -\cos \relax (x )+\frac {\left (\sqrt {2}-1\right ) \sqrt {2}\, \arctanh \left (\frac {2 \cos \relax (x )}{\sqrt {2-\sqrt {2}}}\right )}{4 \sqrt {2-\sqrt {2}}}+\frac {\left (1+\sqrt {2}\right ) \sqrt {2}\, \arctanh \left (\frac {2 \cos \relax (x )}{\sqrt {2+\sqrt {2}}}\right )}{4 \sqrt {2+\sqrt {2}}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F] time = 0.00, size = 0, normalized size = 0.00 \[ -\cos \relax (x) - \int -\frac {{\left (\sin \left (7 \, x\right ) - \sin \relax (x)\right )} \cos \left (8 \, x\right ) - {\left (\cos \left (7 \, x\right ) - \cos \relax (x)\right )} \sin \left (8 \, x\right ) + \sin \left (7 \, x\right ) - \sin \relax (x)}{\cos \left (8 \, x\right )^{2} + \sin \left (8 \, x\right )^{2} + 2 \, \cos \left (8 \, x\right ) + 1}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 2.45, size = 295, normalized size = 4.15 \[ -\frac {\mathrm {atanh}\left (\frac {219747975168\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2\,\sqrt {2-\sqrt {2}}}{6098518016\,\sqrt {2}-254015438848\,\sqrt {2}\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2+386664497152\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2-20887633920}-\frac {15971909632\,\sqrt {2-\sqrt {2}}}{6098518016\,\sqrt {2}-254015438848\,\sqrt {2}\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2+386664497152\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2-20887633920}-\frac {130056978432\,\sqrt {2}\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2\,\sqrt {2-\sqrt {2}}}{6098518016\,\sqrt {2}-254015438848\,\sqrt {2}\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2+386664497152\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2-20887633920}\right )\,\sqrt {2-\sqrt {2}}}{4}-\frac {2}{{\mathrm {tan}\left (\frac {x}{2}\right )}^2+1}-\frac {\mathrm {atanh}\left (\frac {15971909632\,\sqrt {\sqrt {2}+2}}{6098518016\,\sqrt {2}-254015438848\,\sqrt {2}\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2-386664497152\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2+20887633920}-\frac {219747975168\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2\,\sqrt {\sqrt {2}+2}}{6098518016\,\sqrt {2}-254015438848\,\sqrt {2}\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2-386664497152\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2+20887633920}-\frac {130056978432\,\sqrt {2}\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2\,\sqrt {\sqrt {2}+2}}{6098518016\,\sqrt {2}-254015438848\,\sqrt {2}\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2-386664497152\,{\mathrm {tan}\left (\frac {x}{2}\right )}^2+20887633920}\right )\,\sqrt {\sqrt {2}+2}}{4} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \cos {\relax (x )} \tan {\left (4 x \right )}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________