\(\int \frac {(d x)^m}{(a+b x^n+c x^{2 n})^2} \, dx\) [244]

Optimal result
Mathematica [B] (warning: unable to verify)
Rubi [A] (verified)
Maple [F]
Fricas [F]
Sympy [F(-1)]
Maxima [F]
Giac [F]
Mupad [F(-1)]
Reduce [F]

Optimal result

Integrand size = 22, antiderivative size = 328 \[ \int \frac {(d x)^m}{\left (a+b x^n+c x^{2 n}\right )^2} \, dx=\frac {(d x)^{1+m} \left (b^2-2 a c+b c x^n\right )}{a \left (b^2-4 a c\right ) d n \left (a+b x^n+c x^{2 n}\right )}+\frac {c \left (4 a c (1+m-2 n)-b^2 (1+m-n)-b \sqrt {b^2-4 a c} (1+m-n)\right ) (d x)^{1+m} \operatorname {Hypergeometric2F1}\left (1,\frac {1+m}{n},\frac {1+m+n}{n},-\frac {2 c x^n}{b-\sqrt {b^2-4 a c}}\right )}{a \left (b^2-4 a c\right )^{3/2} \left (b-\sqrt {b^2-4 a c}\right ) d (1+m) n}-\frac {c \left (4 a c (1+m-2 n)-b^2 (1+m-n)+b \sqrt {b^2-4 a c} (1+m-n)\right ) (d x)^{1+m} \operatorname {Hypergeometric2F1}\left (1,\frac {1+m}{n},\frac {1+m+n}{n},-\frac {2 c x^n}{b+\sqrt {b^2-4 a c}}\right )}{a \left (b^2-4 a c\right )^{3/2} \left (b+\sqrt {b^2-4 a c}\right ) d (1+m) n} \] Output:

(d*x)^(1+m)*(b^2-2*a*c+b*c*x^n)/a/(-4*a*c+b^2)/d/n/(a+b*x^n+c*x^(2*n))+c*( 
4*a*c*(1+m-2*n)-b^2*(1+m-n)-b*(-4*a*c+b^2)^(1/2)*(1+m-n))*(d*x)^(1+m)*hype 
rgeom([1, (1+m)/n],[(1+m+n)/n],-2*c*x^n/(b-(-4*a*c+b^2)^(1/2)))/a/(-4*a*c+ 
b^2)^(3/2)/(b-(-4*a*c+b^2)^(1/2))/d/(1+m)/n-c*(4*a*c*(1+m-2*n)-b^2*(1+m-n) 
+b*(-4*a*c+b^2)^(1/2)*(1+m-n))*(d*x)^(1+m)*hypergeom([1, (1+m)/n],[(1+m+n) 
/n],-2*c*x^n/(b+(-4*a*c+b^2)^(1/2)))/a/(-4*a*c+b^2)^(3/2)/(b+(-4*a*c+b^2)^ 
(1/2))/d/(1+m)/n
 

Mathematica [B] (warning: unable to verify)

Leaf count is larger than twice the leaf count of optimal. \(3515\) vs. \(2(328)=656\).

Time = 6.73 (sec) , antiderivative size = 3515, normalized size of antiderivative = 10.72 \[ \int \frac {(d x)^m}{\left (a+b x^n+c x^{2 n}\right )^2} \, dx=\text {Result too large to show} \] Input:

Integrate[(d*x)^m/(a + b*x^n + c*x^(2*n))^2,x]
 

Output:

