\(\int \frac {\log (d (a+b x+c x^2)^n)}{x} \, dx\) [76]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [F]
   Sympy [F]
   Maxima [F]
   Giac [F]
   Mupad [F(-1)]

Optimal result

Integrand size = 19, antiderivative size = 129 \[ \int \frac {\log \left (d \left (a+b x+c x^2\right )^n\right )}{x} \, dx=-n \log (x) \log \left (1+\frac {2 c x}{b-\sqrt {b^2-4 a c}}\right )-n \log (x) \log \left (1+\frac {2 c x}{b+\sqrt {b^2-4 a c}}\right )+\log (x) \log \left (d \left (a+b x+c x^2\right )^n\right )-n \operatorname {PolyLog}\left (2,-\frac {2 c x}{b-\sqrt {b^2-4 a c}}\right )-n \operatorname {PolyLog}\left (2,-\frac {2 c x}{b+\sqrt {b^2-4 a c}}\right ) \]

[Out]

ln(x)*ln(d*(c*x^2+b*x+a)^n)-n*ln(x)*ln(1+2*c*x/(b-(-4*a*c+b^2)^(1/2)))-n*ln(x)*ln(1+2*c*x/(b+(-4*a*c+b^2)^(1/2
)))-n*polylog(2,-2*c*x/(b-(-4*a*c+b^2)^(1/2)))-n*polylog(2,-2*c*x/(b+(-4*a*c+b^2)^(1/2)))

Rubi [A] (verified)

Time = 0.11 (sec) , antiderivative size = 129, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.211, Rules used = {2604, 2404, 2354, 2438} \[ \int \frac {\log \left (d \left (a+b x+c x^2\right )^n\right )}{x} \, dx=-n \operatorname {PolyLog}\left (2,-\frac {2 c x}{b-\sqrt {b^2-4 a c}}\right )-n \operatorname {PolyLog}\left (2,-\frac {2 c x}{b+\sqrt {b^2-4 a c}}\right )-n \log (x) \log \left (\frac {2 c x}{b-\sqrt {b^2-4 a c}}+1\right )-n \log (x) \log \left (\frac {2 c x}{\sqrt {b^2-4 a c}+b}+1\right )+\log (x) \log \left (d \left (a+b x+c x^2\right )^n\right ) \]

[In]

Int[Log[d*(a + b*x + c*x^2)^n]/x,x]

[Out]

-(n*Log[x]*Log[1 + (2*c*x)/(b - Sqrt[b^2 - 4*a*c])]) - n*Log[x]*Log[1 + (2*c*x)/(b + Sqrt[b^2 - 4*a*c])] + Log
[x]*Log[d*(a + b*x + c*x^2)^n] - n*PolyLog[2, (-2*c*x)/(b - Sqrt[b^2 - 4*a*c])] - n*PolyLog[2, (-2*c*x)/(b + S
qrt[b^2 - 4*a*c])]

Rule 2354

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

Rule 2404

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]

Rule 2438

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 2604

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

Rubi steps \begin{align*} \text {integral}& = \log (x) \log \left (d \left (a+b x+c x^2\right )^n\right )-n \int \frac {(b+2 c x) \log (x)}{a+b x+c x^2} \, dx \\ & = \log (x) \log \left (d \left (a+b x+c x^2\right )^n\right )-n \int \left (\frac {2 c \log (x)}{b-\sqrt {b^2-4 a c}+2 c x}+\frac {2 c \log (x)}{b+\sqrt {b^2-4 a c}+2 c x}\right ) \, dx \\ & = \log (x) \log \left (d \left (a+b x+c x^2\right )^n\right )-(2 c n) \int \frac {\log (x)}{b-\sqrt {b^2-4 a c}+2 c x} \, dx-(2 c n) \int \frac {\log (x)}{b+\sqrt {b^2-4 a c}+2 c x} \, dx \\ & = -n \log (x) \log \left (1+\frac {2 c x}{b-\sqrt {b^2-4 a c}}\right )-n \log (x) \log \left (1+\frac {2 c x}{b+\sqrt {b^2-4 a c}}\right )+\log (x) \log \left (d \left (a+b x+c x^2\right )^n\right )+n \int \frac {\log \left (1+\frac {2 c x}{b-\sqrt {b^2-4 a c}}\right )}{x} \, dx+n \int \frac {\log \left (1+\frac {2 c x}{b+\sqrt {b^2-4 a c}}\right )}{x} \, dx \\ & = -n \log (x) \log \left (1+\frac {2 c x}{b-\sqrt {b^2-4 a c}}\right )-n \log (x) \log \left (1+\frac {2 c x}{b+\sqrt {b^2-4 a c}}\right )+\log (x) \log \left (d \left (a+b x+c x^2\right )^n\right )-n \text {Li}_2\left (-\frac {2 c x}{b-\sqrt {b^2-4 a c}}\right )-n \text {Li}_2\left (-\frac {2 c x}{b+\sqrt {b^2-4 a c}}\right ) \\ \end{align*}

