### 3.80 $$\int \frac{4+x^2+3 x^4+5 x^6}{x^3 (2+3 x^2+x^4)^2} \, dx$$

Optimal. Leaf size=55 $\frac{11 x^2+9}{4 \left (x^4+3 x^2+2\right )}-\frac{1}{2 x^2}+5 \log \left (x^2+1\right )-\frac{29}{8} \log \left (x^2+2\right )-\frac{11 \log (x)}{4}$

[Out]

-1/(2*x^2) + (9 + 11*x^2)/(4*(2 + 3*x^2 + x^4)) - (11*Log[x])/4 + 5*Log[1 + x^2] - (29*Log[2 + x^2])/8

________________________________________________________________________________________

Rubi [A]  time = 0.104323, antiderivative size = 55, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 3, integrand size = 31, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.097, Rules used = {1663, 1646, 1628} $\frac{11 x^2+9}{4 \left (x^4+3 x^2+2\right )}-\frac{1}{2 x^2}+5 \log \left (x^2+1\right )-\frac{29}{8} \log \left (x^2+2\right )-\frac{11 \log (x)}{4}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

-1/(2*x^2) + (9 + 11*x^2)/(4*(2 + 3*x^2 + x^4)) - (11*Log[x])/4 + 5*Log[1 + x^2] - (29*Log[2 + x^2])/8

Rule 1663

