Optimal. Leaf size=23 \[ -6 \cos (x)+3 x^2 \cos (x)-6 x \sin (x)+x^3 \sin (x) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 23, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 2, integrand size = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.333, Rules used = {3377, 2718}
\begin {gather*} x^3 \sin (x)+3 x^2 \cos (x)-6 x \sin (x)-6 \cos (x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2718
Rule 3377
Rubi steps
\begin {align*} \int x^3 \cos (x) \, dx &=x^3 \sin (x)-3 \int x^2 \sin (x) \, dx\\ &=3 x^2 \cos (x)+x^3 \sin (x)-6 \int x \cos (x) \, dx\\ &=3 x^2 \cos (x)-6 x \sin (x)+x^3 \sin (x)+6 \int \sin (x) \, dx\\ &=-6 \cos (x)+3 x^2 \cos (x)-6 x \sin (x)+x^3 \sin (x)\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.01, size = 19, normalized size = 0.83 \begin {gather*} 3 \left (-2+x^2\right ) \cos (x)+x \left (-6+x^2\right ) \sin (x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.02, size = 24, normalized size = 1.04
method | result | size |
risch | \(3 \left (x^{2}-2\right ) \cos \left (x \right )+x \left (x^{2}-6\right ) \sin \left (x \right )\) | \(20\) |
default | \(-6 \cos \left (x \right )+3 x^{2} \cos \left (x \right )-6 x \sin \left (x \right )+x^{3} \sin \left (x \right )\) | \(24\) |
meijerg | \(8 \sqrt {\pi }\, \left (\frac {3}{4 \sqrt {\pi }}-\frac {\left (-\frac {3 x^{2}}{2}+3\right ) \cos \left (x \right )}{4 \sqrt {\pi }}-\frac {x \left (-\frac {x^{2}}{2}+3\right ) \sin \left (x \right )}{4 \sqrt {\pi }}\right )\) | \(41\) |
norman | \(\frac {3 x^{2}-12 x \tan \left (\frac {x}{2}\right )-3 x^{2} \left (\tan ^{2}\left (\frac {x}{2}\right )\right )+2 x^{3} \tan \left (\frac {x}{2}\right )-12}{1+\tan ^{2}\left (\frac {x}{2}\right )}\) | \(46\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 4.80, size = 20, normalized size = 0.87 \begin {gather*} 3 \, {\left (x^{2} - 2\right )} \cos \left (x\right ) + {\left (x^{3} - 6 \, x\right )} \sin \left (x\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.41, size = 20, normalized size = 0.87 \begin {gather*} 3 \, {\left (x^{2} - 2\right )} \cos \left (x\right ) + {\left (x^{3} - 6 \, x\right )} \sin \left (x\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 0.13, size = 26, normalized size = 1.13 \begin {gather*} x^{3} \sin {\left (x \right )} + 3 x^{2} \cos {\left (x \right )} - 6 x \sin {\left (x \right )} - 6 \cos {\left (x \right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.55, size = 20, normalized size = 0.87 \begin {gather*} 3 \, {\left (x^{2} - 2\right )} \cos \left (x\right ) + {\left (x^{3} - 6 \, x\right )} \sin \left (x\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.03, size = 24, normalized size = 1.04 \begin {gather*} \cos \left (x\right )\,\left (3\,x^2-6\right )-\sin \left (x\right )\,\left (6\,x-x^3\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________