?.  ∫(((((d x))^m) (e+f (x^(n/4))+g (x^(3 n/4))+h (x^n)))/(((a+c (x^n)))^(3/2)))dx  when 4 m-n+4==0 ∧ c e+a h==0

1:  ∫(((x^m) (e+f (x^(n/4))+g (x^(3 n/4))+h (x^n)))/(((a+c (x^n)))^(3/2)))dx  when 4 m-n+4==0 ∧ c e+a h==0

Rule: If  4 m-n+4==0 ∧ c e+a h==0, then

∫(((x^m) (e+f (x^(n/4))+g (x^(3 n/4))+h (x^n)))/(((a+c (x^n)))^(3/2)))dx  ⟶  -((2 a g+4 a h (x^(n/4))-2 c f (x^(n/2)))/(a c n (Sqrt[a+c (x^n)])))

Program code:

Int[x_^m_.*(e_+f_.*x_^q_.+g_.*x_^r_.+h_.*x_^n_.)/(a_+c_.*x_^n_.)^(3/2),x_Symbol] :=
  -(2*a*g+4*a*h*x^(n/4)-2*c*f*x^(n/2))/(a*c*n*Sqrt[a+c*x^n]) /;
FreeQ[{a,c,e,f,g,h,m,n},x] && EqQ[q,n/4] && EqQ[r,3*n/4] && EqQ[4*m-n+4,0] && EqQ[c*e+a*h,0]

2:  ∫(((((d x))^m) (e+f (x^(n/4))+g (x^(3 n/4))+h (x^n)))/(((a+c (x^n)))^(3/2)))dx  when 4 m-n+4==0 ∧ c e+a h==0

Rule: If  4 m-n+4==0 ∧ c e+a h==0, then

∫(((((d x))^m) (e+f (x^(n/4))+g (x^(3 n/4))+h (x^n)))/(((a+c (x^n)))^(3/2)))dx  ⟶  ((((d x))^m)/(x^m)) ∫(((x^m) (e+f (x^(n/4))+g (x^(3 n/4))+h (x^n)))/(((a+c (x^n)))^(3/2)))dx

Program code:

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

Rules for integrands of the form(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)

1:  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b x))^p)dx  when  p∈𝔽 ∧ m+1∈(SuperMinus[ℤ])

Derivation: Integration by substitution

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

Rule: If  p∈𝔽 ∧ m+1∈(SuperMinus[ℤ]), let n=Denominator[p],  then

∫(((c x))^m) (Subscript[P, q])[x] (((a+b x))^p)dx  ⟶  (n/b) Subst[∫(x^(n p+n-1))(((-((a c)/b)+((c (x^n))/b)))^m) (Subscript[P, q])[-(a/b)+((x^n)/b)]dx,x,(((a+b x))^(1/n))]

Program code:

Int[(c_.*x_)^m_*Pq_*(a_+b_.*x_)^p_,x_Symbol] :=
  With[{n=Denominator[p]},
  n/b*Subst[Int[x^(n*p+n-1)*(-a*c/b+c*x^n/b)^m*ReplaceAll[Pq,x->-a/b+x^n/b],x],x,(a+b*x)^(1/n)]] /;
FreeQ[{a,b,c,m},x] && PolyQ[Pq,x] && FractionQ[p] && ILtQ[m,-1]

2:  ∫(x^m) (Subscript[P, q])[(x^(m+1))] (((a+b (x^n)))^p)dx  when  m≠-1 ∧ (n/(m+1))∈(SuperPlus[ℤ])

Derivation: Integration by substitution

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

Rule: If  m≠-1 ∧ (n/(m+1))∈(SuperPlus[ℤ]), then

∫(x^m) (Subscript[P, q])[(x^(m+1))] (((a+b (x^n)))^p)dx  ⟶  (1/(m+1)) Subst[∫(Subscript[P, q])[x] (((a+b (x^(n/(m+1)))))^p)dx,x,(x^(m+1))]

Program code:

Int[x_^m_.*Pq_*(a_+b_.*x_^n_)^p_.,x_Symbol] :=
  1/(m+1)*Subst[Int[SubstFor[x^(m+1),Pq,x]*(a+b*x^Simplify[n/(m+1)])^p,x],x,x^(m+1)] /;
FreeQ[{a,b,m,n,p},x] && NeQ[m,-1] && IGtQ[Simplify[n/(m+1)],0] && PolyQ[Pq,x^(m+1)]

3:  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when p∈(SuperPlus[ℤ])

Derivation: Algebraic expansion

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

∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  ∫ ExpandIntegrand[(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p),x]dx

Program code:

Int[(c_.*x_)^m_.*Pq_*(a_+b_.*x_^n_.)^p_.,x_Symbol] :=
  Int[ExpandIntegrand[(c*x)^m*Pq*(a+b*x^n)^p,x],x] /;
FreeQ[{a,b,c,m,n},x] && PolyQ[Pq,x] && (IGtQ[p,0] || EqQ[n,1])