Int[(Pq_)*(x_)^(m_.)*((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4)^(p_), x_Symbol] :> Dist[1/2, Subst[Int[x^((m - 1)/2)
*SubstFor[x^2, Pq, x]*(a + b*x + c*x^2)^p, x], x, x^2], x] /; FreeQ[{a, b, c, p}, x] && PolyQ[Pq, x^2] && Inte
gerQ[(m - 1)/2]

Rule 1646

Int[(Pq_)*((d_.) + (e_.)*(x_))^(m_.)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> With[{Q = Polynomi
alQuotient[(d + e*x)^m*Pq, a + b*x + c*x^2, x], f = Coeff[PolynomialRemainder[(d + e*x)^m*Pq, a + b*x + c*x^2,
x], x, 0], g = Coeff[PolynomialRemainder[(d + e*x)^m*Pq, a + b*x + c*x^2, x], x, 1]}, Simp[((b*f - 2*a*g + (2
*c*f - b*g)*x)*(a + b*x + c*x^2)^(p + 1))/((p + 1)*(b^2 - 4*a*c)), x] + Dist[1/((p + 1)*(b^2 - 4*a*c)), Int[(d
+ e*x)^m*(a + b*x + c*x^2)^(p + 1)*ExpandToSum[((p + 1)*(b^2 - 4*a*c)*Q)/(d + e*x)^m - ((2*p + 3)*(2*c*f - b*
g))/(d + e*x)^m, x], x], x]] /; FreeQ[{a, b, c, d, e}, x] && PolyQ[Pq, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2
- b*d*e + a*e^2, 0] && LtQ[p, -1] && ILtQ[m, 0]

Rule 1628

Int[(Pq_)*((d_.) + (e_.)*(x_))^(m_.)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ExpandIntegra
nd[(d + e*x)^m*Pq*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, m}, x] && PolyQ[Pq, x] && IGtQ[p, -2]

Rubi steps

\begin{align*} \int \frac{4+x^2+3 x^4+5 x^6}{x^3 \left (2+3 x^2+x^4\right )^2} \, dx &=\frac{1}{2} \operatorname{Subst}\left (\int \frac{4+x+3 x^2+5 x^3}{x^2 \left (2+3 x+x^2\right )^2} \, dx,x,x^2\right )\\ &=\frac{9+11 x^2}{4 \left (2+3 x^2+x^4\right )}-\frac{1}{2} \operatorname{Subst}\left (\int \frac{-2+\frac{5 x}{2}-\frac{11 x^2}{2}}{x^2 \left (2+3 x+x^2\right )} \, dx,x,x^2\right )\\ &=\frac{9+11 x^2}{4 \left (2+3 x^2+x^4\right )}-\frac{1}{2} \operatorname{Subst}\left (\int \left (-\frac{1}{x^2}+\frac{11}{4 x}-\frac{10}{1+x}+\frac{29}{4 (2+x)}\right ) \, dx,x,x^2\right )\\ &=-\frac{1}{2 x^2}+\frac{9+11 x^2}{4 \left (2+3 x^2+x^4\right )}-\frac{11 \log (x)}{4}+5 \log \left (1+x^2\right )-\frac{29}{8} \log \left (2+x^2\right )\\ \end{align*}

Mathematica [A]  time = 0.0251518, size = 50, normalized size = 0.91 $\frac{1}{8} \left (\frac{22 x^2+18}{x^4+3 x^2+2}-\frac{4}{x^2}+40 \log \left (x^2+1\right )-29 \log \left (x^2+2\right )-22 \log (x)\right )$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

(-4/x^2 + (18 + 22*x^2)/(2 + 3*x^2 + x^4) - 22*Log[x] + 40*Log[1 + x^2] - 29*Log[2 + x^2])/8

________________________________________________________________________________________

Maple [A]  time = 0.017, size = 45, normalized size = 0.8 \begin{align*} -{\frac{29\,\ln \left ({x}^{2}+2 \right ) }{8}}+{\frac{13}{4\,{x}^{2}+8}}+5\,\ln \left ({x}^{2}+1 \right ) -{\frac{1}{2\,{x}^{2}+2}}-{\frac{1}{2\,{x}^{2}}}-{\frac{11\,\ln \left ( x \right ) }{4}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-29/8*ln(x^2+2)+13/4/(x^2+2)+5*ln(x^2+1)-1/2/(x^2+1)-1/2/x^2-11/4*ln(x)

________________________________________________________________________________________

Maxima [A]  time = 1.00124, size = 72, normalized size = 1.31 \begin{align*} \frac{9 \, x^{4} + 3 \, x^{2} - 4}{4 \,{\left (x^{6} + 3 \, x^{4} + 2 \, x^{2}\right )}} - \frac{29}{8} \, \log \left (x^{2} + 2\right ) + 5 \, \log \left (x^{2} + 1\right ) - \frac{11}{8} \, \log \left (x^{2}\right ) \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*(9*x^4 + 3*x^2 - 4)/(x^6 + 3*x^4 + 2*x^2) - 29/8*log(x^2 + 2) + 5*log(x^2 + 1) - 11/8*log(x^2)

________________________________________________________________________________________

Fricas [A]  time = 1.85876, size = 219, normalized size = 3.98 \begin{align*} \frac{18 \, x^{4} + 6 \, x^{2} - 29 \,{\left (x^{6} + 3 \, x^{4} + 2 \, x^{2}\right )} \log \left (x^{2} + 2\right ) + 40 \,{\left (x^{6} + 3 \, x^{4} + 2 \, x^{2}\right )} \log \left (x^{2} + 1\right ) - 22 \,{\left (x^{6} + 3 \, x^{4} + 2 \, x^{2}\right )} \log \left (x\right ) - 8}{8 \,{\left (x^{6} + 3 \, x^{4} + 2 \, x^{2}\right )}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/8*(18*x^4 + 6*x^2 - 29*(x^6 + 3*x^4 + 2*x^2)*log(x^2 + 2) + 40*(x^6 + 3*x^4 + 2*x^2)*log(x^2 + 1) - 22*(x^6
+ 3*x^4 + 2*x^2)*log(x) - 8)/(x^6 + 3*x^4 + 2*x^2)

________________________________________________________________________________________

Sympy [A]  time = 0.190424, size = 51, normalized size = 0.93 \begin{align*} \frac{9 x^{4} + 3 x^{2} - 4}{4 x^{6} + 12 x^{4} + 8 x^{2}} - \frac{11 \log{\left (x \right )}}{4} + 5 \log{\left (x^{2} + 1 \right )} - \frac{29 \log{\left (x^{2} + 2 \right )}}{8} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

(9*x**4 + 3*x**2 - 4)/(4*x**6 + 12*x**4 + 8*x**2) - 11*log(x)/4 + 5*log(x**2 + 1) - 29*log(x**2 + 2)/8

________________________________________________________________________________________

Giac [A]  time = 1.1098, size = 72, normalized size = 1.31 \begin{align*} \frac{9 \, x^{4} + 3 \, x^{2} - 4}{4 \,{\left (x^{6} + 3 \, x^{4} + 2 \, x^{2}\right )}} - \frac{29}{8} \, \log \left (x^{2} + 2\right ) + 5 \, \log \left (x^{2} + 1\right ) - \frac{11}{8} \, \log \left (x^{2}\right ) \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*(9*x^4 + 3*x^2 - 4)/(x^6 + 3*x^4 + 2*x^2) - 29/8*log(x^2 + 2) + 5*log(x^2 + 1) - 11/8*log(x^2)