Optimal. Leaf size=12 \[ \tanh ^{-1}(\sin (x))-\frac {8 \sin ^3(x)}{3} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 12, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 3, integrand size = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.429, Rules used = {4449, 1167, 212}
\begin {gather*} \tanh ^{-1}(\sin (x))-\frac {8 \sin ^3(x)}{3} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 212
Rule 1167
Rule 4449
Rubi steps
\begin {align*} \int \cos (4 x) \sec (x) \, dx &=\text {Subst}\left (\int \frac {1-8 x^2+8 x^4}{1-x^2} \, dx,x,\sin (x)\right )\\ &=\text {Subst}\left (\int \left (-8 x^2+\frac {1}{1-x^2}\right ) \, dx,x,\sin (x)\right )\\ &=-\frac {8}{3} \sin ^3(x)+\text {Subst}\left (\int \frac {1}{1-x^2} \, dx,x,\sin (x)\right )\\ &=\tanh ^{-1}(\sin (x))-\frac {8 \sin ^3(x)}{3}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.01, size = 12, normalized size = 1.00 \begin {gather*} \tanh ^{-1}(\sin (x))-\frac {8 \sin ^3(x)}{3} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(21\) vs.
\(2(10)=20\).
time = 0.08, size = 22, normalized size = 1.83
method | result | size |
default | \(\ln \left (\sec \left (x \right )+\tan \left (x \right )\right )+\frac {8 \left (2+\cos ^{2}\left (x \right )\right ) \sin \left (x \right )}{3}-8 \sin \left (x \right )\) | \(22\) |
risch | \(i {\mathrm e}^{i x}-i {\mathrm e}^{-i x}+\ln \left ({\mathrm e}^{i x}+i\right )-\ln \left ({\mathrm e}^{i x}-i\right )+\frac {2 \sin \left (3 x \right )}{3}\) | \(44\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 21 vs.
\(2 (10) = 20\).
time = 1.52, size = 21, normalized size = 1.75 \begin {gather*} -\frac {8}{3} \, \sin \left (x\right )^{3} + \frac {1}{2} \, \log \left (\sin \left (x\right ) + 1\right ) - \frac {1}{2} \, \log \left (\sin \left (x\right ) - 1\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 27 vs.
\(2 (10) = 20\).
time = 0.95, size = 27, normalized size = 2.25 \begin {gather*} \frac {8}{3} \, {\left (\cos \left (x\right )^{2} - 1\right )} \sin \left (x\right ) + \frac {1}{2} \, \log \left (\sin \left (x\right ) + 1\right ) - \frac {1}{2} \, \log \left (-\sin \left (x\right ) + 1\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 0.83, size = 24, normalized size = 2.00 \begin {gather*} - \frac {\log {\left (\sin {\left (x \right )} - 1 \right )}}{2} + \frac {\log {\left (\sin {\left (x \right )} + 1 \right )}}{2} - \frac {8 \sin ^{3}{\left (x \right )}}{3} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 23 vs.
\(2 (10) = 20\).
time = 0.93, size = 23, normalized size = 1.92 \begin {gather*} -\frac {8}{3} \, \sin \left (x\right )^{3} + \frac {1}{2} \, \log \left (\sin \left (x\right ) + 1\right ) - \frac {1}{2} \, \log \left (-\sin \left (x\right ) + 1\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.27, size = 10, normalized size = 0.83 \begin {gather*} \mathrm {atanh}\left (\sin \left (x\right )\right )-\frac {8\,{\sin \left (x\right )}^3}{3} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________