Optimal. Leaf size=231 \[ \frac {(x-1) \left (a+(x-1)^2+5\right )}{4 \left (a^2+7 a+12\right ) \left (a-(x-1)^4-2 (x-1)^2+3\right )}+\frac {(x-1)^2+1}{4 (a+4) \left (a-(x-1)^4-2 (x-1)^2+3\right )}-\frac {\left (3 a+\sqrt {a+4}+10\right ) \tan ^{-1}\left (\frac {x-1}{\sqrt {1-\sqrt {a+4}}}\right )}{8 (a+3) (a+4)^{3/2} \sqrt {1-\sqrt {a+4}}}+\frac {\left (3 a-\sqrt {a+4}+10\right ) \tan ^{-1}\left (\frac {x-1}{\sqrt {\sqrt {a+4}+1}}\right )}{8 (a+3) (a+4)^{3/2} \sqrt {\sqrt {a+4}+1}}+\frac {\tanh ^{-1}\left (\frac {(x-1)^2+1}{\sqrt {a+4}}\right )}{4 (a+4)^{3/2}} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.24, antiderivative size = 231, normalized size of antiderivative = 1.00, number of steps used = 10, number of rules used = 9, integrand size = 24, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.375, Rules used = {1680, 1673, 1092, 1166, 204, 1107, 614, 618, 206} \[ \frac {(x-1) \left (a+(x-1)^2+5\right )}{4 \left (a^2+7 a+12\right ) \left (a-(x-1)^4-2 (x-1)^2+3\right )}+\frac {(x-1)^2+1}{4 (a+4) \left (a-(x-1)^4-2 (x-1)^2+3\right )}-\frac {\left (3 a+\sqrt {a+4}+10\right ) \tan ^{-1}\left (\frac {x-1}{\sqrt {1-\sqrt {a+4}}}\right )}{8 (a+3) (a+4)^{3/2} \sqrt {1-\sqrt {a+4}}}+\frac {\left (3 a-\sqrt {a+4}+10\right ) \tan ^{-1}\left (\frac {x-1}{\sqrt {\sqrt {a+4}+1}}\right )}{8 (a+3) (a+4)^{3/2} \sqrt {\sqrt {a+4}+1}}+\frac {\tanh ^{-1}\left (\frac {(x-1)^2+1}{\sqrt {a+4}}\right )}{4 (a+4)^{3/2}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 204
Rule 206
Rule 614
Rule 618
Rule 1092
Rule 1107
Rule 1166
Rule 1673
Rule 1680
Rubi steps
\begin {align*} \int \frac {x}{\left (a+8 x-8 x^2+4 x^3-x^4\right )^2} \, dx &=\operatorname {Subst}\left (\int \frac {1+x}{\left (3+a-2 x^2-x^4\right )^2} \, dx,x,-1+x\right )\\ &=\operatorname {Subst}\left (\int \frac {1}{\left (3+a-2 x^2-x^4\right )^2} \, dx,x,-1+x\right )+\operatorname {Subst}\left (\int \frac {x}{\left (3+a-2 x^2-x^4\right )^2} \, dx,x,-1+x\right )\\ &=\frac {\left (5+a+(-1+x)^2\right ) (-1+x)}{4 \left (12+7 a+a^2\right ) \left (3+a-2 (-1+x)^2-(-1+x)^4\right )}+\frac {1}{2} \operatorname {Subst}\left (\int \frac {1}{\left (3+a-2 x-x^2\right )^2} \, dx,x,(-1+x)^2\right )-\frac {\operatorname {Subst}\left (\int \frac {4+2 (3+a)-2 (4+4 (3+a))-2 x^2}{3+a-2 x^2-x^4} \, dx,x,-1+x\right )}{8 \left (12+7 a+a^2\right )}\\ &=\frac {1+(-1+x)^2}{4 (4+a) \left (3+a-2 (1-x)^2-(1-x)^4\right )}+\frac {\left (5+a+(-1+x)^2\right ) (-1+x)}{4 \left (12+7 a+a^2\right ) \left (3+a-2 (-1+x)^2-(-1+x)^4\right )}+\frac {\operatorname {Subst}\left (\int \frac {1}{3+a-2 x-x^2} \, dx,x,(-1+x)^2\right )}{4 (4+a)}-\frac {\left (10+3 a-\sqrt {4+a}\right ) \operatorname {Subst}\left (\int \frac {1}{-1-\sqrt {4+a}-x^2} \, dx,x,-1+x\right )}{8 (3+a) (4+a)^{3/2}}+\frac {\left (10+3 a+\sqrt {4+a}\right ) \operatorname {Subst}\left (\int \frac {1}{-1+\sqrt {4+a}-x^2} \, dx,x,-1+x\right )}{8 (3+a) (4+a)^{3/2}}\\ &=\frac {1+(-1+x)^2}{4 (4+a) \left (3+a-2 (1-x)^2-(1-x)^4\right )}+\frac {\left (5+a+(-1+x)^2\right ) (-1+x)}{4 \left (12+7 a+a^2\right ) \left (3+a-2 (-1+x)^2-(-1+x)^4\right )}+\frac {\left (10+3 a+\sqrt {4+a}\right ) \tan ^{-1}\left (\frac {1-x}{\sqrt {1-\sqrt {4+a}}}\right )}{8 (3+a) (4+a)^{3/2} \sqrt {1-\sqrt {4+a}}}-\frac {\left (10+3 a-\sqrt {4+a}\right ) \tan ^{-1}\left (\frac {1-x}{\sqrt {1+\sqrt {4+a}}}\right )}{8 (3+a) (4+a)^{3/2} \sqrt {1+\sqrt {4+a}}}-\frac {\operatorname {Subst}\left (\int \frac {1}{4 (4+a)-x^2} \, dx,x,-2 \left (1+(-1+x)^2\right )\right )}{2 (4+a)}\\ &=\frac {1+(-1+x)^2}{4 (4+a) \left (3+a-2 (1-x)^2-(1-x)^4\right )}+\frac {\left (5+a+(-1+x)^2\right ) (-1+x)}{4 \left (12+7 a+a^2\right ) \left (3+a-2 (-1+x)^2-(-1+x)^4\right )}+\frac {\left (10+3 a+\sqrt {4+a}\right ) \tan ^{-1}\left (\frac {1-x}{\sqrt {1-\sqrt {4+a}}}\right )}{8 (3+a) (4+a)^{3/2} \sqrt {1-\sqrt {4+a}}}-\frac {\left (10+3 a-\sqrt {4+a}\right ) \tan ^{-1}\left (\frac {1-x}{\sqrt {1+\sqrt {4+a}}}\right )}{8 (3+a) (4+a)^{3/2} \sqrt {1+\sqrt {4+a}}}+\frac {\tanh ^{-1}\left (\frac {1+(-1+x)^2}{\sqrt {4+a}}\right )}{4 (4+a)^{3/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] time = 0.07, size = 166, normalized size = 0.72 \[ \frac {a x^2-a x+a+x^3+2 x}{4 (a+3) (a+4) \left (a-x \left (x^3-4 x^2+8 x-8\right )\right )}-\frac {\text {RootSum}\left [-\text {$\#$1}^4+4 \text {$\#$1}^3-8 \text {$\#$1}^2+8 \text {$\#$1}+a\& ,\frac {\text {$\#$1}^2 \log (x-\text {$\#$1})+2 \text {$\#$1} a \log (x-\text {$\#$1})+a \log (x-\text {$\#$1})+4 \text {$\#$1} \log (x-\text {$\#$1})+6 \log (x-\text {$\#$1})}{\text {$\#$1}^3-3 \text {$\#$1}^2+4 \text {$\#$1}-2}\& \right ]}{16 \left (a^2+7 a+12\right )} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {x}{{\left (x^{4} - 4 \, x^{3} + 8 \, x^{2} - a - 8 \, x\right )}^{2}}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [C] time = 0.01, size = 162, normalized size = 0.70 \[ \frac {\left (-\RootOf \left (\textit {\_Z}^{4}-4 \textit {\_Z}^{3}+8 \textit {\_Z}^{2}-8 \textit {\_Z} -a \right )^{2}+2 \left (-a -2\right ) \RootOf \left (\textit {\_Z}^{4}-4 \textit {\_Z}^{3}+8 \textit {\_Z}^{2}-8 \textit {\_Z} -a \right )-a -6\right ) \ln \left (-\RootOf \left (\textit {\_Z}^{4}-4 \textit {\_Z}^{3}+8 \textit {\_Z}^{2}-8 \textit {\_Z} -a \right )+x \right )}{16 \left (a^{2}+7 a +12\right ) \left (\RootOf \left (\textit {\_Z}^{4}-4 \textit {\_Z}^{3}+8 \textit {\_Z}^{2}-8 \textit {\_Z} -a \right )^{3}-3 \RootOf \left (\textit {\_Z}^{4}-4 \textit {\_Z}^{3}+8 \textit {\_Z}^{2}-8 \textit {\_Z} -a \right )^{2}+4 \RootOf \left (\textit {\_Z}^{4}-4 \textit {\_Z}^{3}+8 \textit {\_Z}^{2}-8 \textit {\_Z} -a \right )-2\right )}+\frac {-\frac {a \,x^{2}}{4 \left (a^{2}+7 a +12\right )}-\frac {x^{3}}{4 \left (a^{2}+7 a +12\right )}-\frac {a}{4 \left (a^{2}+7 a +12\right )}+\frac {\left (a -2\right ) x}{4 a^{2}+28 a +48}}{x^{4}-4 x^{3}+8 x^{2}-a -8 x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F] time = 0.00, size = 0, normalized size = 0.00 \[ -\frac {a x^{2} + x^{3} - {\left (a - 2\right )} x + a}{4 \, {\left ({\left (a^{2} + 7 \, a + 12\right )} x^{4} - 4 \, {\left (a^{2} + 7 \, a + 12\right )} x^{3} - a^{3} + 8 \, {\left (a^{2} + 7 \, a + 12\right )} x^{2} - 7 \, a^{2} - 8 \, {\left (a^{2} + 7 \, a + 12\right )} x - 12 \, a\right )}} - \frac {\int \frac {2 \, {\left (a + 2\right )} x + x^{2} + a + 6}{x^{4} - 4 \, x^{3} + 8 \, x^{2} - a - 8 \, x}\,{d x}}{4 \, {\left (a^{2} + 7 \, a + 12\right )}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 2.82, size = 1167, normalized size = 5.05 \[ \text {result too large to display} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [B] time = 31.42, size = 539, normalized size = 2.33 \[ \frac {- a x^{2} - a - x^{3} + x \left (a - 2\right )}{- 4 a^{3} - 28 a^{2} - 48 a + x^{4} \left (4 a^{2} + 28 a + 48\right ) + x^{3} \left (- 16 a^{2} - 112 a - 192\right ) + x^{2} \left (32 a^{2} + 224 a + 384\right ) + x \left (- 32 a^{2} - 224 a - 384\right )} + \operatorname {RootSum} {\left (t^{4} \left (65536 a^{9} + 2162688 a^{8} + 31653888 a^{7} + 269680640 a^{6} + 1473773568 a^{5} + 5357174784 a^{4} + 12952010752 a^{3} + 20082327552 a^{2} + 18119393280 a + 7247757312\right ) + t^{2} \left (- 2048 a^{6} - 50688 a^{5} - 520704 a^{4} - 2842624 a^{3} - 8699904 a^{2} - 14155776 a - 9568256\right ) + t \left (1152 a^{4} + 17792 a^{3} + 102912 a^{2} + 264192 a + 253952\right ) + 16 a^{3} - 57 a^{2} - 984 a - 2064, \left (t \mapsto t \log {\left (x + \frac {98304 t^{3} a^{12} + 3948544 t^{3} a^{11} + 72196096 t^{3} a^{10} + 793837568 t^{3} a^{9} + 5839372288 t^{3} a^{8} + 30226464768 t^{3} a^{7} + 112668450816 t^{3} a^{6} + 303864643584 t^{3} a^{5} + 586157391872 t^{3} a^{4} + 784017129472 t^{3} a^{3} + 683648483328 t^{3} a^{2} + 343136010240 t^{3} a + 72477573120 t^{3} + 30208 t^{2} a^{10} + 986624 t^{2} a^{9} + 14420992 t^{2} a^{8} + 124156928 t^{2} a^{7} + 696815104 t^{2} a^{6} + 2661758464 t^{2} a^{5} + 7001485312 t^{2} a^{4} + 12506562560 t^{2} a^{3} + 14494924800 t^{2} a^{2} + 9820569600 t^{2} a + 2944401408 t^{2} - 1536 t a^{9} - 52048 t a^{8} - 757040 t a^{7} - 6200656 t a^{6} - 31380496 t a^{5} - 100736416 t a^{4} - 200813696 t a^{3} - 228144640 t a^{2} - 114632704 t a - 2490368 t + 248 a^{7} + 6797 a^{6} + 71132 a^{5} + 369745 a^{4} + 987758 a^{3} + 1128896 a^{2} - 129568 a - 956416}{576 a^{7} + 10985 a^{6} + 88746 a^{5} + 396609 a^{4} + 1076268 a^{3} + 1826304 a^{2} + 1867776 a + 917504} \right )} \right )\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________