4.  ∫(((c x))^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx  when  ((m+1)/n)∈ℤ

1:  ∫(x^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)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 (((c x))^m) automatically evaluates to (c^m)(x^m).

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

∫(x^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx  ⟶  (1/n) Subst[∫(x^(((m+1)/n)-1)) (Subscript[P, q])[x] (((a+b x))^p)dx,x,(x^n)]

Program code:

Int[x_^m_.*Pq_*(a_+b_.*x_^n_)^p_.,x_Symbol] :=
  1/n*Subst[Int[x^(Simplify[(m+1)/n]-1)*SubstFor[x^n,Pq,x]*(a+b*x)^p,x],x,x^n] /;
FreeQ[{a,b,m,n,p},x] && PolyQ[Pq,x^n] && IntegerQ[Simplify[(m+1)/n]]

2:  ∫(((c x))^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx  when  ((m+1)/n)∈ℤ

Derivation: Piecewise constant extraction

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

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

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

∫(((c x))^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx  ⟶  (((c^(IntPart[m]))(((c x))^(FracPart[m])))/(x^(FracPart[m])))∫(x^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx

Program code:

Int[(c_*x_)^m_.*Pq_*(a_+b_.*x_^n_)^p_.,x_Symbol] :=
  c^IntPart[m]*(c*x)^FracPart[m]/x^FracPart[m]*Int[x^m*Pq*(a+b*x^n)^p,x] /;
FreeQ[{a,b,c,m,n,p},x] && PolyQ[Pq,x^n] && IntegerQ[Simplify[(m+1)/n]]

5:  ∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when m-n+1==0 ∧ p<-1

Derivation: Integration by parts

Basis: (x^(n-1)) (((a+b (x^n)))^p)==(∂_x)((((a+b (x^n)))^(p+1))/(b n (p+1)))

Rule: If  m-n+1==0 ∧ p<-1, then

∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  (((Subscript[P, q])[x](((a+b (x^n)))^(p+1)))/(b n(p+1)))-(1/(b n(p+1)))∫(∂_x)(Subscript[P, q])[x](((a+b (x^n)))^(p+1))dx

Program code:

Int[x_^m_.*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  Pq*(a+b*x^n)^(p+1)/(b*n*(p+1)) - 
  1/(b*n*(p+1))*Int[D[Pq,x]*(a+b*x^n)^(p+1),x] /;
FreeQ[{a,b,m,n},x] && PolyQ[Pq,x] && EqQ[m-n+1,0] && LtQ[p,-1]

6:  ∫(((d x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when (Subscript[P, q])[x,0]==0

Derivation: Algebraic simplification

Rule: If  (Subscript[P, q])[x,0]==0, then

∫(((d x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  (1/d) ∫(((d x))^(m+1)) PolynomialQuotient[(Subscript[P, q])[x],x,x] (((a+b (x^n)))^p)dx

Program code:

Int[(d_.*x_)^m_.*Pq_*(a_+b_.*x_^n_.)^p_,x_Symbol] :=
  1/d*Int[(d*x)^(m+1)*PolynomialQuotient[Pq,x,x]*(a+b*x^n)^p,x] /;
FreeQ[{a,b,d,m,n,p},x] && PolyQ[Pq,x] && EqQ[Coeff[Pq,x,0],0]

7.  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈ℤ

1.  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])

1.  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])∧ p>0

1:  ∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])∧ p>0 ∧ m+q+1<0

Derivation: Integration by parts

Rule: If  n∈(SuperPlus[ℤ])∧ p>0 ∧ m+q+1<0, let u=∫(x^m) (Subscript[P, q])[x] dx  then

∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  u (((a+b (x^n)))^p)-b n p ∫(x^(m+n)) (((a+b (x^n)))^(p-1)) (u/(x^(m+1))) dx

Program code:

Int[x_^m_.*Pq_*(a_+b_.*x_^n_.)^p_,x_Symbol] :=
  Module[{u=IntHide[x^m*Pq,x]},
  u*(a+b*x^n)^p - b*n*p*Int[x^(m+n)*(a+b*x^n)^(p-1)*ExpandToSum[u/x^(m+1),x],x]] /;
FreeQ[{a,b},x] && PolyQ[Pq,x] && IGtQ[n,0] && GtQ[p,0] && LtQ[m+Expon[Pq,x]+1,0]

2:  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when ((n-1)/2)∈(SuperPlus[ℤ])∧ p>0

Derivation: Binomial recurrence 1b applied q times

Rule: If  ((n-1)/2)∈(SuperPlus[ℤ])∧ p>0, then

∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  (((c x))^m) (((a+b (x^n)))^p) (∑_(i=0)^q)(((Subscript[P, q])[x,i] (x^(i+1)))/(m+n p+i+1))+a n p ∫(((c x))^m)(((a+b (x^n)))^(p-1)) ((∑_(i=0)^q)(((Subscript[P, q])[x,i] (x^i))/(m+n p+i+1))) dx

Program code:

Int[(c_.*x_)^m_.*Pq_*(a_+b_.*x_^n_.)^p_,x_Symbol] :=
  Module[{q=Expon[Pq,x],i},
  (c*x)^m*(a+b*x^n)^p*Sum[Coeff[Pq,x,i]*x^(i+1)/(m+n*p+i+1),{i,0,q}] + 
  a*n*p*Int[(c*x)^m*(a+b*x^n)^(p-1)*Sum[Coeff[Pq,x,i]*x^i/(m+n*p+i+1),{i,0,q}],x]] /;
FreeQ[{a,b,c,m},x] && PolyQ[Pq,x] && IGtQ[(n-1)/2,0] && GtQ[p,0]

2.  ∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])∧ p<-1 ∧ m∈ℤ

1.  ∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])∧ p<-1 ∧ m∈(SuperPlus[ℤ])

1:  ∫(((x^2) (e+f x+h (x^4)))/(((a+b (x^4)))^(3/2)))dx  when b e-3 a h==0

Rule: If  b e-3 a h==0, then

∫(((x^2) (e+f x+h (x^4)))/(((a+b (x^4)))^(3/2)))dx  ⟶  -((f-2 h (x^3))/(2 b (Sqrt[a+b (x^4)])))

Program code:

Int[x_^2*P4_/(a_+b_.*x_^4)^(3/2),x_Symbol] :=
  With[{e=Coeff[P4,x,0],f=Coeff[P4,x,1],h=Coeff[P4,x,4]},
  -(f-2*h*x^3)/(2*b*Sqrt[a+b*x^4]) /;
 EqQ[b*e-3*a*h,0]] /;
FreeQ[{a,b},x] && PolyQ[P4,x,4] && EqQ[Coeff[P4,x,2],0] && EqQ[Coeff[P4,x,3],0]

2:  ∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])∧ p<-1 ∧ m∈(SuperPlus[ℤ])∧ m+q≥n

