\(\int (a g+b g x)^{-2-m} (c i+d i x)^m (A+B \log (e (a+b x)^n (c+d x)^{-n}))^p \, dx\) [227]

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

Optimal result

Integrand size = 50, antiderivative size = 194 \[ \int (a g+b g x)^{-2-m} (c i+d i x)^m \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^p \, dx=-\frac {e^{\frac {A (1+m)}{B n}} (a+b x) (g (a+b x))^{-2-m} (i (c+d x))^{2+m} \left (e (a+b x)^n (c+d x)^{-n}\right )^{\frac {1+m}{n}} \Gamma \left (1+p,\frac {(1+m) \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )}{B n}\right ) \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^p \left (\frac {(1+m) \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )}{B n}\right )^{-p}}{(b c-a d) i^2 (1+m) (c+d x)} \] Output:

-exp(A*(1+m)/B/n)*(b*x+a)*(g*(b*x+a))^(-2-m)*(i*(d*x+c))^(2+m)*(e*(b*x+a)^ 
n/((d*x+c)^n))^((1+m)/n)*GAMMA(p+1,(1+m)*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n))) 
/B/n)*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))^p/(-a*d+b*c)/i^2/(1+m)/(d*x+c)/((( 
1+m)*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))/B/n)^p)
                                                                                    
                                                                                    
 

Mathematica [F]

\[ \int (a g+b g x)^{-2-m} (c i+d i x)^m \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^p \, dx=\int (a g+b g x)^{-2-m} (c i+d i x)^m \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^p \, dx \] Input:

Integrate[(a*g + b*g*x)^(-2 - m)*(c*i + d*i*x)^m*(A + B*Log[(e*(a + b*x)^n 
)/(c + d*x)^n])^p,x]
 

Output:

Integrate[(a*g + b*g*x)^(-2 - m)*(c*i + d*i*x)^m*(A + B*Log[(e*(a + b*x)^n 
)/(c + d*x)^n])^p, x]
 

Rubi [A] (warning: unable to verify)

Time = 0.80 (sec) , antiderivative size = 190, normalized size of antiderivative = 0.98, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.080, Rules used = {2973, 2963, 2747, 2612}

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 (a g+b g x)^{-m-2} (c i+d i x)^m \left (B \log \left (e (a+b x)^n (c+d x)^{-n}\right )+A\right )^p \, dx\)

\(\Big \downarrow \) 2973

\(\displaystyle \int (a g+b g x)^{-m-2} (c i+d i x)^m \left (B \log \left (e (a+b x)^n (c+d x)^{-n}\right )+A\right )^pdx\)

\(\Big \downarrow \) 2963

\(\displaystyle \frac {(g (a+b x))^{-m-2} (i (c+d x))^{m+2} \left (\frac {a+b x}{c+d x}\right )^{m+2} \int \left (\frac {a+b x}{c+d x}\right )^{-m-2} \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^pd\frac {a+b x}{c+d x}}{i^2 (b c-a d)}\)

\(\Big \downarrow \) 2747

\(\displaystyle \frac {(a+b x) (g (a+b x))^{-m-2} (i (c+d x))^{m+2} \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )^{\frac {m+1}{n}} \int \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )^{-\frac {m+1}{n}} \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^pd\log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )}{i^2 n (c+d x) (b c-a d)}\)

\(\Big \downarrow \) 2612

\(\displaystyle -\frac {(a+b x) e^{\frac {A (m+1)}{B n}} (g (a+b x))^{-m-2} (i (c+d x))^{m+2} \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )^{\frac {m+1}{n}} \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )^p \left (\frac {(m+1) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{B n}\right )^{-p} \Gamma \left (p+1,\frac {(m+1) \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )}{B n}\right )}{i^2 (m+1) (c+d x) (b c-a d)}\)

Input:

Int[(a*g + b*g*x)^(-2 - m)*(c*i + d*i*x)^m*(A + B*Log[(e*(a + b*x)^n)/(c + 
 d*x)^n])^p,x]
 

Output:

