3.91.79 \(\int \frac {-4+3 x+8 x^2-8 x^3+2 x^4}{8 x^3-8 x^4+2 x^5} \, dx\)

Optimal. Leaf size=22 \[ -1+\frac {1}{2 (2-x) x^2}+\log \left (\frac {x}{5}\right ) \]

________________________________________________________________________________________

Rubi [A]  time = 0.06, antiderivative size = 28, normalized size of antiderivative = 1.27, number of steps used = 5, number of rules used = 4, integrand size = 39, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.103, Rules used = {1594, 27, 12, 1620} \begin {gather*} \frac {1}{4 x^2}+\frac {1}{8 (2-x)}+\frac {1}{8 x}+\log (x) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-4 + 3*x + 8*x^2 - 8*x^3 + 2*x^4)/(8*x^3 - 8*x^4 + 2*x^5),x]

[Out]

1/(8*(2 - x)) + 1/(4*x^2) + 1/(8*x) + Log[x]

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 27

Int[(u_.)*((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[u*Cancel[(b/2 + c*x)^(2*p)/c^p], x] /; Fr
eeQ[{a, b, c}, x] && EqQ[b^2 - 4*a*c, 0] && IntegerQ[p]

Rule 1594

Int[(u_.)*((a_.)*(x_)^(p_.) + (b_.)*(x_)^(q_.) + (c_.)*(x_)^(r_.))^(n_.), x_Symbol] :> Int[u*x^(n*p)*(a + b*x^
(q - p) + c*x^(r - p))^n, x] /; FreeQ[{a, b, c, p, q, r}, x] && IntegerQ[n] && PosQ[q - p] && PosQ[r - p]

Rule 1620

Int[(Px_)*((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[Px*(a + b*x)
^m*(c + d*x)^n, x], x] /; FreeQ[{a, b, c, d, m, n}, x] && PolyQ[Px, x] && (IntegersQ[m, n] || IGtQ[m, -2]) &&
GtQ[Expon[Px, x], 2]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {-4+3 x+8 x^2-8 x^3+2 x^4}{x^3 \left (8-8 x+2 x^2\right )} \, dx\\ &=\int \frac {-4+3 x+8 x^2-8 x^3+2 x^4}{2 (-2+x)^2 x^3} \, dx\\ &=\frac {1}{2} \int \frac {-4+3 x+8 x^2-8 x^3+2 x^4}{(-2+x)^2 x^3} \, dx\\ &=\frac {1}{2} \int \left (\frac {1}{4 (-2+x)^2}-\frac {1}{x^3}-\frac {1}{4 x^2}+\frac {2}{x}\right ) \, dx\\ &=\frac {1}{8 (2-x)}+\frac {1}{4 x^2}+\frac {1}{8 x}+\log (x)\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 19, normalized size = 0.86 \begin {gather*} \frac {1}{2} \left (-\frac {1}{(-2+x) x^2}+2 \log (x)\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-4 + 3*x + 8*x^2 - 8*x^3 + 2*x^4)/(8*x^3 - 8*x^4 + 2*x^5),x]

[Out]

(-(1/((-2 + x)*x^2)) + 2*Log[x])/2

________________________________________________________________________________________

fricas [A]  time = 0.59, size = 28, normalized size = 1.27 \begin {gather*} \frac {2 \, {\left (x^{3} - 2 \, x^{2}\right )} \log \relax (x) - 1}{2 \, {\left (x^{3} - 2 \, x^{2}\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^4-8*x^3+8*x^2+3*x-4)/(2*x^5-8*x^4+8*x^3),x, algorithm="fricas")

[Out]

1/2*(2*(x^3 - 2*x^2)*log(x) - 1)/(x^3 - 2*x^2)

________________________________________________________________________________________

giac [A]  time = 0.15, size = 14, normalized size = 0.64 \begin {gather*} -\frac {1}{2 \, {\left (x - 2\right )} x^{2}} + \log \left ({\left | x \right |}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^4-8*x^3+8*x^2+3*x-4)/(2*x^5-8*x^4+8*x^3),x, algorithm="giac")

[Out]

-1/2/((x - 2)*x^2) + log(abs(x))

________________________________________________________________________________________

maple [A]  time = 0.03, size = 14, normalized size = 0.64




method result size



norman \(-\frac {1}{2 x^{2} \left (x -2\right )}+\ln \relax (x )\) \(14\)
risch \(-\frac {1}{2 x^{2} \left (x -2\right )}+\ln \relax (x )\) \(14\)
default \(\frac {1}{4 x^{2}}+\frac {1}{8 x}+\ln \relax (x )-\frac {1}{8 \left (x -2\right )}\) \(21\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((2*x^4-8*x^3+8*x^2+3*x-4)/(2*x^5-8*x^4+8*x^3),x,method=_RETURNVERBOSE)

[Out]

-1/2/x^2/(x-2)+ln(x)

________________________________________________________________________________________

maxima [A]  time = 0.35, size = 16, normalized size = 0.73 \begin {gather*} -\frac {1}{2 \, {\left (x^{3} - 2 \, x^{2}\right )}} + \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^4-8*x^3+8*x^2+3*x-4)/(2*x^5-8*x^4+8*x^3),x, algorithm="maxima")

[Out]

-1/2/(x^3 - 2*x^2) + log(x)

________________________________________________________________________________________

mupad [B]  time = 0.05, size = 13, normalized size = 0.59 \begin {gather*} \ln \relax (x)-\frac {1}{2\,x^2\,\left (x-2\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((3*x + 8*x^2 - 8*x^3 + 2*x^4 - 4)/(8*x^3 - 8*x^4 + 2*x^5),x)

[Out]

log(x) - 1/(2*x^2*(x - 2))

________________________________________________________________________________________

sympy [A]  time = 0.10, size = 14, normalized size = 0.64 \begin {gather*} \log {\relax (x )} - \frac {1}{2 x^{3} - 4 x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x**4-8*x**3+8*x**2+3*x-4)/(2*x**5-8*x**4+8*x**3),x)

[Out]

log(x) - 1/(2*x**3 - 4*x**2)

________________________________________________________________________________________