Derivation: Algebraic expansion and binomial recurrence 2b applied n-1 times

Note: (∑_(i=0)^q)(i+1) (Subscript[P, q])[x,i] (x^i)==(∂_x)(x (Subscript[P, q])[x]) contributed by Martin Welz on 5 June 2015

Rule: If  n∈(SuperPlus[ℤ])∧ p<-1 ∧ m∈(SuperPlus[ℤ])∧ m+q≥n, let (Subscript[Q, m+q-n])[x]->PolynomialQuotient[(x^m) (Subscript[P, q])[x],a+b (x^n),x] and (Subscript[R, n-1])[x]->PolynomialRemainder[(x^m) (Subscript[P, q])[x],a+b (x^n),x], then

∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  

∫(Subscript[R, n-1])[x] (((a+b (x^n)))^p)dx+∫(Subscript[Q, m+q-n])[x] (((a+b (x^n)))^(p+1))dx  ⟶  

-((x (Subscript[R, n-1])[x] (((a+b (x^n)))^(p+1)))/(a n(p+1)))+(1/(a n(p+1)))∫(a n(p+1) (Subscript[Q, m+q-n])[x]+n (p+1) (Subscript[R, n-1])[x]+(∂_x)(x (Subscript[R, n-1])[x])) (((a+b (x^n)))^(p+1)) dx

Program code:

Int[x_^m_.*Pq_*(a_+b_.*x_^n_.)^p_,x_Symbol] :=
  With[{q=m+Expon[Pq,x]},
    Module[{Q=PolynomialQuotient[b^(Floor[(q-1)/n]+1)*x^m*Pq,a+b*x^n,x],
            R=PolynomialRemainder[b^(Floor[(q-1)/n]+1)*x^m*Pq,a+b*x^n,x]},
    -x*R*(a+b*x^n)^(p+1)/(a*n*(p+1)*b^(Floor[(q-1)/n]+1)) + 
    1/(a*n*(p+1)*b^(Floor[(q-1)/n]+1))*Int[(a+b*x^n)^(p+1)*ExpandToSum[a*n*(p+1)*Q+n*(p+1)*R+D[x*R,x],x],x]] /;
  GeQ[q,n]] /;
FreeQ[{a,b},x] && PolyQ[Pq,x] && IGtQ[n,0] && LtQ[p,-1] && IGtQ[m,0]

2:  ∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])∧ p<-1 ∧ m∈(SuperMinus[ℤ])

Derivation: Algebraic expansion and binomial recurrence 2b applied n-1 times

Rule: If  n∈(SuperPlus[ℤ])∧ p<-1 ∧ m∈(SuperMinus[ℤ]), let (Subscript[Q, q-n])[x]=PolynomialQuotient[(x^m) (Subscript[P, q])[x],a+b (x^n),x] and (Subscript[R, n-1])[x]=PolynomialRemainder[(x^m) (Subscript[P, q])[x],a+b (x^n),x], then

∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  

∫(Subscript[R, n-1])[x] (((a+b (x^n)))^p)dx+∫(Subscript[Q, q-n])[x] (((a+b (x^n)))^(p+1))dx  ⟶  

-((x (Subscript[R, n-1])[x] (((a+b (x^n)))^(p+1)))/(a n(p+1)))+(1/(a n(p+1)))∫(x^m) (a n(p+1) (x^(-m)) (Subscript[Q, q-n])[x]+(∑_(i=0)^(n-1))(n (p+1)+i+1) (Subscript[R, n-1])[x,i] (x^(i-m))) (((a+b (x^n)))^(p+1)) dx

