Integrand size = 96, antiderivative size = 27 \[ \int \frac {-16 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-9-4 x-16 x^2-16 x^3\right )}{2 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-4 x-16 x^2-16 x^3\right )} \, dx=3+\frac {3}{2 \left (2+\frac {1}{x}\right ) \left (-\frac {e}{3}+\frac {x}{3}\right )}+x \] Output:
3/2/(1/3*x-1/3*exp(1))/(2+1/x)+3+x
Time = 0.03 (sec) , antiderivative size = 52, normalized size of antiderivative = 1.93 \[ \int \frac {-16 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-9-4 x-16 x^2-16 x^3\right )}{2 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-4 x-16 x^2-16 x^3\right )} \, dx=\frac {1}{2} \left (-\frac {9}{(1+2 e) (-1-2 e+2 (e-x))}-\frac {9 e}{(1+2 e) (e-x)}-2 (e-x)\right ) \] Input:
Integrate[(-16*x^2 + 8*x^3 + 8*x^4 + E^2*(2 + 8*x + 8*x^2) + E*(-9 - 4*x - 16*x^2 - 16*x^3))/(2*x^2 + 8*x^3 + 8*x^4 + E^2*(2 + 8*x + 8*x^2) + E*(-4* x - 16*x^2 - 16*x^3)),x]
Output:
(-9/((1 + 2*E)*(-1 - 2*E + 2*(E - x))) - (9*E)/((1 + 2*E)*(E - x)) - 2*(E - x))/2
Leaf count is larger than twice the leaf count of optimal. \(56\) vs. \(2(27)=54\).
Time = 0.40 (sec) , antiderivative size = 56, normalized size of antiderivative = 2.07, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.052, Rules used = {2459, 1380, 27, 2345, 24}
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 {8 x^4+8 x^3-16 x^2+e^2 \left (8 x^2+8 x+2\right )+e \left (-16 x^3-16 x^2-4 x-9\right )}{8 x^4+8 x^3+2 x^2+e^2 \left (8 x^2+8 x+2\right )+e \left (-16 x^3-16 x^2-4 x\right )} \, dx\) |
\(\Big \downarrow \) 2459 |
\(\displaystyle \int \frac {8 \left (x+\frac {1}{32} (8-16 e)\right )^4-\left (19+4 e+4 e^2\right ) \left (x+\frac {1}{32} (8-16 e)\right )^2+9 (1-2 e) \left (x+\frac {1}{32} (8-16 e)\right )-\frac {1}{32} (1+2 e)^2 \left (35-4 e-4 e^2\right )}{8 \left (x+\frac {1}{32} (8-16 e)\right )^4-(1+2 e)^2 \left (x+\frac {1}{32} (8-16 e)\right )^2+\frac {1}{32} (1+2 e)^4}d\left (x+\frac {1}{32} (8-16 e)\right )\) |
\(\Big \downarrow \) 1380 |
\(\displaystyle 8 \int -\frac {-256 \left (x+\frac {1}{32} (8-16 e)\right )^4+32 \left (19+4 e+4 e^2\right ) \left (x+\frac {1}{32} (8-16 e)\right )^2-288 (1-2 e) \left (x+\frac {1}{32} (8-16 e)\right )+(1+2 e)^2 \left (35-4 e-4 e^2\right )}{8 \left ((1+2 e)^2-16 \left (x+\frac {1}{32} (8-16 e)\right )^2\right )^2}d\left (x+\frac {1}{32} (8-16 e)\right )\) |
\(\Big \downarrow \) 27 |
\(\displaystyle -\int \frac {-256 \left (x+\frac {1}{32} (8-16 e)\right )^4+32 \left (19+4 e+4 e^2\right ) \left (x+\frac {1}{32} (8-16 e)\right )^2-288 (1-2 e) \left (x+\frac {1}{32} (8-16 e)\right )+(1+2 e)^2 \left (35-4 e-4 e^2\right )}{\left ((1+2 e)^2-16 \left (x+\frac {1}{32} (8-16 e)\right )^2\right )^2}d\left (x+\frac {1}{32} (8-16 e)\right )\) |
\(\Big \downarrow \) 2345 |
\(\displaystyle \frac {\int 2 (1+2 e)^2d\left (x+\frac {1}{32} (8-16 e)\right )}{2 (1+2 e)^2}+\frac {9 \left (-4 \left (x+\frac {1}{32} (8-16 e)\right )-2 e+1\right )}{(1+2 e)^2-16 \left (x+\frac {1}{32} (8-16 e)\right )^2}\) |
\(\Big \downarrow \) 24 |
\(\displaystyle x+\frac {9 \left (-4 \left (x+\frac {1}{32} (8-16 e)\right )-2 e+1\right )}{(1+2 e)^2-16 \left (x+\frac {1}{32} (8-16 e)\right )^2}+\frac {1}{32} (8-16 e)\) |
Input:
Int[(-16*x^2 + 8*x^3 + 8*x^4 + E^2*(2 + 8*x + 8*x^2) + E*(-9 - 4*x - 16*x^ 2 - 16*x^3))/(2*x^2 + 8*x^3 + 8*x^4 + E^2*(2 + 8*x + 8*x^2) + E*(-4*x - 16 *x^2 - 16*x^3)),x]
Output:
(8 - 16*E)/32 + x + (9*(1 - 2*E - 4*((8 - 16*E)/32 + x)))/((1 + 2*E)^2 - 1 6*((8 - 16*E)/32 + x)^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_)*((a_) + (c_.)*(x_)^(n2_.) + (b_.)*(x_)^(n_))^(p_.), x_Symbol] :> S imp[1/c^p Int[u*(b/2 + c*x^n)^(2*p), x], x] /; FreeQ[{a, b, c, n, p}, x] && EqQ[n2, 2*n] && EqQ[b^2 - 4*a*c, 0] && IntegerQ[p]
Int[(Pq_)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> With[{Q = PolynomialQuot ient[Pq, a + b*x^2, x], f = Coeff[PolynomialRemainder[Pq, a + b*x^2, x], x, 0], g = Coeff[PolynomialRemainder[Pq, a + b*x^2, x], x, 1]}, Simp[(a*g - b *f*x)*((a + b*x^2)^(p + 1)/(2*a*b*(p + 1))), x] + Simp[1/(2*a*(p + 1)) In t[(a + b*x^2)^(p + 1)*ExpandToSum[2*a*(p + 1)*Q + f*(2*p + 3), x], x], x]] /; FreeQ[{a, b}, x] && PolyQ[Pq, x] && LtQ[p, -1]
Int[(Pn_)^(p_.)*(Qx_), x_Symbol] :> With[{S = Coeff[Pn, x, Expon[Pn, x] - 1 ]/(Expon[Pn, x]*Coeff[Pn, x, Expon[Pn, x]])}, Subst[Int[ExpandToSum[Pn /. x -> x - S, x]^p*ExpandToSum[Qx /. x -> x - S, x], x], x, x + S] /; Binomial Q[Pn /. x -> x - S, x] || (IntegerQ[Expon[Pn, x]/2] && TrinomialQ[Pn /. x - > x - S, x])] /; FreeQ[p, x] && PolyQ[Pn, x] && GtQ[Expon[Pn, x], 2] && NeQ [Coeff[Pn, x, Expon[Pn, x] - 1], 0] && PolyQ[Qx, x] && !(MonomialQ[Qx, x] && IGtQ[p, 0])
Time = 0.30 (sec) , antiderivative size = 25, normalized size of antiderivative = 0.93
method | result | size |
risch | \(x -\frac {9 x}{4 \left (x \,{\mathrm e}-x^{2}+\frac {{\mathrm e}}{2}-\frac {x}{2}\right )}\) | \(25\) |
norman | \(\frac {\left (2 \,{\mathrm e}^{2}-{\mathrm e}-4\right ) x -2 x^{3}+{\mathrm e}^{2}-\frac {{\mathrm e}}{2}}{\left (1+2 x \right ) \left (-x +{\mathrm e}\right )}\) | \(45\) |
gosper | \(\frac {4 \,{\mathrm e}^{2} x -4 x^{3}+2 \,{\mathrm e}^{2}-2 x \,{\mathrm e}-{\mathrm e}-8 x}{4 x \,{\mathrm e}-4 x^{2}+2 \,{\mathrm e}-2 x}\) | \(52\) |
parallelrisch | \(\frac {8 \,{\mathrm e}^{2} x -8 x^{3}+4 \,{\mathrm e}^{2}-4 x \,{\mathrm e}-2 \,{\mathrm e}-16 x}{8 x \,{\mathrm e}-8 x^{2}+4 \,{\mathrm e}-4 x}\) | \(52\) |
Input:
int(((8*x^2+8*x+2)*exp(1)^2+(-16*x^3-16*x^2-4*x-9)*exp(1)+8*x^4+8*x^3-16*x ^2)/((8*x^2+8*x+2)*exp(1)^2+(-16*x^3-16*x^2-4*x)*exp(1)+8*x^4+8*x^3+2*x^2) ,x,method=_RETURNVERBOSE)
Output:
x-9/4*x/(x*exp(1)-x^2+1/2*exp(1)-1/2*x)
Leaf count of result is larger than twice the leaf count of optimal. 45 vs. \(2 (20) = 40\).
Time = 0.07 (sec) , antiderivative size = 45, normalized size of antiderivative = 1.67 \[ \int \frac {-16 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-9-4 x-16 x^2-16 x^3\right )}{2 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-4 x-16 x^2-16 x^3\right )} \, dx=\frac {4 \, x^{3} + 2 \, x^{2} - 2 \, {\left (2 \, x^{2} + x\right )} e + 9 \, x}{2 \, {\left (2 \, x^{2} - {\left (2 \, x + 1\right )} e + x\right )}} \] Input:
integrate(((8*x^2+8*x+2)*exp(1)^2+(-16*x^3-16*x^2-4*x-9)*exp(1)+8*x^4+8*x^ 3-16*x^2)/((8*x^2+8*x+2)*exp(1)^2+(-16*x^3-16*x^2-4*x)*exp(1)+8*x^4+8*x^3+ 2*x^2),x, algorithm="fricas")
Output:
1/2*(4*x^3 + 2*x^2 - 2*(2*x^2 + x)*e + 9*x)/(2*x^2 - (2*x + 1)*e + x)
Time = 0.40 (sec) , antiderivative size = 22, normalized size of antiderivative = 0.81 \[ \int \frac {-16 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-9-4 x-16 x^2-16 x^3\right )}{2 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-4 x-16 x^2-16 x^3\right )} \, dx=x + \frac {9 x}{4 x^{2} + x \left (2 - 4 e\right ) - 2 e} \] Input:
integrate(((8*x**2+8*x+2)*exp(1)**2+(-16*x**3-16*x**2-4*x-9)*exp(1)+8*x**4 +8*x**3-16*x**2)/((8*x**2+8*x+2)*exp(1)**2+(-16*x**3-16*x**2-4*x)*exp(1)+8 *x**4+8*x**3+2*x**2),x)
Output:
x + 9*x/(4*x**2 + x*(2 - 4*E) - 2*E)
Time = 0.04 (sec) , antiderivative size = 26, normalized size of antiderivative = 0.96 \[ \int \frac {-16 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-9-4 x-16 x^2-16 x^3\right )}{2 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-4 x-16 x^2-16 x^3\right )} \, dx=x + \frac {9 \, x}{2 \, {\left (2 \, x^{2} - x {\left (2 \, e - 1\right )} - e\right )}} \] Input:
integrate(((8*x^2+8*x+2)*exp(1)^2+(-16*x^3-16*x^2-4*x-9)*exp(1)+8*x^4+8*x^ 3-16*x^2)/((8*x^2+8*x+2)*exp(1)^2+(-16*x^3-16*x^2-4*x)*exp(1)+8*x^4+8*x^3+ 2*x^2),x, algorithm="maxima")
Output:
x + 9/2*x/(2*x^2 - x*(2*e - 1) - e)
Time = 0.11 (sec) , antiderivative size = 23, normalized size of antiderivative = 0.85 \[ \int \frac {-16 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-9-4 x-16 x^2-16 x^3\right )}{2 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-4 x-16 x^2-16 x^3\right )} \, dx=x + \frac {9 \, x}{2 \, {\left (2 \, x^{2} - 2 \, x e + x - e\right )}} \] Input:
integrate(((8*x^2+8*x+2)*exp(1)^2+(-16*x^3-16*x^2-4*x-9)*exp(1)+8*x^4+8*x^ 3-16*x^2)/((8*x^2+8*x+2)*exp(1)^2+(-16*x^3-16*x^2-4*x)*exp(1)+8*x^4+8*x^3+ 2*x^2),x, algorithm="giac")
Output:
x + 9/2*x/(2*x^2 - 2*x*e + x - e)
Time = 2.24 (sec) , antiderivative size = 20, normalized size of antiderivative = 0.74 \[ \int \frac {-16 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-9-4 x-16 x^2-16 x^3\right )}{2 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-4 x-16 x^2-16 x^3\right )} \, dx=x+\frac {9\,x}{2\,\left (2\,x+1\right )\,\left (x-\mathrm {e}\right )} \] Input:
int((exp(2)*(8*x + 8*x^2 + 2) - exp(1)*(4*x + 16*x^2 + 16*x^3 + 9) - 16*x^ 2 + 8*x^3 + 8*x^4)/(exp(2)*(8*x + 8*x^2 + 2) - exp(1)*(4*x + 16*x^2 + 16*x ^3) + 2*x^2 + 8*x^3 + 8*x^4),x)
Output:
x + (9*x)/(2*(2*x + 1)*(x - exp(1)))
Time = 0.21 (sec) , antiderivative size = 75, normalized size of antiderivative = 2.78 \[ \int \frac {-16 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-9-4 x-16 x^2-16 x^3\right )}{2 x^2+8 x^3+8 x^4+e^2 \left (2+8 x+8 x^2\right )+e \left (-4 x-16 x^2-16 x^3\right )} \, dx=\frac {8 e^{2} x^{2}-8 e \,x^{3}-4 e \,x^{2}+4 x^{3}-2 e^{2}-16 x^{2}+9 e}{8 e^{2} x -8 e \,x^{2}+4 e^{2}-8 e x +4 x^{2}-2 e +2 x} \] Input:
int(((8*x^2+8*x+2)*exp(1)^2+(-16*x^3-16*x^2-4*x-9)*exp(1)+8*x^4+8*x^3-16*x ^2)/((8*x^2+8*x+2)*exp(1)^2+(-16*x^3-16*x^2-4*x)*exp(1)+8*x^4+8*x^3+2*x^2) ,x)
Output:
(8*e**2*x**2 - 2*e**2 - 8*e*x**3 - 4*e*x**2 + 9*e + 4*x**3 - 16*x**2)/(2*( 4*e**2*x + 2*e**2 - 4*e*x**2 - 4*e*x - e + 2*x**2 + x))