Integrand size = 33, antiderivative size = 301 \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{g+h x} \, dx=-\frac {\log \left (\frac {b c-a d}{b (c+d x)}\right ) \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{h}+\frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2 \log \left (1-\frac {(d g-c h) (a+b x)}{(b g-a h) (c+d x)}\right )}{h}-\frac {2 B n \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right ) \operatorname {PolyLog}\left (2,\frac {d (a+b x)}{b (c+d x)}\right )}{h}+\frac {2 B n \left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right ) \operatorname {PolyLog}\left (2,\frac {(d g-c h) (a+b x)}{(b g-a h) (c+d x)}\right )}{h}+\frac {2 B^2 n^2 \operatorname {PolyLog}\left (3,\frac {d (a+b x)}{b (c+d x)}\right )}{h}-\frac {2 B^2 n^2 \operatorname {PolyLog}\left (3,\frac {(d g-c h) (a+b x)}{(b g-a h) (c+d x)}\right )}{h} \] Output:
-ln((-a*d+b*c)/b/(d*x+c))*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))^2/h+(A+B*ln(e* (b*x+a)^n/((d*x+c)^n)))^2*ln(1-(-c*h+d*g)*(b*x+a)/(-a*h+b*g)/(d*x+c))/h-2* B*n*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))*polylog(2,d*(b*x+a)/b/(d*x+c))/h+2*B *n*(A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))*polylog(2,(-c*h+d*g)*(b*x+a)/(-a*h+b* g)/(d*x+c))/h+2*B^2*n^2*polylog(3,d*(b*x+a)/b/(d*x+c))/h-2*B^2*n^2*polylog (3,(-c*h+d*g)*(b*x+a)/(-a*h+b*g)/(d*x+c))/h
Leaf count is larger than twice the leaf count of optimal. \(1082\) vs. \(2(301)=602\).
Time = 0.49 (sec) , antiderivative size = 1082, normalized size of antiderivative = 3.59 \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{g+h x} \, dx =\text {Too large to display} \] Input:
Integrate[(A + B*Log[(e*(a + b*x)^n)/(c + d*x)^n])^2/(g + h*x),x]
Output:
((A + B*(-(n*Log[a + b*x]) + n*Log[c + d*x] + Log[(e*(a + b*x)^n)/(c + d*x )^n]))^2*Log[g + h*x] + 2*B*n*(A + B*(-(n*Log[a + b*x]) + n*Log[c + d*x] + Log[(e*(a + b*x)^n)/(c + d*x)^n]))*(Log[a + b*x]*Log[(b*(g + h*x))/(b*g - a*h)] + PolyLog[2, (h*(a + b*x))/(-(b*g) + a*h)]) - 2*A*B*n*(Log[c + d*x] *Log[(d*(g + h*x))/(d*g - c*h)] + PolyLog[2, (h*(c + d*x))/(-(d*g) + c*h)] ) - 2*B^2*n*(-(n*Log[a + b*x]) + n*Log[c + d*x] + Log[(e*(a + b*x)^n)/(c + d*x)^n])*(Log[c + d*x]*Log[(d*(g + h*x))/(d*g - c*h)] + PolyLog[2, (h*(c + d*x))/(-(d*g) + c*h)]) + B^2*n^2*(Log[a + b*x]^2*Log[(b*(g + h*x))/(b*g - a*h)] + 2*Log[a + b*x]*PolyLog[2, (h*(a + b*x))/(-(b*g) + a*h)] - 2*Poly Log[3, (h*(a + b*x))/(-(b*g) + a*h)]) + B^2*n^2*(Log[c + d*x]^2*Log[(d*(g + h*x))/(d*g - c*h)] + 2*Log[c + d*x]*PolyLog[2, (h*(c + d*x))/(-(d*g) + c *h)] - 2*PolyLog[3, (h*(c + d*x))/(-(d*g) + c*h)]) - 2*B^2*n^2*(Log[a + b* x]*Log[c + d*x]*Log[(b*(g + h*x))/(b*g - a*h)] + (Log[(h*(c + d*x))/(-(d*g ) + c*h)]*(-2*Log[a + b*x] + Log[(h*(c + d*x))/(-(d*g) + c*h)])*(Log[(b*(g + h*x))/(b*g - a*h)] - Log[(d*(g + h*x))/(d*g - c*h)]))/2 + Log[(h*(c + d *x))/(-(d*g) + c*h)]*Log[((b*g - a*h)*(c + d*x))/((d*g - c*h)*(a + b*x))]* (-Log[(b*(g + h*x))/(b*g - a*h)] + Log[(d*(g + h*x))/(d*g - c*h)]) + (Log[ ((b*g - a*h)*(c + d*x))/((d*g - c*h)*(a + b*x))]^2*(Log[(-(b*c) + a*d)/(d* (a + b*x))] + Log[(b*(g + h*x))/(b*g - a*h)] - Log[((-(b*c) + a*d)*(g + h* x))/((d*g - c*h)*(a + b*x))]))/2 + (Log[c + d*x] - Log[((b*g - a*h)*(c ...
Time = 0.89 (sec) , antiderivative size = 367, normalized size of antiderivative = 1.22, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.121, Rules used = {2973, 2953, 2804, 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 {\left (B \log \left (e (a+b x)^n (c+d x)^{-n}\right )+A\right )^2}{g+h x} \, dx\) |
\(\Big \downarrow \) 2973 |
\(\displaystyle \int \frac {\left (B \log \left (e (a+b x)^n (c+d x)^{-n}\right )+A\right )^2}{g+h x}dx\) |
\(\Big \downarrow \) 2953 |
\(\displaystyle (b c-a d) \int \frac {\left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{\left (b-\frac {d (a+b x)}{c+d x}\right ) \left (b g-a h-\frac {(d g-c h) (a+b x)}{c+d x}\right )}d\frac {a+b x}{c+d x}\) |
\(\Big \downarrow \) 2804 |
\(\displaystyle (b c-a d) \int \left (\frac {d \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{(b c-a d) h \left (b-\frac {d (a+b x)}{c+d x}\right )}+\frac {(c h-d g) \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{(b c-a d) h \left (b g-a h-\frac {(d g-c h) (a+b x)}{c+d x}\right )}\right )d\frac {a+b x}{c+d x}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle (b c-a d) \left (\frac {2 B n \operatorname {PolyLog}\left (2,\frac {(d g-c h) (a+b x)}{(b g-a h) (c+d x)}\right ) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{h (b c-a d)}+\frac {\log \left (1-\frac {(a+b x) (d g-c h)}{(c+d x) (b g-a h)}\right ) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )^2}{h (b c-a d)}-\frac {2 B n \operatorname {PolyLog}\left (2,\frac {d (a+b x)}{b (c+d x)}\right ) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{h (b c-a d)}-\frac {\log \left (1-\frac {d (a+b x)}{b (c+d x)}\right ) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )^2}{h (b c-a d)}-\frac {2 B^2 n^2 \operatorname {PolyLog}\left (3,\frac {(d g-c h) (a+b x)}{(b g-a h) (c+d x)}\right )}{h (b c-a d)}+\frac {2 B^2 n^2 \operatorname {PolyLog}\left (3,\frac {d (a+b x)}{b (c+d x)}\right )}{h (b c-a d)}\right )\) |
Input:
Int[(A + B*Log[(e*(a + b*x)^n)/(c + d*x)^n])^2/(g + h*x),x]
Output:
(b*c - a*d)*(-(((A + B*Log[e*((a + b*x)/(c + d*x))^n])^2*Log[1 - (d*(a + b *x))/(b*(c + d*x))])/((b*c - a*d)*h)) + ((A + B*Log[e*((a + b*x)/(c + d*x) )^n])^2*Log[1 - ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))])/((b*c - a*d)*h) - (2*B*n*(A + B*Log[e*((a + b*x)/(c + d*x))^n])*PolyLog[2, (d*(a + b*x))/(b*(c + d*x))])/((b*c - a*d)*h) + (2*B*n*(A + B*Log[e*((a + b*x)/(c + d*x))^n])*PolyLog[2, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*(c + d*x))])/ ((b*c - a*d)*h) + (2*B^2*n^2*PolyLog[3, (d*(a + b*x))/(b*(c + d*x))])/((b* c - a*d)*h) - (2*B^2*n^2*PolyLog[3, ((d*g - c*h)*(a + b*x))/((b*g - a*h)*( c + d*x))])/((b*c - a*d)*h))
Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*(RFx_), x_Symbol] :> With[{ u = ExpandIntegrand[(a + b*Log[c*x^n])^p, RFx, x]}, Int[u, x] /; SumQ[u]] / ; FreeQ[{a, b, c, n}, x] && RationalFunctionQ[RFx, x] && IGtQ[p, 0]
Int[((A_.) + Log[(e_.)*(((a_.) + (b_.)*(x_))/((c_.) + (d_.)*(x_)))^(n_.)]*( B_.))^(p_.)*((f_.) + (g_.)*(x_))^(m_.), x_Symbol] :> Simp[(b*c - a*d) Sub st[Int[(b*f - a*g - (d*f - c*g)*x)^m*((A + B*Log[e*x^n])^p/(b - d*x)^(m + 2 )), x], x, (a + b*x)/(c + d*x)], x] /; FreeQ[{a, b, c, d, e, f, g, A, B, n} , x] && NeQ[b*c - a*d, 0] && IntegerQ[m] && IGtQ[p, 0]
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]
\[\int \frac {{\left (A +B \ln \left (e \left (b x +a \right )^{n} \left (d x +c \right )^{-n}\right )\right )}^{2}}{h x +g}d x\]
Input:
int((A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))^2/(h*x+g),x)
Output:
int((A+B*ln(e*(b*x+a)^n/((d*x+c)^n)))^2/(h*x+g),x)
\[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{g+h x} \, dx=\int { \frac {{\left (B \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right ) + A\right )}^{2}}{h x + g} \,d x } \] Input:
integrate((A+B*log(e*(b*x+a)^n/((d*x+c)^n)))^2/(h*x+g),x, algorithm="frica s")
Output:
integral((B^2*log((b*x + a)^n*e/(d*x + c)^n)^2 + 2*A*B*log((b*x + a)^n*e/( d*x + c)^n) + A^2)/(h*x + g), x)
Exception generated. \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{g+h x} \, dx=\text {Exception raised: HeuristicGCDFailed} \] Input:
integrate((A+B*ln(e*(b*x+a)**n/((d*x+c)**n)))**2/(h*x+g),x)
Output:
Exception raised: HeuristicGCDFailed >> no luck
\[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{g+h x} \, dx=\int { \frac {{\left (B \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right ) + A\right )}^{2}}{h x + g} \,d x } \] Input:
integrate((A+B*log(e*(b*x+a)^n/((d*x+c)^n)))^2/(h*x+g),x, algorithm="maxim a")
Output:
A^2*log(h*x + g)/h + integrate((B^2*log((b*x + a)^n)^2 + B^2*log((d*x + c) ^n)^2 + B^2*log(e)^2 + 2*A*B*log(e) + 2*(B^2*log(e) + A*B)*log((b*x + a)^n ) - 2*(B^2*log((b*x + a)^n) + B^2*log(e) + A*B)*log((d*x + c)^n))/(h*x + g ), x)
\[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{g+h x} \, dx=\int { \frac {{\left (B \log \left (\frac {{\left (b x + a\right )}^{n} e}{{\left (d x + c\right )}^{n}}\right ) + A\right )}^{2}}{h x + g} \,d x } \] Input:
integrate((A+B*log(e*(b*x+a)^n/((d*x+c)^n)))^2/(h*x+g),x, algorithm="giac" )
Output:
integrate((B*log((b*x + a)^n*e/(d*x + c)^n) + A)^2/(h*x + g), x)
Timed out. \[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{g+h x} \, dx=\int \frac {{\left (A+B\,\ln \left (\frac {e\,{\left (a+b\,x\right )}^n}{{\left (c+d\,x\right )}^n}\right )\right )}^2}{g+h\,x} \,d x \] Input:
int((A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2/(g + h*x),x)
Output:
int((A + B*log((e*(a + b*x)^n)/(c + d*x)^n))^2/(g + h*x), x)
\[ \int \frac {\left (A+B \log \left (e (a+b x)^n (c+d x)^{-n}\right )\right )^2}{g+h x} \, dx=\frac {\left (\int \frac {\mathrm {log}\left (\frac {\left (b x +a \right )^{n} e}{\left (d x +c \right )^{n}}\right )^{2}}{h x +g}d x \right ) b^{2} h +2 \left (\int \frac {\mathrm {log}\left (\frac {\left (b x +a \right )^{n} e}{\left (d x +c \right )^{n}}\right )}{h x +g}d x \right ) a b h +\mathrm {log}\left (h x +g \right ) a^{2}}{h} \] Input:
int((A+B*log(e*(b*x+a)^n/((d*x+c)^n)))^2/(h*x+g),x)
Output:
(int(log(((a + b*x)**n*e)/(c + d*x)**n)**2/(g + h*x),x)*b**2*h + 2*int(log (((a + b*x)**n*e)/(c + d*x)**n)/(g + h*x),x)*a*b*h + log(g + h*x)*a**2)/h