Optimal. Leaf size=16 \[ -\frac {\tanh ^{-1}\left (\frac {\cos (x)}{\sqrt {2}}\right )}{\sqrt {2}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.01, antiderivative size = 16, normalized size of antiderivative = 1.00, number of steps
used = 2, number of rules used = 2, integrand size = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.182, Rules used = {3265, 212}
\begin {gather*} -\frac {\tanh ^{-1}\left (\frac {\cos (x)}{\sqrt {2}}\right )}{\sqrt {2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 212
Rule 3265
Rubi steps
\begin {align*} \int \frac {\sin (x)}{1+\sin ^2(x)} \, dx &=-\text {Subst}\left (\int \frac {1}{2-x^2} \, dx,x,\cos (x)\right )\\ &=-\frac {\tanh ^{-1}\left (\frac {\cos (x)}{\sqrt {2}}\right )}{\sqrt {2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains complex when optimal does not.
time = 0.04, size = 46, normalized size = 2.88 \begin {gather*} -\frac {i \left (\tan ^{-1}\left (\frac {-i+\tan \left (\frac {x}{2}\right )}{\sqrt {2}}\right )-\tan ^{-1}\left (\frac {i+\tan \left (\frac {x}{2}\right )}{\sqrt {2}}\right )\right )}{\sqrt {2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.04, size = 14, normalized size = 0.88
method | result | size |
default | \(-\frac {\arctanh \left (\frac {\cos \left (x \right ) \sqrt {2}}{2}\right ) \sqrt {2}}{2}\) | \(14\) |
risch | \(\frac {\sqrt {2}\, \ln \left ({\mathrm e}^{2 i x}-2 \sqrt {2}\, {\mathrm e}^{i x}+1\right )}{4}-\frac {\sqrt {2}\, \ln \left ({\mathrm e}^{2 i x}+2 \sqrt {2}\, {\mathrm e}^{i x}+1\right )}{4}\) | \(48\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 3.95, size = 24, normalized size = 1.50 \begin {gather*} \frac {1}{4} \, \sqrt {2} \log \left (-\frac {\sqrt {2} - \cos \left (x\right )}{\sqrt {2} + \cos \left (x\right )}\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. 29 vs.
\(2 (13) = 26\).
time = 0.42, size = 29, normalized size = 1.81 \begin {gather*} \frac {1}{4} \, \sqrt {2} \log \left (-\frac {\cos \left (x\right )^{2} - 2 \, \sqrt {2} \cos \left (x\right ) + 2}{\cos \left (x\right )^{2} - 2}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 46 vs.
\(2 (19) = 38\).
time = 8.70, size = 46, normalized size = 2.88 \begin {gather*} \frac {\sqrt {2} \log {\left (\tan ^{2}{\left (\frac {x}{2} \right )} - 2 \sqrt {2} + 3 \right )}}{4} - \frac {\sqrt {2} \log {\left (\tan ^{2}{\left (\frac {x}{2} \right )} + 2 \sqrt {2} + 3 \right )}}{4} \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. 27 vs.
\(2 (13) = 26\).
time = 0.49, size = 27, normalized size = 1.69 \begin {gather*} -\frac {1}{4} \, \sqrt {2} \log \left (\sqrt {2} + \cos \left (x\right )\right ) + \frac {1}{4} \, \sqrt {2} \log \left (\sqrt {2} - \cos \left (x\right )\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.21, size = 13, normalized size = 0.81 \begin {gather*} -\frac {\sqrt {2}\,\mathrm {atanh}\left (\frac {\sqrt {2}\,\cos \left (x\right )}{2}\right )}{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________