\(\int \frac {\log ^2(e (f (a+b x)^p (c+d x)^q)^r)}{(g+h x)^2} \, dx\) [40]

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

Optimal result

Integrand size = 31, antiderivative size = 832 \[ \int \frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(g+h x)^2} \, dx=\frac {2 b p q r^2 \log \left (-\frac {d (a+b x)}{b c-a d}\right ) \log (c+d x)}{h (b g-a h)}+\frac {2 d p q r^2 \log (a+b x) \log \left (\frac {b (c+d x)}{b c-a d}\right )}{h (d g-c h)}-\frac {2 b p r \log (a+b x) \left (p r \log (a+b x)+q r \log (c+d x)-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )\right )}{h (b g-a h)}-\frac {2 d q r \log (c+d x) \left (p r \log (a+b x)+q r \log (c+d x)-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )\right )}{h (d g-c h)}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}+\frac {2 b p r \left (p r \log (a+b x)+q r \log (c+d x)-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )\right ) \log (g+h x)}{h (b g-a h)}+\frac {2 d q r \left (p r \log (a+b x)+q r \log (c+d x)-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )\right ) \log (g+h x)}{h (d g-c h)}-\frac {2 d p q r^2 \log (a+b x) \log \left (\frac {b (g+h x)}{b g-a h}\right )}{h (d g-c h)}-\frac {2 b p q r^2 \log (c+d x) \log \left (\frac {d (g+h x)}{d g-c h}\right )}{h (b g-a h)}-\frac {2 b p^2 r^2 \log (a+b x) \log \left (1+\frac {b g-a h}{h (a+b x)}\right )}{h (b g-a h)}-\frac {2 d q^2 r^2 \log (c+d x) \log \left (1+\frac {d g-c h}{h (c+d x)}\right )}{h (d g-c h)}+\frac {2 b p^2 r^2 \operatorname {PolyLog}\left (2,-\frac {b g-a h}{h (a+b x)}\right )}{h (b g-a h)}+\frac {2 d p q r^2 \operatorname {PolyLog}\left (2,-\frac {d (a+b x)}{b c-a d}\right )}{h (d g-c h)}-\frac {2 d p q r^2 \operatorname {PolyLog}\left (2,-\frac {h (a+b x)}{b g-a h}\right )}{h (d g-c h)}+\frac {2 d q^2 r^2 \operatorname {PolyLog}\left (2,-\frac {d g-c h}{h (c+d x)}\right )}{h (d g-c h)}+\frac {2 b p q r^2 \operatorname {PolyLog}\left (2,\frac {b (c+d x)}{b c-a d}\right )}{h (b g-a h)}-\frac {2 b p q r^2 \operatorname {PolyLog}\left (2,-\frac {h (c+d x)}{d g-c h}\right )}{h (b g-a h)} \] Output:

2*b*p*q*r^2*ln(-d*(b*x+a)/(-a*d+b*c))*ln(d*x+c)/h/(-a*h+b*g)+2*d*p*q*r^2*l 
n(b*x+a)*ln(b*(d*x+c)/(-a*d+b*c))/h/(-c*h+d*g)-2*b*p*r*ln(b*x+a)*(p*r*ln(b 
*x+a)+q*r*ln(d*x+c)-ln(e*(f*(b*x+a)^p*(d*x+c)^q)^r))/h/(-a*h+b*g)-2*d*q*r* 
ln(d*x+c)*(p*r*ln(b*x+a)+q*r*ln(d*x+c)-ln(e*(f*(b*x+a)^p*(d*x+c)^q)^r))/h/ 
(-c*h+d*g)-ln(e*(f*(b*x+a)^p*(d*x+c)^q)^r)^2/h/(h*x+g)+2*b*p*r*(p*r*ln(b*x 
+a)+q*r*ln(d*x+c)-ln(e*(f*(b*x+a)^p*(d*x+c)^q)^r))*ln(h*x+g)/h/(-a*h+b*g)+ 
2*d*q*r*(p*r*ln(b*x+a)+q*r*ln(d*x+c)-ln(e*(f*(b*x+a)^p*(d*x+c)^q)^r))*ln(h 
*x+g)/h/(-c*h+d*g)-2*d*p*q*r^2*ln(b*x+a)*ln(b*(h*x+g)/(-a*h+b*g))/h/(-c*h+ 
d*g)-2*b*p*q*r^2*ln(d*x+c)*ln(d*(h*x+g)/(-c*h+d*g))/h/(-a*h+b*g)-2*b*p^2*r 
^2*ln(b*x+a)*ln(1+(-a*h+b*g)/h/(b*x+a))/h/(-a*h+b*g)-2*d*q^2*r^2*ln(d*x+c) 
*ln(1+(-c*h+d*g)/h/(d*x+c))/h/(-c*h+d*g)+2*b*p^2*r^2*polylog(2,-(-a*h+b*g) 
/h/(b*x+a))/h/(-a*h+b*g)+2*d*p*q*r^2*polylog(2,-d*(b*x+a)/(-a*d+b*c))/h/(- 
c*h+d*g)-2*d*p*q*r^2*polylog(2,-h*(b*x+a)/(-a*h+b*g))/h/(-c*h+d*g)+2*d*q^2 
*r^2*polylog(2,-(-c*h+d*g)/h/(d*x+c))/h/(-c*h+d*g)+2*b*p*q*r^2*polylog(2,b 
*(d*x+c)/(-a*d+b*c))/h/(-a*h+b*g)-2*b*p*q*r^2*polylog(2,-h*(d*x+c)/(-c*h+d 
*g))/h/(-a*h+b*g)
 

