Optimal. Leaf size=207 \[ -\frac {\left (b^4-4 a b^2 c+2 a^2 c^2\right ) n x}{5 c^4}+\frac {b \left (b^2-3 a c\right ) n x^2}{10 c^3}-\frac {\left (b^2-2 a c\right ) n x^3}{15 c^2}+\frac {b n x^4}{20 c}-\frac {2 n x^5}{25}+\frac {\sqrt {b^2-4 a c} \left (b^4-3 a b^2 c+a^2 c^2\right ) n \tanh ^{-1}\left (\frac {b+2 c x}{\sqrt {b^2-4 a c}}\right )}{5 c^5}+\frac {b \left (b^4-5 a b^2 c+5 a^2 c^2\right ) n \log \left (a+b x+c x^2\right )}{10 c^5}+\frac {1}{5} x^5 \log \left (d \left (a+b x+c x^2\right )^n\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.14, antiderivative size = 207, normalized size of antiderivative = 1.00, number of steps
used = 7, number of rules used = 6, integrand size = 19, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.316, Rules used = {2605, 814, 648,
632, 212, 642} \begin {gather*} \frac {b n \left (5 a^2 c^2-5 a b^2 c+b^4\right ) \log \left (a+b x+c x^2\right )}{10 c^5}+\frac {n \sqrt {b^2-4 a c} \left (a^2 c^2-3 a b^2 c+b^4\right ) \tanh ^{-1}\left (\frac {b+2 c x}{\sqrt {b^2-4 a c}}\right )}{5 c^5}-\frac {n x \left (2 a^2 c^2-4 a b^2 c+b^4\right )}{5 c^4}+\frac {b n x^2 \left (b^2-3 a c\right )}{10 c^3}-\frac {n x^3 \left (b^2-2 a c\right )}{15 c^2}+\frac {1}{5} x^5 \log \left (d \left (a+b x+c x^2\right )^n\right )+\frac {b n x^4}{20 c}-\frac {2 n x^5}{25} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 212
Rule 632
Rule 642
Rule 648
Rule 814
Rule 2605
Rubi steps
\begin {align*} \int x^4 \log \left (d \left (a+b x+c x^2\right )^n\right ) \, dx &=\frac {1}{5} x^5 \log \left (d \left (a+b x+c x^2\right )^n\right )-\frac {1}{5} n \int \frac {x^5 (b+2 c x)}{a+b x+c x^2} \, dx\\ &=\frac {1}{5} x^5 \log \left (d \left (a+b x+c x^2\right )^n\right )-\frac {1}{5} n \int \left (\frac {b^4-4 a b^2 c+2 a^2 c^2}{c^4}-\frac {b \left (b^2-3 a c\right ) x}{c^3}+\frac {\left (b^2-2 a c\right ) x^2}{c^2}-\frac {b x^3}{c}+2 x^4-\frac {a \left (b^4-4 a b^2 c+2 a^2 c^2\right )+b \left (b^4-5 a b^2 c+5 a^2 c^2\right ) x}{c^4 \left (a+b x+c x^2\right )}\right ) \, dx\\ &=-\frac {\left (b^4-4 a b^2 c+2 a^2 c^2\right ) n x}{5 c^4}+\frac {b \left (b^2-3 a c\right ) n x^2}{10 c^3}-\frac {\left (b^2-2 a c\right ) n x^3}{15 c^2}+\frac {b n x^4}{20 c}-\frac {2 n x^5}{25}+\frac {1}{5} x^5 \log \left (d \left (a+b x+c x^2\right )^n\right )+\frac {n \int \frac {a \left (b^4-4 a b^2 c+2 a^2 c^2\right )+b \left (b^4-5 a b^2 c+5 a^2 c^2\right ) x}{a+b x+c x^2} \, dx}{5 c^4}\\ &=-\frac {\left (b^4-4 a b^2 c+2 a^2 c^2\right ) n x}{5 c^4}+\frac {b \left (b^2-3 a c\right ) n x^2}{10 c^3}-\frac {\left (b^2-2 a c\right ) n x^3}{15 c^2}+\frac {b n x^4}{20 c}-\frac {2 n x^5}{25}+\frac {1}{5} x^5 \log \left (d \left (a+b x+c x^2\right )^n\right )-\frac {\left (\left (b^2-4 a c\right ) \left (b^4-3 a b^2 c+a^2 c^2\right ) n\right ) \int \frac {1}{a+b x+c x^2} \, dx}{10 c^5}+\frac {\left (b \left (b^4-5 a b^2 c+5 a^2 c^2\right ) n\right ) \int \frac {b+2 c x}{a+b x+c x^2} \, dx}{10 c^5}\\ &=-\frac {\left (b^4-4 a b^2 c+2 a^2 c^2\right ) n x}{5 c^4}+\frac {b \left (b^2-3 a c\right ) n x^2}{10 c^3}-\frac {\left (b^2-2 a c\right ) n x^3}{15 c^2}+\frac {b n x^4}{20 c}-\frac {2 n x^5}{25}+\frac {b \left (b^4-5 a b^2 c+5 a^2 c^2\right ) n \log \left (a+b x+c x^2\right )}{10 c^5}+\frac {1}{5} x^5 \log \left (d \left (a+b x+c x^2\right )^n\right )+\frac {\left (\left (b^2-4 a c\right ) \left (b^4-3 a b^2 c+a^2 c^2\right ) n\right ) \text {Subst}\left (\int \frac {1}{b^2-4 a c-x^2} \, dx,x,b+2 c x\right )}{5 c^5}\\ &=-\frac {\left (b^4-4 a b^2 c+2 a^2 c^2\right ) n x}{5 c^4}+\frac {b \left (b^2-3 a c\right ) n x^2}{10 c^3}-\frac {\left (b^2-2 a c\right ) n x^3}{15 c^2}+\frac {b n x^4}{20 c}-\frac {2 n x^5}{25}+\frac {\sqrt {b^2-4 a c} \left (b^4-3 a b^2 c+a^2 c^2\right ) n \tanh ^{-1}\left (\frac {b+2 c x}{\sqrt {b^2-4 a c}}\right )}{5 c^5}+\frac {b \left (b^4-5 a b^2 c+5 a^2 c^2\right ) n \log \left (a+b x+c x^2\right )}{10 c^5}+\frac {1}{5} x^5 \log \left (d \left (a+b x+c x^2\right )^n\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.15, size = 190, normalized size = 0.92 \begin {gather*} \frac {c n x \left (-60 b^4+30 b^3 c x-20 b^2 c \left (-12 a+c x^2\right )+15 b c^2 x \left (-6 a+c x^2\right )-8 c^2 \left (15 a^2-5 a c x^2+3 c^2 x^4\right )\right )+60 \sqrt {b^2-4 a c} \left (b^4-3 a b^2 c+a^2 c^2\right ) n \tanh ^{-1}\left (\frac {b+2 c x}{\sqrt {b^2-4 a c}}\right )+30 b \left (b^4-5 a b^2 c+5 a^2 c^2\right ) n \log (a+x (b+c x))+60 c^5 x^5 \log \left (d (a+x (b+c x))^n\right )}{300 c^5} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] Result contains higher order function than in optimal. Order 9 vs. order
3.
time = 0.10, size = 1621, normalized size = 7.83
method | result | size |
risch | \(\text {Expression too large to display}\) | \(1621\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: ValueError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.37, size = 444, normalized size = 2.14 \begin {gather*} \left [-\frac {24 \, c^{5} n x^{5} - 60 \, c^{5} x^{5} \log \left (d\right ) - 15 \, b c^{4} n x^{4} + 20 \, {\left (b^{2} c^{3} - 2 \, a c^{4}\right )} n x^{3} - 30 \, {\left (b^{3} c^{2} - 3 \, a b c^{3}\right )} n x^{2} - 30 \, {\left (b^{4} - 3 \, a b^{2} c + a^{2} c^{2}\right )} \sqrt {b^{2} - 4 \, a c} n \log \left (\frac {2 \, c^{2} x^{2} + 2 \, b c x + b^{2} - 2 \, a c + \sqrt {b^{2} - 4 \, a c} {\left (2 \, c x + b\right )}}{c x^{2} + b x + a}\right ) + 60 \, {\left (b^{4} c - 4 \, a b^{2} c^{2} + 2 \, a^{2} c^{3}\right )} n x - 30 \, {\left (2 \, c^{5} n x^{5} + {\left (b^{5} - 5 \, a b^{3} c + 5 \, a^{2} b c^{2}\right )} n\right )} \log \left (c x^{2} + b x + a\right )}{300 \, c^{5}}, -\frac {24 \, c^{5} n x^{5} - 60 \, c^{5} x^{5} \log \left (d\right ) - 15 \, b c^{4} n x^{4} + 20 \, {\left (b^{2} c^{3} - 2 \, a c^{4}\right )} n x^{3} - 30 \, {\left (b^{3} c^{2} - 3 \, a b c^{3}\right )} n x^{2} - 60 \, {\left (b^{4} - 3 \, a b^{2} c + a^{2} c^{2}\right )} \sqrt {-b^{2} + 4 \, a c} n \arctan \left (-\frac {\sqrt {-b^{2} + 4 \, a c} {\left (2 \, c x + b\right )}}{b^{2} - 4 \, a c}\right ) + 60 \, {\left (b^{4} c - 4 \, a b^{2} c^{2} + 2 \, a^{2} c^{3}\right )} n x - 30 \, {\left (2 \, c^{5} n x^{5} + {\left (b^{5} - 5 \, a b^{3} c + 5 \, a^{2} b c^{2}\right )} n\right )} \log \left (c x^{2} + b x + a\right )}{300 \, c^{5}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 3.75, size = 221, normalized size = 1.07 \begin {gather*} \frac {1}{5} \, n x^{5} \log \left (c x^{2} + b x + a\right ) - \frac {1}{25} \, {\left (2 \, n - 5 \, \log \left (d\right )\right )} x^{5} + \frac {b n x^{4}}{20 \, c} - \frac {{\left (b^{2} n - 2 \, a c n\right )} x^{3}}{15 \, c^{2}} + \frac {{\left (b^{3} n - 3 \, a b c n\right )} x^{2}}{10 \, c^{3}} - \frac {{\left (b^{4} n - 4 \, a b^{2} c n + 2 \, a^{2} c^{2} n\right )} x}{5 \, c^{4}} + \frac {{\left (b^{5} n - 5 \, a b^{3} c n + 5 \, a^{2} b c^{2} n\right )} \log \left (c x^{2} + b x + a\right )}{10 \, c^{5}} - \frac {{\left (b^{6} n - 7 \, a b^{4} c n + 13 \, a^{2} b^{2} c^{2} n - 4 \, a^{3} c^{3} n\right )} \arctan \left (\frac {2 \, c x + b}{\sqrt {-b^{2} + 4 \, a c}}\right )}{5 \, \sqrt {-b^{2} + 4 \, a c} c^{5}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.59, size = 395, normalized size = 1.91 \begin {gather*} x^2\,\left (\frac {b\,\left (\frac {b^2\,n}{5\,c^2}-\frac {2\,a\,n}{5\,c}\right )}{2\,c}-\frac {a\,b\,n}{10\,c^2}\right )-\frac {2\,n\,x^5}{25}+x\,\left (\frac {a\,\left (\frac {b^2\,n}{5\,c^2}-\frac {2\,a\,n}{5\,c}\right )}{c}-\frac {b\,\left (\frac {b\,\left (\frac {b^2\,n}{5\,c^2}-\frac {2\,a\,n}{5\,c}\right )}{c}-\frac {a\,b\,n}{5\,c^2}\right )}{c}\right )+\frac {x^5\,\ln \left (d\,{\left (c\,x^2+b\,x+a\right )}^n\right )}{5}-x^3\,\left (\frac {b^2\,n}{15\,c^2}-\frac {2\,a\,n}{15\,c}\right )+\frac {\ln \left (b\,\sqrt {b^2-4\,a\,c}-4\,a\,c+b^2+2\,c\,x\,\sqrt {b^2-4\,a\,c}\right )\,\left (\frac {b^5\,n}{10}+c^2\,\left (\frac {a^2\,n\,\sqrt {b^2-4\,a\,c}}{10}+\frac {a^2\,b\,n}{2}\right )-c\,\left (\frac {a\,b^3\,n}{2}+\frac {3\,a\,b^2\,n\,\sqrt {b^2-4\,a\,c}}{10}\right )+\frac {b^4\,n\,\sqrt {b^2-4\,a\,c}}{10}\right )}{c^5}-\frac {\ln \left (4\,a\,c+b\,\sqrt {b^2-4\,a\,c}-b^2+2\,c\,x\,\sqrt {b^2-4\,a\,c}\right )\,\left (c^2\,\left (\frac {a^2\,n\,\sqrt {b^2-4\,a\,c}}{10}-\frac {a^2\,b\,n}{2}\right )-\frac {b^5\,n}{10}+c\,\left (\frac {a\,b^3\,n}{2}-\frac {3\,a\,b^2\,n\,\sqrt {b^2-4\,a\,c}}{10}\right )+\frac {b^4\,n\,\sqrt {b^2-4\,a\,c}}{10}\right )}{c^5}+\frac {b\,n\,x^4}{20\,c} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________