Integrand size = 45, antiderivative size = 573 \[ \int \frac {(a g+b g x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{c i+d i x} \, dx=-\frac {B (b c-a d) g^2 n (a+b x) \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )}{d^2 i}-\frac {2 (b c-a d) g^2 (a+b x) \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{d^2 i}+\frac {b^2 g^2 (c+d x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{2 d^3 i}-\frac {4 B (b c-a d)^2 g^2 n \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \log \left (\frac {b c-a d}{b (c+d x)}\right )}{d^3 i}-\frac {(b c-a d)^2 g^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2 \log \left (\frac {b c-a d}{b (c+d x)}\right )}{d^3 i}+\frac {B^2 (b c-a d)^2 g^2 n^2 \log (c+d x)}{d^3 i}+\frac {B (b c-a d)^2 g^2 n \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \log \left (1-\frac {b (c+d x)}{d (a+b x)}\right )}{d^3 i}-\frac {4 B^2 (b c-a d)^2 g^2 n^2 \operatorname {PolyLog}\left (2,\frac {d (a+b x)}{b (c+d x)}\right )}{d^3 i}-\frac {2 B (b c-a d)^2 g^2 n \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \operatorname {PolyLog}\left (2,\frac {d (a+b x)}{b (c+d x)}\right )}{d^3 i}-\frac {B^2 (b c-a d)^2 g^2 n^2 \operatorname {PolyLog}\left (2,\frac {b (c+d x)}{d (a+b x)}\right )}{d^3 i}+\frac {2 B^2 (b c-a d)^2 g^2 n^2 \operatorname {PolyLog}\left (3,\frac {d (a+b x)}{b (c+d x)}\right )}{d^3 i} \] Output:
-B*(-a*d+b*c)*g^2*n*(b*x+a)*(A+B*ln(e*((b*x+a)/(d*x+c))^n))/d^2/i-2*(-a*d+ b*c)*g^2*(b*x+a)*(A+B*ln(e*((b*x+a)/(d*x+c))^n))^2/d^2/i+1/2*b^2*g^2*(d*x+ c)^2*(A+B*ln(e*((b*x+a)/(d*x+c))^n))^2/d^3/i-4*B*(-a*d+b*c)^2*g^2*n*(A+B*l n(e*((b*x+a)/(d*x+c))^n))*ln((-a*d+b*c)/b/(d*x+c))/d^3/i-(-a*d+b*c)^2*g^2* (A+B*ln(e*((b*x+a)/(d*x+c))^n))^2*ln((-a*d+b*c)/b/(d*x+c))/d^3/i+B^2*(-a*d +b*c)^2*g^2*n^2*ln(d*x+c)/d^3/i+B*(-a*d+b*c)^2*g^2*n*(A+B*ln(e*((b*x+a)/(d *x+c))^n))*ln(1-b*(d*x+c)/d/(b*x+a))/d^3/i-4*B^2*(-a*d+b*c)^2*g^2*n^2*poly log(2,d*(b*x+a)/b/(d*x+c))/d^3/i-2*B*(-a*d+b*c)^2*g^2*n*(A+B*ln(e*((b*x+a) /(d*x+c))^n))*polylog(2,d*(b*x+a)/b/(d*x+c))/d^3/i-B^2*(-a*d+b*c)^2*g^2*n^ 2*polylog(2,b*(d*x+c)/d/(b*x+a))/d^3/i+2*B^2*(-a*d+b*c)^2*g^2*n^2*polylog( 3,d*(b*x+a)/b/(d*x+c))/d^3/i
Time = 1.38 (sec) , antiderivative size = 763, normalized size of antiderivative = 1.33 \[ \int \frac {(a g+b g x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{c i+d i x} \, dx=\frac {g^2 \left (-2 b d (b c-a d) x \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2+d^2 (a+b x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2+2 A^2 (b c-a d)^2 \log (c+d x)-4 A B (b c-a d)^2 \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right ) \log \left (\frac {b c-a d}{b c+b d x}\right )-2 B^2 (b c-a d)^2 \log ^2\left (e \left (\frac {a+b x}{c+d x}\right )^n\right ) \log \left (\frac {b c-a d}{b c+b d x}\right )+2 A B (b c-a d)^2 n \left (\log \left (\frac {b c-a d}{b c+b d x}\right ) \left (2 \log \left (\frac {d (a+b x)}{-b c+a d}\right )+\log \left (\frac {b c-a d}{b c+b d x}\right )\right )-2 \operatorname {PolyLog}\left (2,\frac {b (c+d x)}{b c-a d}\right )\right )-2 B (b c-a d) n \left (2 a d \log (a+b x) \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )-2 b c \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \log (c+d x)-a B d n \left (\log (a+b x) \left (\log (a+b x)-2 \log \left (\frac {b (c+d x)}{b c-a d}\right )\right )-2 \operatorname {PolyLog}\left (2,\frac {d (a+b x)}{-b c+a d}\right )\right )+b B c n \left (\left (2 \log \left (\frac {d (a+b x)}{-b c+a d}\right )-\log (c+d x)\right ) \log (c+d x)+2 \operatorname {PolyLog}\left (2,\frac {b (c+d x)}{b c-a d}\right )\right )\right )-B (b c-a d) n \left (2 A b d x+2 B d (a+b x) \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )-2 B (b c-a d) n \log (c+d x)-2 (b c-a d) \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \log (c+d x)+B (b c-a d) n \left (\left (2 \log \left (\frac {d (a+b x)}{-b c+a d}\right )-\log (c+d x)\right ) \log (c+d x)+2 \operatorname {PolyLog}\left (2,\frac {b (c+d x)}{b c-a d}\right )\right )\right )+4 B^2 (b c-a d)^2 n \left (-\log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right ) \operatorname {PolyLog}\left (2,\frac {d (a+b x)}{b (c+d x)}\right )+n \operatorname {PolyLog}\left (3,\frac {d (a+b x)}{b (c+d x)}\right )\right )\right )}{2 d^3 i} \] Input:
Integrate[((a*g + b*g*x)^2*(A + B*Log[e*((a + b*x)/(c + d*x))^n])^2)/(c*i + d*i*x),x]
Output:
(g^2*(-2*b*d*(b*c - a*d)*x*(A + B*Log[e*((a + b*x)/(c + d*x))^n])^2 + d^2* (a + b*x)^2*(A + B*Log[e*((a + b*x)/(c + d*x))^n])^2 + 2*A^2*(b*c - a*d)^2 *Log[c + d*x] - 4*A*B*(b*c - a*d)^2*Log[e*((a + b*x)/(c + d*x))^n]*Log[(b* c - a*d)/(b*c + b*d*x)] - 2*B^2*(b*c - a*d)^2*Log[e*((a + b*x)/(c + d*x))^ n]^2*Log[(b*c - a*d)/(b*c + b*d*x)] + 2*A*B*(b*c - a*d)^2*n*(Log[(b*c - a* d)/(b*c + b*d*x)]*(2*Log[(d*(a + b*x))/(-(b*c) + a*d)] + Log[(b*c - a*d)/( b*c + b*d*x)]) - 2*PolyLog[2, (b*(c + d*x))/(b*c - a*d)]) - 2*B*(b*c - a*d )*n*(2*a*d*Log[a + b*x]*(A + B*Log[e*((a + b*x)/(c + d*x))^n]) - 2*b*c*(A + B*Log[e*((a + b*x)/(c + d*x))^n])*Log[c + d*x] - a*B*d*n*(Log[a + b*x]*( Log[a + b*x] - 2*Log[(b*(c + d*x))/(b*c - a*d)]) - 2*PolyLog[2, (d*(a + b* x))/(-(b*c) + a*d)]) + b*B*c*n*((2*Log[(d*(a + b*x))/(-(b*c) + a*d)] - Log [c + d*x])*Log[c + d*x] + 2*PolyLog[2, (b*(c + d*x))/(b*c - a*d)])) - B*(b *c - a*d)*n*(2*A*b*d*x + 2*B*d*(a + b*x)*Log[e*((a + b*x)/(c + d*x))^n] - 2*B*(b*c - a*d)*n*Log[c + d*x] - 2*(b*c - a*d)*(A + B*Log[e*((a + b*x)/(c + d*x))^n])*Log[c + d*x] + B*(b*c - a*d)*n*((2*Log[(d*(a + b*x))/(-(b*c) + a*d)] - Log[c + d*x])*Log[c + d*x] + 2*PolyLog[2, (b*(c + d*x))/(b*c - a* d)])) + 4*B^2*(b*c - a*d)^2*n*(-(Log[e*((a + b*x)/(c + d*x))^n]*PolyLog[2, (d*(a + b*x))/(b*(c + d*x))]) + n*PolyLog[3, (d*(a + b*x))/(b*(c + d*x))] )))/(2*d^3*i)
Time = 0.87 (sec) , antiderivative size = 507, normalized size of antiderivative = 0.88, number of steps used = 4, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.067, Rules used = {2961, 2795, 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 {(a g+b g x)^2 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )^2}{c i+d i x} \, dx\) |
\(\Big \downarrow \) 2961 |
\(\displaystyle \frac {g^2 (b c-a d)^2 \int \frac {(a+b x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{(c+d x)^2 \left (b-\frac {d (a+b x)}{c+d x}\right )^3}d\frac {a+b x}{c+d x}}{i}\) |
\(\Big \downarrow \) 2795 |
\(\displaystyle \frac {g^2 (b c-a d)^2 \int \left (\frac {\left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{d^2 \left (b-\frac {d (a+b x)}{c+d x}\right )}-\frac {2 b \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{d^2 \left (b-\frac {d (a+b x)}{c+d x}\right )^2}+\frac {b^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{d^2 \left (b-\frac {d (a+b x)}{c+d x}\right )^3}\right )d\frac {a+b x}{c+d x}}{i}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {g^2 (b c-a d)^2 \left (\frac {b^2 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )^2}{2 d^3 \left (b-\frac {d (a+b x)}{c+d x}\right )^2}-\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 )}{d^3}-\frac {4 B n \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 )}{d^3}+\frac {B n \log \left (1-\frac {b (c+d x)}{d (a+b x)}\right ) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{d^3}-\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}{d^3}-\frac {B n (a+b x) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{d^2 (c+d x) \left (b-\frac {d (a+b x)}{c+d x}\right )}-\frac {2 (a+b x) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )^2}{d^2 (c+d x) \left (b-\frac {d (a+b x)}{c+d x}\right )}-\frac {4 B^2 n^2 \operatorname {PolyLog}\left (2,\frac {d (a+b x)}{b (c+d x)}\right )}{d^3}-\frac {B^2 n^2 \operatorname {PolyLog}\left (2,\frac {b (c+d x)}{d (a+b x)}\right )}{d^3}+\frac {2 B^2 n^2 \operatorname {PolyLog}\left (3,\frac {d (a+b x)}{b (c+d x)}\right )}{d^3}-\frac {B^2 n^2 \log \left (b-\frac {d (a+b x)}{c+d x}\right )}{d^3}\right )}{i}\) |
Input:
Int[((a*g + b*g*x)^2*(A + B*Log[e*((a + b*x)/(c + d*x))^n])^2)/(c*i + d*i* x),x]
Output:
((b*c - a*d)^2*g^2*(-((B*n*(a + b*x)*(A + B*Log[e*((a + b*x)/(c + d*x))^n] ))/(d^2*(c + d*x)*(b - (d*(a + b*x))/(c + d*x)))) + (b^2*(A + B*Log[e*((a + b*x)/(c + d*x))^n])^2)/(2*d^3*(b - (d*(a + b*x))/(c + d*x))^2) - (2*(a + b*x)*(A + B*Log[e*((a + b*x)/(c + d*x))^n])^2)/(d^2*(c + d*x)*(b - (d*(a + b*x))/(c + d*x))) - (B^2*n^2*Log[b - (d*(a + b*x))/(c + d*x)])/d^3 - (4* B*n*(A + B*Log[e*((a + b*x)/(c + d*x))^n])*Log[1 - (d*(a + b*x))/(b*(c + d *x))])/d^3 - ((A + B*Log[e*((a + b*x)/(c + d*x))^n])^2*Log[1 - (d*(a + b*x ))/(b*(c + d*x))])/d^3 + (B*n*(A + B*Log[e*((a + b*x)/(c + d*x))^n])*Log[1 - (b*(c + d*x))/(d*(a + b*x))])/d^3 - (4*B^2*n^2*PolyLog[2, (d*(a + b*x)) /(b*(c + d*x))])/d^3 - (2*B*n*(A + B*Log[e*((a + b*x)/(c + d*x))^n])*PolyL og[2, (d*(a + b*x))/(b*(c + d*x))])/d^3 - (B^2*n^2*PolyLog[2, (b*(c + d*x) )/(d*(a + b*x))])/d^3 + (2*B^2*n^2*PolyLog[3, (d*(a + b*x))/(b*(c + d*x))] )/d^3))/i
Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*((f_.)*(x_))^(m_.)*((d_) + (e_.)*(x_)^(r_.))^(q_.), x_Symbol] :> With[{u = ExpandIntegrand[(a + b*Log[ c*x^n])^p, (f*x)^m*(d + e*x^r)^q, x]}, Int[u, x] /; SumQ[u]] /; FreeQ[{a, b , c, d, e, f, m, n, p, q, r}, x] && IntegerQ[q] && (GtQ[q, 0] || (IGtQ[p, 0 ] && IntegerQ[m] && IntegerQ[r]))
Int[((A_.) + Log[(e_.)*(((a_.) + (b_.)*(x_))/((c_.) + (d_.)*(x_)))^(n_.)]*( B_.))^(p_.)*((f_.) + (g_.)*(x_))^(m_.)*((h_.) + (i_.)*(x_))^(q_.), x_Symbol ] :> Simp[(b*c - a*d)^(m + q + 1)*(g/b)^m*(i/d)^q Subst[Int[x^m*((A + B*L og[e*x^n])^p/(b - d*x)^(m + q + 2)), x], x, (a + b*x)/(c + d*x)], x] /; Fre eQ[{a, b, c, d, e, f, g, h, i, A, B, n, p}, x] && NeQ[b*c - a*d, 0] && EqQ[ b*f - a*g, 0] && EqQ[d*h - c*i, 0] && IntegersQ[m, q]
\[\int \frac {\left (b g x +a g \right )^{2} {\left (A +B \ln \left (e \left (\frac {b x +a}{d x +c}\right )^{n}\right )\right )}^{2}}{d i x +c i}d x\]
Input:
int((b*g*x+a*g)^2*(A+B*ln(e*((b*x+a)/(d*x+c))^n))^2/(d*i*x+c*i),x)
Output:
int((b*g*x+a*g)^2*(A+B*ln(e*((b*x+a)/(d*x+c))^n))^2/(d*i*x+c*i),x)
\[ \int \frac {(a g+b g x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{c i+d i x} \, dx=\int { \frac {{\left (b g x + a g\right )}^{2} {\left (B \log \left (e \left (\frac {b x + a}{d x + c}\right )^{n}\right ) + A\right )}^{2}}{d i x + c i} \,d x } \] Input:
integrate((b*g*x+a*g)^2*(A+B*log(e*((b*x+a)/(d*x+c))^n))^2/(d*i*x+c*i),x, algorithm="fricas")
Output:
integral((A^2*b^2*g^2*x^2 + 2*A^2*a*b*g^2*x + A^2*a^2*g^2 + (B^2*b^2*g^2*x ^2 + 2*B^2*a*b*g^2*x + B^2*a^2*g^2)*log(e*((b*x + a)/(d*x + c))^n)^2 + 2*( A*B*b^2*g^2*x^2 + 2*A*B*a*b*g^2*x + A*B*a^2*g^2)*log(e*((b*x + a)/(d*x + c ))^n))/(d*i*x + c*i), x)
\[ \int \frac {(a g+b g x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{c i+d i x} \, dx=\frac {g^{2} \left (\int \frac {A^{2} a^{2}}{c + d x}\, dx + \int \frac {A^{2} b^{2} x^{2}}{c + d x}\, dx + \int \frac {B^{2} a^{2} \log {\left (e \left (\frac {a}{c + d x} + \frac {b x}{c + d x}\right )^{n} \right )}^{2}}{c + d x}\, dx + \int \frac {2 A B a^{2} \log {\left (e \left (\frac {a}{c + d x} + \frac {b x}{c + d x}\right )^{n} \right )}}{c + d x}\, dx + \int \frac {2 A^{2} a b x}{c + d x}\, dx + \int \frac {B^{2} b^{2} x^{2} \log {\left (e \left (\frac {a}{c + d x} + \frac {b x}{c + d x}\right )^{n} \right )}^{2}}{c + d x}\, dx + \int \frac {2 A B b^{2} x^{2} \log {\left (e \left (\frac {a}{c + d x} + \frac {b x}{c + d x}\right )^{n} \right )}}{c + d x}\, dx + \int \frac {2 B^{2} a b x \log {\left (e \left (\frac {a}{c + d x} + \frac {b x}{c + d x}\right )^{n} \right )}^{2}}{c + d x}\, dx + \int \frac {4 A B a b x \log {\left (e \left (\frac {a}{c + d x} + \frac {b x}{c + d x}\right )^{n} \right )}}{c + d x}\, dx\right )}{i} \] Input:
integrate((b*g*x+a*g)**2*(A+B*ln(e*((b*x+a)/(d*x+c))**n))**2/(d*i*x+c*i),x )
Output:
g**2*(Integral(A**2*a**2/(c + d*x), x) + Integral(A**2*b**2*x**2/(c + d*x) , x) + Integral(B**2*a**2*log(e*(a/(c + d*x) + b*x/(c + d*x))**n)**2/(c + d*x), x) + Integral(2*A*B*a**2*log(e*(a/(c + d*x) + b*x/(c + d*x))**n)/(c + d*x), x) + Integral(2*A**2*a*b*x/(c + d*x), x) + Integral(B**2*b**2*x**2 *log(e*(a/(c + d*x) + b*x/(c + d*x))**n)**2/(c + d*x), x) + Integral(2*A*B *b**2*x**2*log(e*(a/(c + d*x) + b*x/(c + d*x))**n)/(c + d*x), x) + Integra l(2*B**2*a*b*x*log(e*(a/(c + d*x) + b*x/(c + d*x))**n)**2/(c + d*x), x) + Integral(4*A*B*a*b*x*log(e*(a/(c + d*x) + b*x/(c + d*x))**n)/(c + d*x), x) )/i
\[ \int \frac {(a g+b g x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{c i+d i x} \, dx=\int { \frac {{\left (b g x + a g\right )}^{2} {\left (B \log \left (e \left (\frac {b x + a}{d x + c}\right )^{n}\right ) + A\right )}^{2}}{d i x + c i} \,d x } \] Input:
integrate((b*g*x+a*g)^2*(A+B*log(e*((b*x+a)/(d*x+c))^n))^2/(d*i*x+c*i),x, algorithm="maxima")
Output:
2*A^2*a*b*g^2*(x/(d*i) - c*log(d*x + c)/(d^2*i)) + 1/2*A^2*b^2*g^2*(2*c^2* log(d*x + c)/(d^3*i) + (d*x^2 - 2*c*x)/(d^2*i)) + A^2*a^2*g^2*log(d*i*x + c*i)/(d*i) + 1/2*(B^2*b^2*d^2*g^2*x^2 - 2*(b^2*c*d*g^2 - 2*a*b*d^2*g^2)*B^ 2*x + 2*(b^2*c^2*g^2 - 2*a*b*c*d*g^2 + a^2*d^2*g^2)*B^2*log(d*x + c))*log( (d*x + c)^n)^2/(d^3*i) - integrate(-(B^2*a^2*d^2*g^2*log(e)^2 + 2*A*B*a^2* d^2*g^2*log(e) + (B^2*b^2*d^2*g^2*log(e)^2 + 2*A*B*b^2*d^2*g^2*log(e))*x^2 + (B^2*b^2*d^2*g^2*x^2 + 2*B^2*a*b*d^2*g^2*x + B^2*a^2*d^2*g^2)*log((b*x + a)^n)^2 + 2*(B^2*a*b*d^2*g^2*log(e)^2 + 2*A*B*a*b*d^2*g^2*log(e))*x + 2* (B^2*a^2*d^2*g^2*log(e) + A*B*a^2*d^2*g^2 + (B^2*b^2*d^2*g^2*log(e) + A*B* b^2*d^2*g^2)*x^2 + 2*(B^2*a*b*d^2*g^2*log(e) + A*B*a*b*d^2*g^2)*x)*log((b* x + a)^n) - (2*B^2*a^2*d^2*g^2*log(e) + 2*A*B*a^2*d^2*g^2 + 2*(b^2*c^2*g^2 *n - 2*a*b*c*d*g^2*n + a^2*d^2*g^2*n)*B^2*log(d*x + c) + (2*A*B*b^2*d^2*g^ 2 + (g^2*n + 2*g^2*log(e))*B^2*b^2*d^2)*x^2 + 2*(2*A*B*a*b*d^2*g^2 - (b^2* c*d*g^2*n - 2*(g^2*n + g^2*log(e))*a*b*d^2)*B^2)*x + 2*(B^2*b^2*d^2*g^2*x^ 2 + 2*B^2*a*b*d^2*g^2*x + B^2*a^2*d^2*g^2)*log((b*x + a)^n))*log((d*x + c) ^n))/(d^3*i*x + c*d^2*i), x)
\[ \int \frac {(a g+b g x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{c i+d i x} \, dx=\int { \frac {{\left (b g x + a g\right )}^{2} {\left (B \log \left (e \left (\frac {b x + a}{d x + c}\right )^{n}\right ) + A\right )}^{2}}{d i x + c i} \,d x } \] Input:
integrate((b*g*x+a*g)^2*(A+B*log(e*((b*x+a)/(d*x+c))^n))^2/(d*i*x+c*i),x, algorithm="giac")
Output:
integrate((b*g*x + a*g)^2*(B*log(e*((b*x + a)/(d*x + c))^n) + A)^2/(d*i*x + c*i), x)
Timed out. \[ \int \frac {(a g+b g x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{c i+d i x} \, dx=\int \frac {{\left (a\,g+b\,g\,x\right )}^2\,{\left (A+B\,\ln \left (e\,{\left (\frac {a+b\,x}{c+d\,x}\right )}^n\right )\right )}^2}{c\,i+d\,i\,x} \,d x \] Input:
int(((a*g + b*g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(c*i + d*i* x),x)
Output:
int(((a*g + b*g*x)^2*(A + B*log(e*((a + b*x)/(c + d*x))^n))^2)/(c*i + d*i* x), x)
\[ \int \frac {(a g+b g x)^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )^2}{c i+d i x} \, dx=\frac {g^{2} i \left (-2 \left (\int \frac {\mathrm {log}\left (\frac {\left (b x +a \right )^{n} e}{\left (d x +c \right )^{n}}\right )^{2}}{d x +c}d x \right ) a^{2} b^{2} d^{3}-4 \left (\int \frac {\mathrm {log}\left (\frac {\left (b x +a \right )^{n} e}{\left (d x +c \right )^{n}}\right )}{d x +c}d x \right ) a^{3} b \,d^{3}-2 \left (\int \frac {\mathrm {log}\left (\frac {\left (b x +a \right )^{n} e}{\left (d x +c \right )^{n}}\right )^{2} x^{2}}{d x +c}d x \right ) b^{4} d^{3}-4 \left (\int \frac {\mathrm {log}\left (\frac {\left (b x +a \right )^{n} e}{\left (d x +c \right )^{n}}\right )^{2} x}{d x +c}d x \right ) a \,b^{3} d^{3}-4 \left (\int \frac {\mathrm {log}\left (\frac {\left (b x +a \right )^{n} e}{\left (d x +c \right )^{n}}\right ) x^{2}}{d x +c}d x \right ) a \,b^{3} d^{3}-8 \left (\int \frac {\mathrm {log}\left (\frac {\left (b x +a \right )^{n} e}{\left (d x +c \right )^{n}}\right ) x}{d x +c}d x \right ) a^{2} b^{2} d^{3}-2 \,\mathrm {log}\left (d x +c \right ) a^{4} d^{2}+4 \,\mathrm {log}\left (d x +c \right ) a^{3} b c d -2 \,\mathrm {log}\left (d x +c \right ) a^{2} b^{2} c^{2}-4 a^{3} b \,d^{2} x +2 a^{2} b^{2} c d x -a^{2} b^{2} d^{2} x^{2}\right )}{2 d^{3}} \] Input:
int((b*g*x+a*g)^2*(A+B*log(e*((b*x+a)/(d*x+c))^n))^2/(d*i*x+c*i),x)
Output:
(g**2*i*( - 2*int(log(((a + b*x)**n*e)/(c + d*x)**n)**2/(c + d*x),x)*a**2* b**2*d**3 - 4*int(log(((a + b*x)**n*e)/(c + d*x)**n)/(c + d*x),x)*a**3*b*d **3 - 2*int((log(((a + b*x)**n*e)/(c + d*x)**n)**2*x**2)/(c + d*x),x)*b**4 *d**3 - 4*int((log(((a + b*x)**n*e)/(c + d*x)**n)**2*x)/(c + d*x),x)*a*b** 3*d**3 - 4*int((log(((a + b*x)**n*e)/(c + d*x)**n)*x**2)/(c + d*x),x)*a*b* *3*d**3 - 8*int((log(((a + b*x)**n*e)/(c + d*x)**n)*x)/(c + d*x),x)*a**2*b **2*d**3 - 2*log(c + d*x)*a**4*d**2 + 4*log(c + d*x)*a**3*b*c*d - 2*log(c + d*x)*a**2*b**2*c**2 - 4*a**3*b*d**2*x + 2*a**2*b**2*c*d*x - a**2*b**2*d* *2*x**2))/(2*d**3)