3.6.36 \(\int \frac {x (2 e-2 f x^3)}{e^2+4 e f x^3+4 d f x^4+4 f^2 x^6} \, dx\) [536]

Optimal. Leaf size=40 \[ \frac {\tan ^{-1}\left (\frac {2 \sqrt {d} \sqrt {f} x^2}{e+2 f x^3}\right )}{2 \sqrt {d} \sqrt {f}} \]

[Out]

1/2*arctan(2*x^2*d^(1/2)*f^(1/2)/(2*f*x^3+e))/d^(1/2)/f^(1/2)

________________________________________________________________________________________

Rubi [A]
time = 0.06, antiderivative size = 40, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, integrand size = 40, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.050, Rules used = {2119, 211} \begin {gather*} \frac {\text {ArcTan}\left (\frac {2 \sqrt {d} \sqrt {f} x^2}{e+2 f x^3}\right )}{2 \sqrt {d} \sqrt {f}} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(x*(2*e - 2*f*x^3))/(e^2 + 4*e*f*x^3 + 4*d*f*x^4 + 4*f^2*x^6),x]

[Out]

ArcTan[(2*Sqrt[d]*Sqrt[f]*x^2)/(e + 2*f*x^3)]/(2*Sqrt[d]*Sqrt[f])

Rule 211

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]/a)*ArcTan[x/Rt[a/b, 2]], x] /; FreeQ[{a, b}, x]
&& PosQ[a/b]

Rule 2119

Int[((x_)^(m_.)*((A_) + (B_.)*(x_)^(n_.)))/((a_) + (b_.)*(x_)^(k_.) + (c_.)*(x_)^(n_.) + (d_.)*(x_)^(n2_)), x_
Symbol] :> Dist[A^2*((m - n + 1)/(m + 1)), Subst[Int[1/(a + A^2*b*(m - n + 1)^2*x^2), x], x, x^(m + 1)/(A*(m -
 n + 1) + B*(m + 1)*x^n)], x] /; FreeQ[{a, b, c, d, A, B, m, n}, x] && EqQ[n2, 2*n] && EqQ[k, 2*(m + 1)] && Eq
Q[a*B^2*(m + 1)^2 - A^2*d*(m - n + 1)^2, 0] && EqQ[B*c*(m + 1) - 2*A*d*(m - n + 1), 0]

Rubi steps

