Integrand size = 45, antiderivative size = 34 \[ \int \left (a+b x+c x^2\right )^p \left (d \left (2 b^2-2 a c+b^2 p\right )-2 c^2 d (3+2 p) x^2\right ) \, dx=\frac {d (b (2+p)-2 c (1+p) x) \left (a+b x+c x^2\right )^{1+p}}{1+p} \] Output:
d*(b*(2+p)-2*c*(p+1)*x)*(c*x^2+b*x+a)^(p+1)/(p+1)
Time = 0.58 (sec) , antiderivative size = 33, normalized size of antiderivative = 0.97 \[ \int \left (a+b x+c x^2\right )^p \left (d \left (2 b^2-2 a c+b^2 p\right )-2 c^2 d (3+2 p) x^2\right ) \, dx=\frac {d (b (2+p)-2 c (1+p) x) (a+x (b+c x))^{1+p}}{1+p} \] Input:
Integrate[(a + b*x + c*x^2)^p*(d*(2*b^2 - 2*a*c + b^2*p) - 2*c^2*d*(3 + 2* p)*x^2),x]
Output:
(d*(b*(2 + p) - 2*c*(1 + p)*x)*(a + x*(b + c*x))^(1 + p))/(1 + p)
Time = 0.23 (sec) , antiderivative size = 45, normalized size of antiderivative = 1.32, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.067, Rules used = {2192, 27, 1104}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \left (a+b x+c x^2\right )^p \left (d \left (-2 a c+b^2 p+2 b^2\right )-2 c^2 d (2 p+3) x^2\right ) \, dx\) |
\(\Big \downarrow \) 2192 |
\(\displaystyle \frac {\int b c d (p+2) (2 p+3) (b+2 c x) \left (c x^2+b x+a\right )^pdx}{c (2 p+3)}-2 c d x \left (a+b x+c x^2\right )^{p+1}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle b d (p+2) \int (b+2 c x) \left (c x^2+b x+a\right )^pdx-2 c d x \left (a+b x+c x^2\right )^{p+1}\) |
\(\Big \downarrow \) 1104 |
\(\displaystyle \frac {b d (p+2) \left (a+b x+c x^2\right )^{p+1}}{p+1}-2 c d x \left (a+b x+c x^2\right )^{p+1}\) |
Input:
Int[(a + b*x + c*x^2)^p*(d*(2*b^2 - 2*a*c + b^2*p) - 2*c^2*d*(3 + 2*p)*x^2 ),x]
Output:
(b*d*(2 + p)*(a + b*x + c*x^2)^(1 + p))/(1 + p) - 2*c*d*x*(a + b*x + c*x^2 )^(1 + p)
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[((d_) + (e_.)*(x_))*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol ] :> Simp[d*((a + b*x + c*x^2)^(p + 1)/(b*(p + 1))), x] /; FreeQ[{a, b, c, d, e, p}, x] && EqQ[2*c*d - b*e, 0]
Int[(Pq_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> With[{q = Expon[Pq, x], e = Coeff[Pq, x, Expon[Pq, x]]}, Simp[e*x^(q - 1)*((a + b*x + c*x^2)^(p + 1)/(c*(q + 2*p + 1))), x] + Simp[1/(c*(q + 2*p + 1)) Int[(a + b*x + c*x^2)^p*ExpandToSum[c*(q + 2*p + 1)*Pq - a*e*(q - 1)*x^(q - 2) - b *e*(q + p)*x^(q - 1) - c*e*(q + 2*p + 1)*x^q, x], x], x]] /; FreeQ[{a, b, c , p}, x] && PolyQ[Pq, x] && NeQ[b^2 - 4*a*c, 0] && !LeQ[p, -1]
Time = 1.47 (sec) , antiderivative size = 38, normalized size of antiderivative = 1.12
method | result | size |
gosper | \(\frac {d \left (c \,x^{2}+b x +a \right )^{p +1} \left (-2 c p x +b p -2 c x +2 b \right )}{p +1}\) | \(38\) |
risch | \(\frac {d \left (-2 p \,c^{2} x^{3}-b c p \,x^{2}-2 x^{3} c^{2}-2 a c p x +b^{2} p x +a b p -2 a c x +2 b^{2} x +2 a b \right ) \left (c \,x^{2}+b x +a \right )^{p}}{p +1}\) | \(77\) |
orering | \(-\frac {\left (-2 c p x +b p -2 c x +2 b \right ) \left (c \,x^{2}+b x +a \right ) \left (c \,x^{2}+b x +a \right )^{p} \left (d \left (b^{2} p -2 a c +2 b^{2}\right )-2 c^{2} d \left (3+2 p \right ) x^{2}\right )}{\left (p +1\right ) \left (4 c^{2} x^{2} p +6 c^{2} x^{2}-b^{2} p +2 a c -2 b^{2}\right )}\) | \(113\) |
norman | \(\frac {d a b \left (2+p \right ) {\mathrm e}^{p \ln \left (c \,x^{2}+b x +a \right )}}{p +1}-2 c^{2} d \,x^{3} {\mathrm e}^{p \ln \left (c \,x^{2}+b x +a \right )}-\frac {d \left (2 a c p -b^{2} p +2 a c -2 b^{2}\right ) x \,{\mathrm e}^{p \ln \left (c \,x^{2}+b x +a \right )}}{p +1}-\frac {b c d p \,x^{2} {\mathrm e}^{p \ln \left (c \,x^{2}+b x +a \right )}}{p +1}\) | \(123\) |
parallelrisch | \(-\frac {2 x^{3} \left (c \,x^{2}+b x +a \right )^{p} a \,c^{2} d p +2 x^{3} \left (c \,x^{2}+b x +a \right )^{p} a \,c^{2} d +x^{2} \left (c \,x^{2}+b x +a \right )^{p} a b c d p +2 x \left (c \,x^{2}+b x +a \right )^{p} a^{2} c d p -x \left (c \,x^{2}+b x +a \right )^{p} a \,b^{2} d p +2 x \left (c \,x^{2}+b x +a \right )^{p} a^{2} c d -2 x \left (c \,x^{2}+b x +a \right )^{p} a \,b^{2} d -\left (c \,x^{2}+b x +a \right )^{p} a^{2} b d p -2 \left (c \,x^{2}+b x +a \right )^{p} a^{2} b d}{\left (p +1\right ) a}\) | \(199\) |
Input:
int((c*x^2+b*x+a)^p*(d*(b^2*p-2*a*c+2*b^2)-2*c^2*d*(3+2*p)*x^2),x,method=_ RETURNVERBOSE)
Output:
d/(p+1)*(c*x^2+b*x+a)^(p+1)*(-2*c*p*x+b*p-2*c*x+2*b)
Leaf count of result is larger than twice the leaf count of optimal. 82 vs. \(2 (36) = 72\).
Time = 0.09 (sec) , antiderivative size = 82, normalized size of antiderivative = 2.41 \[ \int \left (a+b x+c x^2\right )^p \left (d \left (2 b^2-2 a c+b^2 p\right )-2 c^2 d (3+2 p) x^2\right ) \, dx=-\frac {{\left (b c d p x^{2} - a b d p + 2 \, {\left (c^{2} d p + c^{2} d\right )} x^{3} - 2 \, a b d - {\left ({\left (b^{2} - 2 \, a c\right )} d p + 2 \, {\left (b^{2} - a c\right )} d\right )} x\right )} {\left (c x^{2} + b x + a\right )}^{p}}{p + 1} \] Input:
integrate((c*x^2+b*x+a)^p*(d*(b^2*p-2*a*c+2*b^2)-2*c^2*d*(3+2*p)*x^2),x, a lgorithm="fricas")
Output:
-(b*c*d*p*x^2 - a*b*d*p + 2*(c^2*d*p + c^2*d)*x^3 - 2*a*b*d - ((b^2 - 2*a* c)*d*p + 2*(b^2 - a*c)*d)*x)*(c*x^2 + b*x + a)^p/(p + 1)
Leaf count of result is larger than twice the leaf count of optimal. 280 vs. \(2 (31) = 62\).
Time = 56.59 (sec) , antiderivative size = 280, normalized size of antiderivative = 8.24 \[ \int \left (a+b x+c x^2\right )^p \left (d \left (2 b^2-2 a c+b^2 p\right )-2 c^2 d (3+2 p) x^2\right ) \, dx=\begin {cases} \frac {a b d p \left (a + b x + c x^{2}\right )^{p}}{p + 1} + \frac {2 a b d \left (a + b x + c x^{2}\right )^{p}}{p + 1} - \frac {2 a c d p x \left (a + b x + c x^{2}\right )^{p}}{p + 1} - \frac {2 a c d x \left (a + b x + c x^{2}\right )^{p}}{p + 1} + \frac {b^{2} d p x \left (a + b x + c x^{2}\right )^{p}}{p + 1} + \frac {2 b^{2} d x \left (a + b x + c x^{2}\right )^{p}}{p + 1} - \frac {b c d p x^{2} \left (a + b x + c x^{2}\right )^{p}}{p + 1} - \frac {2 c^{2} d p x^{3} \left (a + b x + c x^{2}\right )^{p}}{p + 1} - \frac {2 c^{2} d x^{3} \left (a + b x + c x^{2}\right )^{p}}{p + 1} & \text {for}\: p \neq -1 \\b d \log {\left (\frac {b}{2 c} + x - \frac {\sqrt {- 4 a c + b^{2}}}{2 c} \right )} + b d \log {\left (\frac {b}{2 c} + x + \frac {\sqrt {- 4 a c + b^{2}}}{2 c} \right )} - 2 c d x & \text {otherwise} \end {cases} \] Input:
integrate((c*x**2+b*x+a)**p*(d*(b**2*p-2*a*c+2*b**2)-2*c**2*d*(3+2*p)*x**2 ),x)
Output:
Piecewise((a*b*d*p*(a + b*x + c*x**2)**p/(p + 1) + 2*a*b*d*(a + b*x + c*x* *2)**p/(p + 1) - 2*a*c*d*p*x*(a + b*x + c*x**2)**p/(p + 1) - 2*a*c*d*x*(a + b*x + c*x**2)**p/(p + 1) + b**2*d*p*x*(a + b*x + c*x**2)**p/(p + 1) + 2* b**2*d*x*(a + b*x + c*x**2)**p/(p + 1) - b*c*d*p*x**2*(a + b*x + c*x**2)** p/(p + 1) - 2*c**2*d*p*x**3*(a + b*x + c*x**2)**p/(p + 1) - 2*c**2*d*x**3* (a + b*x + c*x**2)**p/(p + 1), Ne(p, -1)), (b*d*log(b/(2*c) + x - sqrt(-4* a*c + b**2)/(2*c)) + b*d*log(b/(2*c) + x + sqrt(-4*a*c + b**2)/(2*c)) - 2* c*d*x, True))
Time = 0.07 (sec) , antiderivative size = 68, normalized size of antiderivative = 2.00 \[ \int \left (a+b x+c x^2\right )^p \left (d \left (2 b^2-2 a c+b^2 p\right )-2 c^2 d (3+2 p) x^2\right ) \, dx=-\frac {{\left (2 \, c^{2} d {\left (p + 1\right )} x^{3} + b c d p x^{2} - a b d {\left (p + 2\right )} - {\left (b^{2} d {\left (p + 2\right )} - 2 \, a c d {\left (p + 1\right )}\right )} x\right )} {\left (c x^{2} + b x + a\right )}^{p}}{p + 1} \] Input:
integrate((c*x^2+b*x+a)^p*(d*(b^2*p-2*a*c+2*b^2)-2*c^2*d*(3+2*p)*x^2),x, a lgorithm="maxima")
Output:
-(2*c^2*d*(p + 1)*x^3 + b*c*d*p*x^2 - a*b*d*(p + 2) - (b^2*d*(p + 2) - 2*a *c*d*(p + 1))*x)*(c*x^2 + b*x + a)^p/(p + 1)
Leaf count of result is larger than twice the leaf count of optimal. 182 vs. \(2 (36) = 72\).
Time = 0.15 (sec) , antiderivative size = 182, normalized size of antiderivative = 5.35 \[ \int \left (a+b x+c x^2\right )^p \left (d \left (2 b^2-2 a c+b^2 p\right )-2 c^2 d (3+2 p) x^2\right ) \, dx=-\frac {2 \, {\left (c x^{2} + b x + a\right )}^{p} c^{2} d p x^{3} + {\left (c x^{2} + b x + a\right )}^{p} b c d p x^{2} + 2 \, {\left (c x^{2} + b x + a\right )}^{p} c^{2} d x^{3} - {\left (c x^{2} + b x + a\right )}^{p} b^{2} d p x + 2 \, {\left (c x^{2} + b x + a\right )}^{p} a c d p x - {\left (c x^{2} + b x + a\right )}^{p} a b d p - 2 \, {\left (c x^{2} + b x + a\right )}^{p} b^{2} d x + 2 \, {\left (c x^{2} + b x + a\right )}^{p} a c d x - 2 \, {\left (c x^{2} + b x + a\right )}^{p} a b d}{p + 1} \] Input:
integrate((c*x^2+b*x+a)^p*(d*(b^2*p-2*a*c+2*b^2)-2*c^2*d*(3+2*p)*x^2),x, a lgorithm="giac")
Output:
-(2*(c*x^2 + b*x + a)^p*c^2*d*p*x^3 + (c*x^2 + b*x + a)^p*b*c*d*p*x^2 + 2* (c*x^2 + b*x + a)^p*c^2*d*x^3 - (c*x^2 + b*x + a)^p*b^2*d*p*x + 2*(c*x^2 + b*x + a)^p*a*c*d*p*x - (c*x^2 + b*x + a)^p*a*b*d*p - 2*(c*x^2 + b*x + a)^ p*b^2*d*x + 2*(c*x^2 + b*x + a)^p*a*c*d*x - 2*(c*x^2 + b*x + a)^p*a*b*d)/( p + 1)
Time = 15.98 (sec) , antiderivative size = 79, normalized size of antiderivative = 2.32 \[ \int \left (a+b x+c x^2\right )^p \left (d \left (2 b^2-2 a c+b^2 p\right )-2 c^2 d (3+2 p) x^2\right ) \, dx=-{\left (c\,x^2+b\,x+a\right )}^p\,\left (2\,c^2\,d\,x^3+\frac {d\,x\,\left (2\,a\,c-b^2\,p-2\,b^2+2\,a\,c\,p\right )}{p+1}-\frac {a\,b\,d\,\left (p+2\right )}{p+1}+\frac {b\,c\,d\,p\,x^2}{p+1}\right ) \] Input:
int((d*(b^2*p - 2*a*c + 2*b^2) - 2*c^2*d*x^2*(2*p + 3))*(a + b*x + c*x^2)^ p,x)
Output:
-(a + b*x + c*x^2)^p*(2*c^2*d*x^3 + (d*x*(2*a*c - b^2*p - 2*b^2 + 2*a*c*p) )/(p + 1) - (a*b*d*(p + 2))/(p + 1) + (b*c*d*p*x^2)/(p + 1))
Time = 0.20 (sec) , antiderivative size = 76, normalized size of antiderivative = 2.24 \[ \int \left (a+b x+c x^2\right )^p \left (d \left (2 b^2-2 a c+b^2 p\right )-2 c^2 d (3+2 p) x^2\right ) \, dx=\frac {\left (c \,x^{2}+b x +a \right )^{p} d \left (-2 c^{2} p \,x^{3}-b c p \,x^{2}-2 c^{2} x^{3}-2 a c p x +b^{2} p x +a b p -2 a c x +2 b^{2} x +2 a b \right )}{p +1} \] Input:
int((c*x^2+b*x+a)^p*(d*(b^2*p-2*a*c+2*b^2)-2*c^2*d*(3+2*p)*x^2),x)
Output:
((a + b*x + c*x**2)**p*d*(a*b*p + 2*a*b - 2*a*c*p*x - 2*a*c*x + b**2*p*x + 2*b**2*x - b*c*p*x**2 - 2*c**2*p*x**3 - 2*c**2*x**3))/(p + 1)