Program code:

Int[x_^m_*Pq_*(a_+b_.*x_^n_.)^p_,x_Symbol] :=
  With[{q=Expon[Pq,x]},
  Module[{Q=PolynomialQuotient[a*b^(Floor[(q-1)/n]+1)*x^m*Pq,a+b*x^n,x],
          R=PolynomialRemainder[a*b^(Floor[(q-1)/n]+1)*x^m*Pq,a+b*x^n,x],i},
    -x*R*(a+b*x^n)^(p+1)/(a^2*n*(p+1)*b^(Floor[(q-1)/n]+1)) + 
    1/(a*n*(p+1)*b^(Floor[(q-1)/n]+1))*Int[x^m*(a+b*x^n)^(p+1)*
      ExpandToSum[n*(p+1)*x^(-m)*Q+Sum[(n*(p+1)+i+1)/a*Coeff[R,x,i]*x^(i-m),{i,0,n-1}],x],x]]] /;
FreeQ[{a,b},x] && PolyQ[Pq,x] && IGtQ[n,0] && LtQ[p,-1] && ILtQ[m,0]

3:  ∫(x^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])∧ m∈ℤ ∧ GCD[m+1,n]≠1

Derivation: Integration by substitution

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

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

∫(x^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx  ⟶  (1/g) Subst[∫(x^(((m+1)/g)-1)) (Subscript[P, q])[(x^(n/g))] (((a+b (x^(n/g))))^p)dx,x,(x^g)]

Program code:

Int[x_^m_.*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  With[{g=GCD[m+1,n]},
  1/g*Subst[Int[x^((m+1)/g-1)*ReplaceAll[Pq,x->x^(1/g)]*(a+b*x^(n/g))^p,x],x,x^g] /;
 g≠1] /;
FreeQ[{a,b,p},x] && PolyQ[Pq,x^n] && IGtQ[n,0] && IntegerQ[m]

4:  ∫(((((c x))^m) (Subscript[P, q])[x])/(a+b (x^n)))dx  when (n/2)∈(SuperPlus[ℤ])∧ q<n

Derivation: Algebraic expansion

Basis: If  (n/2)∈ℤ ∧ q<n, then (Subscript[P, q])[x]==(∑_(i=0)^(n-1))(x^i)(Subscript[P, q])[x,i]==(∑_(i=0)^(n/2-1))(x^i)((Subscript[P, q])[x,i]+(Subscript[P, q])[x,(n/2)+i](x^(n/2)))

Note: The resulting integrands are of the form (((((c x))^q) (r+s (x^(n/2))))/(a+b (x^n))) for which there are rules.

Rule: If  (n/2)∈(SuperPlus[ℤ])∧ q<n, then

∫(((((c x))^m) (Subscript[P, q])[x])/(a+b (x^n)))dx  ⟶  ∫ (∑_(i=0)^(n/2-1))(((((c x))^(m+i)) ((Subscript[P, q])[x,i]+(Subscript[P, q])[x,(n/2)+i] (x^(n/2))))/((c^i) (a+b (x^n))))dx

Program code:

Int[(c_.*x_)^m_.*Pq_/(a_+b_.*x_^n_),x_Symbol] :=
  With[{v=Sum[(c*x)^(m+ii)*(Coeff[Pq,x,ii]+Coeff[Pq,x,n/2+ii]*x^(n/2))/(c^ii*(a+b*x^n)),{ii,0,n/2-1}]},
  Int[v,x] /;
 SumQ[v]] /;
FreeQ[{a,b,c,m},x] && PolyQ[Pq,x] && IGtQ[n/2,0] && Expon[Pq,x]<n

5:  ∫(((Subscript[P, q])[x])/(x (Sqrt[a+b (x^n)])))dx  when n∈(SuperPlus[ℤ])∧ (Subscript[P, q])[x,0]≠0

Derivation: Algebraic expansion

Rule: If  n∈(SuperPlus[ℤ])∧ (Subscript[P, q])[x,0]≠0, then

∫(((Subscript[P, q])[x])/(x (Sqrt[a+b (x^n)])))dx  ⟶  (Subscript[P, q])[x,0] ∫(1/(x(Sqrt[a+b (x^n)])))dx+∫(((Subscript[P, q])[x]-(Subscript[P, q])[x,0])/x)(1/(Sqrt[a+b (x^n)]))dx

Program code:

Int[Pq_/(x_*Sqrt[a_+b_.*x_^n_]),x_Symbol] :=
  Coeff[Pq,x,0]*Int[1/(x*Sqrt[a+b*x^n]),x] + 
  Int[ExpandToSum[(Pq-Coeff[Pq,x,0])/x,x]/Sqrt[a+b*x^n],x] /;
FreeQ[{a,b},x] && PolyQ[Pq,x] && IGtQ[n,0] && NeQ[Coeff[Pq,x,0],0]

6:  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when (n/2)∈(SuperPlus[ℤ])∧ ¬PolynomialQ[(Subscript[P, q])[x],(x^(n/2))]

Derivation: Algebraic expansion

Basis: If  n∈(SuperPlus[ℤ]) , then (Subscript[P, q])[x]==(∑_(j=0)^(n-1))(x^j)(∑_(k=0)^((q-j)/n+1))(Subscript[P, q])[x,j+k n] (x^(k n))

Note: This rule transform integrand into a sum of terms of the form (x^k) (Subscript[Q, r])[(x^(n/2))] (((a+b (x^n)))^p).

Rule: If  (n/2)∈(SuperPlus[ℤ])∧ ¬PolynomialQ[(Subscript[P, q])[x],(x^(n/2))], then

∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  ∫ (∑_(j=0)^((n/2)-1))((((c x))^(m+j))/(c^j))((∑_(k=0)^(((2 (q-j))/n)+1))(Subscript[P, q])[x,j+((k n)/2)] (x^((k n)/2)))(((a+b (x^n)))^p)dx

Program code:

Int[(c_.*x_)^m_.*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  Module[{q=Expon[Pq,x],j,k},
  Int[Sum[(c*x)^(m+j)/c^j*Sum[Coeff[Pq,x,j+k*n/2]*x^(k*n/2),{k,0,2*(q-j)/n+1}]*(a+b*x^n)^p,{j,0,n/2-1}],x]] /;
FreeQ[{a,b,c,m,p},x] && PolyQ[Pq,x] && IGtQ[n/2,0] && Not[PolyQ[Pq,x^(n/2)]]

7:  ∫(((((c x))^m) (Subscript[P, q])[x])/(a+b (x^n)))dx  when n∈(SuperPlus[ℤ])

Derivation: Algebraic expansion

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

∫(((((c x))^m) (Subscript[P, q])[x])/(a+b (x^n)))dx  ⟶  ∫ ExpandIntegrand[(((((c x))^m) (Subscript[P, q])[x])/(a+b (x^n))),x]dx

Program code:

Int[(c_.*x_)^m_.*Pq_/(a_+b_.*x_^n_),x_Symbol] :=
  Int[ExpandIntegrand[(c*x)^m*Pq/(a+b*x^n),x],x] /;
FreeQ[{a,b,c,m},x] && PolyQ[Pq,x] && IntegerQ[n] && Not[IGtQ[m,0]]

8.  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])∧ q-n≥-1

1:  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])∧ q-n≥-1 ∧ m<-1 ∧ (Subscript[P, q])[x,0]≠0

