3.13.30 \(\int \frac {-2+6 x^2+(1-x^2) \log (x^2-2 x^4+x^6)}{-x^2+x^4} \, dx\)

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

________________________________________________________________________________________

Rubi [A]  time = 0.29, antiderivative size = 18, normalized size of antiderivative = 1.00, number of steps used = 8, number of rules used = 6, integrand size = 40, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.150, Rules used = {1593, 6725, 453, 207, 2525, 206} \begin {gather*} \frac {\log \left (x^2 \left (1-x^2\right )^2\right )}{x} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-2 + 6*x^2 + (1 - x^2)*Log[x^2 - 2*x^4 + x^6])/(-x^2 + x^4),x]

[Out]

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

Rule 206

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTanh[(Rt[-b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[-b, 2]), x]
 /; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rule 207

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> -Simp[ArcTanh[(Rt[b, 2]*x)/Rt[-a, 2]]/(Rt[-a, 2]*Rt[b, 2]), x] /;
 FreeQ[{a, b}, x] && NegQ[a/b] && (LtQ[a, 0] || GtQ[b, 0])

Rule 453

Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.)*((c_) + (d_.)*(x_)^(n_)), x_Symbol] :> Simp[(c*(e*x)^(m
+ 1)*(a + b*x^n)^(p + 1))/(a*e*(m + 1)), x] + Dist[(a*d*(m + 1) - b*c*(m + n*(p + 1) + 1))/(a*e^n*(m + 1)), In
t[(e*x)^(m + n)*(a + b*x^n)^p, x], x] /; FreeQ[{a, b, c, d, e, p}, x] && NeQ[b*c - a*d, 0] && (IntegerQ[n] ||
GtQ[e, 0]) && ((GtQ[n, 0] && LtQ[m, -1]) || (LtQ[n, 0] && GtQ[m + n, -1])) &&  !ILtQ[p, -1]

Rule 1593

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

Rule 2525

Int[((a_.) + Log[(c_.)*(RFx_)^(p_.)]*(b_.))^(n_.)*((d_.) + (e_.)*(x_))^(m_.), x_Symbol] :> Simp[((d + e*x)^(m
+ 1)*(a + b*Log[c*RFx^p])^n)/(e*(m + 1)), x] - Dist[(b*n*p)/(e*(m + 1)), Int[SimplifyIntegrand[((d + e*x)^(m +
 1)*(a + b*Log[c*RFx^p])^(n - 1)*D[RFx, x])/RFx, x], x], x] /; FreeQ[{a, b, c, d, e, m, p}, x] && RationalFunc
tionQ[RFx, x] && IGtQ[n, 0] && (EqQ[n, 1] || IntegerQ[m]) && NeQ[m, -1]

Rule 6725

Int[(u_)/((a_) + (b_.)*(x_)^(n_)), x_Symbol] :> With[{v = RationalFunctionExpand[u/(a + b*x^n), x]}, Int[v, x]
 /; SumQ[v]] /; FreeQ[{a, b}, x] && IGtQ[n, 0]

Rubi steps

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

________________________________________________________________________________________

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

Antiderivative was successfully verified.

[In]

Integrate[(-2 + 6*x^2 + (1 - x^2)*Log[x^2 - 2*x^4 + x^6])/(-x^2 + x^4),x]

[Out]

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

________________________________________________________________________________________

fricas [A]  time = 0.59, size = 17, normalized size = 0.94 \begin {gather*} \frac {\log \left (x^{6} - 2 \, x^{4} + x^{2}\right )}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-x^2+1)*log(x^6-2*x^4+x^2)+6*x^2-2)/(x^4-x^2),x, algorithm="fricas")

[Out]

log(x^6 - 2*x^4 + x^2)/x

________________________________________________________________________________________

giac [A]  time = 0.46, size = 17, normalized size = 0.94 \begin {gather*} \frac {\log \left (x^{6} - 2 \, x^{4} + x^{2}\right )}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-x^2+1)*log(x^6-2*x^4+x^2)+6*x^2-2)/(x^4-x^2),x, algorithm="giac")

[Out]

log(x^6 - 2*x^4 + x^2)/x

________________________________________________________________________________________

maple [A]  time = 0.21, size = 18, normalized size = 1.00




method result size



default \(\frac {\ln \left (x^{6}-2 x^{4}+x^{2}\right )}{x}\) \(18\)
norman \(\frac {\ln \left (x^{6}-2 x^{4}+x^{2}\right )}{x}\) \(18\)
risch \(\frac {\ln \left (x^{6}-2 x^{4}+x^{2}\right )}{x}\) \(18\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((-x^2+1)*ln(x^6-2*x^4+x^2)+6*x^2-2)/(x^4-x^2),x,method=_RETURNVERBOSE)

[Out]

1/x*ln(x^6-2*x^4+x^2)

________________________________________________________________________________________

maxima [B]  time = 0.44, size = 44, normalized size = 2.44 \begin {gather*} \frac {2 \, {\left ({\left (x + 1\right )} \log \left (x + 1\right ) - {\left (x - 1\right )} \log \left (x - 1\right ) + \log \relax (x) + 1\right )}}{x} - \frac {2}{x} - 2 \, \log \left (x + 1\right ) + 2 \, \log \left (x - 1\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-x^2+1)*log(x^6-2*x^4+x^2)+6*x^2-2)/(x^4-x^2),x, algorithm="maxima")

[Out]

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

________________________________________________________________________________________

mupad [B]  time = 0.98, size = 16, normalized size = 0.89 \begin {gather*} \frac {\ln \left (x^2\,{\left (x^2-1\right )}^2\right )}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((log(x^2 - 2*x^4 + x^6)*(x^2 - 1) - 6*x^2 + 2)/(x^2 - x^4),x)

[Out]

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

________________________________________________________________________________________

sympy [A]  time = 0.13, size = 14, normalized size = 0.78 \begin {gather*} \frac {\log {\left (x^{6} - 2 x^{4} + x^{2} \right )}}{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-x**2+1)*ln(x**6-2*x**4+x**2)+6*x**2-2)/(x**4-x**2),x)

[Out]

log(x**6 - 2*x**4 + x**2)/x

________________________________________________________________________________________