Rules for integrands of the form(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)
when b c-a d≠0 ∧ b e-a f≠0 ∧ d e-c f≠0

0.  ∫(((g x))^m) (((b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx

1.  ∫(((g x))^m) (((b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when m∈ℤ ∨ g>0

1:  ∫(((g x))^m) (((b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r) dx  when (m∈ℤ ∨ g>0) ∧ ((m+1)/n)∈ℤ

Derivation: Integration by substitution

Basis: If  ((m+1)/n)∈ℤ, then (x^m) (((b (x^n)))^p)==(1/(b^(((m+1)/n)-1))) (x^(n-1)) (((b (x^n)))^(p+((m+1)/n)-1))

Basis: (x^(n-1))F[(x^n)]==(1/n) Subst[F[x],x,(x^n)] (∂_x)(x^n)

Rule 1.1.3.6.0.1.1: If  (m∈ℤ ∨ g>0) ∧ ((m+1)/n)∈ℤ, then

∫(((g x))^m) (((b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r) dx  ⟶  ((g^m)/(n (b^(((m+1)/n)-1)))) Subst[∫(((b x))^(p+((m+1)/n)-1)) (((c+d x))^q) (((e+f x))^r)dx,x,(x^n)]

Program code:

Int[(g_.*x_)^m_.*(b_.*x_^n_)^p_*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  g^m/(n*b^(Simplify[(m+1)/n]-1))*Subst[Int[(b*x)^(p+Simplify[(m+1)/n]-1)*(c+d*x)^q*(e+f*x)^r,x],x,x^n] /;
FreeQ[{b,c,d,e,f,g,m,n,p,q,r},x] && (IntegerQ[m] || GtQ[g,0]) && IntegerQ[Simplify[(m+1)/n]]

2:  ∫(((g x))^m) (((b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when (m∈ℤ ∨ g>0) ∧ ((m+1)/n)∉ℤ

Derivation: Piecewise constant extraction

Basis: (∂_x)((((b (x^n)))^p)/(x^(n p)))==0

Rule 1.1.3.6.0.1.2: If (m∈ℤ ∨ g>0) ∧ ((m+1)/n)∉ℤ, then

∫(((g x))^m) (((b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (((g^m) (b^(IntPart[p])) (((b (x^n)))^(FracPart[p])))/(x^(n FracPart[p])))∫(x^(m+n p)) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx

Program code:

Int[(g_.*x_)^m_.*(b_.*x_^n_.)^p_*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  g^m*b^IntPart[p]*(b*x^n)^FracPart[p]/x^(n*FracPart[p])*Int[x^(m+n*p)*(c+d*x^n)^q*(e+f*x^n)^r,x] /;
FreeQ[{b,c,d,e,f,g,m,n,p,q,r},x] && (IntegerQ[m] || GtQ[g,0]) && Not[IntegerQ[Simplify[(m+1)/n]]]

2:  ∫(((g x))^m) (((b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when m∉ℤ

Derivation: Piecewise constant extraction

Basis: (∂_x)((((g x))^m)/(x^m))==0

Rule 1.1.3.6.0.2: If  m∉ℤ, then

∫(((g x))^m) (((b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (((g^(IntPart[m]))(((g x))^(FracPart[m])))/(x^(FracPart[m])))∫(x^m) (((b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx

Program code:

Int[(g_*x_)^m_*(b_.*x_^n_.)^p_*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  g^IntPart[m]*(g*x)^FracPart[m]/x^FracPart[m]*Int[x^m*(b*x^n)^p*(c+d*x^n)^q*(e+f*x^n)^r,x] /;
FreeQ[{b,c,d,e,f,g,m,n,p,q,r},x] && Not[IntegerQ[m]]

1:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when p+2∈(SuperPlus[ℤ])∧ q∈(SuperPlus[ℤ])∧ r∈(SuperPlus[ℤ])

Derivation: Algebraic expansion

Rule 1.1.3.6.1: If  p+2∈(SuperPlus[ℤ])∧ q∈(SuperPlus[ℤ])∧ r∈(SuperPlus[ℤ]), then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  ∫ExpandIntegrand[(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r),x]dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  Int[ExpandIntegrand[(g*x)^m*(a+b*x^n)^p*(c+d*x^n)^q*(e+f*x^n)^r,x],x] /;
FreeQ[{a,b,c,d,e,f,g,m,n},x] && IGtQ[p,-2] && IGtQ[q,0] && IGtQ[r,0]

2:  ∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when m-n+1==0

Derivation: Integration by substitution

Basis: (x^(n-1))F[(x^n)]==(1/n) Subst[F[x],x,(x^n)] (∂_x)(x^n)

Rule 1.1.3.6.2: If  m-n+1==0, then

∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (1/n) Subst[∫(((a+b x))^p) (((c+d x))^q) (((e+f x))^r)dx,x,(x^n)]

Program code:

Int[x_^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  1/n*Subst[Int[(a+b*x)^p*(c+d*x)^q*(e+f*x)^r,x],x,x^n] /;
FreeQ[{a,b,c,d,e,f,m,n,p,q,r},x] && EqQ[m-n+1,0]

3:  ∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  (p|q|r)∈ℤ ∧ n<0

Derivation: Algebraic expansion

Basis: If (p|q|r)∈ℤ, then (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)==(x^(n (p+q+r)))(((b+a (x^(-n))))^p) (((d+c (x^(-n))))^q) (((f+e (x^(-n))))^r)

Rule 1.1.3.6.3: If (p|q|r)∈ℤ ∧ n<0, then

∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  ∫(x^(m+n (p+q+r)))(((b+a (x^(-n))))^p) (((d+c (x^(-n))))^q) (((f+e (x^(-n))))^r)dx

Program code:

Int[x_^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  Int[x^(m+n*(p+q+r))*(b+a*x^(-n))^p*(d+c*x^(-n))^q*(f+e*x^(-n))^r,x] /;
FreeQ[{a,b,c,d,e,f,m,n},x] && IntegersQ[p,q,r] && NegQ[n]

4.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  ((m+1)/n)∈ℤ

1:  ∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when ((m+1)/n)∈ℤ

Derivation: Integration by substitution

Basis: If ((m+1)/n)∈ℤ, then (x^m)F[(x^n)]==(1/n) Subst[(x^(((m+1)/n)-1)) F[x],x,(x^n)] (∂_x)(x^n)

Note: If  n∈ℤ ∧ ((m+1)/n)∈ℤ, then m∈ℤ, and (((e x))^m) automatically evaluates to (e^m)(x^m).

Rule 1.1.3.6.4.1: If ((m+1)/n)∈ℤ, then

∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (1/n) Subst[∫(x^(((m+1)/n)-1)) (((a+b x))^p) (((c+d x))^q) (((e+f x))^r)dx,x,(x^n)]

Program code:

Int[x_^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  1/n*Subst[Int[x^(Simplify[(m+1)/n]-1)*(a+b*x)^p*(c+d*x)^q*(e+f*x)^r,x],x,x^n] /;
FreeQ[{a,b,c,d,e,f,m,n,p,q,r},x] && IntegerQ[Simplify[(m+1)/n]]

2:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  ((m+1)/n)∈ℤ

Derivation: Piecewise constant extraction

Basis: (∂_x)((((g x))^m)/(x^m))==0

Basis: ((((g x))^m)/(x^m))==(((g^(IntPart[m]))(((g x))^(FracPart[m])))/(x^(FracPart[m])))

Rule 1.1.3.6.4.2: If ((m+1)/n)∈ℤ, then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (((g^(IntPart[m]))(((g x))^(FracPart[m])))/(x^(FracPart[m])))∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx

Program code:

Int[(g_*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  g^IntPart[m]*(g*x)^FracPart[m]/x^FracPart[m]*Int[x^m*(a+b*x^n)^p*(c+d*x^n)^q*(e+f*x^n)^r,x] /;
FreeQ[{a,b,c,d,e,f,g,m,n,p,q,r},x] && IntegerQ[Simplify[(m+1)/n]]

5.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈ℤ

1.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈(SuperPlus[ℤ])

1:  ∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈(SuperPlus[ℤ])∧ m∈ℤ ∧ GCD[m+1,n]≠1

Derivation: Integration by substitution

Basis: If  n∈ℤ ∧ m∈ℤ, let k=GCD[m+1,n], then (x^m) F[(x^n)]==(1/k)Subst[(x^(((m+1)/k)-1)) F[(x^(n/k))],x,(x^k)] (∂_x)(x^k)

Rule 1.1.3.6.5.1.1: If  n∈(SuperPlus[ℤ])∧ m∈ℤ, let k=GCD[m+1,n], if  k≠1, then

∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (1/k) Subst[∫(x^(((m+1)/k)-1)) (((a+b (x^(n/k))))^p) (((c+d (x^(n/k))))^q) (((e+f (x^(n/k))))^r)dx,x,(x^k)]

Program code:

Int[x_^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  With[{k=GCD[m+1,n]},
  1/k*Subst[Int[x^((m+1)/k-1)*(a+b*x^(n/k))^p*(c+d*x^(n/k))^q*(e+f*x^(n/k))^r,x],x,x^k] /;
 k≠1] /;
FreeQ[{a,b,c,d,e,f,p,q,r},x] && IGtQ[n,0] && IntegerQ[m]

2:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈(SuperPlus[ℤ])∧ m∈𝔽

Derivation: Integration by substitution

Basis: If  k∈(SuperPlus[ℤ]), then (((g x))^m) F[x]==(k/g) Subst[(x^(k (m+1)-1))F[((x^k)/g)],x,(((g x))^(1/k))] (∂_x)(((g x))^(1/k))

Rule 1.1.3.6.5.1.2: If  n∈(SuperPlus[ℤ])∧ m∈𝔽, let k=Denominator[m], then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (k/g) Subst[∫(x^(k (m+1)-1)) (((a+((b (x^(k n)))/(g^n))))^p) (((c+((d (x^(k n)))/(g^n))))^q) (((e+((f (x^(k n)))/(g^n))))^r)dx,x,(((g x))^(1/k))]

Program code:

Int[(g_.*x_)^m_*(a_+b_.*x_^n_)^p_*(c_+d_.*x_^n_)^q_*(e_+f_.*x_^n_)^r_,x_Symbol] :=
  With[{k=Denominator[m]},
  k/g*Subst[Int[x^(k*(m+1)-1)*(a+b*x^(k*n)/g^n)^p*(c+d*x^(k*n)/g^n)^q*(e+f*x^(k*n)/g^n)^r,x],x,(g*x)^(1/k)]] /;
FreeQ[{a,b,c,d,e,f,g,p,q,r},x] && IGtQ[n,0] && FractionQ[m]

3.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when  n∈(SuperPlus[ℤ])

1.  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when n∈(SuperPlus[ℤ])∧ p<-1

1:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when n∈(SuperPlus[ℤ])∧ p<-1 ∧ q>0

Derivation: Binomial product recurrence 1

Rule 1.1.3.6.5.1.3.1.1: If  n∈(SuperPlus[ℤ])∧ p<-1 ∧ q>0, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
-(((b e-a f)(((g x))^(m+1)) (((a+b (x^n)))^(p+1))(((c+d (x^n)))^q))/(a b g n(p+1)))+(1/(a b n(p+1)))·
∫(((g x))^m) (((a+b (x^n)))^(p+1)) (((c+d (x^n)))^(q-1)) (c (b e n (p+1)+(b e-a f) (m+1))+d (b e n (p+1)+(b e-a f) (m+n q+1)) (x^n))dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_),x_Symbol] :=
  -(b*e-a*f)*(g*x)^(m+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^q/(a*b*g*n*(p+1)) + 
  1/(a*b*n*(p+1))*Int[(g*x)^m*(a+b*x^n)^(p+1)*(c+d*x^n)^(q-1)*
    Simp[c*(b*e*n*(p+1)+(b*e-a*f)*(m+1))+d*(b*e*n*(p+1)+(b*e-a*f)*(m+n*q+1))*x^n,x],x] /;
FreeQ[{a,b,c,d,e,f,g,m},x] && IGtQ[n,0] && LtQ[p,-1] && GtQ[q,0] && Not[EqQ[q,1] && SimplerQ[b*c-a*d,b*e-a*f]]

2:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when n∈(SuperPlus[ℤ])∧ p<-1 ∧ m-n+1>0

Derivation: Binomial product recurrence 3a

Rule 1.1.3.6.5.1.3.1.2: If  n∈(SuperPlus[ℤ])∧ p<-1 ∧ m-n+1>0, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
(((g^(n-1))(b e-a f) (((g x))^(m-n+1)) (((a+b (x^n)))^(p+1))(((c+d (x^n)))^(q+1)))/(b n(b c-a d)(p+1)))-((g^n)/(b n(b c-a d)(p+1)))·
∫(((g x))^(m-n)) (((a+b (x^n)))^(p+1)) (((c+d (x^n)))^q) (c(b e-a f)(m-n+1)+(d(b e-a f)(m+n q+1)-b n(c f-d e)(p+1)) (x^n))dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_*(c_+d_.*x_^n_)^q_*(e_+f_.*x_^n_),x_Symbol] :=
  g^(n-1)*(b*e-a*f)*(g*x)^(m-n+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^(q+1)/(b*n*(b*c-a*d)*(p+1)) - 
  g^n/(b*n*(b*c-a*d)*(p+1))*Int[(g*x)^(m-n)*(a+b*x^n)^(p+1)*(c+d*x^n)^q*
    Simp[c*(b*e-a*f)*(m-n+1)+(d*(b*e-a*f)*(m+n*q+1)-b*n*(c*f-d*e)*(p+1))*x^n,x],x] /;
FreeQ[{a,b,c,d,e,f,g,q},x] && IGtQ[n,0] && LtQ[p,-1] && GtQ[m-n+1,0]

3:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when n∈(SuperPlus[ℤ])∧ p<-1

Derivation: Binomial product recurrence 3b

Rule 1.1.3.6.5.1.3.1.3: If  n∈(SuperPlus[ℤ])∧ p<-1, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
-(((b e-a f)(((g x))^(m+1)) (((a+b (x^n)))^(p+1))(((c+d (x^n)))^(q+1)))/(a g n(b c-a d)(p+1)))+(1/(a n(b c-a d)(p+1)))·
∫(((g x))^m) (((a+b (x^n)))^(p+1)) (((c+d (x^n)))^q) (c(b e-a f)(m+1)+e n (b c-a d)(p+1)+d(b e-a f) (m+n (p+q+2)+1) (x^n))dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_*(c_+d_.*x_^n_)^q_*(e_+f_.*x_^n_),x_Symbol] :=
  -(b*e-a*f)*(g*x)^(m+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^(q+1)/(a*g*n*(b*c-a*d)*(p+1)) + 
  1/(a*n*(b*c-a*d)*(p+1))*Int[(g*x)^m*(a+b*x^n)^(p+1)*(c+d*x^n)^q*
    Simp[c*(b*e-a*f)*(m+1)+e*n*(b*c-a*d)*(p+1)+d*(b*e-a*f)*(m+n*(p+q+2)+1)*x^n,x],x] /;
FreeQ[{a,b,c,d,e,f,g,m,q},x] && IGtQ[n,0] && LtQ[p,-1]

2.  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when n∈(SuperPlus[ℤ])∧ q>0

1:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when n∈(SuperPlus[ℤ])∧ q>0 ∧ m<-1

Derivation: Binomial product recurrence 2a

Rule 1.1.3.6.5.1.3.2.1: If  n∈(SuperPlus[ℤ])∧ q>0 ∧ m<-1, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
((e (((g x))^(m+1)) (((a+b (x^n)))^(p+1))(((c+d (x^n)))^q))/(a g(m+1)))-(1/(a (g^n) (m+1)))·
∫(((g x))^(m+n)) (((a+b (x^n)))^p) (((c+d (x^n)))^(q-1)) (c(b e-a f)(m+1)+e n (b c (p+1)+a d q)+d ((b e-a f) (m+1)+b e n (p+q+1)) (x^n))dx

Program code:

Int[(g_.*x_)^m_*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_),x_Symbol] :=
  e*(g*x)^(m+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^q/(a*g*(m+1)) - 
  1/(a*g^n*(m+1))*Int[(g*x)^(m+n)*(a+b*x^n)^p*(c+d*x^n)^(q-1)*
    Simp[c*(b*e-a*f)*(m+1)+e*n*(b*c*(p+1)+a*d*q)+d*((b*e-a*f)*(m+1)+b*e*n*(p+q+1))*x^n,x],x] /;
FreeQ[{a,b,c,d,e,f,g,p},x] && IGtQ[n,0] && GtQ[q,0] && LtQ[m,-1] && Not[EqQ[q,1] && SimplerQ[e+f*x^n,c+d*x^n]]

2:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when n∈(SuperPlus[ℤ])∧ q>0

Derivation: Binomial product recurrence 2b

Rule 1.1.3.6.5.1.3.2.2: If  n∈(SuperPlus[ℤ])∧ q>0, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
((f (((g x))^(m+1)) (((a+b (x^n)))^(p+1))(((c+d (x^n)))^q))/(b g (m+n (p+q+1)+1)))+(1/(b (m+n (p+q+1)+1)))·
∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^(q-1)) (c ((b e-a f) (m+1)+b e n (p+q+1))+(d(b e-a f) (m+1)+f n q(b c-a d)+b e d n (p+q+1)) (x^n))dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_),x_Symbol] :=
  f*(g*x)^(m+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^q/(b*g*(m+n*(p+q+1)+1)) + 
  1/(b*(m+n*(p+q+1)+1))*Int[(g*x)^m*(a+b*x^n)^p*(c+d*x^n)^(q-1)*
    Simp[c*((b*e-a*f)*(m+1)+b*e*n*(p+q+1))+(d*(b*e-a*f)*(m+1)+f*n*q*(b*c-a*d)+b*e*d*n*(p+q+1))*x^n,x],x] /;
FreeQ[{a,b,c,d,e,f,g,m,p},x] && IGtQ[n,0] && GtQ[q,0] && Not[EqQ[q,1] && SimplerQ[e+f*x^n,c+d*x^n]]

3:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when n∈(SuperPlus[ℤ])∧ m>n-1

Derivation: Binomial product recurrence 4a

Rule 1.1.3.6.5.1.3.3: If  n∈(SuperPlus[ℤ])∧ m>n-1, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
((f (g^(n-1))(((g x))^(m-n+1)) (((a+b (x^n)))^(p+1))(((c+d (x^n)))^(q+1)))/(b d (m+n (p+q+1)+1)))-((g^n)/(b d (m+n (p+q+1)+1)))·
∫(((g x))^(m-n)) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (a f c (m-n+1)+(a f d (m+n q+1)+b (f c (m+n p+1)-e d (m+n (p+q+1)+1))) (x^n))dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_),x_Symbol] :=
  f*g^(n-1)*(g*x)^(m-n+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^(q+1)/(b*d*(m+n*(p+q+1)+1)) - 
  g^n/(b*d*(m+n*(p+q+1)+1))*Int[(g*x)^(m-n)*(a+b*x^n)^p*(c+d*x^n)^q*
    Simp[a*f*c*(m-n+1)+(a*f*d*(m+n*q+1)+b*(f*c*(m+n*p+1)-e*d*(m+n*(p+q+1)+1)))*x^n,x],x] /;
FreeQ[{a,b,c,d,e,f,g,p,q},x] && IGtQ[n,0] && GtQ[m,n-1]

4:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when n∈(SuperPlus[ℤ])∧ m<-1

Derivation: Binomial product recurrence 4b

Rule 1.1.3.6.5.1.3.4: If  n∈(SuperPlus[ℤ])∧ m<-1, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
((e (((g x))^(m+1)) (((a+b (x^n)))^(p+1))(((c+d (x^n)))^(q+1)))/(a c g (m+1)))+(1/(a c (g^n)(m+1)))·
∫(((g x))^(m+n)) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (a f c (m+1)-e (b c+a d) (m+n+1)-e n (b c p+a d q)-b e d (m+n (p+q+2)+1) (x^n))dx

Program code:

Int[(g_.*x_)^m_*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_),x_Symbol] :=
  e*(g*x)^(m+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^(q+1)/(a*c*g*(m+1)) + 
  1/(a*c*g^n*(m+1))*Int[(g*x)^(m+n)*(a+b*x^n)^p*(c+d*x^n)^q*
    Simp[a*f*c*(m+1)-e*(b*c+a*d)*(m+n+1)-e*n*(b*c*p+a*d*q)-b*e*d*(m+n*(p+q+2)+1)*x^n,x],x] /;
FreeQ[{a,b,c,d,e,f,g,p,q},x] && IGtQ[n,0] && LtQ[m,-1]

5:  ∫(((((g x))^m) (((a+b (x^n)))^p) (e+f (x^n)))/(c+d (x^n)))dx  when n∈(SuperPlus[ℤ])

Derivation: Algebraic expansion

Rule 1.1.3.6.5.1.3.5: If  n∈(SuperPlus[ℤ]), then

∫(((((g x))^m) (((a+b (x^n)))^p) (e+f (x^n)))/(c+d (x^n)))dx  ⟶  ∫ExpandIntegrand[(((((g x))^m) (((a+b (x^n)))^p) (e+f (x^n)))/(c+d (x^n))),x]dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_*(e_+f_.*x_^n_)/(c_+d_.*x_^n_),x_Symbol] :=
  Int[ExpandIntegrand[(g*x)^m*(a+b*x^n)^p*(e+f*x^n)/(c+d*x^n),x],x] /;
FreeQ[{a,b,c,d,e,f,g,m,p},x] && IGtQ[n,0]

6:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when n∈(SuperPlus[ℤ])

Derivation: Algebraic expansion

Rule 1.1.3.6.5.1.3.6: If  n∈(SuperPlus[ℤ]), then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
e∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q)dx+(f/(e^n))∫(((g x))^(m+n)) (((a+b (x^n)))^p) (((c+d (x^n)))^q)dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_),x_Symbol] :=
  e*Int[(g*x)^m*(a+b*x^n)^p*(c+d*x^n)^q,x] + 
  f/e^n*Int[(g*x)^(m+n)*(a+b*x^n)^p*(c+d*x^n)^q,x] /;
FreeQ[{a,b,c,d,e,f,g,m,p,q},x] && IGtQ[n,0]

4:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when n∈(SuperPlus[ℤ])∧ r∈(SuperPlus[ℤ])

Derivation: Algebraic expansion

Rule 1.1.3.6.5.1.4: If  n∈(SuperPlus[ℤ])∧ r∈(SuperPlus[ℤ]), then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  
e∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^(r-1))dx+(f/(e^n))∫(((g x))^(m+n)) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^(r-1))dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  e*Int[(g*x)^m*(a+b*x^n)^p*(c+d*x^n)^q*(e+f*x^n)^(r-1),x] + 
  f/e^n*Int[(g*x)^(m+n)*(a+b*x^n)^p*(c+d*x^n)^q*(e+f*x^n)^(r-1),x] /;
FreeQ[{a,b,c,d,e,f,g,m,p,q},x] && IGtQ[n,0] && IGtQ[r,0]

2.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈(SuperMinus[ℤ])

1.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈(SuperMinus[ℤ])∧ m∈ℚ

1:  ∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈(SuperMinus[ℤ])∧ m∈ℤ

Derivation: Integration by substitution

Basis: F[x]==-Subst[((F[(x^(-1))] )/(x^2)),x,(1/x)](∂_x)(1/x)

Rule 1.1.3.6.5.2.1.1: If  n∈(SuperMinus[ℤ])∧ m∈ℤ, then

∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  -Subst[∫(((((a+b (x^(-n))))^p) (((c+d (x^(-n))))^q) (((e+f (x^(-n))))^r))/(x^(m+2)))dx,x,(1/x)]

Program code:

Int[x_^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  -Subst[Int[(a+b*x^(-n))^p*(c+d*x^(-n))^q*(e+f*x^(-n))^r/x^(m+2),x],x,1/x] /;
FreeQ[{a,b,c,d,e,f,p,q,r},x] && ILtQ[n,0] && IntegerQ[m]

2:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈(SuperMinus[ℤ])∧ m∈𝔽

Derivation: Integration by substitution

Basis: If  n∈ℤ ∧ k>1, then (((g x))^m) F[(x^n)]==-(k/g)Subst[ ((F[(g^(-n)) (x^(-k n))])/(x^(k (m+1)+1))),x,(1/(((g x))^(1/k)))] (∂_x)(1/(((g x))^(1/k)))

Rule 1.1.3.6.5.2.1.2: If  n∈(SuperMinus[ℤ])∧ m∈𝔽, let k=Denominator[m], then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  -(k/g) Subst[∫(((((a+b (g^(-n)) (x^(-k n))))^p) (((c+d (g^(-n)) (x^(-k n))))^q) (((e+f (g^(-n)) (x^(-k n))))^r))/(x^(k (m+1)+1)))dx,x,(1/(((g x))^(1/k)))]

Program code:

Int[(g_.*x_)^m_*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  With[{k=Denominator[m]},
  -k/g*Subst[Int[(a+b*g^(-n)*x^(-k*n))^p*(c+d*g^(-n)*x^(-k*n))^q*(e+f*g^(-n)*x^(-k*n))^r/x^(k*(m+1)+1),x],x,1/(g*x)^(1/k)]] /;
FreeQ[{a,b,c,d,e,f,g,p,q,r},x] && ILtQ[n,0] && FractionQ[m]

2:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈(SuperMinus[ℤ])∧ m∉ℚ

Derivation:  Piecewise constant extraction and integration by substitution

Basis: (∂_x)((((g x))^m) ((((x^(-1))))^m))==0

Basis: F[x]==-Subst[((F[(x^(-1))] )/(x^2)),x,(1/x)](∂_x)(1/x)

Rule 1.1.3.6.5.2.2: If  n∈(SuperMinus[ℤ])∧ m∉ℚ, then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (((g x))^m) ((((x^(-1))))^m)∫(((((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r))/((((x^(-1))))^m))dx
  ⟶  -(((g x))^m) ((((x^(-1))))^m) Subst[∫(((((a+b (x^(-n))))^p) (((c+d (x^(-n))))^q) (((e+f (x^(-n))))^r))/(x^(m+2)))dx,x,(1/x)]

Program code:

Int[(g_.*x_)^m_*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  -(g*x)^m*(x^(-1))^m*Subst[Int[(a+b*x^(-n))^p*(c+d*x^(-n))^q*(e+f*x^(-n))^r/x^(m+2),x],x,1/x] /;
FreeQ[{a,b,c,d,e,f,g,m,p,q,r},x] && ILtQ[n,0] && Not[RationalQ[m]]

6.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈𝔽

1:  ∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈𝔽

Derivation: Integration by substitution

Basis: If  k∈(SuperPlus[ℤ]), then (x^m)F[(x^n)]==k Subst[(x^(k(m+1)-1))F[(x^(k n))],x,(x^(1/k))] (∂_x)(x^(1/k))

Rule 1.1.3.6.6.1: If  n∈𝔽, let k=Denominator[n], then

∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  k Subst[∫(x^(k(m+1)-1)) (((a+b (x^(k n))))^p) (((c+d (x^(k n))))^q) (((e+f (x^(k n))))^r)dx,x,(x^(1/k))]

Program code:

Int[x_^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  With[{k=Denominator[n]},
  k*Subst[Int[x^(k*(m+1)-1)*(a+b*x^(k*n))^p*(c+d*x^(k*n))^q*(e+f*x^(k*n))^r,x],x,x^(1/k)]] /;
FreeQ[{a,b,c,d,e,f,m,p,q,r},x] && FractionQ[n]

2:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  n∈𝔽

Derivation: Piecewise constant extraction

Basis: (∂_x)((((g x))^m)/(x^m))==0

Basis: ((((g x))^m)/(x^m))==(((g^(IntPart[m]))(((g x))^(FracPart[m])))/(x^(FracPart[m])))

Rule 1.1.3.6.6.2: If  n∈𝔽, then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (((g^(IntPart[m]))(((g x))^(FracPart[m])))/(x^(FracPart[m])))∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx

Program code:

Int[(g_*x_)^m_*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  g^IntPart[m]*(g*x)^FracPart[m]/x^FracPart[m]*Int[x^m*(a+b*x^n)^p*(c+d*x^n)^q*(e+f*x^n)^r,x] /;
FreeQ[{a,b,c,d,e,f,g,m,p,q,r},x] && FractionQ[n]

7.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  (n/(m+1))∈ℤ

1:  ∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  (n/(m+1))∈ℤ

Derivation: Integration by substitution

Basis: If (n/(m+1))∈ℤ, then (x^m)F[(x^n)]==(1/(m+1))Subst[F[(x^(n/(m+1)))],x,(x^(m+1))](∂_x)(x^(m+1))

Rule 1.1.3.6.7.1: If  (n/(m+1))∈ℤ, then

∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (1/(m+1))Subst[∫(((a+b (x^(n/(m+1)))))^p) (((c+d (x^(n/(m+1)))))^q) (((e+f (x^(n/(m+1)))))^r)dx,x,(x^(m+1))]

Program code:

Int[x_^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  1/(m+1)*Subst[Int[(a+b*x^Simplify[n/(m+1)])^p*(c+d*x^Simplify[n/(m+1)])^q*(e+f*x^Simplify[n/(m+1)])^r,x],x,x^(m+1)] /;
FreeQ[{a,b,c,d,e,f,m,n,p,q,r},x] && IntegerQ[Simplify[n/(m+1)]]

2:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  when  (n/(m+1))∈ℤ

Derivation: Piecewise constant extraction

Basis: (∂_x)((((g x))^m)/(x^m))==0

Basis: ((((g x))^m)/(x^m))==(((g^(IntPart[m]))(((g x))^(FracPart[m])))/(x^(FracPart[m])))

Rule 1.1.3.6.7.2: If (n/(m+1))∈ℤ, then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  (((g^(IntPart[m]))(((g x))^(FracPart[m])))/(x^(FracPart[m])))∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx

Program code:

Int[(g_*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  g^IntPart[m]*(g*x)^FracPart[m]/x^FracPart[m]*Int[x^m*(a+b*x^n)^p*(c+d*x^n)^q*(e+f*x^n)^r,x] /;
FreeQ[{a,b,c,d,e,f,g,m,n,p,q,r},x] && IntegerQ[Simplify[n/(m+1)]]

8.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx

1.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when  p<-1

1:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when p<-1 ∧ q>0

Derivation: Binomial product recurrence 1

Rule 1.1.3.6.8.1.1: If  p<-1 ∧ q>0, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
-(((b e-a f)(((g x))^(m+1)) (((a+b (x^n)))^(p+1))(((c+d (x^n)))^q))/(a b g n(p+1)))+(1/(a b n(p+1)))·
∫(((g x))^m) (((a+b (x^n)))^(p+1)) (((c+d (x^n)))^(q-1)) (c (b e n (p+1)+(b e-a f) (m+1))+d (b e n (p+1)+(b e-a f) (m+n q+1)) (x^n))dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_),x_Symbol] :=
  -(b*e-a*f)*(g*x)^(m+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^q/(a*b*g*n*(p+1)) + 
  1/(a*b*n*(p+1))*Int[(g*x)^m*(a+b*x^n)^(p+1)*(c+d*x^n)^(q-1)*
    Simp[c*(b*e*n*(p+1)+(b*e-a*f)*(m+1))+d*(b*e*n*(p+1)+(b*e-a*f)*(m+n*q+1))*x^n,x],x] /;
FreeQ[{a,b,c,d,e,f,g,m,n},x] && LtQ[p,-1] && GtQ[q,0] && Not[EqQ[q,1] && SimplerQ[b*c-a*d,b*e-a*f]]

2:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when p<-1

Derivation: Binomial product recurrence 3b

Rule 1.1.3.6.8.1.2: If  p<-1, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
-(((b e-a f)(((g x))^(m+1)) (((a+b (x^n)))^(p+1))(((c+d (x^n)))^(q+1)))/(a g n(b c-a d)(p+1)))+(1/(a n(b c-a d)(p+1)))·
∫(((g x))^m) (((a+b (x^n)))^(p+1)) (((c+d (x^n)))^q) (c(b e-a f)(m+1)+e n (b c-a d)(p+1)+d(b e-a f) (m+n (p+q+2)+1) (x^n))dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_*(c_+d_.*x_^n_)^q_*(e_+f_.*x_^n_),x_Symbol] :=
  -(b*e-a*f)*(g*x)^(m+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^(q+1)/(a*g*n*(b*c-a*d)*(p+1)) + 
  1/(a*n*(b*c-a*d)*(p+1))*Int[(g*x)^m*(a+b*x^n)^(p+1)*(c+d*x^n)^q*
    Simp[c*(b*e-a*f)*(m+1)+e*n*(b*c-a*d)*(p+1)+d*(b*e-a*f)*(m+n*(p+q+2)+1)*x^n,x],x] /;
FreeQ[{a,b,c,d,e,f,g,m,n,q},x] && LtQ[p,-1]

2:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when q>0

Derivation: Binomial product recurrence 2b

Rule 1.1.3.6.8.2: If  q>0, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  
((f (((g x))^(m+1)) (((a+b (x^n)))^(p+1))(((c+d (x^n)))^q))/(b g (m+n (p+q+1)+1)))+(1/(b (m+n (p+q+1)+1)))·
∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^(q-1)) (c ((b e-a f) (m+1)+b e n (p+q+1))+(d(b e-a f) (m+1)+f n q(b c-a d)+b e d n (p+q+1)) (x^n))dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_),x_Symbol] :=
  f*(g*x)^(m+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^q/(b*g*(m+n*(p+q+1)+1)) + 
  1/(b*(m+n*(p+q+1)+1))*Int[(g*x)^m*(a+b*x^n)^p*(c+d*x^n)^(q-1)*
    Simp[c*((b*e-a*f)*(m+1)+b*e*n*(p+q+1))+(d*(b*e-a*f)*(m+1)+f*n*q*(b*c-a*d)+b*e*d*n*(p+q+1))*x^n,x],x] /;
FreeQ[{a,b,c,d,e,f,g,m,n,p},x] && GtQ[q,0] && Not[EqQ[q,1] && SimplerQ[e+f*x^n,c+d*x^n]]

3:  ∫(((((g x))^m) (((a+b (x^n)))^p) (e+f (x^n)))/(c+d (x^n)))dx  when b c-a d≠0

Derivation: Algebraic expansion

Rule 1.1.3.6.8.3: If  b c-a d≠0, then

∫(((((g x))^m) (((a+b (x^n)))^p) (e+f (x^n)))/(c+d (x^n)))dx  ⟶  ∫ExpandIntegrand[(((((g x))^m) (((a+b (x^n)))^p) (e+f (x^n)))/(c+d (x^n))),x]dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_*(e_+f_.*x_^n_)/(c_+d_.*x_^n_),x_Symbol] :=
  Int[ExpandIntegrand[(g*x)^m*(a+b*x^n)^p*(e+f*x^n)/(c+d*x^n),x],x] /;
FreeQ[{a,b,c,d,e,f,g,m,n,p},x]

4:  ∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  when b c-a d≠0

Derivation: Algebraic expansion

Rule 1.1.3.6.8.4: If  b c-a d≠0, then

∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q) (e+f (x^n))dx  ⟶  e∫(((g x))^m)(((a+b (x^n)))^p) (((c+d (x^n)))^q)dx+((f (((g x))^m))/(x^m))∫(x^(m+n))(((a+b (x^n)))^p) (((c+d (x^n)))^q)dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_*(c_+d_.*x_^n_)^q_*(e_+f_.*x_^n_),x_Symbol] :=
  e*Int[(g*x)^m*(a+b*x^n)^p*(c+d*x^n)^q,x] + 
  f*(g*x)^m/x^m*Int[x^(m+n)*(a+b*x^n)^p*(c+d*x^n)^q,x] /;
FreeQ[{a,b,c,d,e,f,g,m,n,p,q},x]

9.  ∫(((g x))^m)(((a+b (x^n)))^p)(((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx

1.  ∫(x^m)(((a+b (x^n)))^p)(((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx

1:  ∫(x^m) (((a+b (x^n)))^p) (((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx  when  q∈ℤ

Derivation: Algebraic normalization

Basis: If  q∈ℤ, then (((c+d (x^(-n))))^q)==(x^(-n q))(((d+c (x^n)))^q)

Rule 1.1.3.6.9.1.1: If  q∈ℤ, then

∫(x^m) (((a+b (x^n)))^p) (((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx  ⟶  ∫(x^(m-n q)) (((a+b (x^n)))^p) (((d+c (x^n)))^q) (((e+f (x^n)))^r)dx

Program code:

Int[x_^m_.*(a_+b_.*x_^n_.)^p_.*(c_+d_.*x_^mn_.)^q_.*(e_+f_.*x_^n_.)^r_.,x_Symbol] :=
  Int[x^(m-n*q)*(a+b*x^n)^p*(d+c*x^n)^q*(e+f*x^n)^r,x] /;
FreeQ[{a,b,c,d,e,f,m,n,p,r},x] && EqQ[mn,-n] && IntegerQ[q]

2:  ∫(x^m) (((a+b (x^n)))^p) (((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx  when  p∈ℤ ∧ r∈ℤ

Derivation: Algebraic normalization

Basis: If  p∈ℤ, then (((a+b (x^n)))^p)==(x^(n p)) (((b+a (x^(-n))))^p)

Rule 1.1.3.6.9.2: If  p∈ℤ ∧ r∈ℤ, then

∫(x^m) (((a+b (x^n)))^p) (((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx  ⟶  ∫(x^(m+n (p+r)))(((b+a (x^(-n))))^p) (((c+d (x^(-n))))^q) (((f+e (x^(-n))))^r)dx

Program code:

Int[x_^m_.*(a_.+b_.*x_^n_.)^p_.*(c_+d_.*x_^mn_.)^q_.*(e_+f_.*x_^n_.)^r_.,x_Symbol] :=
  Int[x^(m+n*(p+r))*(b+a*x^(-n))^p*(c+d*x^(-n))^q*(f+e*x^(-n))^r,x] /;
FreeQ[{a,b,c,d,e,f,m,n,q},x] && EqQ[mn,-n] && IntegerQ[p] && IntegerQ[r]

3:  ∫(x^m) (((a+b (x^n)))^p) (((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx  when  q∉ℤ

Derivation: Piecewise constant extraction

Basis: (∂_x)(((x^(n q)) (((c+d (x^(-n))))^q))/(((d+c (x^n)))^q))==0

Basis: (((x^(n q)) (((c+d (x^(-n))))^q))/(((d+c (x^n)))^q))==(((x^(n FracPart[q])) (((c+d (x^(-n))))^(FracPart[q])))/(((d+c (x^n)))^(FracPart[q])))

Rule 1.1.3.6.9.3: If  q∉ℤ, then

∫(x^m) (((a+b (x^n)))^p) (((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx  ⟶  (((x^(n FracPart[q])) (((c+d (x^(-n))))^(FracPart[q])))/(((d+c (x^n)))^(FracPart[q])))∫(x^(m-n q)) (((a+b (x^n)))^p) (((d+c (x^n)))^q) (((e+f (x^n)))^r)dx

Program code:

Int[x_^m_.*(a_.+b_.*x_^n_.)^p_.*(c_+d_.*x_^mn_.)^q_*(e_+f_.*x_^n_.)^r_.,x_Symbol] :=
  x^(n*FracPart[q])*(c+d*x^(-n))^FracPart[q]/(d+c*x^n)^FracPart[q]*Int[x^(m-n*q)*(a+b*x^n)^p*(d+c*x^n)^q*(e+f*x^n)^r,x] /;
FreeQ[{a,b,c,d,e,f,m,n,p,q,r},x] && EqQ[mn,-n] && Not[IntegerQ[q]]

2:  ∫(((g x))^m)(((a+b (x^n)))^p)(((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx

Derivation: Piecewise constant extraction

Basis: (∂_x)((((g x))^m)/(x^m))==0

Basis: ((((g x))^m)/(x^m))==(((g^(IntPart[m]))(((g x))^(FracPart[m])))/(x^(FracPart[m])))

Rule 1.1.3.6.9.2:

∫(((g x))^m)(((a+b (x^n)))^p)(((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx  ⟶  (((g^(IntPart[m]))(((g x))^(FracPart[m])))/(x^(FracPart[m])))∫(x^m)(((a+b (x^n)))^p)(((c+d (x^(-n))))^q) (((e+f (x^n)))^r)dx

Program code:

Int[(g_*x_)^m_*(a_+b_.*x_^n_.)^p_.*(c_+d_.*x_^mn_.)^q_.*(e_+f_.*x_^n_.)^r_.,x_Symbol] :=
  g^IntPart[m]*(g*x)^FracPart[m]/x^FracPart[m]*Int[x^m*(a+b*x^n)^p*(c+d*x^(-n))^q*(e+f*x^n)^r,x] /;
FreeQ[{a,b,c,d,e,f,g,m,n,p,q,r},x] && EqQ[mn,-n]

X:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx

Rule 1.1.3.6.X:

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx  ⟶  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e_+f_.*x_^n_)^r_.,x_Symbol] :=
  Unintegrable[(g*x)^m*(a+b*x^n)^p*(c+d*x^n)^q*(e+f*x^n)^r,x] /;
FreeQ[{a,b,c,d,e,f,g,m,n,p,q,r},x]

S:  ∫(u^m) (((a+b (v^n)))^p) (((c+d (v^n)))^q) (((e+f (v^n)))^r)dx  when  v==h+i x ∧ u==g v

Derivation: Integration by substitution and piecewise constant extraction

Basis: If  u==g v, then (∂_x)((u^m)/(v^m))==0

Rule 1.1.3.6.S: If  v==h+i x ∧ u==g v, then

∫(u^m) (((a+b (v^n)))^p) (((c+d (v^n)))^q) (((e+f (v^n)))^r)dx  ⟶  ((u^m)/(i (v^m)))Subst[∫(x^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) (((e+f (x^n)))^r)dx,x,v]

Program code:

Int[u_^m_.*(a_.+b_.*v_^n_)^p_.*(c_.+d_.*v_^n_)^q_.*(e_+f_.*v_^n_)^r_.,x_Symbol] :=
  u^m/(Coefficient[v,x,1]*v^m)*Subst[Int[x^m*(a+b*x^n)^p*(c+d*x^n)^q*(e+f*x^n)^r,x],x,v] /;
FreeQ[{a,b,c,d,e,f,m,n,p,q,r},x] && LinearPairQ[u,v,x]

Rules for integrands of the form(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) ((((Subscript[e, 1])+(Subscript[f, 1]) (x^(n/2))))^r) ((((Subscript[e, 2])+(Subscript[f, 2]) (x^(n/2))))^r)

1.  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) ((((Subscript[e, 1])+(Subscript[f, 1]) (x^(n/2))))^r) ((((Subscript[e, 2])+(Subscript[f, 2]) (x^(n/2))))^r)dx  when  (Subscript[e, 2]) (Subscript[f, 1])+(Subscript[e, 1]) (Subscript[f, 2])==0

1:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) ((((Subscript[e, 1])+(Subscript[f, 1]) (x^(n/2))))^r) ((((Subscript[e, 2])+(Subscript[f, 2]) (x^(n/2))))^r)dx  when  (Subscript[e, 2]) (Subscript[f, 1])+(Subscript[e, 1]) (Subscript[f, 2])==0 ∧ (r∈ℤ ∨ (Subscript[e, 1])>0 ∧ (Subscript[e, 2])>0)

Derivation: Algebraic simplification

Basis: If  (Subscript[e, 2]) (Subscript[f, 1])+(Subscript[e, 1]) (Subscript[f, 2])==0 ∧ (r∈ℤ ∨ (Subscript[e, 1])>0 ∧ (Subscript[e, 2])>0), then ((((Subscript[e, 1])+(Subscript[f, 1]) (x^(n/2))))^r) ((((Subscript[e, 2])+(Subscript[f, 2]) (x^(n/2))))^r)==((((Subscript[e, 1]) (Subscript[e, 2])+(Subscript[f, 1]) (Subscript[f, 2]) (x^n)))^r)

Rule: If  (Subscript[e, 2]) (Subscript[f, 1])+(Subscript[e, 1]) (Subscript[f, 2])==0 ∧ (r∈ℤ ∨ (Subscript[e, 1])>0 ∧ (Subscript[e, 2])>0), then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) ((((Subscript[e, 1])+(Subscript[f, 1]) (x^(n/2))))^r) ((((Subscript[e, 2])+(Subscript[f, 2]) (x^(n/2))))^r)dx  ⟶  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) ((((Subscript[e, 1]) (Subscript[e, 2])+(Subscript[f, 1]) (Subscript[f, 2]) (x^n)))^r)dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e1_+f1_.*x_^n2_.)^r_.*(e2_+f2_.*x_^n2_.)^r_.,x_Symbol] :=
  Int[(g*x)^m*(a+b*x^n)^p*(c+d*x^n)^q*(e1*e2+f1*f2*x^n)^r,x] /;
FreeQ[{a,b,c,d,e1,f1,e2,f2,g,m,n,p,q,r},x] && EqQ[n2,n/2] && EqQ[e2*f1+e1*f2,0] && (IntegerQ[r] || GtQ[e1,0] && GtQ[e2,0])

2:  ∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) ((((Subscript[e, 1])+(Subscript[f, 1]) (x^(n/2))))^r) ((((Subscript[e, 2])+(Subscript[f, 2]) (x^(n/2))))^r)dx  when  (Subscript[e, 2]) (Subscript[f, 1])+(Subscript[e, 1]) (Subscript[f, 2])==0

Derivation: Piecewise constant extraction

Basis: If  (Subscript[e, 2]) (Subscript[f, 1])+(Subscript[e, 1]) (Subscript[f, 2])==0, then (∂_x)((((((Subscript[e, 1])+(Subscript[f, 1]) (x^(n/2))))^r) ((((Subscript[e, 2])+(Subscript[f, 2]) (x^(n/2))))^r))/((((Subscript[e, 1]) (Subscript[e, 2])+(Subscript[f, 1]) (Subscript[f, 2]) (x^n)))^r))==0

Rule: If  (Subscript[e, 2]) (Subscript[f, 1])+(Subscript[e, 1]) (Subscript[f, 2])==0, then

∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) ((((Subscript[e, 1])+(Subscript[f, 1]) (x^(n/2))))^r) ((((Subscript[e, 2])+(Subscript[f, 2]) (x^(n/2))))^r)dx  ⟶  
((((((Subscript[e, 1])+(Subscript[f, 1]) (x^(n/2))))^(FracPart[r])) ((((Subscript[e, 2])+(Subscript[f, 2]) (x^(n/2))))^(FracPart[r])))/((((Subscript[e, 1]) (Subscript[e, 2])+(Subscript[f, 1]) (Subscript[f, 2]) (x^n)))^(FracPart[r])))∫(((g x))^m) (((a+b (x^n)))^p) (((c+d (x^n)))^q) ((((Subscript[e, 1]) (Subscript[e, 2])+(Subscript[f, 1]) (Subscript[f, 2]) (x^n)))^r)dx

Program code:

Int[(g_.*x_)^m_.*(a_+b_.*x_^n_)^p_.*(c_+d_.*x_^n_)^q_.*(e1_+f1_.*x_^n2_.)^r_.*(e2_+f2_.*x_^n2_.)^r_.,x_Symbol] :=
  (e1+f1*x^(n/2))^FracPart[r]*(e2+f2*x^(n/2))^FracPart[r]/(e1*e2+f1*f2*x^n)^FracPart[r]*
    Int[(g*x)^m*(a+b*x^n)^p*(c+d*x^n)^q*(e1*e2+f1*f2*x^n)^r,x] /;
FreeQ[{a,b,c,d,e1,f1,e2,f2,g,m,n,p,q,r},x] && EqQ[n2,n/2] && EqQ[e2*f1+e1*f2,0]