3.2.17 \(\int \frac {x}{2-3 x+x^3} \, dx\) [117]

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

[Out]

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

________________________________________________________________________________________

Rubi [A]
time = 0.01, antiderivative size = 30, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 1, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.083, Rules used = {2099} \begin {gather*} \frac {1}{3 (1-x)}+\frac {2}{9} \log (1-x)-\frac {2}{9} \log (x+2) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

Rule 2099

Int[(P_)^(p_)*(Q_)^(q_.), x_Symbol] :> With[{PP = Factor[P]}, Int[ExpandIntegrand[PP^p*Q^q, x], x] /;  !SumQ[N
onfreeFactors[PP, x]]] /; FreeQ[q, x] && PolyQ[P, x] && PolyQ[Q, x] && IntegerQ[p] && NeQ[P, x]

Rubi steps

\begin {align*} \int \frac {x}{2-3 x+x^3} \, dx &=\int \left (\frac {1}{3 (-1+x)^2}+\frac {2}{9 (-1+x)}-\frac {2}{9 (2+x)}\right ) \, dx\\ &=\frac {1}{3 (1-x)}+\frac {2}{9} \log (1-x)-\frac {2}{9} \log (2+x)\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.01, size = 28, normalized size = 0.93 \begin {gather*} -\frac {1}{3 (-1+x)}+\frac {2}{9} \log (1-x)-\frac {2}{9} \log (2+x) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

Maple [A]
time = 0.02, size = 21, normalized size = 0.70

method result size
default \(-\frac {1}{3 \left (-1+x \right )}+\frac {2 \ln \left (-1+x \right )}{9}-\frac {2 \ln \left (2+x \right )}{9}\) \(21\)
norman \(-\frac {1}{3 \left (-1+x \right )}+\frac {2 \ln \left (-1+x \right )}{9}-\frac {2 \ln \left (2+x \right )}{9}\) \(21\)
risch \(-\frac {1}{3 \left (-1+x \right )}+\frac {2 \ln \left (-1+x \right )}{9}-\frac {2 \ln \left (2+x \right )}{9}\) \(21\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Maxima [A]
time = 3.11, size = 20, normalized size = 0.67 \begin {gather*} -\frac {1}{3 \, {\left (x - 1\right )}} - \frac {2}{9} \, \log \left (x + 2\right ) + \frac {2}{9} \, \log \left (x - 1\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Fricas [A]
time = 1.03, size = 27, normalized size = 0.90 \begin {gather*} -\frac {2 \, {\left (x - 1\right )} \log \left (x + 2\right ) - 2 \, {\left (x - 1\right )} \log \left (x - 1\right ) + 3}{9 \, {\left (x - 1\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Sympy [A]
time = 0.03, size = 22, normalized size = 0.73 \begin {gather*} \frac {2 \log {\left (x - 1 \right )}}{9} - \frac {2 \log {\left (x + 2 \right )}}{9} - \frac {1}{3 x - 3} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x/(x**3-3*x+2),x)

[Out]

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

________________________________________________________________________________________

Giac [A]
time = 0.45, size = 22, normalized size = 0.73 \begin {gather*} -\frac {1}{3 \, {\left (x - 1\right )}} - \frac {2}{9} \, \log \left ({\left | x + 2 \right |}\right ) + \frac {2}{9} \, \log \left ({\left | x - 1 \right |}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-1/3/(x - 1) - 2/9*log(abs(x + 2)) + 2/9*log(abs(x - 1))

________________________________________________________________________________________

Mupad [B]
time = 0.04, size = 18, normalized size = 0.60 \begin {gather*} -\frac {4\,\mathrm {atanh}\left (\frac {2\,x}{3}+\frac {1}{3}\right )}{9}-\frac {1}{3\,\left (x-1\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

- (4*atanh((2*x)/3 + 1/3))/9 - 1/(3*(x - 1))

________________________________________________________________________________________