Mathematica [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(2930\) vs. \(2(832)=1664\).

Time = 0.95 (sec) , antiderivative size = 2930, normalized size of antiderivative = 3.52 \[ \int \frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(g+h x)^2} \, dx=\text {Result too large to show} \] Input:

Integrate[Log[e*(f*(a + b*x)^p*(c + d*x)^q)^r]^2/(g + h*x)^2,x]
 

Output:

(-(b*d*g^2*p^2*r^2*Log[a + b*x]^2) + b*c*g*h*p^2*r^2*Log[a + b*x]^2 - b*d* 
g*h*p^2*r^2*x*Log[a + b*x]^2 + b*c*h^2*p^2*r^2*x*Log[a + b*x]^2 - 2*b*d*g^ 
2*p*q*r^2*Log[a + b*x]*Log[c + d*x] + 2*a*d*g*h*p*q*r^2*Log[a + b*x]*Log[c 
 + d*x] - 2*b*d*g*h*p*q*r^2*x*Log[a + b*x]*Log[c + d*x] + 2*a*d*h^2*p*q*r^ 
2*x*Log[a + b*x]*Log[c + d*x] - b*d*g^2*q^2*r^2*Log[c + d*x]^2 + a*d*g*h*q 
^2*r^2*Log[c + d*x]^2 - b*d*g*h*q^2*r^2*x*Log[c + d*x]^2 + a*d*h^2*q^2*r^2 
*x*Log[c + d*x]^2 + 2*b*c*g*h*p*q*r^2*Log[a + b*x]*Log[(h*(c + d*x))/(-(d* 
g) + c*h)] - 2*a*d*g*h*p*q*r^2*Log[a + b*x]*Log[(h*(c + d*x))/(-(d*g) + c* 
h)] + 2*b*c*h^2*p*q*r^2*x*Log[a + b*x]*Log[(h*(c + d*x))/(-(d*g) + c*h)] - 
 2*a*d*h^2*p*q*r^2*x*Log[a + b*x]*Log[(h*(c + d*x))/(-(d*g) + c*h)] - b*c* 
g*h*p*q*r^2*Log[(h*(c + d*x))/(-(d*g) + c*h)]^2 + a*d*g*h*p*q*r^2*Log[(h*( 
c + d*x))/(-(d*g) + c*h)]^2 - b*c*h^2*p*q*r^2*x*Log[(h*(c + d*x))/(-(d*g) 
+ c*h)]^2 + a*d*h^2*p*q*r^2*x*Log[(h*(c + d*x))/(-(d*g) + c*h)]^2 + 2*b*c* 
g*h*p*q*r^2*Log[(-(b*c) + a*d)/(d*(a + b*x))]*Log[((b*g - a*h)*(c + d*x))/ 
((d*g - c*h)*(a + b*x))] - 2*a*d*g*h*p*q*r^2*Log[(-(b*c) + a*d)/(d*(a + b* 
x))]*Log[((b*g - a*h)*(c + d*x))/((d*g - c*h)*(a + b*x))] + 2*b*c*h^2*p*q* 
r^2*x*Log[(-(b*c) + a*d)/(d*(a + b*x))]*Log[((b*g - a*h)*(c + d*x))/((d*g 
- c*h)*(a + b*x))] - 2*a*d*h^2*p*q*r^2*x*Log[(-(b*c) + a*d)/(d*(a + b*x))] 
*Log[((b*g - a*h)*(c + d*x))/((d*g - c*h)*(a + b*x))] + 2*b*c*g*h*p*q*r^2* 
Log[(h*(c + d*x))/(-(d*g) + c*h)]*Log[((b*g - a*h)*(c + d*x))/((d*g - c...
 

Rubi [A] (verified)

Time = 1.91 (sec) , antiderivative size = 644, normalized size of antiderivative = 0.77, number of steps used = 11, number of rules used = 10, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.323, Rules used = {2984, 2993, 47, 16, 2858, 27, 2779, 2838, 2865, 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 {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(g+h x)^2} \, dx\)

\(\Big \downarrow \) 2984

\(\displaystyle \frac {2 b p r \int \frac {\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(a+b x) (g+h x)}dx}{h}+\frac {2 d q r \int \frac {\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(c+d x) (g+h x)}dx}{h}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}\)

\(\Big \downarrow \) 2993

\(\displaystyle \frac {2 b p r \left (-\left (\left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right ) \int \frac {1}{(a+b x) (g+h x)}dx\right )+q r \int \frac {\log (c+d x)}{(a+b x) (g+h x)}dx+p r \int \frac {\log (a+b x)}{(a+b x) (g+h x)}dx\right )}{h}+\frac {2 d q r \left (-\left (\left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right ) \int \frac {1}{(c+d x) (g+h x)}dx\right )+p r \int \frac {\log (a+b x)}{(c+d x) (g+h x)}dx+q r \int \frac {\log (c+d x)}{(c+d x) (g+h x)}dx\right )}{h}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}\)

