Integrand size = 167, antiderivative size = 37 \[ \int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \left (-a d+(b d m+a e n) x+(c d+b e+a f+2 c d m+b e m+b e n+2 a f n) x^2+(2 c e+2 b f+2 a g+2 c e m+b f m+c e n+2 b f n+3 a g n) x^3+(3 c f+3 b g+2 c f m+b g m+2 c f n+3 b g n) x^4+c g (4+2 m+3 n) x^5\right )}{x^2} \, dx=\frac {\left (a+b x+c x^2\right )^{1+m} \left (d+e x+f x^2+g x^3\right )^{1+n}}{x} \]
[Out]
\[ \int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \left (-a d+(b d m+a e n) x+(c d+b e+a f+2 c d m+b e m+b e n+2 a f n) x^2+(2 c e+2 b f+2 a g+2 c e m+b f m+c e n+2 b f n+3 a g n) x^3+(3 c f+3 b g+2 c f m+b g m+2 c f n+3 b g n) x^4+c g (4+2 m+3 n) x^5\right )}{x^2} \, dx=\int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \left (-a d+(b d m+a e n) x+(c d+b e+a f+2 c d m+b e m+b e n+2 a f n) x^2+(2 c e+2 b f+2 a g+2 c e m+b f m+c e n+2 b f n+3 a g n) x^3+(3 c f+3 b g+2 c f m+b g m+2 c f n+3 b g n) x^4+c g (4+2 m+3 n) x^5\right )}{x^2} \, dx \]
[In]
[Out]
Rubi steps \begin{align*} \text {integral}& = \int \left (c d \left (1+\frac {2 c d m+b e (1+m+n)+a (f+2 f n)}{c d}\right ) \left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n-\frac {a d \left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n}{x^2}+\frac {(b d m+a e n) \left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n}{x}+(c e (2+2 m+n)+b f (2+m+2 n)+a g (2+3 n)) x \left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n+(c f (3+2 m+2 n)+b g (3+m+3 n)) x^2 \left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n+c g (4+2 m+3 n) x^3 \left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n\right ) \, dx \\ & = -\left ((a d) \int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n}{x^2} \, dx\right )+(c g (4+2 m+3 n)) \int x^3 \left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \, dx+(b d m+a e n) \int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n}{x} \, dx+(c (d+2 d m)+b e (1+m+n)+a f (1+2 n)) \int \left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \, dx+(c e (2+2 m+n)+b f (2+m+2 n)+a g (2+3 n)) \int x \left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \, dx+(c f (3+2 m+2 n)+b g (3+m+3 n)) \int x^2 \left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \, dx \\ \end{align*}
Time = 8.77 (sec) , antiderivative size = 34, normalized size of antiderivative = 0.92 \[ \int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \left (-a d+(b d m+a e n) x+(c d+b e+a f+2 c d m+b e m+b e n+2 a f n) x^2+(2 c e+2 b f+2 a g+2 c e m+b f m+c e n+2 b f n+3 a g n) x^3+(3 c f+3 b g+2 c f m+b g m+2 c f n+3 b g n) x^4+c g (4+2 m+3 n) x^5\right )}{x^2} \, dx=\frac {(a+x (b+c x))^{1+m} (d+x (e+x (f+g x)))^{1+n}}{x} \]
[In]
[Out]
Time = 84.55 (sec) , antiderivative size = 38, normalized size of antiderivative = 1.03
method | result | size |
gosper | \(\frac {\left (c \,x^{2}+b x +a \right )^{1+m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{1+n}}{x}\) | \(38\) |
risch | \(\frac {\left (c g \,x^{5}+b g \,x^{4}+c f \,x^{4}+a g \,x^{3}+b f \,x^{3}+c \,x^{3} e +a f \,x^{2}+e \,x^{2} b +x^{2} c d +a e x +b d x +a d \right ) \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n}}{x}\) | \(100\) |
parallelrisch | \(\frac {x^{5} \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} c^{2} g^{2}+x^{4} \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} b c \,g^{2}+x^{4} \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} c^{2} f g +x^{3} \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} a c \,g^{2}+x^{3} \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} b c f g +x^{3} \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} c^{2} e g +x^{2} \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} a c f g +x^{2} \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} b c e g +x^{2} \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} c^{2} d g +x \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} a c e g +x \left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} b c d g +\left (c \,x^{2}+b x +a \right )^{m} \left (g \,x^{3}+f \,x^{2}+e x +d \right )^{n} a c d g}{x g c}\) | \(456\) |
[In]
[Out]
Timed out. \[ \int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \left (-a d+(b d m+a e n) x+(c d+b e+a f+2 c d m+b e m+b e n+2 a f n) x^2+(2 c e+2 b f+2 a g+2 c e m+b f m+c e n+2 b f n+3 a g n) x^3+(3 c f+3 b g+2 c f m+b g m+2 c f n+3 b g n) x^4+c g (4+2 m+3 n) x^5\right )}{x^2} \, dx=\text {Timed out} \]
[In]
[Out]
Timed out. \[ \int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \left (-a d+(b d m+a e n) x+(c d+b e+a f+2 c d m+b e m+b e n+2 a f n) x^2+(2 c e+2 b f+2 a g+2 c e m+b f m+c e n+2 b f n+3 a g n) x^3+(3 c f+3 b g+2 c f m+b g m+2 c f n+3 b g n) x^4+c g (4+2 m+3 n) x^5\right )}{x^2} \, dx=\text {Timed out} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 95 vs. \(2 (37) = 74\).
Time = 0.28 (sec) , antiderivative size = 95, normalized size of antiderivative = 2.57 \[ \int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \left (-a d+(b d m+a e n) x+(c d+b e+a f+2 c d m+b e m+b e n+2 a f n) x^2+(2 c e+2 b f+2 a g+2 c e m+b f m+c e n+2 b f n+3 a g n) x^3+(3 c f+3 b g+2 c f m+b g m+2 c f n+3 b g n) x^4+c g (4+2 m+3 n) x^5\right )}{x^2} \, dx=\frac {{\left (c g x^{5} + {\left (c f + b g\right )} x^{4} + {\left (c e + b f + a g\right )} x^{3} + {\left (c d + b e + a f\right )} x^{2} + a d + {\left (b d + a e\right )} x\right )} e^{\left (n \log \left (g x^{3} + f x^{2} + e x + d\right ) + m \log \left (c x^{2} + b x + a\right )\right )}}{x} \]
[In]
[Out]
Timed out. \[ \int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \left (-a d+(b d m+a e n) x+(c d+b e+a f+2 c d m+b e m+b e n+2 a f n) x^2+(2 c e+2 b f+2 a g+2 c e m+b f m+c e n+2 b f n+3 a g n) x^3+(3 c f+3 b g+2 c f m+b g m+2 c f n+3 b g n) x^4+c g (4+2 m+3 n) x^5\right )}{x^2} \, dx=\text {Timed out} \]
[In]
[Out]
Time = 25.13 (sec) , antiderivative size = 37, normalized size of antiderivative = 1.00 \[ \int \frac {\left (a+b x+c x^2\right )^m \left (d+e x+f x^2+g x^3\right )^n \left (-a d+(b d m+a e n) x+(c d+b e+a f+2 c d m+b e m+b e n+2 a f n) x^2+(2 c e+2 b f+2 a g+2 c e m+b f m+c e n+2 b f n+3 a g n) x^3+(3 c f+3 b g+2 c f m+b g m+2 c f n+3 b g n) x^4+c g (4+2 m+3 n) x^5\right )}{x^2} \, dx=\frac {{\left (c\,x^2+b\,x+a\right )}^{m+1}\,{\left (g\,x^3+f\,x^2+e\,x+d\right )}^{n+1}}{x} \]
[In]
[Out]