Mathematica [A] (verified)

Time = 0.14 (sec) , antiderivative size = 150, normalized size of antiderivative = 1.16 \[ \int \frac {\log \left (d \left (a+b x+c x^2\right )^n\right )}{x} \, dx=\log (x) \log \left (d (a+x (b+c x))^n\right )-n \left (\log (x) \log \left (\frac {b-\sqrt {b^2-4 a c}+2 c x}{b-\sqrt {b^2-4 a c}}\right )+\log (x) \log \left (\frac {b+\sqrt {b^2-4 a c}+2 c x}{b+\sqrt {b^2-4 a c}}\right )+\operatorname {PolyLog}\left (2,-\frac {2 c x}{b-\sqrt {b^2-4 a c}}\right )+\operatorname {PolyLog}\left (2,-\frac {2 c x}{b+\sqrt {b^2-4 a c}}\right )\right ) \]

[In]

Integrate[Log[d*(a + b*x + c*x^2)^n]/x,x]

[Out]

Log[x]*Log[d*(a + x*(b + c*x))^n] - n*(Log[x]*Log[(b - Sqrt[b^2 - 4*a*c] + 2*c*x)/(b - Sqrt[b^2 - 4*a*c])] + L
og[x]*Log[(b + Sqrt[b^2 - 4*a*c] + 2*c*x)/(b + Sqrt[b^2 - 4*a*c])] + PolyLog[2, (-2*c*x)/(b - Sqrt[b^2 - 4*a*c
])] + PolyLog[2, (-2*c*x)/(b + Sqrt[b^2 - 4*a*c])])

Maple [A] (verified)

Time = 0.25 (sec) , antiderivative size = 166, normalized size of antiderivative = 1.29

method result size
parts \(\ln \left (x \right ) \ln \left (d \left (c \,x^{2}+b x +a \right )^{n}\right )-n \left (\ln \left (x \right ) \ln \left (\frac {-2 x c +\sqrt {-4 c a +b^{2}}-b}{-b +\sqrt {-4 c a +b^{2}}}\right )+\ln \left (x \right ) \ln \left (\frac {2 x c +\sqrt {-4 c a +b^{2}}+b}{b +\sqrt {-4 c a +b^{2}}}\right )+\operatorname {dilog}\left (\frac {-2 x c +\sqrt {-4 c a +b^{2}}-b}{-b +\sqrt {-4 c a +b^{2}}}\right )+\operatorname {dilog}\left (\frac {2 x c +\sqrt {-4 c a +b^{2}}+b}{b +\sqrt {-4 c a +b^{2}}}\right )\right )\) \(166\)
risch \(\ln \left (\left (c \,x^{2}+b x +a \right )^{n}\right ) \ln \left (x \right )-\ln \left (\frac {-2 x c +\sqrt {-4 c a +b^{2}}-b}{-b +\sqrt {-4 c a +b^{2}}}\right ) \ln \left (x \right ) n -\ln \left (\frac {2 x c +\sqrt {-4 c a +b^{2}}+b}{b +\sqrt {-4 c a +b^{2}}}\right ) \ln \left (x \right ) n -\operatorname {dilog}\left (\frac {-2 x c +\sqrt {-4 c a +b^{2}}-b}{-b +\sqrt {-4 c a +b^{2}}}\right ) n -\operatorname {dilog}\left (\frac {2 x c +\sqrt {-4 c a +b^{2}}+b}{b +\sqrt {-4 c a +b^{2}}}\right ) n +\left (\frac {i \pi \,\operatorname {csgn}\left (i \left (c \,x^{2}+b x +a \right )^{n}\right ) {\operatorname {csgn}\left (i d \left (c \,x^{2}+b x +a \right )^{n}\right )}^{2}}{2}-\frac {i \pi \,\operatorname {csgn}\left (i \left (c \,x^{2}+b x +a \right )^{n}\right ) \operatorname {csgn}\left (i d \left (c \,x^{2}+b x +a \right )^{n}\right ) \operatorname {csgn}\left (i d \right )}{2}-\frac {i \pi {\operatorname {csgn}\left (i d \left (c \,x^{2}+b x +a \right )^{n}\right )}^{3}}{2}+\frac {i \pi {\operatorname {csgn}\left (i d \left (c \,x^{2}+b x +a \right )^{n}\right )}^{2} \operatorname {csgn}\left (i d \right )}{2}+\ln \left (d \right )\right ) \ln \left (x \right )\) \(308\)