\(\Big \downarrow \) 47

\(\displaystyle \frac {2 b p r \left (-\left (\left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right ) \left (\frac {b \int \frac {1}{a+b x}dx}{b g-a h}-\frac {h \int \frac {1}{g+h x}dx}{b g-a h}\right )\right )+q r \int \frac {\log (c+d x)}{(a+b x) (g+h x)}dx+p r \int \frac {\log (a+b x)}{(a+b x) (g+h x)}dx\right )}{h}+\frac {2 d q r \left (-\left (\left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right ) \left (\frac {d \int \frac {1}{c+d x}dx}{d g-c h}-\frac {h \int \frac {1}{g+h x}dx}{d g-c h}\right )\right )+p r \int \frac {\log (a+b x)}{(c+d x) (g+h x)}dx+q r \int \frac {\log (c+d x)}{(c+d x) (g+h x)}dx\right )}{h}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}\)

\(\Big \downarrow \) 16

\(\displaystyle \frac {2 b p r \left (q r \int \frac {\log (c+d x)}{(a+b x) (g+h x)}dx+p r \int \frac {\log (a+b x)}{(a+b x) (g+h x)}dx-\left (\left (\frac {\log (a+b x)}{b g-a h}-\frac {\log (g+h x)}{b g-a h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )\right )}{h}+\frac {2 d q r \left (p r \int \frac {\log (a+b x)}{(c+d x) (g+h x)}dx+q r \int \frac {\log (c+d x)}{(c+d x) (g+h x)}dx-\left (\left (\frac {\log (c+d x)}{d g-c h}-\frac {\log (g+h x)}{d g-c h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )\right )}{h}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}\)

\(\Big \downarrow \) 2858

\(\displaystyle \frac {2 b p r \left (q r \int \frac {\log (c+d x)}{(a+b x) (g+h x)}dx+\frac {p r \int \frac {b \log (a+b x)}{(a+b x) \left (b \left (g-\frac {a h}{b}\right )+h (a+b x)\right )}d(a+b x)}{b}-\left (\left (\frac {\log (a+b x)}{b g-a h}-\frac {\log (g+h x)}{b g-a h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )\right )}{h}+\frac {2 d q r \left (p r \int \frac {\log (a+b x)}{(c+d x) (g+h x)}dx+\frac {q r \int \frac {d \log (c+d x)}{(c+d x) \left (d \left (g-\frac {c h}{d}\right )+h (c+d x)\right )}d(c+d x)}{d}-\left (\left (\frac {\log (c+d x)}{d g-c h}-\frac {\log (g+h x)}{d g-c h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )\right )}{h}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {2 b p r \left (q r \int \frac {\log (c+d x)}{(a+b x) (g+h x)}dx+p r \int \frac {\log (a+b x)}{(a+b x) (b g-a h+h (a+b x))}d(a+b x)-\left (\left (\frac {\log (a+b x)}{b g-a h}-\frac {\log (g+h x)}{b g-a h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )\right )}{h}+\frac {2 d q r \left (p r \int \frac {\log (a+b x)}{(c+d x) (g+h x)}dx+q r \int \frac {\log (c+d x)}{(c+d x) (d g-c h+h (c+d x))}d(c+d x)-\left (\left (\frac {\log (c+d x)}{d g-c h}-\frac {\log (g+h x)}{d g-c h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )\right )}{h}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}\)

\(\Big \downarrow \) 2779

\(\displaystyle \frac {2 b p r \left (q r \int \frac {\log (c+d x)}{(a+b x) (g+h x)}dx+p r \left (\frac {\int \frac {\log \left (\frac {b g-a h}{h (a+b x)}+1\right )}{a+b x}d(a+b x)}{b g-a h}-\frac {\log (a+b x) \log \left (\frac {b g-a h}{h (a+b x)}+1\right )}{b g-a h}\right )-\left (\left (\frac {\log (a+b x)}{b g-a h}-\frac {\log (g+h x)}{b g-a h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )\right )}{h}+\frac {2 d q r \left (p r \int \frac {\log (a+b x)}{(c+d x) (g+h x)}dx+q r \left (\frac {\int \frac {\log \left (\frac {d g-c h}{h (c+d x)}+1\right )}{c+d x}d(c+d x)}{d g-c h}-\frac {\log (c+d x) \log \left (\frac {d g-c h}{h (c+d x)}+1\right )}{d g-c h}\right )-\left (\left (\frac {\log (c+d x)}{d g-c h}-\frac {\log (g+h x)}{d g-c h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )\right )}{h}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}\)

\(\Big \downarrow \) 2838

\(\displaystyle \frac {2 d q r \left (p r \int \frac {\log (a+b x)}{(c+d x) (g+h x)}dx-\left (\left (\frac {\log (c+d x)}{d g-c h}-\frac {\log (g+h x)}{d g-c h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )+q r \left (\frac {\operatorname {PolyLog}\left (2,-\frac {d g-c h}{h (c+d x)}\right )}{d g-c h}-\frac {\log (c+d x) \log \left (\frac {d g-c h}{h (c+d x)}+1\right )}{d g-c h}\right )\right )}{h}+\frac {2 b p r \left (q r \int \frac {\log (c+d x)}{(a+b x) (g+h x)}dx-\left (\left (\frac {\log (a+b x)}{b g-a h}-\frac {\log (g+h x)}{b g-a h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )+p r \left (\frac {\operatorname {PolyLog}\left (2,-\frac {b g-a h}{h (a+b x)}\right )}{b g-a h}-\frac {\log (a+b x) \log \left (\frac {b g-a h}{h (a+b x)}+1\right )}{b g-a h}\right )\right )}{h}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}\)

\(\Big \downarrow \) 2865

\(\displaystyle \frac {2 d q r \left (p r \int \left (\frac {d \log (a+b x)}{(d g-c h) (c+d x)}-\frac {h \log (a+b x)}{(d g-c h) (g+h x)}\right )dx-\left (\left (\frac {\log (c+d x)}{d g-c h}-\frac {\log (g+h x)}{d g-c h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )+q r \left (\frac {\operatorname {PolyLog}\left (2,-\frac {d g-c h}{h (c+d x)}\right )}{d g-c h}-\frac {\log (c+d x) \log \left (\frac {d g-c h}{h (c+d x)}+1\right )}{d g-c h}\right )\right )}{h}+\frac {2 b p r \left (q r \int \left (\frac {b \log (c+d x)}{(b g-a h) (a+b x)}-\frac {h \log (c+d x)}{(b g-a h) (g+h x)}\right )dx-\left (\left (\frac {\log (a+b x)}{b g-a h}-\frac {\log (g+h x)}{b g-a h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )+p r \left (\frac {\operatorname {PolyLog}\left (2,-\frac {b g-a h}{h (a+b x)}\right )}{b g-a h}-\frac {\log (a+b x) \log \left (\frac {b g-a h}{h (a+b x)}+1\right )}{b g-a h}\right )\right )}{h}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {2 d q r \left (-\left (\left (\frac {\log (c+d x)}{d g-c h}-\frac {\log (g+h x)}{d g-c h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )+p r \left (\frac {\operatorname {PolyLog}\left (2,-\frac {d (a+b x)}{b c-a d}\right )}{d g-c h}-\frac {\operatorname {PolyLog}\left (2,-\frac {h (a+b x)}{b g-a h}\right )}{d g-c h}+\frac {\log (a+b x) \log \left (\frac {b (c+d x)}{b c-a d}\right )}{d g-c h}-\frac {\log (a+b x) \log \left (\frac {b (g+h x)}{b g-a h}\right )}{d g-c h}\right )+q r \left (\frac {\operatorname {PolyLog}\left (2,-\frac {d g-c h}{h (c+d x)}\right )}{d g-c h}-\frac {\log (c+d x) \log \left (\frac {d g-c h}{h (c+d x)}+1\right )}{d g-c h}\right )\right )}{h}+\frac {2 b p r \left (-\left (\left (\frac {\log (a+b x)}{b g-a h}-\frac {\log (g+h x)}{b g-a h}\right ) \left (-\log \left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )+p r \log (a+b x)+q r \log (c+d x)\right )\right )+q r \left (\frac {\operatorname {PolyLog}\left (2,\frac {b (c+d x)}{b c-a d}\right )}{b g-a h}-\frac {\operatorname {PolyLog}\left (2,-\frac {h (c+d x)}{d g-c h}\right )}{b g-a h}+\frac {\log (c+d x) \log \left (-\frac {d (a+b x)}{b c-a d}\right )}{b g-a h}-\frac {\log (c+d x) \log \left (\frac {d (g+h x)}{d g-c h}\right )}{b g-a h}\right )+p r \left (\frac {\operatorname {PolyLog}\left (2,-\frac {b g-a h}{h (a+b x)}\right )}{b g-a h}-\frac {\log (a+b x) \log \left (\frac {b g-a h}{h (a+b x)}+1\right )}{b g-a h}\right )\right )}{h}-\frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{h (g+h x)}\)

Input:

Int[Log[e*(f*(a + b*x)^p*(c + d*x)^q)^r]^2/(g + h*x)^2,x]
 

Output:

-(Log[e*(f*(a + b*x)^p*(c + d*x)^q)^r]^2/(h*(g + h*x))) + (2*d*q*r*(-((p*r 
*Log[a + b*x] + q*r*Log[c + d*x] - Log[e*(f*(a + b*x)^p*(c + d*x)^q)^r])*( 
Log[c + d*x]/(d*g - c*h) - Log[g + h*x]/(d*g - c*h))) + p*r*((Log[a + b*x] 
*Log[(b*(c + d*x))/(b*c - a*d)])/(d*g - c*h) - (Log[a + b*x]*Log[(b*(g + h 
*x))/(b*g - a*h)])/(d*g - c*h) + PolyLog[2, -((d*(a + b*x))/(b*c - a*d))]/ 
(d*g - c*h) - PolyLog[2, -((h*(a + b*x))/(b*g - a*h))]/(d*g - c*h)) + q*r* 
(-((Log[c + d*x]*Log[1 + (d*g - c*h)/(h*(c + d*x))])/(d*g - c*h)) + PolyLo 
g[2, -((d*g - c*h)/(h*(c + d*x)))]/(d*g - c*h))))/h + (2*b*p*r*(-((p*r*Log 
[a + b*x] + q*r*Log[c + d*x] - Log[e*(f*(a + b*x)^p*(c + d*x)^q)^r])*(Log[ 
a + b*x]/(b*g - a*h) - Log[g + h*x]/(b*g - a*h))) + p*r*(-((Log[a + b*x]*L 
og[1 + (b*g - a*h)/(h*(a + b*x))])/(b*g - a*h)) + PolyLog[2, -((b*g - a*h) 
/(h*(a + b*x)))]/(b*g - a*h)) + q*r*((Log[-((d*(a + b*x))/(b*c - a*d))]*Lo 
g[c + d*x])/(b*g - a*h) - (Log[c + d*x]*Log[(d*(g + h*x))/(d*g - c*h)])/(b 
*g - a*h) + PolyLog[2, (b*(c + d*x))/(b*c - a*d)]/(b*g - a*h) - PolyLog[2, 
 -((h*(c + d*x))/(d*g - c*h))]/(b*g - a*h))))/h
 

Defintions of rubi rules used

rule 16
Int[(c_.)/((a_.) + (b_.)*(x_)), x_Symbol] :> Simp[c*(Log[RemoveContent[a + 
b*x, x]]/b), x] /; FreeQ[{a, b, c}, x]
 

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

rule 47
Int[1/(((a_.) + (b_.)*(x_))*((c_.) + (d_.)*(x_))), x_Symbol] :> Simp[b/(b*c 
 - a*d)   Int[1/(a + b*x), x], x] - Simp[d/(b*c - a*d)   Int[1/(c + d*x), x 
], x] /; FreeQ[{a, b, c, d}, x]
 

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 2779
Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)/((x_)*((d_) + (e_.)*(x_)^(r 
_.))), x_Symbol] :> Simp[(-Log[1 + d/(e*x^r)])*((a + b*Log[c*x^n])^p/(d*r)) 
, x] + Simp[b*n*(p/(d*r))   Int[Log[1 + d/(e*x^r)]*((a + b*Log[c*x^n])^(p - 
 1)/x), x], x] /; FreeQ[{a, b, c, d, e, n, r}, x] && IGtQ[p, 0]
 

rule 2838
Int[Log[(c_.)*((d_) + (e_.)*(x_)^(n_.))]/(x_), x_Symbol] :> Simp[-PolyLog[2 
, (-c)*e*x^n]/n, x] /; FreeQ[{c, d, e, n}, x] && EqQ[c*d, 1]
 

rule 2858
Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_.) + (g_ 
.)*(x_))^(q_.)*((h_.) + (i_.)*(x_))^(r_.), x_Symbol] :> Simp[1/e   Subst[In 
t[(g*(x/e))^q*((e*h - d*i)/e + i*(x/e))^r*(a + b*Log[c*x^n])^p, x], x, d + 
e*x], x] /; FreeQ[{a, b, c, d, e, f, g, h, i, n, p, q, r}, x] && EqQ[e*f - 
d*g, 0] && (IGtQ[p, 0] || IGtQ[r, 0]) && IntegerQ[2*r]
 

rule 2865
Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*(RFx_), x_Sy 
mbol] :> With[{u = ExpandIntegrand[(a + b*Log[c*(d + e*x)^n])^p, RFx, x]}, 
Int[u, x] /; SumQ[u]] /; FreeQ[{a, b, c, d, e, n}, x] && RationalFunctionQ[ 
RFx, x] && IntegerQ[p]
 

rule 2984
Int[Log[(e_.)*((f_.)*((a_.) + (b_.)*(x_))^(p_.)*((c_.) + (d_.)*(x_))^(q_.)) 
^(r_.)]^(s_)*((g_.) + (h_.)*(x_))^(m_.), x_Symbol] :> Simp[(g + h*x)^(m + 1 
)*(Log[e*(f*(a + b*x)^p*(c + d*x)^q)^r]^s/(h*(m + 1))), x] + (-Simp[b*p*r*( 
s/(h*(m + 1)))   Int[(g + h*x)^(m + 1)*(Log[e*(f*(a + b*x)^p*(c + d*x)^q)^r 
]^(s - 1)/(a + b*x)), x], x] - Simp[d*q*r*(s/(h*(m + 1)))   Int[(g + h*x)^( 
m + 1)*(Log[e*(f*(a + b*x)^p*(c + d*x)^q)^r]^(s - 1)/(c + d*x)), x], x]) /; 
 FreeQ[{a, b, c, d, e, f, g, h, m, p, q, r, s}, x] && NeQ[b*c - a*d, 0] && 
IGtQ[s, 0] && NeQ[m, -1]
 

rule 2993
Int[Log[(e_.)*((f_.)*((a_.) + (b_.)*(x_))^(p_.)*((c_.) + (d_.)*(x_))^(q_.)) 
^(r_.)]*(RFx_.), x_Symbol] :> Simp[p*r   Int[RFx*Log[a + b*x], x], x] + (Si 
mp[q*r   Int[RFx*Log[c + d*x], x], x] - Simp[(p*r*Log[a + b*x] + q*r*Log[c 
+ d*x] - Log[e*(f*(a + b*x)^p*(c + d*x)^q)^r])   Int[RFx, x], x]) /; FreeQ[ 
{a, b, c, d, e, f, p, q, r}, x] && RationalFunctionQ[RFx, x] && NeQ[b*c - a 
*d, 0] &&  !MatchQ[RFx, (u_.)*(a + b*x)^(m_.)*(c + d*x)^(n_.) /; IntegersQ[ 
m, n]]
 
Maple [F]

\[\int \frac {{\ln \left (e \left (f \left (b x +a \right )^{p} \left (d x +c \right )^{q}\right )^{r}\right )}^{2}}{\left (h x +g \right )^{2}}d x\]

Input:

int(ln(e*(f*(b*x+a)^p*(d*x+c)^q)^r)^2/(h*x+g)^2,x)
 

Output:

int(ln(e*(f*(b*x+a)^p*(d*x+c)^q)^r)^2/(h*x+g)^2,x)
 

Fricas [F]

\[ \int \frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(g+h x)^2} \, dx=\int { \frac {\log \left (\left ({\left (b x + a\right )}^{p} {\left (d x + c\right )}^{q} f\right )^{r} e\right )^{2}}{{\left (h x + g\right )}^{2}} \,d x } \] Input:

integrate(log(e*(f*(b*x+a)^p*(d*x+c)^q)^r)^2/(h*x+g)^2,x, algorithm="frica 
s")
 

Output:

integral(log(((b*x + a)^p*(d*x + c)^q*f)^r*e)^2/(h^2*x^2 + 2*g*h*x + g^2), 
 x)
 

Sympy [F(-1)]

Timed out. \[ \int \frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(g+h x)^2} \, dx=\text {Timed out} \] Input:

integrate(ln(e*(f*(b*x+a)**p*(d*x+c)**q)**r)**2/(h*x+g)**2,x)
 

Output:

Timed out
 

Maxima [A] (verification not implemented)

Time = 0.10 (sec) , antiderivative size = 745, normalized size of antiderivative = 0.90 \[ \int \frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(g+h x)^2} \, dx =\text {Too large to display} \] Input:

integrate(log(e*(f*(b*x+a)^p*(d*x+c)^q)^r)^2/(h*x+g)^2,x, algorithm="maxim 
a")
 

Output:

2*(b*f*p*log(b*x + a)/(b*g - a*h) + d*f*q*log(d*x + c)/(d*g - c*h) - (a*d* 
f*h*q - (d*f*g*(p + q) - c*f*h*p)*b)*log(h*x + g)/((d*g*h - c*h^2)*a - (d* 
g^2 - c*g*h)*b))*r*log(((b*x + a)^p*(d*x + c)^q*f)^r*e)/(f*h) - (2*(b*c*f^ 
2*h*p*q - a*d*f^2*h*p*q)*(log(b*x + a)*log((b*d*x + a*d)/(b*c - a*d) + 1) 
+ dilog(-(b*d*x + a*d)/(b*c - a*d)))/((d*g*h - c*h^2)*a - (d*g^2 - c*g*h)* 
b) + 2*(a*d*f^2*h*p*q + (c*f^2*h*p^2 - (p^2 + p*q)*d*f^2*g)*b)*(log(b*x + 
a)*log((b*h*x + a*h)/(b*g - a*h) + 1) + dilog(-(b*h*x + a*h)/(b*g - a*h))) 
/((d*g*h - c*h^2)*a - (d*g^2 - c*g*h)*b) + 2*(a*d*f^2*h*q^2 + (c*f^2*h*p*q 
 - (p*q + q^2)*d*f^2*g)*b)*(log(d*x + c)*log((d*h*x + c*h)/(d*g - c*h) + 1 
) + dilog(-(d*h*x + c*h)/(d*g - c*h)))/((d*g*h - c*h^2)*a - (d*g^2 - c*g*h 
)*b) - ((d*f^2*g*p^2 - c*f^2*h*p^2)*b*log(b*x + a)^2 + 2*(b*d*f^2*g*p*q - 
a*d*f^2*h*p*q)*log(b*x + a)*log(d*x + c) + (b*d*f^2*g*q^2 - a*d*f^2*h*q^2) 
*log(d*x + c)^2 + 2*((a*d*f^2*h*p*q + (c*f^2*h*p^2 - (p^2 + p*q)*d*f^2*g)* 
b)*log(b*x + a) + (a*d*f^2*h*q^2 + (c*f^2*h*p*q - (p*q + q^2)*d*f^2*g)*b)* 
log(d*x + c))*log(h*x + g))/((d*g*h - c*h^2)*a - (d*g^2 - c*g*h)*b))*r^2/( 
f^2*h) - log(((b*x + a)^p*(d*x + c)^q*f)^r*e)^2/((h*x + g)*h)
 

Giac [F]

\[ \int \frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(g+h x)^2} \, dx=\int { \frac {\log \left (\left ({\left (b x + a\right )}^{p} {\left (d x + c\right )}^{q} f\right )^{r} e\right )^{2}}{{\left (h x + g\right )}^{2}} \,d x } \] Input:

integrate(log(e*(f*(b*x+a)^p*(d*x+c)^q)^r)^2/(h*x+g)^2,x, algorithm="giac" 
)
 

Output:

integrate(log(((b*x + a)^p*(d*x + c)^q*f)^r*e)^2/(h*x + g)^2, x)
 

Mupad [F(-1)]

Timed out. \[ \int \frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(g+h x)^2} \, dx=\int \frac {{\ln \left (e\,{\left (f\,{\left (a+b\,x\right )}^p\,{\left (c+d\,x\right )}^q\right )}^r\right )}^2}{{\left (g+h\,x\right )}^2} \,d x \] Input:

int(log(e*(f*(a + b*x)^p*(c + d*x)^q)^r)^2/(g + h*x)^2,x)
 

Output:

int(log(e*(f*(a + b*x)^p*(c + d*x)^q)^r)^2/(g + h*x)^2, x)
 

Reduce [F]

\[ \int \frac {\log ^2\left (e \left (f (a+b x)^p (c+d x)^q\right )^r\right )}{(g+h x)^2} \, dx=\text {too large to display} \] Input:

int(log(e*(f*(b*x+a)^p*(d*x+c)^q)^r)^2/(h*x+g)^2,x)
 

Output:

( - 2*int(log(f**r*(c + d*x)**(q*r)*(a + b*x)**(p*r)*e)/(a**2*c*d*g**2 + 2 
*a**2*c*d*g*h*x + a**2*c*d*h**2*x**2 + a**2*d**2*g**2*x + 2*a**2*d**2*g*h* 
x**2 + a**2*d**2*h**2*x**3 + a*b*c**2*g**2 + 2*a*b*c**2*g*h*x + a*b*c**2*h 
**2*x**2 + 2*a*b*c*d*g**2*x + 4*a*b*c*d*g*h*x**2 + 2*a*b*c*d*h**2*x**3 + a 
*b*d**2*g**2*x**2 + 2*a*b*d**2*g*h*x**3 + a*b*d**2*h**2*x**4 + b**2*c**2*g 
**2*x + 2*b**2*c**2*g*h*x**2 + b**2*c**2*h**2*x**3 + b**2*c*d*g**2*x**2 + 
2*b**2*c*d*g*h*x**3 + b**2*c*d*h**2*x**4),x)*a**4*c**2*d**2*g**2*h**4*q*r 
- 2*int(log(f**r*(c + d*x)**(q*r)*(a + b*x)**(p*r)*e)/(a**2*c*d*g**2 + 2*a 
**2*c*d*g*h*x + a**2*c*d*h**2*x**2 + a**2*d**2*g**2*x + 2*a**2*d**2*g*h*x* 
*2 + a**2*d**2*h**2*x**3 + a*b*c**2*g**2 + 2*a*b*c**2*g*h*x + a*b*c**2*h** 
2*x**2 + 2*a*b*c*d*g**2*x + 4*a*b*c*d*g*h*x**2 + 2*a*b*c*d*h**2*x**3 + a*b 
*d**2*g**2*x**2 + 2*a*b*d**2*g*h*x**3 + a*b*d**2*h**2*x**4 + b**2*c**2*g** 
2*x + 2*b**2*c**2*g*h*x**2 + b**2*c**2*h**2*x**3 + b**2*c*d*g**2*x**2 + 2* 
b**2*c*d*g*h*x**3 + b**2*c*d*h**2*x**4),x)*a**4*c**2*d**2*g*h**5*q*r*x + 4 
*int(log(f**r*(c + d*x)**(q*r)*(a + b*x)**(p*r)*e)/(a**2*c*d*g**2 + 2*a**2 
*c*d*g*h*x + a**2*c*d*h**2*x**2 + a**2*d**2*g**2*x + 2*a**2*d**2*g*h*x**2 
+ a**2*d**2*h**2*x**3 + a*b*c**2*g**2 + 2*a*b*c**2*g*h*x + a*b*c**2*h**2*x 
**2 + 2*a*b*c*d*g**2*x + 4*a*b*c*d*g*h*x**2 + 2*a*b*c*d*h**2*x**3 + a*b*d* 
*2*g**2*x**2 + 2*a*b*d**2*g*h*x**3 + a*b*d**2*h**2*x**4 + b**2*c**2*g**2*x 
 + 2*b**2*c**2*g*h*x**2 + b**2*c**2*h**2*x**3 + b**2*c*d*g**2*x**2 + 2*...