Integrand size = 32, antiderivative size = 177 \[ \int \frac {A+B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )}{(a g+b g x)^4} \, dx=\frac {2 B}{9 b g^4 (a+b x)^3}-\frac {B d}{3 b (b c-a d) g^4 (a+b x)^2}+\frac {2 B d^2}{3 b (b c-a d)^2 g^4 (a+b x)}+\frac {2 B d^3 \log (a+b x)}{3 b (b c-a d)^3 g^4}-\frac {2 B d^3 \log (c+d x)}{3 b (b c-a d)^3 g^4}-\frac {A+B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )}{3 b g^4 (a+b x)^3} \] Output:
2/9*B/b/g^4/(b*x+a)^3-1/3*B*d/b/(-a*d+b*c)/g^4/(b*x+a)^2+2/3*B*d^2/b/(-a*d +b*c)^2/g^4/(b*x+a)+2/3*B*d^3*ln(b*x+a)/b/(-a*d+b*c)^3/g^4-2/3*B*d^3*ln(d* x+c)/b/(-a*d+b*c)^3/g^4-1/3*(A+B*ln(e*(d*x+c)^2/(b*x+a)^2))/b/g^4/(b*x+a)^ 3
Time = 0.13 (sec) , antiderivative size = 140, normalized size of antiderivative = 0.79 \[ \int \frac {A+B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )}{(a g+b g x)^4} \, dx=\frac {\frac {B \left (2 (b c-a d)^3-3 d (b c-a d)^2 (a+b x)+6 d^2 (b c-a d) (a+b x)^2+6 d^3 (a+b x)^3 \log (a+b x)-6 d^3 (a+b x)^3 \log (c+d x)\right )}{(b c-a d)^3}-3 \left (A+B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )\right )}{9 b g^4 (a+b x)^3} \] Input:
Integrate[(A + B*Log[(e*(c + d*x)^2)/(a + b*x)^2])/(a*g + b*g*x)^4,x]
Output:
((B*(2*(b*c - a*d)^3 - 3*d*(b*c - a*d)^2*(a + b*x) + 6*d^2*(b*c - a*d)*(a + b*x)^2 + 6*d^3*(a + b*x)^3*Log[a + b*x] - 6*d^3*(a + b*x)^3*Log[c + d*x] ))/(b*c - a*d)^3 - 3*(A + B*Log[(e*(c + d*x)^2)/(a + b*x)^2]))/(9*b*g^4*(a + b*x)^3)
Time = 0.36 (sec) , antiderivative size = 165, normalized size of antiderivative = 0.93, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {2948, 27, 54, 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 {B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )+A}{(a g+b g x)^4} \, dx\) |
\(\Big \downarrow \) 2948 |
\(\displaystyle -\frac {2 B (b c-a d) \int \frac {1}{g^3 (a+b x)^4 (c+d x)}dx}{3 b g}-\frac {B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )+A}{3 b g^4 (a+b x)^3}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle -\frac {2 B (b c-a d) \int \frac {1}{(a+b x)^4 (c+d x)}dx}{3 b g^4}-\frac {B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )+A}{3 b g^4 (a+b x)^3}\) |
\(\Big \downarrow \) 54 |
\(\displaystyle -\frac {2 B (b c-a d) \int \left (\frac {d^4}{(b c-a d)^4 (c+d x)}-\frac {b d^3}{(b c-a d)^4 (a+b x)}+\frac {b d^2}{(b c-a d)^3 (a+b x)^2}-\frac {b d}{(b c-a d)^2 (a+b x)^3}+\frac {b}{(b c-a d) (a+b x)^4}\right )dx}{3 b g^4}-\frac {B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )+A}{3 b g^4 (a+b x)^3}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )+A}{3 b g^4 (a+b x)^3}-\frac {2 B (b c-a d) \left (-\frac {d^3 \log (a+b x)}{(b c-a d)^4}+\frac {d^3 \log (c+d x)}{(b c-a d)^4}-\frac {d^2}{(a+b x) (b c-a d)^3}+\frac {d}{2 (a+b x)^2 (b c-a d)^2}-\frac {1}{3 (a+b x)^3 (b c-a d)}\right )}{3 b g^4}\) |
Input:
Int[(A + B*Log[(e*(c + d*x)^2)/(a + b*x)^2])/(a*g + b*g*x)^4,x]
Output:
(-2*B*(b*c - a*d)*(-1/3*1/((b*c - a*d)*(a + b*x)^3) + d/(2*(b*c - a*d)^2*( a + b*x)^2) - d^2/((b*c - a*d)^3*(a + b*x)) - (d^3*Log[a + b*x])/(b*c - a* d)^4 + (d^3*Log[c + d*x])/(b*c - a*d)^4))/(3*b*g^4) - (A + B*Log[(e*(c + d *x)^2)/(a + b*x)^2])/(3*b*g^4*(a + b*x)^3)
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[((a_) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[E xpandIntegrand[(a + b*x)^m*(c + d*x)^n, x], x] /; FreeQ[{a, b, c, d}, x] && ILtQ[m, 0] && IntegerQ[n] && !(IGtQ[n, 0] && LtQ[m + n + 2, 0])
Int[((A_.) + Log[(e_.)*((a_.) + (b_.)*(x_))^(n_.)*((c_.) + (d_.)*(x_))^(mn_ )]*(B_.))*((f_.) + (g_.)*(x_))^(m_.), x_Symbol] :> Simp[(f + g*x)^(m + 1)*( (A + B*Log[e*((a + b*x)^n/(c + d*x)^n)])/(g*(m + 1))), x] - Simp[B*n*((b*c - a*d)/(g*(m + 1))) Int[(f + g*x)^(m + 1)/((a + b*x)*(c + d*x)), x], x] / ; FreeQ[{a, b, c, d, e, f, g, A, B, m, n}, x] && EqQ[n + mn, 0] && NeQ[b*c - a*d, 0] && NeQ[m, -1] && !(EqQ[m, -2] && IntegerQ[n])
Time = 1.42 (sec) , antiderivative size = 211, normalized size of antiderivative = 1.19
method | result | size |
derivativedivides | \(-\frac {\frac {A}{3 g^{4} \left (b x +a \right )^{3}}+\frac {B \left (\frac {\ln \left (\frac {e \left (\frac {a d}{b x +a}-\frac {b c}{b x +a}-d \right )^{2}}{b^{2}}\right )}{3 \left (b x +a \right )^{3}}-\left (\frac {2 d a}{3}-\frac {2 b c}{3}\right ) \left (\frac {\frac {d^{2} a^{2}}{3 \left (b x +a \right )^{3}}-\frac {2 a b c d}{3 \left (b x +a \right )^{3}}+\frac {c^{2} b^{2}}{3 \left (b x +a \right )^{3}}+\frac {a \,d^{2}}{2 \left (b x +a \right )^{2}}-\frac {b c d}{2 \left (b x +a \right )^{2}}+\frac {d^{2}}{b x +a}}{\left (d a -b c \right )^{3}}+\frac {d^{3} \ln \left (\frac {a d}{b x +a}-\frac {b c}{b x +a}-d \right )}{\left (d a -b c \right )^{4}}\right )\right )}{g^{4}}}{b}\) | \(211\) |
default | \(-\frac {\frac {A}{3 g^{4} \left (b x +a \right )^{3}}+\frac {B \left (\frac {\ln \left (\frac {e \left (\frac {a d}{b x +a}-\frac {b c}{b x +a}-d \right )^{2}}{b^{2}}\right )}{3 \left (b x +a \right )^{3}}-\left (\frac {2 d a}{3}-\frac {2 b c}{3}\right ) \left (\frac {\frac {d^{2} a^{2}}{3 \left (b x +a \right )^{3}}-\frac {2 a b c d}{3 \left (b x +a \right )^{3}}+\frac {c^{2} b^{2}}{3 \left (b x +a \right )^{3}}+\frac {a \,d^{2}}{2 \left (b x +a \right )^{2}}-\frac {b c d}{2 \left (b x +a \right )^{2}}+\frac {d^{2}}{b x +a}}{\left (d a -b c \right )^{3}}+\frac {d^{3} \ln \left (\frac {a d}{b x +a}-\frac {b c}{b x +a}-d \right )}{\left (d a -b c \right )^{4}}\right )\right )}{g^{4}}}{b}\) | \(211\) |
parts | \(-\frac {A}{3 g^{4} \left (b x +a \right )^{3} b}-\frac {B \left (\frac {\ln \left (\frac {e \left (\frac {a d}{b x +a}-\frac {b c}{b x +a}-d \right )^{2}}{b^{2}}\right )}{3 \left (b x +a \right )^{3}}-\left (\frac {2 d a}{3}-\frac {2 b c}{3}\right ) \left (\frac {\frac {d^{2} a^{2}}{3 \left (b x +a \right )^{3}}-\frac {2 a b c d}{3 \left (b x +a \right )^{3}}+\frac {c^{2} b^{2}}{3 \left (b x +a \right )^{3}}+\frac {a \,d^{2}}{2 \left (b x +a \right )^{2}}-\frac {b c d}{2 \left (b x +a \right )^{2}}+\frac {d^{2}}{b x +a}}{\left (d a -b c \right )^{3}}+\frac {d^{3} \ln \left (\frac {a d}{b x +a}-\frac {b c}{b x +a}-d \right )}{\left (d a -b c \right )^{4}}\right )\right )}{g^{4} b}\) | \(213\) |
orering | \(\frac {\left (b x +a \right ) \left (15 b^{2} d^{3} x^{3}+39 a b \,d^{3} x^{2}+6 b^{2} c \,d^{2} x^{2}+31 a^{2} d^{3} x +16 a b c \,d^{2} x -2 b^{2} c^{2} d x +31 a^{2} c \,d^{2}-23 a b \,c^{2} d +7 b^{2} c^{3}\right ) \left (A +B \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right )\right )}{9 \left (a^{3} d^{3}-3 a^{2} b c \,d^{2}+3 a \,b^{2} c^{2} d -b^{3} c^{3}\right ) \left (b g x +a g \right )^{4}}+\frac {\left (6 d^{2} b^{2} x^{2}+15 a b \,d^{2} x -3 b^{2} c d x +11 a^{2} d^{2}-7 a c d b +2 c^{2} b^{2}\right ) \left (b x +a \right )^{2} \left (d x +c \right ) \left (\frac {B \left (\frac {2 e \left (d x +c \right ) d}{\left (b x +a \right )^{2}}-\frac {2 e \left (d x +c \right )^{2} b}{\left (b x +a \right )^{3}}\right ) \left (b x +a \right )^{2}}{e \left (d x +c \right )^{2} \left (b g x +a g \right )^{4}}-\frac {4 \left (A +B \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right )\right ) b g}{\left (b g x +a g \right )^{5}}\right )}{18 b \left (a^{3} d^{3}-3 a^{2} b c \,d^{2}+3 a \,b^{2} c^{2} d -b^{3} c^{3}\right )}\) | \(370\) |
risch | \(-\frac {B \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right )}{3 b \,g^{4} \left (b x +a \right )^{3}}-\frac {-6 B \ln \left (-d x -c \right ) b^{3} d^{3} x^{3}+6 B \ln \left (b x +a \right ) b^{3} d^{3} x^{3}-18 B \ln \left (-d x -c \right ) a \,b^{2} d^{3} x^{2}+18 B \ln \left (b x +a \right ) a \,b^{2} d^{3} x^{2}-18 B \ln \left (-d x -c \right ) a^{2} b \,d^{3} x +18 B \ln \left (b x +a \right ) a^{2} b \,d^{3} x -6 B a \,b^{2} d^{3} x^{2}+6 B \,b^{3} c \,d^{2} x^{2}-6 B \ln \left (-d x -c \right ) a^{3} d^{3}+6 B \ln \left (b x +a \right ) a^{3} d^{3}-15 B \,a^{2} b \,d^{3} x +18 B a \,b^{2} c \,d^{2} x -3 B \,b^{3} c^{2} d x +3 A \,a^{3} d^{3}-9 A \,a^{2} b c \,d^{2}+9 A a \,b^{2} c^{2} d -3 A \,b^{3} c^{3}-11 B \,a^{3} d^{3}+18 B \,a^{2} b c \,d^{2}-9 B a \,b^{2} c^{2} d +2 B \,c^{3} b^{3}}{9 \left (a^{3} d^{3}-3 a^{2} b c \,d^{2}+3 a \,b^{2} c^{2} d -b^{3} c^{3}\right ) g^{4} \left (b x +a \right )^{3} b}\) | \(379\) |
parallelrisch | \(-\frac {-18 B \,x^{2} \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right ) a \,b^{6} d^{4}-18 B x \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right ) a^{2} b^{5} d^{4}-18 B \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right ) a^{2} b^{5} c \,d^{3}+18 B \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right ) a \,b^{6} c^{2} d^{2}+6 A \,a^{3} b^{4} d^{4}-6 A \,b^{7} c^{3} d -22 B \,a^{3} b^{4} d^{4}+4 B \,b^{7} c^{3} d -18 A \,a^{2} b^{5} c \,d^{3}+18 A a \,b^{6} c^{2} d^{2}-6 B \,x^{3} \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right ) b^{7} d^{4}-6 B \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right ) b^{7} c^{3} d +36 B \,a^{2} b^{5} c \,d^{3}-18 B a \,b^{6} c^{2} d^{2}-12 B \,x^{2} a \,b^{6} d^{4}+12 B \,x^{2} b^{7} c \,d^{3}-30 B x \,a^{2} b^{5} d^{4}-6 B x \,b^{7} c^{2} d^{2}+36 B x a \,b^{6} c \,d^{3}}{18 g^{4} \left (b x +a \right )^{3} \left (a^{3} d^{3}-3 a^{2} b c \,d^{2}+3 a \,b^{2} c^{2} d -b^{3} c^{3}\right ) b^{5} d}\) | \(394\) |
norman | \(\frac {\frac {B \,a^{2} d^{3} x \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right )}{\left (a^{3} d^{3}-3 a^{2} b c \,d^{2}+3 a \,b^{2} c^{2} d -b^{3} c^{3}\right ) g}+\frac {B a b \,d^{3} x^{2} \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right )}{\left (a^{3} d^{3}-3 a^{2} b c \,d^{2}+3 a \,b^{2} c^{2} d -b^{3} c^{3}\right ) g}+\frac {\left (3 A \,a^{2} d^{2}-6 A a b c d +3 A \,b^{2} c^{2}-6 B \,a^{2} d^{2}+6 B a b c d -2 B \,b^{2} c^{2}\right ) x}{3 g a \left (a^{2} d^{2}-2 a c d b +c^{2} b^{2}\right )}+\frac {B c \left (3 a^{2} d^{2}-3 a c d b +c^{2} b^{2}\right ) \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right )}{3 g \left (a^{3} d^{3}-3 a^{2} b c \,d^{2}+3 a \,b^{2} c^{2} d -b^{3} c^{3}\right )}+\frac {\left (3 A \,a^{2} d^{2}-6 A a b c d +3 A \,b^{2} c^{2}-11 B \,a^{2} d^{2}+7 B a b c d -2 B \,b^{2} c^{2}\right ) b^{2} x^{3}}{9 a^{3} g \left (a^{2} d^{2}-2 a c d b +c^{2} b^{2}\right )}+\frac {\left (3 A \,a^{2} d^{2}-6 A a b c d +3 A \,b^{2} c^{2}-9 B \,a^{2} d^{2}+7 B a b c d -2 B \,b^{2} c^{2}\right ) b \,x^{2}}{3 g \,a^{2} \left (a^{2} d^{2}-2 a c d b +c^{2} b^{2}\right )}+\frac {B \,b^{2} d^{3} x^{3} \ln \left (\frac {e \left (d x +c \right )^{2}}{\left (b x +a \right )^{2}}\right )}{3 \left (a^{3} d^{3}-3 a^{2} b c \,d^{2}+3 a \,b^{2} c^{2} d -b^{3} c^{3}\right ) g}}{g^{3} \left (b x +a \right )^{3}}\) | \(559\) |
Input:
int((A+B*ln(e*(d*x+c)^2/(b*x+a)^2))/(b*g*x+a*g)^4,x,method=_RETURNVERBOSE)
Output:
-1/b*(1/3/g^4*A/(b*x+a)^3+1/g^4*B*(1/3/(b*x+a)^3*ln(e*(a*d/(b*x+a)-b*c/(b* x+a)-d)^2/b^2)-(2/3*d*a-2/3*b*c)*(1/(a*d-b*c)^3*(1/3*d^2/(b*x+a)^3*a^2-2/3 *a*b*c*d/(b*x+a)^3+1/3*c^2/(b*x+a)^3*b^2+1/2*a*d^2/(b*x+a)^2-1/2*b*c*d/(b* x+a)^2+d^2/(b*x+a))+d^3/(a*d-b*c)^4*ln(a*d/(b*x+a)-b*c/(b*x+a)-d))))
Leaf count of result is larger than twice the leaf count of optimal. 432 vs. \(2 (165) = 330\).
Time = 0.09 (sec) , antiderivative size = 432, normalized size of antiderivative = 2.44 \[ \int \frac {A+B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )}{(a g+b g x)^4} \, dx=-\frac {{\left (3 \, A - 2 \, B\right )} b^{3} c^{3} - 9 \, {\left (A - B\right )} a b^{2} c^{2} d + 9 \, {\left (A - 2 \, B\right )} a^{2} b c d^{2} - {\left (3 \, A - 11 \, B\right )} a^{3} d^{3} - 6 \, {\left (B b^{3} c d^{2} - B a b^{2} d^{3}\right )} x^{2} + 3 \, {\left (B b^{3} c^{2} d - 6 \, B a b^{2} c d^{2} + 5 \, B a^{2} b d^{3}\right )} x + 3 \, {\left (B b^{3} d^{3} x^{3} + 3 \, B a b^{2} d^{3} x^{2} + 3 \, B a^{2} b d^{3} x + B b^{3} c^{3} - 3 \, B a b^{2} c^{2} d + 3 \, B a^{2} b c d^{2}\right )} \log \left (\frac {d^{2} e x^{2} + 2 \, c d e x + c^{2} e}{b^{2} x^{2} + 2 \, a b x + a^{2}}\right )}{9 \, {\left ({\left (b^{7} c^{3} - 3 \, a b^{6} c^{2} d + 3 \, a^{2} b^{5} c d^{2} - a^{3} b^{4} d^{3}\right )} g^{4} x^{3} + 3 \, {\left (a b^{6} c^{3} - 3 \, a^{2} b^{5} c^{2} d + 3 \, a^{3} b^{4} c d^{2} - a^{4} b^{3} d^{3}\right )} g^{4} x^{2} + 3 \, {\left (a^{2} b^{5} c^{3} - 3 \, a^{3} b^{4} c^{2} d + 3 \, a^{4} b^{3} c d^{2} - a^{5} b^{2} d^{3}\right )} g^{4} x + {\left (a^{3} b^{4} c^{3} - 3 \, a^{4} b^{3} c^{2} d + 3 \, a^{5} b^{2} c d^{2} - a^{6} b d^{3}\right )} g^{4}\right )}} \] Input:
integrate((A+B*log(e*(d*x+c)^2/(b*x+a)^2))/(b*g*x+a*g)^4,x, algorithm="fri cas")
Output:
-1/9*((3*A - 2*B)*b^3*c^3 - 9*(A - B)*a*b^2*c^2*d + 9*(A - 2*B)*a^2*b*c*d^ 2 - (3*A - 11*B)*a^3*d^3 - 6*(B*b^3*c*d^2 - B*a*b^2*d^3)*x^2 + 3*(B*b^3*c^ 2*d - 6*B*a*b^2*c*d^2 + 5*B*a^2*b*d^3)*x + 3*(B*b^3*d^3*x^3 + 3*B*a*b^2*d^ 3*x^2 + 3*B*a^2*b*d^3*x + B*b^3*c^3 - 3*B*a*b^2*c^2*d + 3*B*a^2*b*c*d^2)*l og((d^2*e*x^2 + 2*c*d*e*x + c^2*e)/(b^2*x^2 + 2*a*b*x + a^2)))/((b^7*c^3 - 3*a*b^6*c^2*d + 3*a^2*b^5*c*d^2 - a^3*b^4*d^3)*g^4*x^3 + 3*(a*b^6*c^3 - 3 *a^2*b^5*c^2*d + 3*a^3*b^4*c*d^2 - a^4*b^3*d^3)*g^4*x^2 + 3*(a^2*b^5*c^3 - 3*a^3*b^4*c^2*d + 3*a^4*b^3*c*d^2 - a^5*b^2*d^3)*g^4*x + (a^3*b^4*c^3 - 3 *a^4*b^3*c^2*d + 3*a^5*b^2*c*d^2 - a^6*b*d^3)*g^4)
Leaf count of result is larger than twice the leaf count of optimal. 677 vs. \(2 (160) = 320\).
Time = 1.84 (sec) , antiderivative size = 677, normalized size of antiderivative = 3.82 \[ \int \frac {A+B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )}{(a g+b g x)^4} \, dx=- \frac {B \log {\left (\frac {e \left (c + d x\right )^{2}}{\left (a + b x\right )^{2}} \right )}}{3 a^{3} b g^{4} + 9 a^{2} b^{2} g^{4} x + 9 a b^{3} g^{4} x^{2} + 3 b^{4} g^{4} x^{3}} + \frac {2 B d^{3} \log {\left (x + \frac {- \frac {2 B a^{4} d^{7}}{\left (a d - b c\right )^{3}} + \frac {8 B a^{3} b c d^{6}}{\left (a d - b c\right )^{3}} - \frac {12 B a^{2} b^{2} c^{2} d^{5}}{\left (a d - b c\right )^{3}} + \frac {8 B a b^{3} c^{3} d^{4}}{\left (a d - b c\right )^{3}} + 2 B a d^{4} - \frac {2 B b^{4} c^{4} d^{3}}{\left (a d - b c\right )^{3}} + 2 B b c d^{3}}{4 B b d^{4}} \right )}}{3 b g^{4} \left (a d - b c\right )^{3}} - \frac {2 B d^{3} \log {\left (x + \frac {\frac {2 B a^{4} d^{7}}{\left (a d - b c\right )^{3}} - \frac {8 B a^{3} b c d^{6}}{\left (a d - b c\right )^{3}} + \frac {12 B a^{2} b^{2} c^{2} d^{5}}{\left (a d - b c\right )^{3}} - \frac {8 B a b^{3} c^{3} d^{4}}{\left (a d - b c\right )^{3}} + 2 B a d^{4} + \frac {2 B b^{4} c^{4} d^{3}}{\left (a d - b c\right )^{3}} + 2 B b c d^{3}}{4 B b d^{4}} \right )}}{3 b g^{4} \left (a d - b c\right )^{3}} + \frac {- 3 A a^{2} d^{2} + 6 A a b c d - 3 A b^{2} c^{2} + 11 B a^{2} d^{2} - 7 B a b c d + 2 B b^{2} c^{2} + 6 B b^{2} d^{2} x^{2} + x \left (15 B a b d^{2} - 3 B b^{2} c d\right )}{9 a^{5} b d^{2} g^{4} - 18 a^{4} b^{2} c d g^{4} + 9 a^{3} b^{3} c^{2} g^{4} + x^{3} \cdot \left (9 a^{2} b^{4} d^{2} g^{4} - 18 a b^{5} c d g^{4} + 9 b^{6} c^{2} g^{4}\right ) + x^{2} \cdot \left (27 a^{3} b^{3} d^{2} g^{4} - 54 a^{2} b^{4} c d g^{4} + 27 a b^{5} c^{2} g^{4}\right ) + x \left (27 a^{4} b^{2} d^{2} g^{4} - 54 a^{3} b^{3} c d g^{4} + 27 a^{2} b^{4} c^{2} g^{4}\right )} \] Input:
integrate((A+B*ln(e*(d*x+c)**2/(b*x+a)**2))/(b*g*x+a*g)**4,x)
Output:
-B*log(e*(c + d*x)**2/(a + b*x)**2)/(3*a**3*b*g**4 + 9*a**2*b**2*g**4*x + 9*a*b**3*g**4*x**2 + 3*b**4*g**4*x**3) + 2*B*d**3*log(x + (-2*B*a**4*d**7/ (a*d - b*c)**3 + 8*B*a**3*b*c*d**6/(a*d - b*c)**3 - 12*B*a**2*b**2*c**2*d* *5/(a*d - b*c)**3 + 8*B*a*b**3*c**3*d**4/(a*d - b*c)**3 + 2*B*a*d**4 - 2*B *b**4*c**4*d**3/(a*d - b*c)**3 + 2*B*b*c*d**3)/(4*B*b*d**4))/(3*b*g**4*(a* d - b*c)**3) - 2*B*d**3*log(x + (2*B*a**4*d**7/(a*d - b*c)**3 - 8*B*a**3*b *c*d**6/(a*d - b*c)**3 + 12*B*a**2*b**2*c**2*d**5/(a*d - b*c)**3 - 8*B*a*b **3*c**3*d**4/(a*d - b*c)**3 + 2*B*a*d**4 + 2*B*b**4*c**4*d**3/(a*d - b*c) **3 + 2*B*b*c*d**3)/(4*B*b*d**4))/(3*b*g**4*(a*d - b*c)**3) + (-3*A*a**2*d **2 + 6*A*a*b*c*d - 3*A*b**2*c**2 + 11*B*a**2*d**2 - 7*B*a*b*c*d + 2*B*b** 2*c**2 + 6*B*b**2*d**2*x**2 + x*(15*B*a*b*d**2 - 3*B*b**2*c*d))/(9*a**5*b* d**2*g**4 - 18*a**4*b**2*c*d*g**4 + 9*a**3*b**3*c**2*g**4 + x**3*(9*a**2*b **4*d**2*g**4 - 18*a*b**5*c*d*g**4 + 9*b**6*c**2*g**4) + x**2*(27*a**3*b** 3*d**2*g**4 - 54*a**2*b**4*c*d*g**4 + 27*a*b**5*c**2*g**4) + x*(27*a**4*b* *2*d**2*g**4 - 54*a**3*b**3*c*d*g**4 + 27*a**2*b**4*c**2*g**4))
Leaf count of result is larger than twice the leaf count of optimal. 480 vs. \(2 (165) = 330\).
Time = 0.05 (sec) , antiderivative size = 480, normalized size of antiderivative = 2.71 \[ \int \frac {A+B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )}{(a g+b g x)^4} \, dx=\frac {1}{9} \, B {\left (\frac {6 \, b^{2} d^{2} x^{2} + 2 \, b^{2} c^{2} - 7 \, a b c d + 11 \, a^{2} d^{2} - 3 \, {\left (b^{2} c d - 5 \, a b d^{2}\right )} x}{{\left (b^{6} c^{2} - 2 \, a b^{5} c d + a^{2} b^{4} d^{2}\right )} g^{4} x^{3} + 3 \, {\left (a b^{5} c^{2} - 2 \, a^{2} b^{4} c d + a^{3} b^{3} d^{2}\right )} g^{4} x^{2} + 3 \, {\left (a^{2} b^{4} c^{2} - 2 \, a^{3} b^{3} c d + a^{4} b^{2} d^{2}\right )} g^{4} x + {\left (a^{3} b^{3} c^{2} - 2 \, a^{4} b^{2} c d + a^{5} b d^{2}\right )} g^{4}} - \frac {3 \, \log \left (\frac {d^{2} e x^{2}}{b^{2} x^{2} + 2 \, a b x + a^{2}} + \frac {2 \, c d e x}{b^{2} x^{2} + 2 \, a b x + a^{2}} + \frac {c^{2} e}{b^{2} x^{2} + 2 \, a b x + a^{2}}\right )}{b^{4} g^{4} x^{3} + 3 \, a b^{3} g^{4} x^{2} + 3 \, a^{2} b^{2} g^{4} x + a^{3} b g^{4}} + \frac {6 \, d^{3} \log \left (b x + a\right )}{{\left (b^{4} c^{3} - 3 \, a b^{3} c^{2} d + 3 \, a^{2} b^{2} c d^{2} - a^{3} b d^{3}\right )} g^{4}} - \frac {6 \, d^{3} \log \left (d x + c\right )}{{\left (b^{4} c^{3} - 3 \, a b^{3} c^{2} d + 3 \, a^{2} b^{2} c d^{2} - a^{3} b d^{3}\right )} g^{4}}\right )} - \frac {A}{3 \, {\left (b^{4} g^{4} x^{3} + 3 \, a b^{3} g^{4} x^{2} + 3 \, a^{2} b^{2} g^{4} x + a^{3} b g^{4}\right )}} \] Input:
integrate((A+B*log(e*(d*x+c)^2/(b*x+a)^2))/(b*g*x+a*g)^4,x, algorithm="max ima")
Output:
1/9*B*((6*b^2*d^2*x^2 + 2*b^2*c^2 - 7*a*b*c*d + 11*a^2*d^2 - 3*(b^2*c*d - 5*a*b*d^2)*x)/((b^6*c^2 - 2*a*b^5*c*d + a^2*b^4*d^2)*g^4*x^3 + 3*(a*b^5*c^ 2 - 2*a^2*b^4*c*d + a^3*b^3*d^2)*g^4*x^2 + 3*(a^2*b^4*c^2 - 2*a^3*b^3*c*d + a^4*b^2*d^2)*g^4*x + (a^3*b^3*c^2 - 2*a^4*b^2*c*d + a^5*b*d^2)*g^4) - 3* log(d^2*e*x^2/(b^2*x^2 + 2*a*b*x + a^2) + 2*c*d*e*x/(b^2*x^2 + 2*a*b*x + a ^2) + c^2*e/(b^2*x^2 + 2*a*b*x + a^2))/(b^4*g^4*x^3 + 3*a*b^3*g^4*x^2 + 3* a^2*b^2*g^4*x + a^3*b*g^4) + 6*d^3*log(b*x + a)/((b^4*c^3 - 3*a*b^3*c^2*d + 3*a^2*b^2*c*d^2 - a^3*b*d^3)*g^4) - 6*d^3*log(d*x + c)/((b^4*c^3 - 3*a*b ^3*c^2*d + 3*a^2*b^2*c*d^2 - a^3*b*d^3)*g^4)) - 1/3*A/(b^4*g^4*x^3 + 3*a*b ^3*g^4*x^2 + 3*a^2*b^2*g^4*x + a^3*b*g^4)
Leaf count of result is larger than twice the leaf count of optimal. 477 vs. \(2 (165) = 330\).
Time = 0.15 (sec) , antiderivative size = 477, normalized size of antiderivative = 2.69 \[ \int \frac {A+B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )}{(a g+b g x)^4} \, dx=\frac {2 \, B d^{3} \log \left (b x + a\right )}{3 \, {\left (b^{4} c^{3} g^{4} - 3 \, a b^{3} c^{2} d g^{4} + 3 \, a^{2} b^{2} c d^{2} g^{4} - a^{3} b d^{3} g^{4}\right )}} - \frac {2 \, B d^{3} \log \left (d x + c\right )}{3 \, {\left (b^{4} c^{3} g^{4} - 3 \, a b^{3} c^{2} d g^{4} + 3 \, a^{2} b^{2} c d^{2} g^{4} - a^{3} b d^{3} g^{4}\right )}} - \frac {B \log \left (\frac {d^{2} e x^{2} + 2 \, c d e x + c^{2} e}{b^{2} x^{2} + 2 \, a b x + a^{2}}\right )}{3 \, {\left (b^{4} g^{4} x^{3} + 3 \, a b^{3} g^{4} x^{2} + 3 \, a^{2} b^{2} g^{4} x + a^{3} b g^{4}\right )}} + \frac {6 \, B b^{2} d^{2} x^{2} - 3 \, B b^{2} c d x + 15 \, B a b d^{2} x - 3 \, A b^{2} c^{2} + 2 \, B b^{2} c^{2} + 6 \, A a b c d - 7 \, B a b c d - 3 \, A a^{2} d^{2} + 11 \, B a^{2} d^{2}}{9 \, {\left (b^{6} c^{2} g^{4} x^{3} - 2 \, a b^{5} c d g^{4} x^{3} + a^{2} b^{4} d^{2} g^{4} x^{3} + 3 \, a b^{5} c^{2} g^{4} x^{2} - 6 \, a^{2} b^{4} c d g^{4} x^{2} + 3 \, a^{3} b^{3} d^{2} g^{4} x^{2} + 3 \, a^{2} b^{4} c^{2} g^{4} x - 6 \, a^{3} b^{3} c d g^{4} x + 3 \, a^{4} b^{2} d^{2} g^{4} x + a^{3} b^{3} c^{2} g^{4} - 2 \, a^{4} b^{2} c d g^{4} + a^{5} b d^{2} g^{4}\right )}} \] Input:
integrate((A+B*log(e*(d*x+c)^2/(b*x+a)^2))/(b*g*x+a*g)^4,x, algorithm="gia c")
Output:
2/3*B*d^3*log(b*x + a)/(b^4*c^3*g^4 - 3*a*b^3*c^2*d*g^4 + 3*a^2*b^2*c*d^2* g^4 - a^3*b*d^3*g^4) - 2/3*B*d^3*log(d*x + c)/(b^4*c^3*g^4 - 3*a*b^3*c^2*d *g^4 + 3*a^2*b^2*c*d^2*g^4 - a^3*b*d^3*g^4) - 1/3*B*log((d^2*e*x^2 + 2*c*d *e*x + c^2*e)/(b^2*x^2 + 2*a*b*x + a^2))/(b^4*g^4*x^3 + 3*a*b^3*g^4*x^2 + 3*a^2*b^2*g^4*x + a^3*b*g^4) + 1/9*(6*B*b^2*d^2*x^2 - 3*B*b^2*c*d*x + 15*B *a*b*d^2*x - 3*A*b^2*c^2 + 2*B*b^2*c^2 + 6*A*a*b*c*d - 7*B*a*b*c*d - 3*A*a ^2*d^2 + 11*B*a^2*d^2)/(b^6*c^2*g^4*x^3 - 2*a*b^5*c*d*g^4*x^3 + a^2*b^4*d^ 2*g^4*x^3 + 3*a*b^5*c^2*g^4*x^2 - 6*a^2*b^4*c*d*g^4*x^2 + 3*a^3*b^3*d^2*g^ 4*x^2 + 3*a^2*b^4*c^2*g^4*x - 6*a^3*b^3*c*d*g^4*x + 3*a^4*b^2*d^2*g^4*x + a^3*b^3*c^2*g^4 - 2*a^4*b^2*c*d*g^4 + a^5*b*d^2*g^4)
Time = 27.83 (sec) , antiderivative size = 341, normalized size of antiderivative = 1.93 \[ \int \frac {A+B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )}{(a g+b g x)^4} \, dx=\frac {2\,B\,b\,c^2}{9\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {A\,b\,c^2}{3\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {B\,\ln \left (\frac {e\,{\left (c+d\,x\right )}^2}{{\left (a+b\,x\right )}^2}\right )}{3\,b\,g^4\,{\left (a+b\,x\right )}^3}-\frac {A\,a^2\,d^2}{3\,b\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}+\frac {11\,B\,a^2\,d^2}{9\,b\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}+\frac {5\,B\,a\,d^2\,x}{3\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}+\frac {2\,B\,b\,d^2\,x^2}{3\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}+\frac {2\,A\,a\,c\,d}{3\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {7\,B\,a\,c\,d}{9\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {B\,b\,c\,d\,x}{3\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}+\frac {B\,d^3\,\mathrm {atan}\left (\frac {a\,d\,1{}\mathrm {i}+b\,c\,1{}\mathrm {i}+b\,d\,x\,2{}\mathrm {i}}{a\,d-b\,c}\right )\,4{}\mathrm {i}}{3\,b\,g^4\,{\left (a\,d-b\,c\right )}^3} \] Input:
int((A + B*log((e*(c + d*x)^2)/(a + b*x)^2))/(a*g + b*g*x)^4,x)
Output:
(B*d^3*atan((a*d*1i + b*c*1i + b*d*x*2i)/(a*d - b*c))*4i)/(3*b*g^4*(a*d - b*c)^3) - (B*log((e*(c + d*x)^2)/(a + b*x)^2))/(3*b*g^4*(a + b*x)^3) - (A* b*c^2)/(3*g^4*(a*d - b*c)^2*(a + b*x)^3) + (2*B*b*c^2)/(9*g^4*(a*d - b*c)^ 2*(a + b*x)^3) - (A*a^2*d^2)/(3*b*g^4*(a*d - b*c)^2*(a + b*x)^3) + (11*B*a ^2*d^2)/(9*b*g^4*(a*d - b*c)^2*(a + b*x)^3) + (5*B*a*d^2*x)/(3*g^4*(a*d - b*c)^2*(a + b*x)^3) + (2*B*b*d^2*x^2)/(3*g^4*(a*d - b*c)^2*(a + b*x)^3) + (2*A*a*c*d)/(3*g^4*(a*d - b*c)^2*(a + b*x)^3) - (7*B*a*c*d)/(9*g^4*(a*d - b*c)^2*(a + b*x)^3) - (B*b*c*d*x)/(3*g^4*(a*d - b*c)^2*(a + b*x)^3)
Time = 0.17 (sec) , antiderivative size = 698, normalized size of antiderivative = 3.94 \[ \int \frac {A+B \log \left (\frac {e (c+d x)^2}{(a+b x)^2}\right )}{(a g+b g x)^4} \, dx=\frac {9 \,\mathrm {log}\left (\frac {d^{2} e \,x^{2}+2 c d e x +c^{2} e}{b^{2} x^{2}+2 a b x +a^{2}}\right ) a^{3} b^{2} c \,d^{2}-9 \,\mathrm {log}\left (\frac {d^{2} e \,x^{2}+2 c d e x +c^{2} e}{b^{2} x^{2}+2 a b x +a^{2}}\right ) a^{2} b^{3} c^{2} d -16 a^{3} b^{2} c \,d^{2}+9 a^{3} b^{2} d^{3} x +9 a^{2} b^{3} c^{2} d -2 a \,b^{4} d^{3} x^{3}+2 b^{5} c \,d^{2} x^{3}-6 \,\mathrm {log}\left (b x +a \right ) a^{4} b \,d^{3}+6 \,\mathrm {log}\left (d x +c \right ) a^{4} b \,d^{3}+9 a^{4} b \,d^{3}-2 a \,b^{4} c^{3}+9 a^{4} b c \,d^{2}-9 a^{3} b^{2} c^{2} d -18 \,\mathrm {log}\left (b x +a \right ) a^{3} b^{2} d^{3} x -18 \,\mathrm {log}\left (b x +a \right ) a^{2} b^{3} d^{3} x^{2}-6 \,\mathrm {log}\left (b x +a \right ) a \,b^{4} d^{3} x^{3}+18 \,\mathrm {log}\left (d x +c \right ) a^{3} b^{2} d^{3} x +18 \,\mathrm {log}\left (d x +c \right ) a^{2} b^{3} d^{3} x^{2}+6 \,\mathrm {log}\left (d x +c \right ) a \,b^{4} d^{3} x^{3}-12 a^{2} b^{3} c \,d^{2} x +3 a \,b^{4} c^{2} d x -3 a^{5} d^{3}+3 a^{2} b^{3} c^{3}-3 \,\mathrm {log}\left (\frac {d^{2} e \,x^{2}+2 c d e x +c^{2} e}{b^{2} x^{2}+2 a b x +a^{2}}\right ) a^{4} b \,d^{3}+3 \,\mathrm {log}\left (\frac {d^{2} e \,x^{2}+2 c d e x +c^{2} e}{b^{2} x^{2}+2 a b x +a^{2}}\right ) a \,b^{4} c^{3}}{9 a b \,g^{4} \left (a^{3} b^{3} d^{3} x^{3}-3 a^{2} b^{4} c \,d^{2} x^{3}+3 a \,b^{5} c^{2} d \,x^{3}-b^{6} c^{3} x^{3}+3 a^{4} b^{2} d^{3} x^{2}-9 a^{3} b^{3} c \,d^{2} x^{2}+9 a^{2} b^{4} c^{2} d \,x^{2}-3 a \,b^{5} c^{3} x^{2}+3 a^{5} b \,d^{3} x -9 a^{4} b^{2} c \,d^{2} x +9 a^{3} b^{3} c^{2} d x -3 a^{2} b^{4} c^{3} x +a^{6} d^{3}-3 a^{5} b c \,d^{2}+3 a^{4} b^{2} c^{2} d -a^{3} b^{3} c^{3}\right )} \] Input:
int((A+B*log(e*(d*x+c)^2/(b*x+a)^2))/(b*g*x+a*g)^4,x)
Output:
( - 6*log(a + b*x)*a**4*b*d**3 - 18*log(a + b*x)*a**3*b**2*d**3*x - 18*log (a + b*x)*a**2*b**3*d**3*x**2 - 6*log(a + b*x)*a*b**4*d**3*x**3 + 6*log(c + d*x)*a**4*b*d**3 + 18*log(c + d*x)*a**3*b**2*d**3*x + 18*log(c + d*x)*a* *2*b**3*d**3*x**2 + 6*log(c + d*x)*a*b**4*d**3*x**3 - 3*log((c**2*e + 2*c* d*e*x + d**2*e*x**2)/(a**2 + 2*a*b*x + b**2*x**2))*a**4*b*d**3 + 9*log((c* *2*e + 2*c*d*e*x + d**2*e*x**2)/(a**2 + 2*a*b*x + b**2*x**2))*a**3*b**2*c* d**2 - 9*log((c**2*e + 2*c*d*e*x + d**2*e*x**2)/(a**2 + 2*a*b*x + b**2*x** 2))*a**2*b**3*c**2*d + 3*log((c**2*e + 2*c*d*e*x + d**2*e*x**2)/(a**2 + 2* a*b*x + b**2*x**2))*a*b**4*c**3 - 3*a**5*d**3 + 9*a**4*b*c*d**2 + 9*a**4*b *d**3 - 9*a**3*b**2*c**2*d - 16*a**3*b**2*c*d**2 + 9*a**3*b**2*d**3*x + 3* a**2*b**3*c**3 + 9*a**2*b**3*c**2*d - 12*a**2*b**3*c*d**2*x - 2*a*b**4*c** 3 + 3*a*b**4*c**2*d*x - 2*a*b**4*d**3*x**3 + 2*b**5*c*d**2*x**3)/(9*a*b*g* *4*(a**6*d**3 - 3*a**5*b*c*d**2 + 3*a**5*b*d**3*x + 3*a**4*b**2*c**2*d - 9 *a**4*b**2*c*d**2*x + 3*a**4*b**2*d**3*x**2 - a**3*b**3*c**3 + 9*a**3*b**3 *c**2*d*x - 9*a**3*b**3*c*d**2*x**2 + a**3*b**3*d**3*x**3 - 3*a**2*b**4*c* *3*x + 9*a**2*b**4*c**2*d*x**2 - 3*a**2*b**4*c*d**2*x**3 - 3*a*b**5*c**3*x **2 + 3*a*b**5*c**2*d*x**3 - b**6*c**3*x**3))