3.12.6 \(\int \frac {18-12 x+29 x^2}{54 x^2-36 x^3+6 x^4} \, dx\)

Optimal. Leaf size=24 \[ -\frac {1}{3 x}+\frac {3 x}{2 (3-x)}-\log (3) \]

________________________________________________________________________________________

Rubi [A]  time = 0.05, antiderivative size = 19, normalized size of antiderivative = 0.79, number of steps used = 5, number of rules used = 4, integrand size = 29, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.138, Rules used = {1594, 27, 12, 893} \begin {gather*} \frac {9}{2 (3-x)}-\frac {1}{3 x} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(18 - 12*x + 29*x^2)/(54*x^2 - 36*x^3 + 6*x^4),x]

[Out]

9/(2*(3 - x)) - 1/(3*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 893

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))^(n_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :
> Int[ExpandIntegrand[(d + e*x)^m*(f + g*x)^n*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, f, g}, x] &
& NeQ[e*f - d*g, 0] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - b*d*e + a*e^2, 0] && IntegerQ[p] && ((EqQ[p, 1] && I
ntegersQ[m, n]) || (ILtQ[m, 0] && ILtQ[n, 0]))

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]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {18-12 x+29 x^2}{x^2 \left (54-36 x+6 x^2\right )} \, dx\\ &=\int \frac {18-12 x+29 x^2}{6 (-3+x)^2 x^2} \, dx\\ &=\frac {1}{6} \int \frac {18-12 x+29 x^2}{(-3+x)^2 x^2} \, dx\\ &=\frac {1}{6} \int \left (\frac {27}{(-3+x)^2}+\frac {2}{x^2}\right ) \, dx\\ &=\frac {9}{2 (3-x)}-\frac {1}{3 x}\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 17, normalized size = 0.71 \begin {gather*} \frac {1}{6} \left (-\frac {27}{-3+x}-\frac {2}{x}\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(18 - 12*x + 29*x^2)/(54*x^2 - 36*x^3 + 6*x^4),x]

[Out]

(-27/(-3 + x) - 2/x)/6

________________________________________________________________________________________

fricas [A]  time = 1.12, size = 16, normalized size = 0.67 \begin {gather*} -\frac {29 \, x - 6}{6 \, {\left (x^{2} - 3 \, x\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((29*x^2-12*x+18)/(6*x^4-36*x^3+54*x^2),x, algorithm="fricas")

[Out]

-1/6*(29*x - 6)/(x^2 - 3*x)

________________________________________________________________________________________

giac [A]  time = 0.39, size = 16, normalized size = 0.67 \begin {gather*} -\frac {29 \, x - 6}{6 \, {\left (x^{2} - 3 \, x\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((29*x^2-12*x+18)/(6*x^4-36*x^3+54*x^2),x, algorithm="giac")

[Out]

-1/6*(29*x - 6)/(x^2 - 3*x)

________________________________________________________________________________________

maple [A]  time = 0.02, size = 14, normalized size = 0.58




method result size



default \(-\frac {9}{2 \left (x -3\right )}-\frac {1}{3 x}\) \(14\)
norman \(\frac {1-\frac {29 x}{6}}{x \left (x -3\right )}\) \(15\)
risch \(\frac {1-\frac {29 x}{6}}{x \left (x -3\right )}\) \(15\)
gosper \(-\frac {29 x -6}{6 x \left (x -3\right )}\) \(16\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((29*x^2-12*x+18)/(6*x^4-36*x^3+54*x^2),x,method=_RETURNVERBOSE)

[Out]

-9/2/(x-3)-1/3/x

________________________________________________________________________________________

maxima [A]  time = 0.43, size = 16, normalized size = 0.67 \begin {gather*} -\frac {29 \, x - 6}{6 \, {\left (x^{2} - 3 \, x\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((29*x^2-12*x+18)/(6*x^4-36*x^3+54*x^2),x, algorithm="maxima")

[Out]

-1/6*(29*x - 6)/(x^2 - 3*x)

________________________________________________________________________________________

mupad [B]  time = 0.05, size = 15, normalized size = 0.62 \begin {gather*} -\frac {9}{2\,\left (x-3\right )}-\frac {1}{3\,x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((29*x^2 - 12*x + 18)/(54*x^2 - 36*x^3 + 6*x^4),x)

[Out]

- 9/(2*(x - 3)) - 1/(3*x)

________________________________________________________________________________________

sympy [A]  time = 0.09, size = 12, normalized size = 0.50 \begin {gather*} \frac {6 - 29 x}{6 x^{2} - 18 x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((29*x**2-12*x+18)/(6*x**4-36*x**3+54*x**2),x)

[Out]

(6 - 29*x)/(6*x**2 - 18*x)

________________________________________________________________________________________