\(\int x^{-1+n} (d x^n)^p (a+b x^n+c x^{2 n})^q \, dx\) [488]

Optimal result
Mathematica [A] (verified)
Rubi [A] (verified)
Maple [F]
Fricas [F]
Sympy [F(-1)]
Maxima [F]
Giac [F]
Mupad [F(-1)]
Reduce [F]

Optimal result

Integrand size = 29, antiderivative size = 154 \[ \int x^{-1+n} \left (d x^n\right )^p \left (a+b x^n+c x^{2 n}\right )^q \, dx=\frac {\left (d x^n\right )^{1+p} \left (1+\frac {2 c x^n}{b-\sqrt {b^2-4 a c}}\right )^{-q} \left (1+\frac {2 c x^n}{b+\sqrt {b^2-4 a c}}\right )^{-q} \left (a+b x^n+c x^{2 n}\right )^q \operatorname {AppellF1}\left (1+p,-q,-q,2+p,-\frac {2 c x^n}{b-\sqrt {b^2-4 a c}},-\frac {2 c x^n}{b+\sqrt {b^2-4 a c}}\right )}{d n (1+p)} \] Output:

(d*x^n)^(p+1)*(a+b*x^n+c*x^(2*n))^q*AppellF1(p+1,-q,-q,2+p,-2*c*x^n/(b-(-4 
*a*c+b^2)^(1/2)),-2*c*x^n/(b+(-4*a*c+b^2)^(1/2)))/d/n/(p+1)/((1+2*c*x^n/(b 
-(-4*a*c+b^2)^(1/2)))^q)/((1+2*c*x^n/(b+(-4*a*c+b^2)^(1/2)))^q)
 

Mathematica [A] (verified)

Time = 0.95 (sec) , antiderivative size = 179, normalized size of antiderivative = 1.16 \[ \int x^{-1+n} \left (d x^n\right )^p \left (a+b x^n+c x^{2 n}\right )^q \, dx=\frac {x^n \left (d x^n\right )^p \left (\frac {b-\sqrt {b^2-4 a c}+2 c x^n}{b-\sqrt {b^2-4 a c}}\right )^{-q} \left (\frac {b+\sqrt {b^2-4 a c}+2 c x^n}{b+\sqrt {b^2-4 a c}}\right )^{-q} \left (a+x^n \left (b+c x^n\right )\right )^q \operatorname {AppellF1}\left (1+p,-q,-q,2+p,-\frac {2 c x^n}{b+\sqrt {b^2-4 a c}},\frac {2 c x^n}{-b+\sqrt {b^2-4 a c}}\right )}{n (1+p)} \] Input:

Integrate[x^(-1 + n)*(d*x^n)^p*(a + b*x^n + c*x^(2*n))^q,x]
 

Output:

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

Rubi [A] (verified)

Time = 0.60 (sec) , antiderivative size = 161, normalized size of antiderivative = 1.05, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.103, Rules used = {31, 1721, 1012}

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

\(\Big \downarrow \) 31

\(\displaystyle x^{-n p} \left (d x^n\right )^p \int x^{p n+n-1} \left (b x^n+c x^{2 n}+a\right )^qdx\)

\(\Big \downarrow \) 1721

\(\displaystyle x^{-n p} \left (d x^n\right )^p \left (\frac {2 c x^n}{b-\sqrt {b^2-4 a c}}+1\right )^{-q} \left (\frac {2 c x^n}{\sqrt {b^2-4 a c}+b}+1\right )^{-q} \left (a+b x^n+c x^{2 n}\right )^q \int x^{p n+n-1} \left (\frac {2 c x^n}{b-\sqrt {b^2-4 a c}}+1\right )^q \left (\frac {2 c x^n}{b+\sqrt {b^2-4 a c}}+1\right )^qdx\)

\(\Big \downarrow \) 1012

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

Input:

Int[x^(-1 + n)*(d*x^n)^p*(a + b*x^n + c*x^(2*n))^q,x]
 

Output:

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

Defintions of rubi rules used

rule 31
Int[(u_.)*((a_.)*(x_))^(m_.)*((b_.)*(x_)^(i_.))^(p_), x_Symbol] :> Simp[(b* 
x^i)^p/(a*x)^(i*p)   Int[u*(a*x)^(m + i*p), x], x] /; FreeQ[{a, b, i, m, p} 
, x] &&  !IntegerQ[p]
 

rule 1012
Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_)*((c_) + (d_.)*(x_)^(n_ 
))^(q_), x_Symbol] :> Simp[a^p*c^q*((e*x)^(m + 1)/(e*(m + 1)))*AppellF1[(m 
+ 1)/n, -p, -q, 1 + (m + 1)/n, (-b)*(x^n/a), (-d)*(x^n/c)], x] /; FreeQ[{a, 
 b, c, d, e, m, n, p, q}, x] && NeQ[b*c - a*d, 0] && NeQ[m, -1] && NeQ[m, n 
 - 1] && (IntegerQ[p] || GtQ[a, 0]) && (IntegerQ[q] || GtQ[c, 0])
 

rule 1721
Int[((d_.)*(x_))^(m_.)*((a_) + (c_.)*(x_)^(n2_.) + (b_.)*(x_)^(n_))^(p_), x 
_Symbol] :> Simp[a^IntPart[p]*((a + b*x^n + c*x^(2*n))^FracPart[p]/((1 + 2* 
c*(x^n/(b + Rt[b^2 - 4*a*c, 2])))^FracPart[p]*(1 + 2*c*(x^n/(b - Rt[b^2 - 4 
*a*c, 2])))^FracPart[p]))   Int[(d*x)^m*(1 + 2*c*(x^n/(b + Sqrt[b^2 - 4*a*c 
])))^p*(1 + 2*c*(x^n/(b - Sqrt[b^2 - 4*a*c])))^p, x], x] /; FreeQ[{a, b, c, 
 d, m, n, p}, x] && EqQ[n2, 2*n]
 
