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

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 = 27, antiderivative size = 178 \[ \int \frac {d+e x^n}{x^4 \left (a+b x^n+c x^{2 n}\right )} \, dx=-\frac {\left (e+\frac {2 c d-b e}{\sqrt {b^2-4 a c}}\right ) \operatorname {Hypergeometric2F1}\left (1,-\frac {3}{n},-\frac {3-n}{n},-\frac {2 c x^n}{b-\sqrt {b^2-4 a c}}\right )}{3 \left (b-\sqrt {b^2-4 a c}\right ) x^3}-\frac {\left (e-\frac {2 c d-b e}{\sqrt {b^2-4 a c}}\right ) \operatorname {Hypergeometric2F1}\left (1,-\frac {3}{n},-\frac {3-n}{n},-\frac {2 c x^n}{b+\sqrt {b^2-4 a c}}\right )}{3 \left (b+\sqrt {b^2-4 a c}\right ) x^3} \] Output:

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

Mathematica [B] (warning: unable to verify)

Leaf count is larger than twice the leaf count of optimal. \(513\) vs. \(2(178)=356\).

Time = 1.37 (sec) , antiderivative size = 513, normalized size of antiderivative = 2.88 \[ \int \frac {d+e x^n}{x^4 \left (a+b x^n+c x^{2 n}\right )} \, dx=\frac {8^{\frac {1}{n}} \left (-\frac {e \left (\frac {c x^n}{b-\sqrt {b^2-4 a c}+2 c x^n}\right )^{3/n} \operatorname {Hypergeometric2F1}\left (\frac {3}{n},\frac {3}{n},\frac {3+n}{n},\frac {b-\sqrt {b^2-4 a c}}{b-\sqrt {b^2-4 a c}+2 c x^n}\right )}{\sqrt {b^2-4 a c}}+\frac {e \left (\frac {c x^n}{b+\sqrt {b^2-4 a c}+2 c x^n}\right )^{3/n} \operatorname {Hypergeometric2F1}\left (\frac {3}{n},\frac {3}{n},\frac {3+n}{n},\frac {b+\sqrt {b^2-4 a c}}{b+\sqrt {b^2-4 a c}+2 c x^n}\right )}{\sqrt {b^2-4 a c}}+\frac {6 c d \left (-\frac {\left (\frac {c x^n}{b-\sqrt {b^2-4 a c}+2 c x^n}\right )^{3/n} \operatorname {Hypergeometric2F1}\left (\frac {3+n}{n},\frac {3+n}{n},2+\frac {3}{n},\frac {b-\sqrt {b^2-4 a c}}{b-\sqrt {b^2-4 a c}+2 c x^n}\right )}{-b^2+4 a c+b \sqrt {b^2-4 a c}+2 c \sqrt {b^2-4 a c} x^n}+\frac {\left (\frac {c x^n}{b+\sqrt {b^2-4 a c}+2 c x^n}\right )^{3/n} \operatorname {Hypergeometric2F1}\left (\frac {3+n}{n},\frac {3+n}{n},2+\frac {3}{n},\frac {b+\sqrt {b^2-4 a c}}{b+\sqrt {b^2-4 a c}+2 c x^n}\right )}{b^2-4 a c+b \sqrt {b^2-4 a c}+2 c \sqrt {b^2-4 a c} x^n}\right )}{3+n}\right )}{3 x^3} \] Input:

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

Output:

(8^n^(-1)*(-((e*((c*x^n)/(b - Sqrt[b^2 - 4*a*c] + 2*c*x^n))^(3/n)*Hypergeo 
metric2F1[3/n, 3/n, (3 + n)/n, (b - Sqrt[b^2 - 4*a*c])/(b - Sqrt[b^2 - 4*a 
*c] + 2*c*x^n)])/Sqrt[b^2 - 4*a*c]) + (e*((c*x^n)/(b + Sqrt[b^2 - 4*a*c] + 
 2*c*x^n))^(3/n)*Hypergeometric2F1[3/n, 3/n, (3 + n)/n, (b + Sqrt[b^2 - 4* 
a*c])/(b + Sqrt[b^2 - 4*a*c] + 2*c*x^n)])/Sqrt[b^2 - 4*a*c] + (6*c*d*(-((( 
(c*x^n)/(b - Sqrt[b^2 - 4*a*c] + 2*c*x^n))^(3/n)*Hypergeometric2F1[(3 + n) 
/n, (3 + n)/n, 2 + 3/n, (b - Sqrt[b^2 - 4*a*c])/(b - Sqrt[b^2 - 4*a*c] + 2 
*c*x^n)])/(-b^2 + 4*a*c + b*Sqrt[b^2 - 4*a*c] + 2*c*Sqrt[b^2 - 4*a*c]*x^n) 
) + (((c*x^n)/(b + Sqrt[b^2 - 4*a*c] + 2*c*x^n))^(3/n)*Hypergeometric2F1[( 
3 + n)/n, (3 + n)/n, 2 + 3/n, (b + Sqrt[b^2 - 4*a*c])/(b + Sqrt[b^2 - 4*a* 
c] + 2*c*x^n)])/(b^2 - 4*a*c + b*Sqrt[b^2 - 4*a*c] + 2*c*Sqrt[b^2 - 4*a*c] 
*x^n)))/(3 + n)))/(3*x^3)
 

Rubi [A] (verified)

Time = 0.55 (sec) , antiderivative size = 322, normalized size of antiderivative = 1.81, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.074, Rules used = {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+e x^n}{x^4 \left (a+b x^n+c x^{2 n}\right )} \, dx\)

\(\Big \downarrow \) 1884

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

\(\Big \downarrow \) 2009

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

Input:

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

Output:

(2*c*d*Hypergeometric2F1[1, -3/n, -((3 - n)/n), (-2*c*x^n)/(b - Sqrt[b^2 - 
 4*a*c])])/(3*(b^2 - 4*a*c - b*Sqrt[b^2 - 4*a*c])*x^3) + (2*c*d*Hypergeome 
tric2F1[1, -3/n, -((3 - n)/n), (-2*c*x^n)/(b + Sqrt[b^2 - 4*a*c])])/(3*(b^ 
2 - 4*a*c + b*Sqrt[b^2 - 4*a*c])*x^3) - (2*c*e*x^(-3 + n)*Hypergeometric2F 
1[1, -((3 - n)/n), 2 - 3/n, (-2*c*x^n)/(b - Sqrt[b^2 - 4*a*c])])/(Sqrt[b^2 
 - 4*a*c]*(b - Sqrt[b^2 - 4*a*c])*(3 - n)) + (2*c*e*x^(-3 + n)*Hypergeomet 
ric2F1[1, -((3 - n)/n), 2 - 3/n, (-2*c*x^n)/(b + Sqrt[b^2 - 4*a*c])])/(Sqr 
t[b^2 - 4*a*c]*(b + Sqrt[b^2 - 4*a*c])*(3 - n))
 

Defintions of rubi rules used

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

Input:

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

Output:

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

Fricas [F]

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

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

Output:

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

Sympy [F(-1)]

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

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

Output:

Timed out
 

Maxima [F]

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

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

Output:

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

Giac [F]

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

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

Output:

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

Mupad [F(-1)]

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

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

Output:

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

Reduce [F]

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

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

Output:

int(x**n/(x**(2*n)*c*x**4 + x**n*b*x**4 + a*x**4),x)*e + int(1/(x**(2*n)*c 
*x**4 + x**n*b*x**4 + a*x**4),x)*d