-((E^((A*(1 + m))/(B*n))*(a + b*x)*(g*(a + b*x))^(-2 - m)*(e*((a + b*x)/(c 
 + d*x))^n)^((1 + m)/n)*(i*(c + d*x))^(2 + m)*Gamma[1 + p, ((1 + m)*(A + B 
*Log[e*((a + b*x)/(c + d*x))^n]))/(B*n)]*(A + B*Log[e*((a + b*x)/(c + d*x) 
)^n])^p)/((b*c - a*d)*i^2*(1 + m)*(c + d*x)*(((1 + m)*(A + B*Log[e*((a + b 
*x)/(c + d*x))^n]))/(B*n))^p))
 

Defintions of rubi rules used

rule 2612
Int[(F_)^((g_.)*((e_.) + (f_.)*(x_)))*((c_.) + (d_.)*(x_))^(m_), x_Symbol] 
:> Simp[(-F^(g*(e - c*(f/d))))*((c + d*x)^FracPart[m]/(d*((-f)*g*(Log[F]/d) 
)^(IntPart[m] + 1)*((-f)*g*Log[F]*((c + d*x)/d))^FracPart[m]))*Gamma[m + 1, 
 ((-f)*g*(Log[F]/d))*(c + d*x)], x] /; FreeQ[{F, c, d, e, f, g, m}, x] && 
!IntegerQ[m]
 

rule 2747
Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_)*((d_.)*(x_))^(m_.), x_Symbol 
] :> Simp[(d*x)^(m + 1)/(d*n*(c*x^n)^((m + 1)/n))   Subst[Int[E^(((m + 1)/n 
)*x)*(a + b*x)^p, x], x, Log[c*x^n]], x] /; FreeQ[{a, b, c, d, m, n, p}, x]
 

rule 2963
Int[((A_.) + Log[(e_.)*(((a_.) + (b_.)*(x_))/((c_.) + (d_.)*(x_)))^(n_.)]*( 
B_.))^(p_.)*((f_.) + (g_.)*(x_))^(m_.)*((h_.) + (i_.)*(x_))^(q_.), x_Symbol 
] :> Simp[d^2*((g*((a + b*x)/b))^m/(i^2*(b*c - a*d)*(i*((c + d*x)/d))^m*((a 
 + b*x)/(c + d*x))^m))   Subst[Int[x^m*(A + B*Log[e*x^n])^p, x], x, (a + b* 
x)/(c + d*x)], x] /; FreeQ[{a, b, c, d, e, f, g, h, i, A, B, m, n, p, q}, x 
] && NeQ[b*c - a*d, 0] && EqQ[b*f - a*g, 0] && EqQ[d*h - c*i, 0] && EqQ[m + 
 q + 2, 0]
 

rule 2973
Int[((A_.) + Log[(e_.)*(u_)^(n_.)*(v_)^(mn_)]*(B_.))^(p_.)*(w_.), x_Symbol] 
 :> Subst[Int[w*(A + B*Log[e*(u/v)^n])^p, x], e*(u/v)^n, e*(u^n/v^n)] /; Fr 
eeQ[{e, A, B, n, p}, x] && EqQ[n + mn, 0] && LinearQ[{u, v}, x] &&  !Intege 
rQ[n]
 
Maple [F]

\[\int \left (b g x +a g \right )^{-2-m} \left (d i x +c i \right )^{m} {\left (A +B \ln \left (e \left (b x +a \right )^{n} \left (d x +c \right )^{-n}\right )\right )}^{p}d x\]

Input:

int((b*g*x+a*g)^(-2-m)*(d*i*x+c*i)^m*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))^p,x 
)
 

Output:

int((b*g*x+a*g)^(-2-m)*(d*i*x+c*i)^m*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))^p,x 
)
 

Fricas [F]

\[ \int (a g+b g x)^{-2-m} (c i+d i x)^m \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^p \, dx=\int { {\left (b g x + a g\right )}^{-m - 2} {\left (d i x + c i\right )}^{m} {\left (B \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right ) + A\right )}^{p} \,d x } \] Input:

integrate((b*g*x+a*g)^(-2-m)*(d*i*x+c*i)^m*(A+B*log(e*(b*x+a)^n/((d*x+c)^n 
)))^p,x, algorithm="fricas")
 

Output:

integral((b*g*x + a*g)^(-m - 2)*(d*i*x + c*i)^m*(B*log((b*x + a)^n*e/(d*x 
+ c)^n) + A)^p, x)
 

Sympy [F(-1)]

Timed out. \[ \int (a g+b g x)^{-2-m} (c i+d i x)^m \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^p \, dx=\text {Timed out} \] Input:

integrate((b*g*x+a*g)**(-2-m)*(d*i*x+c*i)**m*(A+B*ln(e*(b*x+a)**n/((d*x+c) 
**n)))**p,x)
 

Output:

Timed out
 

Maxima [F]

\[ \int (a g+b g x)^{-2-m} (c i+d i x)^m \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^p \, dx=\int { {\left (b g x + a g\right )}^{-m - 2} {\left (d i x + c i\right )}^{m} {\left (B \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right ) + A\right )}^{p} \,d x } \] Input:

integrate((b*g*x+a*g)^(-2-m)*(d*i*x+c*i)^m*(A+B*log(e*(b*x+a)^n/((d*x+c)^n 
)))^p,x, algorithm="maxima")
 

Output:

integrate((b*g*x + a*g)^(-m - 2)*(d*i*x + c*i)^m*(B*log((b*x + a)^n*e/(d*x 
 + c)^n) + A)^p, x)
 

Giac [F(-2)]

Exception generated. \[ \int (a g+b g x)^{-2-m} (c i+d i x)^m \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^p \, dx=\text {Exception raised: RuntimeError} \] Input:

integrate((b*g*x+a*g)^(-2-m)*(d*i*x+c*i)^m*(A+B*log(e*(b*x+a)^n/((d*x+c)^n 
)))^p,x, algorithm="giac")
 

Output:

Exception raised: RuntimeError >> an error occurred running a Giac command 
:INPUT:sage2OUTPUT:Unable to divide, perhaps due to rounding error%%%{1,[0 
,0,5,5,0,2,2,3,3,0,0,0,2]%%%}+%%%{-2,[0,0,5,4,1,3,1,3,3,0,0,0,2]%%%}+%%%{1 
,[0,0,5,3,2,
 

Mupad [F(-1)]

Timed out. \[ \int (a g+b g x)^{-2-m} (c i+d i x)^m \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^p \, dx=\int \frac {{\left (c\,i+d\,i\,x\right )}^m\,{\left (A+B\,\ln \left (\frac {e\,{\left (a+b\,x\right )}^n}{{\left (c+d\,x\right )}^n}\right )\right )}^p}{{\left (a\,g+b\,g\,x\right )}^{m+2}} \,d x \] Input:

int(((c*i + d*i*x)^m*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^p)/(a*g + b* 
g*x)^(m + 2),x)
 

Output:

int(((c*i + d*i*x)^m*(A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^p)/(a*g + b* 
g*x)^(m + 2), x)
 

Reduce [F]

\[ \int (a g+b g x)^{-2-m} (c i+d i x)^m \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^p \, dx=\frac {\int \frac {\left (d i x +c i \right )^{m} {\left (\mathrm {log}\left (\frac {\left (b x +a \right )^{n} e}{\left (d x +c \right )^{n}}\right ) b +a \right )}^{p}}{\left (b g x +a g \right )^{m} a^{2}+2 \left (b g x +a g \right )^{m} a b x +\left (b g x +a g \right )^{m} b^{2} x^{2}}d x}{g^{2}} \] Input:

int((b*g*x+a*g)^(-2-m)*(d*i*x+c*i)^m*(A+B*log(e*(b*x+a)^n/((d*x+c)^n)))^p, 
x)
 

Output:

int(((c*i + d*i*x)**m*(log(((a + b*x)**n*e)/(c + d*x)**n)*b + a)**p)/((a*g 
 + b*g*x)**m*a**2 + 2*(a*g + b*g*x)**m*a*b*x + (a*g + b*g*x)**m*b**2*x**2) 
,x)/g**2