Derivation: Algebraic expansion and binomial recurrence 3b

Note: This rule increments m and decrements the degree of the polynomial in the resulting integrand if  n-1<q.

Rule: If  n∈(SuperPlus[ℤ])∧ m<-1 ∧ n-1≤q ∧ (Subscript[P, q])[x,0]≠0, then

∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  

(Subscript[P, q])[x,0]∫(((c x))^m)(((a+b (x^n)))^p)dx+(1/c) ∫(((c x))^(m+1)) (((Subscript[P, q])[x]-(Subscript[P, q])[x,0])/x)(((a+b (x^n)))^p)dx  ⟶  

(((Subscript[P, q])[x,0] (((c x))^(m+1)) (((a+b (x^n)))^(p+1)))/(a c (m+1)))+(1/(2 a c (m+1)))∫(((c x))^(m+1))(2 a (m+1) (((Subscript[P, q])[x]-(Subscript[P, q])[x,0])/x)-2 b (Subscript[P, q])[x,0] (m+n(p+1)+1) (x^(n-1))) (((a+b (x^n)))^p)dx

Program code:

Int[(c_.*x_)^m_*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  With[{Pq0=Coeff[Pq,x,0]},
    Pq0*(c*x)^(m+1)*(a+b*x^n)^(p+1)/(a*c*(m+1)) + 
    1/(2*a*c*(m+1))*Int[(c*x)^(m+1)*ExpandToSum[2*a*(m+1)*(Pq-Pq0)/x-2*b*Pq0*(m+n*(p+1)+1)*x^(n-1),x]*(a+b*x^n)^p,x] /;
 NeQ[Pq0,0]] /;
FreeQ[{a,b,c,p},x] && PolyQ[Pq,x] && IGtQ[n,0] && LtQ[m,-1] && LeQ[n-1,Expon[Pq,x]]

2:  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when n∈(SuperPlus[ℤ])∧ q-n≥0 ∧ m+q+n p+1≠0

Reference: G&R 2.110.5, CRC 88a

Derivation: Algebraic expansion and binomial recurrence 3a

Reference: G&R 2.104

Note: This rule reduces the degree of the polynomial in the resulting integrand.

Rule: If  n∈(SuperPlus[ℤ])∧ m+q+n p+1≠0 ∧ q-n≥0, then

∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  

(((Subscript[P, q])[x,q])/(c^q))∫(((c x))^(m+q))(((a+b (x^n)))^p)+∫(((c x))^m) ((Subscript[P, q])[x]-(Subscript[P, q])[x,q] (x^q))(((a+b (x^n)))^p)dxdx  ⟶  

(((Subscript[P, q])[x,q] (((c x))^(m+q-n+1)) (((a+b (x^n)))^(p+1)))/(b (c^(q-n+1)) (m+q+n p+1)))+
(1/(b (m+q+n p+1)))∫(((c x))^m)(b (m+q+n p+1) ((Subscript[P, q])[x]-(Subscript[P, q])[x,q] (x^q))-a (Subscript[P, q])[x,q] (m+q-n+1)(x^(q-n))) (((a+b (x^n)))^p)dx

Program code:

Int[(c_.*x_)^m_.*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  With[{q=Expon[Pq,x]},
    With[{Pqq=Coeff[Pq,x,q]},
    Pqq*(c*x)^(m+q-n+1)*(a+b*x^n)^(p+1)/(b*c^(q-n+1)*(m+q+n*p+1)) + 
    1/(b*(m+q+n*p+1))*Int[(c*x)^m*ExpandToSum[b*(m+q+n*p+1)*(Pq-Pqq*x^q)-a*Pqq*(m+q-n+1)*x^(q-n),x]*(a+b*x^n)^p,x]] /;
  NeQ[m+q+n*p+1,0] && q-n≥0 && (IntegerQ[2*p] || IntegerQ[p+(q+1)/(2*n)])] /;
FreeQ[{a,b,c,m,p},x] && PolyQ[Pq,x] && IGtQ[n,0]

2.  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when  n∈(SuperMinus[ℤ])

1.  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when  n∈(SuperMinus[ℤ])∧ m∈ℚ

1:  ∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when  n∈(SuperMinus[ℤ])∧ m∈ℤ

Derivation: Integration by substitution

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

Note: (x^q) (Subscript[P, q])[(x^(-1))] is a polynomial in x.

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

∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  -Subst[∫(((x^q) (Subscript[P, q])[(x^(-1))] (((a+b (x^(-n))))^p))/(x^(m+q+2)))dx,x,(1/x)]

Program code:

Int[x_^m_.*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  With[{q=Expon[Pq,x]},
  -Subst[Int[ExpandToSum[x^q*ReplaceAll[Pq,x->x^(-1)],x]*(a+b*x^(-n))^p/x^(m+q+2),x],x,1/x]] /;
FreeQ[{a,b,p},x] && PolyQ[Pq,x] && ILtQ[n,0] && IntegerQ[m]

2:  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when  n∈(SuperMinus[ℤ])∧ m∈𝔽

Derivation: Integration by substitution

Basis: If  g>1, then (((c x))^m) F[x]==-(g/c)Subst[ ((F[(c^(-1)) (x^(-g))])/(x^(g (m+1)+1))),x,(1/(((c x))^(1/g)))] (∂_x)(1/(((c x))^(1/g)))

Note: (x^(g q)) (Subscript[P, q])[(c^(-1)) (x^(-g))] is a polynomial in x.

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

∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  -(g/c)Subst[∫(((x^(g q)) (Subscript[P, q])[(c^(-1)) (x^(-g))] (((a+b (c^(-n)) (x^(-g n))))^p))/(x^(g (m+q+1)+1)))dx,x,(1/(((c x))^(1/g)))]

Program code:

Int[(c_.*x_)^m_.*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  With[{g=Denominator[m],q=Expon[Pq,x]},
  -g/c*Subst[Int[ExpandToSum[x^(g*q)*ReplaceAll[Pq,x->c^(-1)*x^(-g)],x]*
    (a+b*c^(-n)*x^(-g*n))^p/x^(g*(m+q+1)+1),x],x,1/(c*x)^(1/g)]] /;
FreeQ[{a,b,c,p},x] && PolyQ[Pq,x] && ILtQ[n,0] && FractionQ[m]

2:  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when  n∈(SuperMinus[ℤ])∧ m∉ℚ

Derivation:  Piecewise constant extraction and integration by substitution

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

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

Note: (x^q) (Subscript[P, q])[(x^(-1))] is a polynomial in x.

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

∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  (((c x))^m) ((((x^(-1))))^m)∫(((Subscript[P, q])[x] (((a+b (x^n)))^p))/((((x^(-1))))^m))dx
  ⟶  -(((c x))^m) ((((x^(-1))))^m) Subst[∫(((x^q) (Subscript[P, q])[(x^(-1))] (((a+b (x^(-n))))^p))/(x^(m+q+2)))dx,x,(1/x)]

Program code:

Int[(c_.*x_)^m_*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  With[{q=Expon[Pq,x]},
  -(c*x)^m*(x^(-1))^m*Subst[Int[ExpandToSum[x^q*ReplaceAll[Pq,x->x^(-1)],x]*(a+b*x^(-n))^p/x^(m+q+2),x],x,1/x]] /;
FreeQ[{a,b,c,m,p},x] && PolyQ[Pq,x] && ILtQ[n,0] && Not[RationalQ[m]]

8.  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when  n∈𝔽

1:  ∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when  n∈𝔽

Derivation: Integration by substitution

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

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

∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  g Subst[∫(x^(g(m+1)-1)) (Subscript[P, q])[(x^g)] (((a+b (x^(g n))))^p)dx,x,(x^(1/g))]

Program code:

Int[x_^m_.*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  With[{g=Denominator[n]},
  g*Subst[Int[x^(g*(m+1)-1)*ReplaceAll[Pq,x->x^g]*(a+b*x^(g*n))^p,x],x,x^(1/g)]] /;
FreeQ[{a,b,m,p},x] && PolyQ[Pq,x] && FractionQ[n]

2:  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  when  n∈𝔽

Derivation: Piecewise constant extraction

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

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

Rule: If  n∈𝔽, then

∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  (((c^(IntPart[m]))(((c x))^(FracPart[m])))/(x^(FracPart[m])))∫(x^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx

Program code:

Int[(c_*x_)^m_*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  c^IntPart[m]*(c*x)^FracPart[m]/x^FracPart[m]*Int[x^m*Pq*(a+b*x^n)^p,x] /;
FreeQ[{a,b,c,m,p},x] && PolyQ[Pq,x] && FractionQ[n]

9.  ∫(((c x))^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx  when  (n/(m+1))∈ℤ

1:  ∫(x^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)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: If  (n/(m+1))∈ℤ

∫(x^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx  ⟶  (1/(m+1))Subst[∫(Subscript[P, q])[(x^(n/(m+1)))] (((a+b (x^(n/(m+1)))))^p)dx,x,(x^(m+1))]

Program code:

Int[x_^m_.*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  1/(m+1)*Subst[Int[ReplaceAll[SubstFor[x^n,Pq,x],x->x^Simplify[n/(m+1)]]*(a+b*x^Simplify[n/(m+1)])^p,x],x,x^(m+1)] /;
FreeQ[{a,b,m,n,p},x] && PolyQ[Pq,x^n] && IntegerQ[Simplify[n/(m+1)]] && Not[IntegerQ[n]]

2:  ∫(((c x))^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx  when  (n/(m+1))∈ℤ

Derivation: Piecewise constant extraction

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

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

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

∫(((c x))^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx  ⟶  (((c^(IntPart[m]))(((c x))^(FracPart[m])))/(x^(FracPart[m])))∫(x^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx

Program code:

Int[(c_*x_)^m_*Pq_*(a_+b_.*x_^n_)^p_,x_Symbol] :=
  c^IntPart[m]*(c*x)^FracPart[m]/x^FracPart[m]*Int[x^m*Pq*(a+b*x^n)^p,x] /;
FreeQ[{a,b,c,m,n,p},x] && PolyQ[Pq,x^n] && IntegerQ[Simplify[n/(m+1)]] && Not[IntegerQ[n]]

10:  ∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx

Derivation: Algebraic expansion

Rule:

∫(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p)dx  ⟶  ∫ ExpandIntegrand[(((c x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p),x]dx

Program code:

Int[(c_.*x_)^m_.*Pq_*(a_+b_.*x_^n_)^p_.,x_Symbol] :=
  Int[ExpandIntegrand[(c*x)^m*Pq*(a+b*x^n)^p,x],x] /;
FreeQ[{a,b,c,m,n,p},x] && (PolyQ[Pq,x] || PolyQ[Pq,x^n]) && Not[IGtQ[m,0]]

S:  ∫(u^m) (Subscript[P, q])[(v^n)] (((a+b (v^n)))^p)dx  when  v==f+g x ∧ u==h v

Derivation: Integration by substitution and piecewise constant extraction

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

Rule: If  v==f+g x ∧ u==h v, then

∫(u^m) (Subscript[P, q])[(v^n)] (((a+b (v^n)))^p)dx  ⟶  ((u^m)/(g (v^m)))Subst[∫(x^m) (Subscript[P, q])[(x^n)] (((a+b (x^n)))^p)dx,x,v]

Program code:

Int[u_^m_.*Pq_*(a_+b_.*v_^n_.)^p_,x_Symbol] :=
  u^m/(Coeff[v,x,1]*v^m)*Subst[Int[x^m*SubstFor[v,Pq,x]*(a+b*x^n)^p,x],x,v] /;
FreeQ[{a,b,m,n,p},x] && LinearPairQ[u,v,x] && PolyQ[Pq,v^n]

Rules for integrands of the form(((h x))^m) (Subscript[P, q])[x] (((a+b (x^n)))^p) (((c+d (x^n)))^q)

1.  ∫(((c x))^m) (Subscript[P, q])[x] ((((Subscript[a, 1])+(Subscript[b, 1]) (x^n)))^p) ((((Subscript[a, 2])+(Subscript[b, 2]) (x^n)))^p)dx  when  (Subscript[a, 2]) (Subscript[b, 1])+(Subscript[a, 1]) (Subscript[b, 2])==0

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

Derivation: Algebraic simplification

Basis: If  (Subscript[a, 2]) (Subscript[b, 1])+(Subscript[a, 1]) (Subscript[b, 2])==0 ∧ (p∈ℤ ∨ (Subscript[a, 1])>0 ∧ (Subscript[a, 2])>0), then ((((Subscript[a, 1])+(Subscript[b, 1]) (x^n)))^p) ((((Subscript[a, 2])+(Subscript[b, 2]) (x^n)))^p)==((((Subscript[a, 1]) (Subscript[a, 2])+(Subscript[b, 1]) (Subscript[b, 2]) (x^(2 n))))^p)

Rule: If  (Subscript[a, 2]) (Subscript[b, 1])+(Subscript[a, 1]) (Subscript[b, 2])==0 ∧ (p∈ℤ ∨ (Subscript[a, 1])>0 ∧ (Subscript[a, 2])>0), then

∫(((c x))^m) (Subscript[P, q])[x] ((((Subscript[a, 1])+(Subscript[b, 1]) (x^n)))^p) ((((Subscript[a, 2])+(Subscript[b, 2]) (x^n)))^p)dx  ⟶  ∫(((c x))^m) (Subscript[P, q])[x] ((((Subscript[a, 1]) (Subscript[a, 2])+(Subscript[b, 1]) (Subscript[b, 2]) (x^(2 n))))^p)dx

Program code:

Int[(c_.*x_)^m_.*Pq_*(a1_+b1_.*x_^n_.)^p_.*(a2_+b2_.*x_^n_.)^p_.,x_Symbol] :=
  Int[(c*x)^m*Pq*(a1*a2+b1*b2*x^(2*n))^p,x] /;
FreeQ[{a1,b1,a2,b2,c,m,n,p},x] && PolyQ[Pq,x] && EqQ[a2*b1+a1*b2,0] && (IntegerQ[p] || GtQ[a1,0] && GtQ[a2,0])

2:  ∫(((c x))^m) (Subscript[P, q])[x] ((((Subscript[a, 1])+(Subscript[b, 1]) (x^n)))^p) ((((Subscript[a, 2])+(Subscript[b, 2]) (x^n)))^p)dx  when  (Subscript[a, 2]) (Subscript[b, 1])+(Subscript[a, 1]) (Subscript[b, 2])==0

Derivation: Piecewise constant extraction

Basis: If  (Subscript[a, 2]) (Subscript[b, 1])+(Subscript[a, 1]) (Subscript[b, 2])==0, then (∂_x)((((((Subscript[a, 1])+(Subscript[b, 1]) (x^n)))^p) ((((Subscript[a, 2])+(Subscript[b, 2]) (x^n)))^p))/((((Subscript[a, 1]) (Subscript[a, 2])+(Subscript[b, 1]) (Subscript[b, 2]) (x^(2 n))))^p))==0

Rule: If  (Subscript[a, 2]) (Subscript[b, 1])+(Subscript[a, 1]) (Subscript[b, 2])==0, then

∫(((c x))^m) (Subscript[P, q])[x] ((((Subscript[a, 1])+(Subscript[b, 1]) (x^n)))^p) ((((Subscript[a, 2])+(Subscript[b, 2]) (x^n)))^p)dx  ⟶  ((((((Subscript[a, 1])+(Subscript[b, 1]) (x^n)))^(FracPart[p])) ((((Subscript[a, 2])+(Subscript[b, 2]) (x^n)))^(FracPart[p])))/((((Subscript[a, 1]) (Subscript[a, 2])+(Subscript[b, 1]) (Subscript[b, 2]) (x^(2 n))))^(FracPart[p])))∫(((c x))^m) (Subscript[P, q])[x] ((((Subscript[a, 1]) (Subscript[a, 2])+(Subscript[b, 1]) (Subscript[b, 2]) (x^(2 n))))^p)dx

Program code:

Int[(c_.*x_)^m_.*Pq_*(a1_+b1_.*x_^n_.)^p_.*(a2_+b2_.*x_^n_.)^p_.,x_Symbol] :=
  (a1+b1*x^n)^FracPart[p]*(a2+b2*x^n)^FracPart[p]/(a1*a2+b1*b2*x^(2*n))^FracPart[p]*
    Int[(c*x)^m*Pq*(a1*a2+b1*b2*x^(2*n))^p,x] /;
FreeQ[{a1,b1,a2,b2,c,m,n,p},x] && PolyQ[Pq,x] && EqQ[a2*b1+a1*b2,0] && Not[EqQ[n,1] && LinearQ[Pq,x]]

2:  ∫(((h x))^m) (e+f (x^n)+g (x^(2 n))) (((a+b (x^n)))^p) (((c+d (x^n)))^p)dx  when a c f (m+1)==e (b c+a d) (m+n(p+1)+1)∧ a c g (m+1)==b d e (m+2 n (p+1)+1)∧ m≠-1

Rule: If  a c f (m+1)==e (b c+a d) (m+n(p+1)+1)∧ a c g (m+1)==b d e (m+2 n (p+1)+1)∧ m≠-1, then

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

Program code:

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

Int[(h_.*x_)^m_.*(e_+g_.*x_^n2_.)*(a_+b_.*x_^n_.)^p_.*(c_+d_.*x_^n_.)^p_.,x_Symbol] :=
  e*(h*x)^(m+1)*(a+b*x^n)^(p+1)*(c+d*x^n)^(p+1)/(a*c*h*(m+1)) /;
FreeQ[{a,b,c,d,e,g,h,m,n,p},x] && EqQ[n2,2*n] && EqQ[m+n*(p+1)+1,0] && EqQ[a*c*g*(m+1)-b*d*e*(m+2*n*(p+1)+1),0] && 
  NeQ[m,-1]