Optimal. Leaf size=75 \[ -\frac {3}{10} e^{-3 x} x^2 \sin (x)-\frac {1}{10} e^{-3 x} x^2 \cos (x)-\frac {4}{25} e^{-3 x} x \sin (x)-\frac {9}{250} e^{-3 x} \sin (x)-\frac {3}{25} e^{-3 x} x \cos (x)-\frac {13}{250} e^{-3 x} \cos (x) \]
________________________________________________________________________________________
Rubi [A] time = 0.14, antiderivative size = 75, normalized size of antiderivative = 1.00, number of steps used = 11, number of rules used = 5, integrand size = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.454, Rules used = {4432, 4465, 14, 4433, 4466} \[ -\frac {3}{10} e^{-3 x} x^2 \sin (x)-\frac {1}{10} e^{-3 x} x^2 \cos (x)-\frac {4}{25} e^{-3 x} x \sin (x)-\frac {9}{250} e^{-3 x} \sin (x)-\frac {3}{25} e^{-3 x} x \cos (x)-\frac {13}{250} e^{-3 x} \cos (x) \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 14
Rule 4432
Rule 4433
Rule 4465
Rule 4466
Rubi steps
\begin {align*} \int e^{-3 x} x^2 \sin (x) \, dx &=-\frac {1}{10} e^{-3 x} x^2 \cos (x)-\frac {3}{10} e^{-3 x} x^2 \sin (x)-2 \int x \left (-\frac {1}{10} e^{-3 x} \cos (x)-\frac {3}{10} e^{-3 x} \sin (x)\right ) \, dx\\ &=-\frac {1}{10} e^{-3 x} x^2 \cos (x)-\frac {3}{10} e^{-3 x} x^2 \sin (x)-2 \int \left (-\frac {1}{10} e^{-3 x} x \cos (x)-\frac {3}{10} e^{-3 x} x \sin (x)\right ) \, dx\\ &=-\frac {1}{10} e^{-3 x} x^2 \cos (x)-\frac {3}{10} e^{-3 x} x^2 \sin (x)+\frac {1}{5} \int e^{-3 x} x \cos (x) \, dx+\frac {3}{5} \int e^{-3 x} x \sin (x) \, dx\\ &=-\frac {3}{25} e^{-3 x} x \cos (x)-\frac {1}{10} e^{-3 x} x^2 \cos (x)-\frac {4}{25} e^{-3 x} x \sin (x)-\frac {3}{10} e^{-3 x} x^2 \sin (x)-\frac {1}{5} \int \left (-\frac {3}{10} e^{-3 x} \cos (x)+\frac {1}{10} e^{-3 x} \sin (x)\right ) \, dx-\frac {3}{5} \int \left (-\frac {1}{10} e^{-3 x} \cos (x)-\frac {3}{10} e^{-3 x} \sin (x)\right ) \, dx\\ &=-\frac {3}{25} e^{-3 x} x \cos (x)-\frac {1}{10} e^{-3 x} x^2 \cos (x)-\frac {4}{25} e^{-3 x} x \sin (x)-\frac {3}{10} e^{-3 x} x^2 \sin (x)-\frac {1}{50} \int e^{-3 x} \sin (x) \, dx+2 \left (\frac {3}{50} \int e^{-3 x} \cos (x) \, dx\right )+\frac {9}{50} \int e^{-3 x} \sin (x) \, dx\\ &=-\frac {2}{125} e^{-3 x} \cos (x)-\frac {3}{25} e^{-3 x} x \cos (x)-\frac {1}{10} e^{-3 x} x^2 \cos (x)-\frac {6}{125} e^{-3 x} \sin (x)-\frac {4}{25} e^{-3 x} x \sin (x)-\frac {3}{10} e^{-3 x} x^2 \sin (x)+2 \left (-\frac {9}{500} e^{-3 x} \cos (x)+\frac {3}{500} e^{-3 x} \sin (x)\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.04, size = 38, normalized size = 0.51 \[ \frac {1}{250} e^{-3 x} \left (-\left (75 x^2+40 x+9\right ) \sin (x)-\left (\left (25 x^2+30 x+13\right ) \cos (x)\right )\right ) \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
IntegrateAlgebraic [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int e^{-3 x} x^2 \sin (x) \, dx \]
Verification is Not applicable to the result.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 1.11, size = 37, normalized size = 0.49 \[ -\frac {1}{250} \, {\left (25 \, x^{2} + 30 \, x + 13\right )} \cos \relax (x) e^{\left (-3 \, x\right )} - \frac {1}{250} \, {\left (75 \, x^{2} + 40 \, x + 9\right )} e^{\left (-3 \, x\right )} \sin \relax (x) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.57, size = 33, normalized size = 0.44 \[ -\frac {1}{250} \, {\left ({\left (25 \, x^{2} + 30 \, x + 13\right )} \cos \relax (x) + {\left (75 \, x^{2} + 40 \, x + 9\right )} \sin \relax (x)\right )} e^{\left (-3 \, x\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.08, size = 36, normalized size = 0.48
method | result | size |
default | \(\left (-\frac {1}{10} x^{2}-\frac {3}{25} x -\frac {13}{250}\right ) {\mathrm e}^{-3 x} \cos \relax (x )+\left (-\frac {3}{10} x^{2}-\frac {4}{25} x -\frac {9}{250}\right ) {\mathrm e}^{-3 x} \sin \relax (x )\) | \(36\) |
risch | \(\left (-\frac {1}{500}+\frac {3 i}{500}\right ) \left (25 x^{2}+5 i x +15 x +3 i+4\right ) {\mathrm e}^{\left (-3+i\right ) x}+\left (-\frac {1}{500}-\frac {3 i}{500}\right ) \left (25 x^{2}-5 i x +15 x -3 i+4\right ) {\mathrm e}^{\left (-3-i\right ) x}\) | \(54\) |
norman | \(\frac {\left (-\frac {13}{250}-\frac {3 x}{25}-\frac {x^{2}}{10}+\frac {13 \left (\tan ^{2}\left (\frac {x}{2}\right )\right )}{250}-\frac {8 x \tan \left (\frac {x}{2}\right )}{25}+\frac {3 x \left (\tan ^{2}\left (\frac {x}{2}\right )\right )}{25}-\frac {3 x^{2} \tan \left (\frac {x}{2}\right )}{5}+\frac {x^{2} \left (\tan ^{2}\left (\frac {x}{2}\right )\right )}{10}-\frac {9 \tan \left (\frac {x}{2}\right )}{125}\right ) {\mathrm e}^{-3 x}}{1+\tan ^{2}\left (\frac {x}{2}\right )}\) | \(78\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.46, size = 33, normalized size = 0.44 \[ -\frac {1}{250} \, {\left ({\left (25 \, x^{2} + 30 \, x + 13\right )} \cos \relax (x) + {\left (75 \, x^{2} + 40 \, x + 9\right )} \sin \relax (x)\right )} e^{\left (-3 \, x\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.11, size = 39, normalized size = 0.52 \[ -\frac {{\mathrm {e}}^{-3\,x}\,\left (13\,\cos \relax (x)+9\,\sin \relax (x)+25\,x^2\,\cos \relax (x)+75\,x^2\,\sin \relax (x)+30\,x\,\cos \relax (x)+40\,x\,\sin \relax (x)\right )}{250} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 2.28, size = 80, normalized size = 1.07 \[ - \frac {3 x^{2} e^{- 3 x} \sin {\relax (x )}}{10} - \frac {x^{2} e^{- 3 x} \cos {\relax (x )}}{10} - \frac {4 x e^{- 3 x} \sin {\relax (x )}}{25} - \frac {3 x e^{- 3 x} \cos {\relax (x )}}{25} - \frac {9 e^{- 3 x} \sin {\relax (x )}}{250} - \frac {13 e^{- 3 x} \cos {\relax (x )}}{250} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________