Optimal. Leaf size=14 \[ \frac {x}{2}+\frac {1}{2} \cos (x) \sin (x) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.01, antiderivative size = 14, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 3, integrand size = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.375, Rules used = {3738, 2715, 8}
\begin {gather*} \frac {x}{2}+\frac {1}{2} \sin (x) \cos (x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 8
Rule 2715
Rule 3738
Rubi steps
\begin {align*} \int \frac {1}{1+\tan ^2(x)} \, dx &=\int \cos ^2(x) \, dx\\ &=\frac {1}{2} \cos (x) \sin (x)+\frac {\int 1 \, dx}{2}\\ &=\frac {x}{2}+\frac {1}{2} \cos (x) \sin (x)\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.00, size = 14, normalized size = 1.00 \begin {gather*} \frac {x}{2}+\frac {1}{4} \sin (2 x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Mathics [A]
time = 2.24, size = 10, normalized size = 0.71 \begin {gather*} \frac {x}{2}+\frac {\text {Sin}\left [2 x\right ]}{4} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.02, size = 19, normalized size = 1.36
method | result | size |
risch | \(\frac {x}{2}+\frac {\sin \left (2 x \right )}{4}\) | \(11\) |
derivativedivides | \(\frac {\tan \left (x \right )}{2+2 \left (\tan ^{2}\left (x \right )\right )}+\frac {\arctan \left (\tan \left (x \right )\right )}{2}\) | \(19\) |
default | \(\frac {\tan \left (x \right )}{2+2 \left (\tan ^{2}\left (x \right )\right )}+\frac {\arctan \left (\tan \left (x \right )\right )}{2}\) | \(19\) |
norman | \(\frac {\frac {x}{2}+\frac {x \left (\tan ^{2}\left (x \right )\right )}{2}+\frac {\tan \left (x \right )}{2}}{1+\tan ^{2}\left (x \right )}\) | \(25\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.35, size = 16, normalized size = 1.14 \begin {gather*} \frac {1}{2} \, x + \frac {\tan \left (x\right )}{2 \, {\left (\tan \left (x\right )^{2} + 1\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.33, size = 20, normalized size = 1.43 \begin {gather*} \frac {x \tan \left (x\right )^{2} + x + \tan \left (x\right )}{2 \, {\left (\tan \left (x\right )^{2} + 1\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. 36 vs.
\(2 (10) = 20\)
time = 0.19, size = 36, normalized size = 2.57 \begin {gather*} \frac {x \tan ^{2}{\left (x \right )}}{2 \tan ^{2}{\left (x \right )} + 2} + \frac {x}{2 \tan ^{2}{\left (x \right )} + 2} + \frac {\tan {\left (x \right )}}{2 \tan ^{2}{\left (x \right )} + 2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.00, size = 17, normalized size = 1.21 \begin {gather*} \frac {\tan x}{2 \left (\tan ^{2}x+1\right )}+\frac {x}{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.18, size = 10, normalized size = 0.71 \begin {gather*} \frac {x}{2}+\frac {\sin \left (2\,x\right )}{4} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________