Maple [F]

\[\int x^{-1+n} \left (d \,x^{n}\right )^{p} \left (a +b \,x^{n}+c \,x^{2 n}\right )^{q}d x\]

Input:

int(x^(-1+n)*(d*x^n)^p*(a+b*x^n+c*x^(2*n))^q,x)
 

Output:

int(x^(-1+n)*(d*x^n)^p*(a+b*x^n+c*x^(2*n))^q,x)
 

Fricas [F]

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

integrate(x^(-1+n)*(d*x^n)^p*(a+b*x^n+c*x^(2*n))^q,x, algorithm="fricas")
 

Output:

integral((c*x^(2*n) + b*x^n + a)^q*(d*x^n)^p*x^(n - 1), x)
 

Sympy [F(-1)]

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

integrate(x**(-1+n)*(d*x**n)**p*(a+b*x**n+c*x**(2*n))**q,x)
 

Output:

Timed out
 

Maxima [F]

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

integrate(x^(-1+n)*(d*x^n)^p*(a+b*x^n+c*x^(2*n))^q,x, algorithm="maxima")
 

Output:

integrate((c*x^(2*n) + b*x^n + a)^q*(d*x^n)^p*x^(n - 1), x)
 

Giac [F]

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

integrate(x^(-1+n)*(d*x^n)^p*(a+b*x^n+c*x^(2*n))^q,x, algorithm="giac")
 

Output:

integrate((c*x^(2*n) + b*x^n + a)^q*(d*x^n)^p*x^(n - 1), x)
 

Mupad [F(-1)]

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

int(x^(n - 1)*(d*x^n)^p*(a + b*x^n + c*x^(2*n))^q,x)
 

Output:

int(x^(n - 1)*(d*x^n)^p*(a + b*x^n + c*x^(2*n))^q, x)
 

Reduce [F]

\[ \int x^{-1+n} \left (d x^n\right )^p \left (a+b x^n+c x^{2 n}\right )^q \, dx=\text {too large to display} \] Input:

int(x^(-1+n)*(d*x^n)^p*(a+b*x^n+c*x^(2*n))^q,x)
 

Output:

(d**p*(x**(n*p + n)*(x**(2*n)*c + x**n*b + a)**q*b*p + x**(n*p + n)*(x**(2 
*n)*c + x**n*b + a)**q*b*q + 2*x**(n*p)*(x**(2*n)*c + x**n*b + a)**q*a*q - 
 2*int((x**(n*p + 2*n)*(x**(2*n)*c + x**n*b + a)**q)/(x**(2*n)*c*p**2*x + 
3*x**(2*n)*c*p*q*x + x**(2*n)*c*p*x + 2*x**(2*n)*c*q**2*x + x**(2*n)*c*q*x 
 + x**n*b*p**2*x + 3*x**n*b*p*q*x + x**n*b*p*x + 2*x**n*b*q**2*x + x**n*b* 
q*x + a*p**2*x + 3*a*p*q*x + a*p*x + 2*a*q**2*x + a*q*x),x)*a*c*n*p**3*q - 
 10*int((x**(n*p + 2*n)*(x**(2*n)*c + x**n*b + a)**q)/(x**(2*n)*c*p**2*x + 
 3*x**(2*n)*c*p*q*x + x**(2*n)*c*p*x + 2*x**(2*n)*c*q**2*x + x**(2*n)*c*q* 
x + x**n*b*p**2*x + 3*x**n*b*p*q*x + x**n*b*p*x + 2*x**n*b*q**2*x + x**n*b 
*q*x + a*p**2*x + 3*a*p*q*x + a*p*x + 2*a*q**2*x + a*q*x),x)*a*c*n*p**2*q* 
*2 - 2*int((x**(n*p + 2*n)*(x**(2*n)*c + x**n*b + a)**q)/(x**(2*n)*c*p**2* 
x + 3*x**(2*n)*c*p*q*x + x**(2*n)*c*p*x + 2*x**(2*n)*c*q**2*x + x**(2*n)*c 
*q*x + x**n*b*p**2*x + 3*x**n*b*p*q*x + x**n*b*p*x + 2*x**n*b*q**2*x + x** 
n*b*q*x + a*p**2*x + 3*a*p*q*x + a*p*x + 2*a*q**2*x + a*q*x),x)*a*c*n*p**2 
*q - 16*int((x**(n*p + 2*n)*(x**(2*n)*c + x**n*b + a)**q)/(x**(2*n)*c*p**2 
*x + 3*x**(2*n)*c*p*q*x + x**(2*n)*c*p*x + 2*x**(2*n)*c*q**2*x + x**(2*n)* 
c*q*x + x**n*b*p**2*x + 3*x**n*b*p*q*x + x**n*b*p*x + 2*x**n*b*q**2*x + x* 
*n*b*q*x + a*p**2*x + 3*a*p*q*x + a*p*x + 2*a*q**2*x + a*q*x),x)*a*c*n*p*q 
**3 - 6*int((x**(n*p + 2*n)*(x**(2*n)*c + x**n*b + a)**q)/(x**(2*n)*c*p**2 
*x + 3*x**(2*n)*c*p*q*x + x**(2*n)*c*p*x + 2*x**(2*n)*c*q**2*x + x**(2*...