Integrand size = 9, antiderivative size = 50 \[ \int e^x x^2 \sin (x) \, dx=-\frac {1}{2} e^x \cos (x)+e^x x \cos (x)-\frac {1}{2} e^x x^2 \cos (x)-\frac {1}{2} e^x \sin (x)+\frac {1}{2} e^x x^2 \sin (x) \]
[Out]
Time = 0.08 (sec) , antiderivative size = 50, normalized size of antiderivative = 1.00, number of steps used = 11, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.556, Rules used = {4517, 4553, 14, 4518, 4554} \[ \int e^x x^2 \sin (x) \, dx=\frac {1}{2} e^x x^2 \sin (x)-\frac {1}{2} e^x x^2 \cos (x)-\frac {1}{2} e^x \sin (x)+e^x x \cos (x)-\frac {1}{2} e^x \cos (x) \]
[In]
[Out]
Rule 14
Rule 4517
Rule 4518
Rule 4553
Rule 4554
Rubi steps \begin{align*} \text {integral}& = -\frac {1}{2} e^x x^2 \cos (x)+\frac {1}{2} e^x x^2 \sin (x)-2 \int x \left (-\frac {1}{2} e^x \cos (x)+\frac {1}{2} e^x \sin (x)\right ) \, dx \\ & = -\frac {1}{2} e^x x^2 \cos (x)+\frac {1}{2} e^x x^2 \sin (x)-2 \int \left (-\frac {1}{2} e^x x \cos (x)+\frac {1}{2} e^x x \sin (x)\right ) \, dx \\ & = -\frac {1}{2} e^x x^2 \cos (x)+\frac {1}{2} e^x x^2 \sin (x)+\int e^x x \cos (x) \, dx-\int e^x x \sin (x) \, dx \\ & = e^x x \cos (x)-\frac {1}{2} e^x x^2 \cos (x)+\frac {1}{2} e^x x^2 \sin (x)+\int \left (-\frac {1}{2} e^x \cos (x)+\frac {1}{2} e^x \sin (x)\right ) \, dx-\int \left (\frac {1}{2} e^x \cos (x)+\frac {1}{2} e^x \sin (x)\right ) \, dx \\ & = e^x x \cos (x)-\frac {1}{2} e^x x^2 \cos (x)+\frac {1}{2} e^x x^2 \sin (x)-2 \left (\frac {1}{2} \int e^x \cos (x) \, dx\right ) \\ & = e^x x \cos (x)-\frac {1}{2} e^x x^2 \cos (x)+\frac {1}{2} e^x x^2 \sin (x)-2 \left (\frac {1}{4} e^x \cos (x)+\frac {1}{4} e^x \sin (x)\right ) \\ \end{align*}
Time = 0.03 (sec) , antiderivative size = 25, normalized size of antiderivative = 0.50 \[ \int e^x x^2 \sin (x) \, dx=\frac {1}{2} e^x \left (-(-1+x)^2 \cos (x)+\left (-1+x^2\right ) \sin (x)\right ) \]
[In]
[Out]
Time = 0.11 (sec) , antiderivative size = 22, normalized size of antiderivative = 0.44
method | result | size |
parallelrisch | \(-\frac {{\mathrm e}^{x} \left (\left (-1+x \right ) \cos \left (x \right )-\sin \left (x \right ) \left (1+x \right )\right ) \left (-1+x \right )}{2}\) | \(22\) |
default | \(\left (-\frac {1}{2} x^{2}+x -\frac {1}{2}\right ) {\mathrm e}^{x} \cos \left (x \right )+\left (\frac {x^{2}}{2}-\frac {1}{2}\right ) {\mathrm e}^{x} \sin \left (x \right )\) | \(27\) |
risch | \(\left (-\frac {1}{4}-\frac {i}{4}\right ) \left (x^{2}+i x -x -i\right ) {\mathrm e}^{\left (1+i\right ) x}+\left (-\frac {1}{4}+\frac {i}{4}\right ) \left (x^{2}-i x -x +i\right ) {\mathrm e}^{\left (1-i\right ) x}\) | \(48\) |
norman | \(\frac {{\mathrm e}^{x} x +{\mathrm e}^{x} x^{2} \tan \left (\frac {x}{2}\right )-\frac {{\mathrm e}^{x} x^{2}}{2}-{\mathrm e}^{x} \tan \left (\frac {x}{2}\right )+\frac {{\mathrm e}^{x} \left (\tan ^{2}\left (\frac {x}{2}\right )\right )}{2}-{\mathrm e}^{x} x \left (\tan ^{2}\left (\frac {x}{2}\right )\right )+\frac {{\mathrm e}^{x} x^{2} \left (\tan ^{2}\left (\frac {x}{2}\right )\right )}{2}-\frac {{\mathrm e}^{x}}{2}}{1+\tan ^{2}\left (\frac {x}{2}\right )}\) | \(80\) |
[In]
[Out]
none
Time = 0.24 (sec) , antiderivative size = 26, normalized size of antiderivative = 0.52 \[ \int e^x x^2 \sin (x) \, dx=-\frac {1}{2} \, {\left (x^{2} - 2 \, x + 1\right )} \cos \left (x\right ) e^{x} + \frac {1}{2} \, {\left (x^{2} - 1\right )} e^{x} \sin \left (x\right ) \]
[In]
[Out]
Time = 0.29 (sec) , antiderivative size = 48, normalized size of antiderivative = 0.96 \[ \int e^x x^2 \sin (x) \, dx=\frac {x^{2} e^{x} \sin {\left (x \right )}}{2} - \frac {x^{2} e^{x} \cos {\left (x \right )}}{2} + x e^{x} \cos {\left (x \right )} - \frac {e^{x} \sin {\left (x \right )}}{2} - \frac {e^{x} \cos {\left (x \right )}}{2} \]
[In]
[Out]
none
Time = 0.21 (sec) , antiderivative size = 26, normalized size of antiderivative = 0.52 \[ \int e^x x^2 \sin (x) \, dx=-\frac {1}{2} \, {\left (x^{2} - 2 \, x + 1\right )} \cos \left (x\right ) e^{x} + \frac {1}{2} \, {\left (x^{2} - 1\right )} e^{x} \sin \left (x\right ) \]
[In]
[Out]
none
Time = 0.30 (sec) , antiderivative size = 25, normalized size of antiderivative = 0.50 \[ \int e^x x^2 \sin (x) \, dx=-\frac {1}{2} \, {\left ({\left (x^{2} - 2 \, x + 1\right )} \cos \left (x\right ) - {\left (x^{2} - 1\right )} \sin \left (x\right )\right )} e^{x} \]
[In]
[Out]
Time = 0.40 (sec) , antiderivative size = 21, normalized size of antiderivative = 0.42 \[ \int e^x x^2 \sin (x) \, dx=\frac {{\mathrm {e}}^x\,\left (x-1\right )\,\left (\cos \left (x\right )+\sin \left (x\right )-x\,\cos \left (x\right )+x\,\sin \left (x\right )\right )}{2} \]
[In]
[Out]