Integrand size = 65, antiderivative size = 34 \[ \int \frac {x^3+e^x \left (-56 x+56 x^2-27 x^3-14 x^4\right )+e^{2 x} \left (32-40 x+16 x^2+12 x^3-6 x^4-2 x^5\right )}{2 x^3} \, dx=\frac {1}{e^3}+\frac {1}{2} \left (e^x-\left (7-e^x \left (-1+\frac {4}{x}-x\right )\right )^2+x\right ) \] Output:
exp(-3)-1/2*(7-(4/x-1-x)*exp(x))^2+1/2*x+1/2*exp(x)
Time = 2.18 (sec) , antiderivative size = 42, normalized size of antiderivative = 1.24 \[ \int \frac {x^3+e^x \left (-56 x+56 x^2-27 x^3-14 x^4\right )+e^{2 x} \left (32-40 x+16 x^2+12 x^3-6 x^4-2 x^5\right )}{2 x^3} \, dx=\frac {x^3-e^{2 x} \left (-4+x+x^2\right )^2-e^x x \left (-56+13 x+14 x^2\right )}{2 x^2} \] Input:
Integrate[(x^3 + E^x*(-56*x + 56*x^2 - 27*x^3 - 14*x^4) + E^(2*x)*(32 - 40 *x + 16*x^2 + 12*x^3 - 6*x^4 - 2*x^5))/(2*x^3),x]
Output:
(x^3 - E^(2*x)*(-4 + x + x^2)^2 - E^x*x*(-56 + 13*x + 14*x^2))/(2*x^2)
Leaf count is larger than twice the leaf count of optimal. \(70\) vs. \(2(34)=68\).
Time = 0.47 (sec) , antiderivative size = 70, normalized size of antiderivative = 2.06, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.046, Rules used = {27, 2010, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {x^3+e^x \left (-14 x^4-27 x^3+56 x^2-56 x\right )+e^{2 x} \left (-2 x^5-6 x^4+12 x^3+16 x^2-40 x+32\right )}{2 x^3} \, dx\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \frac {1}{2} \int \frac {x^3-e^x \left (14 x^4+27 x^3-56 x^2+56 x\right )+2 e^{2 x} \left (-x^5-3 x^4+6 x^3+8 x^2-20 x+16\right )}{x^3}dx\) |
\(\Big \downarrow \) 2010 |
\(\displaystyle \frac {1}{2} \int \left (-\frac {2 e^{2 x} \left (x^2+x-4\right ) \left (x^3+2 x^2-4 x+4\right )}{x^3}-\frac {e^x \left (14 x^3+27 x^2-56 x+56\right )}{x^2}+1\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {1}{2} \left (-e^{2 x} x^2-\frac {16 e^{2 x}}{x^2}-14 e^x x-2 e^{2 x} x+x-13 e^x+7 e^{2 x}+\frac {56 e^x}{x}+\frac {8 e^{2 x}}{x}\right )\) |
Input:
Int[(x^3 + E^x*(-56*x + 56*x^2 - 27*x^3 - 14*x^4) + E^(2*x)*(32 - 40*x + 1 6*x^2 + 12*x^3 - 6*x^4 - 2*x^5))/(2*x^3),x]
Output:
(-13*E^x + 7*E^(2*x) - (16*E^(2*x))/x^2 + (56*E^x)/x + (8*E^(2*x))/x + x - 14*E^x*x - 2*E^(2*x)*x - E^(2*x)*x^2)/2
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x] , x] /; FreeQ[{c, m}, x] && SumQ[u] && !LinearQ[u, x] && !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]
Time = 0.72 (sec) , antiderivative size = 49, normalized size of antiderivative = 1.44
method | result | size |
risch | \(\frac {x}{2}-\frac {\left (x^{4}+2 x^{3}-7 x^{2}-8 x +16\right ) {\mathrm e}^{2 x}}{2 x^{2}}-\frac {\left (14 x^{2}+13 x -56\right ) {\mathrm e}^{x}}{2 x}\) | \(49\) |
default | \(\frac {x}{2}+\frac {7 \,{\mathrm e}^{2 x}}{2}-\frac {8 \,{\mathrm e}^{2 x}}{x^{2}}+\frac {4 \,{\mathrm e}^{2 x}}{x}-x \,{\mathrm e}^{2 x}+\frac {28 \,{\mathrm e}^{x}}{x}-7 \,{\mathrm e}^{x} x -\frac {13 \,{\mathrm e}^{x}}{2}-\frac {{\mathrm e}^{2 x} x^{2}}{2}\) | \(61\) |
parts | \(\frac {x}{2}+\frac {7 \,{\mathrm e}^{2 x}}{2}-\frac {8 \,{\mathrm e}^{2 x}}{x^{2}}+\frac {4 \,{\mathrm e}^{2 x}}{x}-x \,{\mathrm e}^{2 x}+\frac {28 \,{\mathrm e}^{x}}{x}-7 \,{\mathrm e}^{x} x -\frac {13 \,{\mathrm e}^{x}}{2}-\frac {{\mathrm e}^{2 x} x^{2}}{2}\) | \(61\) |
norman | \(\frac {\frac {x^{3}}{2}-8 \,{\mathrm e}^{2 x}+4 x \,{\mathrm e}^{2 x}+28 \,{\mathrm e}^{x} x -\frac {13 \,{\mathrm e}^{x} x^{2}}{2}-7 \,{\mathrm e}^{x} x^{3}+\frac {7 \,{\mathrm e}^{2 x} x^{2}}{2}-{\mathrm e}^{2 x} x^{3}-\frac {{\mathrm e}^{2 x} x^{4}}{2}}{x^{2}}\) | \(70\) |
parallelrisch | \(-\frac {{\mathrm e}^{2 x} x^{4}+14 \,{\mathrm e}^{x} x^{3}+2 \,{\mathrm e}^{2 x} x^{3}+13 \,{\mathrm e}^{x} x^{2}-7 \,{\mathrm e}^{2 x} x^{2}-x^{3}-56 \,{\mathrm e}^{x} x -8 x \,{\mathrm e}^{2 x}+16 \,{\mathrm e}^{2 x}}{2 x^{2}}\) | \(70\) |
orering | \(\frac {\left (x -\frac {31}{7}\right ) \left (\left (-2 x^{5}-6 x^{4}+12 x^{3}+16 x^{2}-40 x +32\right ) {\mathrm e}^{2 x}+\left (-14 x^{4}-27 x^{3}+56 x^{2}-56 x \right ) {\mathrm e}^{x}+x^{3}\right )}{2 x^{3}}-\frac {x \left (588 x^{11}+784 x^{10}-19995 x^{9}-24622 x^{8}+121909 x^{7}-131688 x^{6}-215328 x^{5}+974176 x^{4}-1794384 x^{3}+1936896 x^{2}-1188096 x +333312\right ) \left (\frac {\left (-10 x^{4}-24 x^{3}+36 x^{2}+32 x -40\right ) {\mathrm e}^{2 x}+2 \left (-2 x^{5}-6 x^{4}+12 x^{3}+16 x^{2}-40 x +32\right ) {\mathrm e}^{2 x}+\left (-56 x^{3}-81 x^{2}+112 x -56\right ) {\mathrm e}^{x}+\left (-14 x^{4}-27 x^{3}+56 x^{2}-56 x \right ) {\mathrm e}^{x}+3 x^{2}}{2 x^{3}}-\frac {3 \left (\left (-2 x^{5}-6 x^{4}+12 x^{3}+16 x^{2}-40 x +32\right ) {\mathrm e}^{2 x}+\left (-14 x^{4}-27 x^{3}+56 x^{2}-56 x \right ) {\mathrm e}^{x}+x^{3}\right )}{2 x^{4}}\right )}{14 \left (28 x^{11}+222 x^{10}+254 x^{9}-699 x^{8}+1640 x^{7}+664 x^{6}-11256 x^{5}+22584 x^{4}-28480 x^{3}+24192 x^{2}-16128 x +5376\right )}+\frac {\left (196 x^{10}-6665 x^{8}-3764 x^{7}+41891 x^{6}-43896 x^{5}-86408 x^{4}+267120 x^{3}-331008 x^{2}+204288 x -55552\right ) x^{2} \left (\frac {\left (-40 x^{3}-72 x^{2}+72 x +32\right ) {\mathrm e}^{2 x}+4 \left (-10 x^{4}-24 x^{3}+36 x^{2}+32 x -40\right ) {\mathrm e}^{2 x}+4 \left (-2 x^{5}-6 x^{4}+12 x^{3}+16 x^{2}-40 x +32\right ) {\mathrm e}^{2 x}+\left (-168 x^{2}-162 x +112\right ) {\mathrm e}^{x}+2 \left (-56 x^{3}-81 x^{2}+112 x -56\right ) {\mathrm e}^{x}+\left (-14 x^{4}-27 x^{3}+56 x^{2}-56 x \right ) {\mathrm e}^{x}+6 x}{2 x^{3}}-\frac {3 \left (\left (-10 x^{4}-24 x^{3}+36 x^{2}+32 x -40\right ) {\mathrm e}^{2 x}+2 \left (-2 x^{5}-6 x^{4}+12 x^{3}+16 x^{2}-40 x +32\right ) {\mathrm e}^{2 x}+\left (-56 x^{3}-81 x^{2}+112 x -56\right ) {\mathrm e}^{x}+\left (-14 x^{4}-27 x^{3}+56 x^{2}-56 x \right ) {\mathrm e}^{x}+3 x^{2}\right )}{x^{4}}+\frac {6 \left (-2 x^{5}-6 x^{4}+12 x^{3}+16 x^{2}-40 x +32\right ) {\mathrm e}^{2 x}+6 \left (-14 x^{4}-27 x^{3}+56 x^{2}-56 x \right ) {\mathrm e}^{x}+6 x^{3}}{x^{5}}\right )}{392 x^{11}+3108 x^{10}+3556 x^{9}-9786 x^{8}+22960 x^{7}+9296 x^{6}-157584 x^{5}+316176 x^{4}-398720 x^{3}+338688 x^{2}-225792 x +75264}\) | \(766\) |
Input:
int(1/2*((-2*x^5-6*x^4+12*x^3+16*x^2-40*x+32)*exp(x)^2+(-14*x^4-27*x^3+56* x^2-56*x)*exp(x)+x^3)/x^3,x,method=_RETURNVERBOSE)
Output:
1/2*x-1/2*(x^4+2*x^3-7*x^2-8*x+16)/x^2*exp(x)^2-1/2*(14*x^2+13*x-56)/x*exp (x)
Time = 0.07 (sec) , antiderivative size = 51, normalized size of antiderivative = 1.50 \[ \int \frac {x^3+e^x \left (-56 x+56 x^2-27 x^3-14 x^4\right )+e^{2 x} \left (32-40 x+16 x^2+12 x^3-6 x^4-2 x^5\right )}{2 x^3} \, dx=\frac {x^{3} - {\left (x^{4} + 2 \, x^{3} - 7 \, x^{2} - 8 \, x + 16\right )} e^{\left (2 \, x\right )} - {\left (14 \, x^{3} + 13 \, x^{2} - 56 \, x\right )} e^{x}}{2 \, x^{2}} \] Input:
integrate(1/2*((-2*x^5-6*x^4+12*x^3+16*x^2-40*x+32)*exp(x)^2+(-14*x^4-27*x ^3+56*x^2-56*x)*exp(x)+x^3)/x^3,x, algorithm="fricas")
Output:
1/2*(x^3 - (x^4 + 2*x^3 - 7*x^2 - 8*x + 16)*e^(2*x) - (14*x^3 + 13*x^2 - 5 6*x)*e^x)/x^2
Time = 0.08 (sec) , antiderivative size = 54, normalized size of antiderivative = 1.59 \[ \int \frac {x^3+e^x \left (-56 x+56 x^2-27 x^3-14 x^4\right )+e^{2 x} \left (32-40 x+16 x^2+12 x^3-6 x^4-2 x^5\right )}{2 x^3} \, dx=\frac {x}{2} + \frac {\left (- 28 x^{4} - 26 x^{3} + 112 x^{2}\right ) e^{x} + \left (- 2 x^{5} - 4 x^{4} + 14 x^{3} + 16 x^{2} - 32 x\right ) e^{2 x}}{4 x^{3}} \] Input:
integrate(1/2*((-2*x**5-6*x**4+12*x**3+16*x**2-40*x+32)*exp(x)**2+(-14*x** 4-27*x**3+56*x**2-56*x)*exp(x)+x**3)/x**3,x)
Output:
x/2 + ((-28*x**4 - 26*x**3 + 112*x**2)*exp(x) + (-2*x**5 - 4*x**4 + 14*x** 3 + 16*x**2 - 32*x)*exp(2*x))/(4*x**3)
Result contains higher order function than in optimal. Order 4 vs. order 3.
Time = 0.07 (sec) , antiderivative size = 79, normalized size of antiderivative = 2.32 \[ \int \frac {x^3+e^x \left (-56 x+56 x^2-27 x^3-14 x^4\right )+e^{2 x} \left (32-40 x+16 x^2+12 x^3-6 x^4-2 x^5\right )}{2 x^3} \, dx=-\frac {1}{4} \, {\left (2 \, x^{2} - 2 \, x + 1\right )} e^{\left (2 \, x\right )} - \frac {3}{4} \, {\left (2 \, x - 1\right )} e^{\left (2 \, x\right )} - 7 \, {\left (x - 1\right )} e^{x} + \frac {1}{2} \, x + 8 \, {\rm Ei}\left (2 \, x\right ) + 28 \, {\rm Ei}\left (x\right ) + 3 \, e^{\left (2 \, x\right )} - \frac {27}{2} \, e^{x} - 28 \, \Gamma \left (-1, -x\right ) - 40 \, \Gamma \left (-1, -2 \, x\right ) - 64 \, \Gamma \left (-2, -2 \, x\right ) \] Input:
integrate(1/2*((-2*x^5-6*x^4+12*x^3+16*x^2-40*x+32)*exp(x)^2+(-14*x^4-27*x ^3+56*x^2-56*x)*exp(x)+x^3)/x^3,x, algorithm="maxima")
Output:
-1/4*(2*x^2 - 2*x + 1)*e^(2*x) - 3/4*(2*x - 1)*e^(2*x) - 7*(x - 1)*e^x + 1 /2*x + 8*Ei(2*x) + 28*Ei(x) + 3*e^(2*x) - 27/2*e^x - 28*gamma(-1, -x) - 40 *gamma(-1, -2*x) - 64*gamma(-2, -2*x)
Leaf count of result is larger than twice the leaf count of optimal. 69 vs. \(2 (27) = 54\).
Time = 0.11 (sec) , antiderivative size = 69, normalized size of antiderivative = 2.03 \[ \int \frac {x^3+e^x \left (-56 x+56 x^2-27 x^3-14 x^4\right )+e^{2 x} \left (32-40 x+16 x^2+12 x^3-6 x^4-2 x^5\right )}{2 x^3} \, dx=-\frac {x^{4} e^{\left (2 \, x\right )} + 2 \, x^{3} e^{\left (2 \, x\right )} + 14 \, x^{3} e^{x} - x^{3} - 7 \, x^{2} e^{\left (2 \, x\right )} + 13 \, x^{2} e^{x} - 8 \, x e^{\left (2 \, x\right )} - 56 \, x e^{x} + 16 \, e^{\left (2 \, x\right )}}{2 \, x^{2}} \] Input:
integrate(1/2*((-2*x^5-6*x^4+12*x^3+16*x^2-40*x+32)*exp(x)^2+(-14*x^4-27*x ^3+56*x^2-56*x)*exp(x)+x^3)/x^3,x, algorithm="giac")
Output:
-1/2*(x^4*e^(2*x) + 2*x^3*e^(2*x) + 14*x^3*e^x - x^3 - 7*x^2*e^(2*x) + 13* x^2*e^x - 8*x*e^(2*x) - 56*x*e^x + 16*e^(2*x))/x^2
Time = 0.43 (sec) , antiderivative size = 59, normalized size of antiderivative = 1.74 \[ \int \frac {x^3+e^x \left (-56 x+56 x^2-27 x^3-14 x^4\right )+e^{2 x} \left (32-40 x+16 x^2+12 x^3-6 x^4-2 x^5\right )}{2 x^3} \, dx=\frac {7\,{\mathrm {e}}^{2\,x}}{2}-\frac {13\,{\mathrm {e}}^x}{2}-\frac {8\,{\mathrm {e}}^{2\,x}-x\,\left (4\,{\mathrm {e}}^{2\,x}+28\,{\mathrm {e}}^x\right )}{x^2}-\frac {x^2\,{\mathrm {e}}^{2\,x}}{2}-x\,\left ({\mathrm {e}}^{2\,x}+7\,{\mathrm {e}}^x-\frac {1}{2}\right ) \] Input:
int(-((exp(x)*(56*x - 56*x^2 + 27*x^3 + 14*x^4))/2 + (exp(2*x)*(40*x - 16* x^2 - 12*x^3 + 6*x^4 + 2*x^5 - 32))/2 - x^3/2)/x^3,x)
Output:
(7*exp(2*x))/2 - (13*exp(x))/2 - (8*exp(2*x) - x*(4*exp(2*x) + 28*exp(x))) /x^2 - (x^2*exp(2*x))/2 - x*(exp(2*x) + 7*exp(x) - 1/2)
Time = 0.23 (sec) , antiderivative size = 76, normalized size of antiderivative = 2.24 \[ \int \frac {x^3+e^x \left (-56 x+56 x^2-27 x^3-14 x^4\right )+e^{2 x} \left (32-40 x+16 x^2+12 x^3-6 x^4-2 x^5\right )}{2 x^3} \, dx=\frac {-e^{2 x} x^{4}-2 e^{2 x} x^{3}+7 e^{2 x} x^{2}+8 e^{2 x} x -16 e^{2 x}-14 e^{x} x^{3}-13 e^{x} x^{2}+56 e^{x} x +x^{3}}{2 x^{2}} \] Input:
int(1/2*((-2*x^5-6*x^4+12*x^3+16*x^2-40*x+32)*exp(x)^2+(-14*x^4-27*x^3+56* x^2-56*x)*exp(x)+x^3)/x^3,x)
Output:
( - e**(2*x)*x**4 - 2*e**(2*x)*x**3 + 7*e**(2*x)*x**2 + 8*e**(2*x)*x - 16* e**(2*x) - 14*e**x*x**3 - 13*e**x*x**2 + 56*e**x*x + x**3)/(2*x**2)