(x*(d*x)^m*(-b^2 + 2*a*c - b*c*x^n))/(a*(-b^2 + 4*a*c)*n*(a + b*x^n + c*x^ 
(2*n))) - (b*c*x^(1 + n)*(d*x)^m*(x^n)^((1 + m)/n - (1 + m + n)/n)*(-(((x^ 
n/(-1/2*(-b - Sqrt[b^2 - 4*a*c])/c + x^n))^(-n^(-1) - m/n)*Hypergeometric2 
F1[-((1 + m)/n), -((1 + m)/n), 1 - (1 + m)/n, -1/2*(-b - Sqrt[b^2 - 4*a*c] 
)/(c*(-1/2*(-b - Sqrt[b^2 - 4*a*c])/c + x^n))])/Sqrt[b^2 - 4*a*c]) + ((x^n 
/(-1/2*(-b + Sqrt[b^2 - 4*a*c])/c + x^n))^(-n^(-1) - m/n)*Hypergeometric2F 
1[-((1 + m)/n), -((1 + m)/n), 1 - (1 + m)/n, -1/2*(-b + Sqrt[b^2 - 4*a*c]) 
/(c*(-1/2*(-b + Sqrt[b^2 - 4*a*c])/c + x^n))])/Sqrt[b^2 - 4*a*c]))/(a*(-b^ 
2 + 4*a*c)*(1 + m)) + (b*c*x^(1 + n)*(d*x)^m*(x^n)^((1 + m)/n - (1 + m + n 
)/n)*(-(((x^n/(-1/2*(-b - Sqrt[b^2 - 4*a*c])/c + x^n))^(-n^(-1) - m/n)*Hyp 
ergeometric2F1[-((1 + m)/n), -((1 + m)/n), 1 - (1 + m)/n, -1/2*(-b - Sqrt[ 
b^2 - 4*a*c])/(c*(-1/2*(-b - Sqrt[b^2 - 4*a*c])/c + x^n))])/Sqrt[b^2 - 4*a 
*c]) + ((x^n/(-1/2*(-b + Sqrt[b^2 - 4*a*c])/c + x^n))^(-n^(-1) - m/n)*Hype 
rgeometric2F1[-((1 + m)/n), -((1 + m)/n), 1 - (1 + m)/n, -1/2*(-b + Sqrt[b 
^2 - 4*a*c])/(c*(-1/2*(-b + Sqrt[b^2 - 4*a*c])/c + x^n))])/Sqrt[b^2 - 4*a* 
c]))/(a*(-b^2 + 4*a*c)*(1 + m)*n) + (b*c*m*x^(1 + n)*(d*x)^m*(x^n)^((1 + m 
)/n - (1 + m + n)/n)*(-(((x^n/(-1/2*(-b - Sqrt[b^2 - 4*a*c])/c + x^n))^(-n 
^(-1) - m/n)*Hypergeometric2F1[-((1 + m)/n), -((1 + m)/n), 1 - (1 + m)/n, 
-1/2*(-b - Sqrt[b^2 - 4*a*c])/(c*(-1/2*(-b - Sqrt[b^2 - 4*a*c])/c + x^n))] 
)/Sqrt[b^2 - 4*a*c]) + ((x^n/(-1/2*(-b + Sqrt[b^2 - 4*a*c])/c + x^n))^(...
 

Rubi [A] (verified)

Time = 0.74 (sec) , antiderivative size = 314, normalized size of antiderivative = 0.96, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.182, Rules used = {1720, 25, 1884, 2009}

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 \frac {(d x)^m}{\left (a+b x^n+c x^{2 n}\right )^2} \, dx\)

\(\Big \downarrow \) 1720

\(\displaystyle \frac {(d x)^{m+1} \left (-2 a c+b^2+b c x^n\right )}{a d n \left (b^2-4 a c\right ) \left (a+b x^n+c x^{2 n}\right )}-\frac {\int -\frac {(d x)^m \left (-b c (m-n+1) x^n+2 a c (m-2 n+1)-b^2 (m-n+1)\right )}{b x^n+c x^{2 n}+a}dx}{a n \left (b^2-4 a c\right )}\)

\(\Big \downarrow \) 25

\(\displaystyle \frac {\int \frac {(d x)^m \left (-b c (m-n+1) x^n+2 a c (m-2 n+1)-b^2 (m-n+1)\right )}{b x^n+c x^{2 n}+a}dx}{a n \left (b^2-4 a c\right )}+\frac {(d x)^{m+1} \left (-2 a c+b^2+b c x^n\right )}{a d n \left (b^2-4 a c\right ) \left (a+b x^n+c x^{2 n}\right )}\)

\(\Big \downarrow \) 1884

\(\displaystyle \frac {\int \left (\frac {\left (-b c (m-n+1)-\frac {c \left (m b^2-n b^2+b^2-4 a c-4 a c m+8 a c n\right )}{\sqrt {b^2-4 a c}}\right ) (d x)^m}{2 c x^n+b-\sqrt {b^2-4 a c}}+\frac {\left (\frac {c \left (m b^2-n b^2+b^2-4 a c-4 a c m+8 a c n\right )}{\sqrt {b^2-4 a c}}-b c (m-n+1)\right ) (d x)^m}{2 c x^n+b+\sqrt {b^2-4 a c}}\right )dx}{a n \left (b^2-4 a c\right )}+\frac {(d x)^{m+1} \left (-2 a c+b^2+b c x^n\right )}{a d n \left (b^2-4 a c\right ) \left (a+b x^n+c x^{2 n}\right )}\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {\frac {c (d x)^{m+1} \left (\frac {4 a c (m-2 n+1)-b^2 (m-n+1)}{\sqrt {b^2-4 a c}}-b (m-n+1)\right ) \operatorname {Hypergeometric2F1}\left (1,\frac {m+1}{n},\frac {m+n+1}{n},-\frac {2 c x^n}{b-\sqrt {b^2-4 a c}}\right )}{d (m+1) \left (b-\sqrt {b^2-4 a c}\right )}-\frac {c (d x)^{m+1} \left (\frac {4 a c (m-2 n+1)-b^2 (m-n+1)}{\sqrt {b^2-4 a c}}+b (m-n+1)\right ) \operatorname {Hypergeometric2F1}\left (1,\frac {m+1}{n},\frac {m+n+1}{n},-\frac {2 c x^n}{b+\sqrt {b^2-4 a c}}\right )}{d (m+1) \left (\sqrt {b^2-4 a c}+b\right )}}{a n \left (b^2-4 a c\right )}+\frac {(d x)^{m+1} \left (-2 a c+b^2+b c x^n\right )}{a d n \left (b^2-4 a c\right ) \left (a+b x^n+c x^{2 n}\right )}\)

Input:

Int[(d*x)^m/(a + b*x^n + c*x^(2*n))^2,x]
 

Output:

((d*x)^(1 + m)*(b^2 - 2*a*c + b*c*x^n))/(a*(b^2 - 4*a*c)*d*n*(a + b*x^n + 
c*x^(2*n))) + ((c*((4*a*c*(1 + m - 2*n) - b^2*(1 + m - n))/Sqrt[b^2 - 4*a* 
c] - b*(1 + m - n))*(d*x)^(1 + m)*Hypergeometric2F1[1, (1 + m)/n, (1 + m + 
 n)/n, (-2*c*x^n)/(b - Sqrt[b^2 - 4*a*c])])/((b - Sqrt[b^2 - 4*a*c])*d*(1 
+ m)) - (c*((4*a*c*(1 + m - 2*n) - b^2*(1 + m - n))/Sqrt[b^2 - 4*a*c] + b* 
(1 + m - n))*(d*x)^(1 + m)*Hypergeometric2F1[1, (1 + m)/n, (1 + m + n)/n, 
(-2*c*x^n)/(b + Sqrt[b^2 - 4*a*c])])/((b + Sqrt[b^2 - 4*a*c])*d*(1 + m)))/ 
(a*(b^2 - 4*a*c)*n)
 

Defintions of rubi rules used

rule 25
Int[-(Fx_), x_Symbol] :> Simp[Identity[-1]   Int[Fx, x], x]
 

rule 1720
Int[((d_.)*(x_))^(m_.)*((a_) + (c_.)*(x_)^(n2_.) + (b_.)*(x_)^(n_))^(p_), x 
_Symbol] :> Simp[(-(d*x)^(m + 1))*(b^2 - 2*a*c + b*c*x^n)*((a + b*x^n + c*x 
^(2*n))^(p + 1)/(a*d*n*(p + 1)*(b^2 - 4*a*c))), x] + Simp[1/(a*n*(p + 1)*(b 
^2 - 4*a*c))   Int[(d*x)^m*(a + b*x^n + c*x^(2*n))^(p + 1)*Simp[b^2*(n*(p + 
 1) + m + 1) - 2*a*c*(m + 2*n*(p + 1) + 1) + b*c*(2*n*p + 3*n + m + 1)*x^n, 
 x], x], x] /; FreeQ[{a, b, c, d, m, n}, x] && EqQ[n2, 2*n] && NeQ[b^2 - 4* 
a*c, 0] && ILtQ[p + 1, 0]
 

rule 1884
Int[((f_.)*(x_))^(m_.)*((a_) + (c_.)*(x_)^(n2_.) + (b_.)*(x_)^(n_))^(p_.)*( 
(d_) + (e_.)*(x_)^(n_))^(q_.), x_Symbol] :> Int[ExpandIntegrand[(f*x)^m*(d 
+ e*x^n)^q*(a + b*x^n + c*x^(2*n))^p, x], x] /; FreeQ[{a, b, c, d, e, f, m, 
 n, p, q}, x] && EqQ[n2, 2*n] && NeQ[b^2 - 4*a*c, 0] &&  !RationalQ[n] && ( 
IGtQ[p, 0] || IGtQ[q, 0])
 

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 
Maple [F]

\[\int \frac {\left (d x \right )^{m}}{\left (a +b \,x^{n}+c \,x^{2 n}\right )^{2}}d x\]

Input:

int((d*x)^m/(a+b*x^n+c*x^(2*n))^2,x)
 

Output:

int((d*x)^m/(a+b*x^n+c*x^(2*n))^2,x)
 

Fricas [F]

\[ \int \frac {(d x)^m}{\left (a+b x^n+c x^{2 n}\right )^2} \, dx=\int { \frac {\left (d x\right )^{m}}{{\left (c x^{2 \, n} + b x^{n} + a\right )}^{2}} \,d x } \] Input:

integrate((d*x)^m/(a+b*x^n+c*x^(2*n))^2,x, algorithm="fricas")
 

Output:

integral((d*x)^m/(c^2*x^(4*n) + b^2*x^(2*n) + 2*a*b*x^n + a^2 + 2*(b*c*x^n 
 + a*c)*x^(2*n)), x)
 

Sympy [F(-1)]

Timed out. \[ \int \frac {(d x)^m}{\left (a+b x^n+c x^{2 n}\right )^2} \, dx=\text {Timed out} \] Input:

integrate((d*x)**m/(a+b*x**n+c*x**(2*n))**2,x)
 

Output:

Timed out
 

Maxima [F]

\[ \int \frac {(d x)^m}{\left (a+b x^n+c x^{2 n}\right )^2} \, dx=\int { \frac {\left (d x\right )^{m}}{{\left (c x^{2 \, n} + b x^{n} + a\right )}^{2}} \,d x } \] Input:

integrate((d*x)^m/(a+b*x^n+c*x^(2*n))^2,x, algorithm="maxima")
 

Output:

(b*c*d^m*x*e^(m*log(x) + n*log(x)) + (b^2*d^m - 2*a*c*d^m)*x*x^m)/(a^2*b^2 
*n - 4*a^3*c*n + (a*b^2*c*n - 4*a^2*c^2*n)*x^(2*n) + (a*b^3*n - 4*a^2*b*c* 
n)*x^n) + integrate(-(b*c*d^m*(m - n + 1)*e^(m*log(x) + n*log(x)) + (b^2*d 
^m*(m - n + 1) - 2*a*c*d^m*(m - 2*n + 1))*x^m)/(a^2*b^2*n - 4*a^3*c*n + (a 
*b^2*c*n - 4*a^2*c^2*n)*x^(2*n) + (a*b^3*n - 4*a^2*b*c*n)*x^n), x)
 

Giac [F]

\[ \int \frac {(d x)^m}{\left (a+b x^n+c x^{2 n}\right )^2} \, dx=\int { \frac {\left (d x\right )^{m}}{{\left (c x^{2 \, n} + b x^{n} + a\right )}^{2}} \,d x } \] Input:

integrate((d*x)^m/(a+b*x^n+c*x^(2*n))^2,x, algorithm="giac")
 

Output:

integrate((d*x)^m/(c*x^(2*n) + b*x^n + a)^2, x)
 

Mupad [F(-1)]

Timed out. \[ \int \frac {(d x)^m}{\left (a+b x^n+c x^{2 n}\right )^2} \, dx=\int \frac {{\left (d\,x\right )}^m}{{\left (a+b\,x^n+c\,x^{2\,n}\right )}^2} \,d x \] Input:

int((d*x)^m/(a + b*x^n + c*x^(2*n))^2,x)
 

Output:

int((d*x)^m/(a + b*x^n + c*x^(2*n))^2, x)
 

Reduce [F]

\[ \int \frac {(d x)^m}{\left (a+b x^n+c x^{2 n}\right )^2} \, dx=d^{m} \left (\int \frac {x^{m}}{x^{4 n} c^{2}+2 x^{3 n} b c +2 x^{2 n} a c +x^{2 n} b^{2}+2 x^{n} a b +a^{2}}d x \right ) \] Input:

int((d*x)^m/(a+b*x^n+c*x^(2*n))^2,x)
 

Output:

d**m*int(x**m/(x**(4*n)*c**2 + 2*x**(3*n)*b*c + 2*x**(2*n)*a*c + x**(2*n)* 
b**2 + 2*x**n*a*b + a**2),x)