\begin {align*} \int \frac {x \left (2 e-2 f x^3\right )}{e^2+4 e f x^3+4 d f x^4+4 f^2 x^6} \, dx &=-\left (\left (2 e^2\right ) \text {Subst}\left (\int \frac {1}{e^2+16 d e^2 f x^2} \, dx,x,\frac {x^2}{-2 e-4 f x^3}\right )\right )\\ &=\frac {\tan ^{-1}\left (\frac {2 \sqrt {d} \sqrt {f} x^2}{e+2 f x^3}\right )}{2 \sqrt {d} \sqrt {f}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [C] Result contains higher order function than in optimal. Order 9 vs. order 3 in optimal.
time = 0.03, size = 86, normalized size = 2.15 \begin {gather*} -\frac {\text {RootSum}\left [e^2+4 e f \text {$\#$1}^3+4 d f \text {$\#$1}^4+4 f^2 \text {$\#$1}^6\&,\frac {-e \log (x-\text {$\#$1})+f \log (x-\text {$\#$1}) \text {$\#$1}^3}{3 e \text {$\#$1}+4 d \text {$\#$1}^2+6 f \text {$\#$1}^4}\&\right ]}{2 f} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(x*(2*e - 2*f*x^3))/(e^2 + 4*e*f*x^3 + 4*d*f*x^4 + 4*f^2*x^6),x]

[Out]

-1/2*RootSum[e^2 + 4*e*f*#1^3 + 4*d*f*#1^4 + 4*f^2*#1^6 & , (-(e*Log[x - #1]) + f*Log[x - #1]*#1^3)/(3*e*#1 +
4*d*#1^2 + 6*f*#1^4) & ]/f

________________________________________________________________________________________

Maple [C] Result contains higher order function than in optimal. Order 9 vs. order 3.
time = 0.04, size = 74, normalized size = 1.85

method result size
default \(\frac {\munderset {\textit {\_R} =\RootOf \left (4 f^{2} \textit {\_Z}^{6}+4 d f \,\textit {\_Z}^{4}+4 e f \,\textit {\_Z}^{3}+e^{2}\right )}{\sum }\frac {\left (-\textit {\_R}^{4} f +e \textit {\_R} \right ) \ln \left (x -\textit {\_R} \right )}{6 f \,\textit {\_R}^{5}+4 d \,\textit {\_R}^{3}+3 e \,\textit {\_R}^{2}}}{2 f}\) \(74\)
risch \(-\frac {\ln \left (\left (16 f \left (-d f \right )^{\frac {3}{2}} d +54 d \,f^{3} e \right ) x^{3}+\left (54 \left (-d f \right )^{\frac {3}{2}} e f -16 d^{3} f^{2}\right ) x^{2}+8 e \left (-d f \right )^{\frac {3}{2}} d +27 e^{2} f^{2} d \right )}{4 \sqrt {-d f}}+\frac {\ln \left (\left (16 f \left (-d f \right )^{\frac {3}{2}} d -54 d \,f^{3} e \right ) x^{3}+\left (54 \left (-d f \right )^{\frac {3}{2}} e f +16 d^{3} f^{2}\right ) x^{2}+8 e \left (-d f \right )^{\frac {3}{2}} d -27 e^{2} f^{2} d \right )}{4 \sqrt {-d f}}\) \(150\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*(-2*f*x^3+2*e)/(4*f^2*x^6+4*d*f*x^4+4*e*f*x^3+e^2),x,method=_RETURNVERBOSE)

[Out]

1/2/f*sum((-_R^4*f+_R*e)/(6*_R^5*f+4*_R^3*d+3*_R^2*e)*ln(x-_R),_R=RootOf(4*_Z^6*f^2+4*_Z^4*d*f+4*_Z^3*e*f+e^2)
)

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(-2*f*x^3+2*e)/(4*f^2*x^6+4*d*f*x^4+4*e*f*x^3+e^2),x, algorithm="maxima")

[Out]

-2*integrate((f*x^3 - e)*x/(4*f^2*x^6 + 4*d*f*x^4 + 4*f*x^3*e + e^2), x)

________________________________________________________________________________________

Fricas [A]
time = 0.37, size = 154, normalized size = 3.85 \begin {gather*} \left [-\frac {\sqrt {-d f} \log \left (\frac {4 \, f^{2} x^{6} - 4 \, d f x^{4} + 4 \, f x^{3} e + 4 \, {\left (2 \, f x^{5} + x^{2} e\right )} \sqrt {-d f} + e^{2}}{4 \, f^{2} x^{6} + 4 \, d f x^{4} + 4 \, f x^{3} e + e^{2}}\right )}{4 \, d f}, \frac {\sqrt {d f} \arctan \left (\frac {{\left (2 \, f x^{4} + 2 \, d x^{2} + x e\right )} \sqrt {d f} e^{\left (-1\right )}}{d}\right ) - \sqrt {d f} \arctan \left (\frac {\sqrt {d f} x}{d}\right )}{2 \, d f}\right ] \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(-2*f*x^3+2*e)/(4*f^2*x^6+4*d*f*x^4+4*e*f*x^3+e^2),x, algorithm="fricas")

[Out]

[-1/4*sqrt(-d*f)*log((4*f^2*x^6 - 4*d*f*x^4 + 4*f*x^3*e + 4*(2*f*x^5 + x^2*e)*sqrt(-d*f) + e^2)/(4*f^2*x^6 + 4
*d*f*x^4 + 4*f*x^3*e + e^2))/(d*f), 1/2*(sqrt(d*f)*arctan((2*f*x^4 + 2*d*x^2 + x*e)*sqrt(d*f)*e^(-1)/d) - sqrt
(d*f)*arctan(sqrt(d*f)*x/d))/(d*f)]

________________________________________________________________________________________

Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 73 vs. \(2 (36) = 72\).
time = 0.65, size = 73, normalized size = 1.82 \begin {gather*} \frac {\sqrt {- \frac {1}{d f}} \log {\left (- d x^{2} \sqrt {- \frac {1}{d f}} + \frac {e}{2 f} + x^{3} \right )}}{4} - \frac {\sqrt {- \frac {1}{d f}} \log {\left (d x^{2} \sqrt {- \frac {1}{d f}} + \frac {e}{2 f} + x^{3} \right )}}{4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(-2*f*x**3+2*e)/(4*f**2*x**6+4*d*f*x**4+4*e*f*x**3+e**2),x)

[Out]

sqrt(-1/(d*f))*log(-d*x**2*sqrt(-1/(d*f)) + e/(2*f) + x**3)/4 - sqrt(-1/(d*f))*log(d*x**2*sqrt(-1/(d*f)) + e/(
2*f) + x**3)/4

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 73 vs. \(2 (31) = 62\).
time = 5.18, size = 73, normalized size = 1.82 \begin {gather*} -\frac {\sqrt {-d f} \log \left ({\left | 2 \, f x^{3} + 2 \, \sqrt {-d f} x^{2} + e \right |}\right )}{4 \, d f} + \frac {\sqrt {-d f} \log \left ({\left | 2 \, f x^{3} - 2 \, \sqrt {-d f} x^{2} + e \right |}\right )}{4 \, d f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(-2*f*x^3+2*e)/(4*f^2*x^6+4*d*f*x^4+4*e*f*x^3+e^2),x, algorithm="giac")

[Out]

-1/4*sqrt(-d*f)*log(abs(2*f*x^3 + 2*sqrt(-d*f)*x^2 + e))/(d*f) + 1/4*sqrt(-d*f)*log(abs(2*f*x^3 - 2*sqrt(-d*f)
*x^2 + e))/(d*f)

________________________________________________________________________________________

Mupad [B]
time = 3.49, size = 233, normalized size = 5.82 \begin {gather*} \frac {\mathrm {atan}\left (\frac {128\,d^{7/2}\,\sqrt {f}\,x^2}{64\,d^3\,e+729\,f\,e^3}-\frac {216\,d^{3/2}\,e^2\,\sqrt {f}}{64\,d^3\,e+729\,f\,e^3}+\frac {128\,d^{5/2}\,f^{3/2}\,x^4}{64\,d^3\,e+729\,f\,e^3}+\frac {216\,d^{3/2}\,e\,\sqrt {f}}{64\,d^3+729\,f\,e^2}+\frac {729\,d^{3/2}\,e^2\,f^{3/2}\,x}{64\,d^5+729\,f\,d^2\,e^2}+\frac {1458\,d^{3/2}\,e\,f^{5/2}\,x^4}{64\,d^5+729\,f\,d^2\,e^2}+\frac {64\,d^{5/2}\,e\,\sqrt {f}\,x}{64\,d^3\,e+729\,f\,e^3}+\frac {1458\,d^{3/2}\,e\,f^{3/2}\,x^2}{64\,d^4+729\,f\,d\,e^2}\right )-\mathrm {atan}\left (\frac {\sqrt {f}\,x}{\sqrt {d}}\right )}{2\,\sqrt {d}\,\sqrt {f}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((x*(2*e - 2*f*x^3))/(e^2 + 4*f^2*x^6 + 4*d*f*x^4 + 4*e*f*x^3),x)

[Out]

(atan((128*d^(7/2)*f^(1/2)*x^2)/(64*d^3*e + 729*e^3*f) - (216*d^(3/2)*e^2*f^(1/2))/(64*d^3*e + 729*e^3*f) + (1
28*d^(5/2)*f^(3/2)*x^4)/(64*d^3*e + 729*e^3*f) + (216*d^(3/2)*e*f^(1/2))/(729*e^2*f + 64*d^3) + (729*d^(3/2)*e
^2*f^(3/2)*x)/(64*d^5 + 729*d^2*e^2*f) + (1458*d^(3/2)*e*f^(5/2)*x^4)/(64*d^5 + 729*d^2*e^2*f) + (64*d^(5/2)*e
*f^(1/2)*x)/(64*d^3*e + 729*e^3*f) + (1458*d^(3/2)*e*f^(3/2)*x^2)/(64*d^4 + 729*d*e^2*f)) - atan((f^(1/2)*x)/d
^(1/2)))/(2*d^(1/2)*f^(1/2))

________________________________________________________________________________________