[In]

int(ln(d*(c*x^2+b*x+a)^n)/x,x,method=_RETURNVERBOSE)

[Out]

ln(x)*ln(d*(c*x^2+b*x+a)^n)-n*(ln(x)*ln((-2*x*c+(-4*a*c+b^2)^(1/2)-b)/(-b+(-4*a*c+b^2)^(1/2)))+ln(x)*ln((2*x*c
+(-4*a*c+b^2)^(1/2)+b)/(b+(-4*a*c+b^2)^(1/2)))+dilog((-2*x*c+(-4*a*c+b^2)^(1/2)-b)/(-b+(-4*a*c+b^2)^(1/2)))+di
log((2*x*c+(-4*a*c+b^2)^(1/2)+b)/(b+(-4*a*c+b^2)^(1/2))))

Fricas [F]

\[ \int \frac {\log \left (d \left (a+b x+c x^2\right )^n\right )}{x} \, dx=\int { \frac {\log \left ({\left (c x^{2} + b x + a\right )}^{n} d\right )}{x} \,d x } \]

[In]

integrate(log(d*(c*x^2+b*x+a)^n)/x,x, algorithm="fricas")

[Out]

integral(log((c*x^2 + b*x + a)^n*d)/x, x)

Sympy [F]

\[ \int \frac {\log \left (d \left (a+b x+c x^2\right )^n\right )}{x} \, dx=\int \frac {\log {\left (d \left (a + b x + c x^{2}\right )^{n} \right )}}{x}\, dx \]

[In]

integrate(ln(d*(c*x**2+b*x+a)**n)/x,x)

[Out]

Integral(log(d*(a + b*x + c*x**2)**n)/x, x)

Maxima [F]

\[ \int \frac {\log \left (d \left (a+b x+c x^2\right )^n\right )}{x} \, dx=\int { \frac {\log \left ({\left (c x^{2} + b x + a\right )}^{n} d\right )}{x} \,d x } \]

[In]

integrate(log(d*(c*x^2+b*x+a)^n)/x,x, algorithm="maxima")

[Out]

integrate(log((c*x^2 + b*x + a)^n*d)/x, x)

Giac [F]

\[ \int \frac {\log \left (d \left (a+b x+c x^2\right )^n\right )}{x} \, dx=\int { \frac {\log \left ({\left (c x^{2} + b x + a\right )}^{n} d\right )}{x} \,d x } \]

[In]

integrate(log(d*(c*x^2+b*x+a)^n)/x,x, algorithm="giac")

[Out]

integrate(log((c*x^2 + b*x + a)^n*d)/x, x)

Mupad [F(-1)]

Timed out. \[ \int \frac {\log \left (d \left (a+b x+c x^2\right )^n\right )}{x} \, dx=\int \frac {\ln \left (d\,{\left (c\,x^2+b\,x+a\right )}^n\right )}{x} \,d x \]

[In]

int(log(d*(a + b*x + c*x^2)^n)/x,x)

[Out]

int(log(d*(a + b*x + c*x^2)^n)/x, x)