\(\int \frac {\log ^2(c (a+b x^2)^p)}{x} \, dx\) [80]

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

Optimal result

Integrand size = 18, antiderivative size = 72 \[ \int \frac {\log ^2\left (c \left (a+b x^2\right )^p\right )}{x} \, dx=\frac {1}{2} \log \left (-\frac {b x^2}{a}\right ) \log ^2\left (c \left (a+b x^2\right )^p\right )+p \log \left (c \left (a+b x^2\right )^p\right ) \operatorname {PolyLog}\left (2,1+\frac {b x^2}{a}\right )-p^2 \operatorname {PolyLog}\left (3,1+\frac {b x^2}{a}\right ) \] Output:

1/2*ln(-b*x^2/a)*ln(c*(b*x^2+a)^p)^2+p*ln(c*(b*x^2+a)^p)*polylog(2,1+b*x^2 
/a)-p^2*polylog(3,1+b*x^2/a)
 

Mathematica [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(163\) vs. \(2(72)=144\).

Time = 0.15 (sec) , antiderivative size = 163, normalized size of antiderivative = 2.26 \[ \int \frac {\log ^2\left (c \left (a+b x^2\right )^p\right )}{x} \, dx=\log (x) \left (-p \log \left (a+b x^2\right )+\log \left (c \left (a+b x^2\right )^p\right )\right )^2+2 p \left (-p \log \left (a+b x^2\right )+\log \left (c \left (a+b x^2\right )^p\right )\right ) \left (\log (x) \left (\log \left (a+b x^2\right )-\log \left (1+\frac {b x^2}{a}\right )\right )-\frac {1}{2} \operatorname {PolyLog}\left (2,-\frac {b x^2}{a}\right )\right )+\frac {1}{2} p^2 \left (\log \left (-\frac {b x^2}{a}\right ) \log ^2\left (a+b x^2\right )+2 \log \left (a+b x^2\right ) \operatorname {PolyLog}\left (2,1+\frac {b x^2}{a}\right )-2 \operatorname {PolyLog}\left (3,1+\frac {b x^2}{a}\right )\right ) \] Input:

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

Output:

Log[x]*(-(p*Log[a + b*x^2]) + Log[c*(a + b*x^2)^p])^2 + 2*p*(-(p*Log[a + b 
*x^2]) + Log[c*(a + b*x^2)^p])*(Log[x]*(Log[a + b*x^2] - Log[1 + (b*x^2)/a 
]) - PolyLog[2, -((b*x^2)/a)]/2) + (p^2*(Log[-((b*x^2)/a)]*Log[a + b*x^2]^ 
2 + 2*Log[a + b*x^2]*PolyLog[2, 1 + (b*x^2)/a] - 2*PolyLog[3, 1 + (b*x^2)/ 
a]))/2
 

Rubi [A] (verified)

Time = 0.69 (sec) , antiderivative size = 76, normalized size of antiderivative = 1.06, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.278, Rules used = {2904, 2843, 2881, 2821, 7143}

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 (c \left (a+b x^2\right )^p\right )}{x} \, dx\)

\(\Big \downarrow \) 2904

\(\displaystyle \frac {1}{2} \int \frac {\log ^2\left (c \left (b x^2+a\right )^p\right )}{x^2}dx^2\)

\(\Big \downarrow \) 2843

\(\displaystyle \frac {1}{2} \left (\log \left (-\frac {b x^2}{a}\right ) \log ^2\left (c \left (a+b x^2\right )^p\right )-2 b p \int \frac {\log \left (-\frac {b x^2}{a}\right ) \log \left (c \left (b x^2+a\right )^p\right )}{b x^2+a}dx^2\right )\)

\(\Big \downarrow \) 2881

\(\displaystyle \frac {1}{2} \left (\log \left (-\frac {b x^2}{a}\right ) \log ^2\left (c \left (a+b x^2\right )^p\right )-2 p \int \frac {\log \left (-\frac {b x^2}{a}\right ) \log \left (c \left (b x^2+a\right )^p\right )}{x^2}d\left (b x^2+a\right )\right )\)

\(\Big \downarrow \) 2821

\(\displaystyle \frac {1}{2} \left (\log \left (-\frac {b x^2}{a}\right ) \log ^2\left (c \left (a+b x^2\right )^p\right )-2 p \left (p \int \frac {\operatorname {PolyLog}\left (2,\frac {b x^2+a}{a}\right )}{x^2}d\left (b x^2+a\right )-\operatorname {PolyLog}\left (2,\frac {b x^2+a}{a}\right ) \log \left (c \left (a+b x^2\right )^p\right )\right )\right )\)

\(\Big \downarrow \) 7143

\(\displaystyle \frac {1}{2} \left (\log \left (-\frac {b x^2}{a}\right ) \log ^2\left (c \left (a+b x^2\right )^p\right )-2 p \left (p \operatorname {PolyLog}\left (3,\frac {b x^2+a}{a}\right )-\operatorname {PolyLog}\left (2,\frac {b x^2+a}{a}\right ) \log \left (c \left (a+b x^2\right )^p\right )\right )\right )\)

Input:

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

Output:

(Log[-((b*x^2)/a)]*Log[c*(a + b*x^2)^p]^2 - 2*p*(-(Log[c*(a + b*x^2)^p]*Po 
lyLog[2, (a + b*x^2)/a]) + p*PolyLog[3, (a + b*x^2)/a]))/2
 

Defintions of rubi rules used

rule 2821
Int[(Log[(d_.)*((e_) + (f_.)*(x_)^(m_.))]*((a_.) + Log[(c_.)*(x_)^(n_.)]*(b 
_.))^(p_.))/(x_), x_Symbol] :> Simp[(-PolyLog[2, (-d)*f*x^m])*((a + b*Log[c 
*x^n])^p/m), x] + Simp[b*n*(p/m)   Int[PolyLog[2, (-d)*f*x^m]*((a + b*Log[c 
*x^n])^(p - 1)/x), x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && IGtQ[p, 
0] && EqQ[d*e, 1]
 

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

rule 2881
Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_.) + Log 
[(h_.)*((i_.) + (j_.)*(x_))^(m_.)]*(g_.))*((k_.) + (l_.)*(x_))^(r_.), x_Sym 
bol] :> Simp[1/e   Subst[Int[(k*(x/d))^r*(a + b*Log[c*x^n])^p*(f + g*Log[h* 
((e*i - d*j)/e + j*(x/e))^m]), x], x, d + e*x], x] /; FreeQ[{a, b, c, d, e, 
 f, g, h, i, j, k, l, n, p, r}, x] && EqQ[e*k - d*l, 0]
 

rule 2904
Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_)^(n_))^(p_.)]*(b_.))^(q_.)*(x_)^(m 
_.), x_Symbol] :> Simp[1/n   Subst[Int[x^(Simplify[(m + 1)/n] - 1)*(a + b*L 
og[c*(d + e*x)^p])^q, x], x, x^n], x] /; FreeQ[{a, b, c, d, e, m, n, p, q}, 
 x] && IntegerQ[Simplify[(m + 1)/n]] && (GtQ[(m + 1)/n, 0] || IGtQ[q, 0]) & 
&  !(EqQ[q, 1] && ILtQ[n, 0] && IGtQ[m, 0])
 

rule 7143
Int[PolyLog[n_, (c_.)*((a_.) + (b_.)*(x_))^(p_.)]/((d_.) + (e_.)*(x_)), x_S 
ymbol] :> Simp[PolyLog[n + 1, c*(a + b*x)^p]/(e*p), x] /; FreeQ[{a, b, c, d 
, e, n, p}, x] && EqQ[b*d, a*e]
 
Maple [F]

\[\int \frac {{\ln \left (c \left (b \,x^{2}+a \right )^{p}\right )}^{2}}{x}d x\]

Input:

int(ln(c*(b*x^2+a)^p)^2/x,x)
 

Output:

int(ln(c*(b*x^2+a)^p)^2/x,x)
 

Fricas [F]

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

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

Output:

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

Sympy [F]

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

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

Output:

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

Maxima [A] (verification not implemented)

Time = 0.05 (sec) , antiderivative size = 118, normalized size of antiderivative = 1.64 \[ \int \frac {\log ^2\left (c \left (a+b x^2\right )^p\right )}{x} \, dx=\frac {1}{2} \, {\left (\log \left (b x^{2} + a\right )^{2} \log \left (-\frac {b x^{2} + a}{a} + 1\right ) + 2 \, {\rm Li}_2\left (\frac {b x^{2} + a}{a}\right ) \log \left (b x^{2} + a\right ) - 2 \, {\rm Li}_{3}(\frac {b x^{2} + a}{a})\right )} p^{2} + {\left (\log \left (b x^{2} + a\right ) \log \left (-\frac {b x^{2} + a}{a} + 1\right ) + {\rm Li}_2\left (\frac {b x^{2} + a}{a}\right )\right )} p \log \left (c\right ) + \log \left (c\right )^{2} \log \left (x\right ) \] Input:

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

Output:

1/2*(log(b*x^2 + a)^2*log(-(b*x^2 + a)/a + 1) + 2*dilog((b*x^2 + a)/a)*log 
(b*x^2 + a) - 2*polylog(3, (b*x^2 + a)/a))*p^2 + (log(b*x^2 + a)*log(-(b*x 
^2 + a)/a + 1) + dilog((b*x^2 + a)/a))*p*log(c) + log(c)^2*log(x)
 

Giac [F]

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

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

Output:

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

Mupad [F(-1)]

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

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

Output:

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

Reduce [F]

\[ \int \frac {\log ^2\left (c \left (a+b x^2\right )^p\right )}{x} \, dx=\frac {6 \left (\int \frac {{\mathrm {log}\left (\left (b \,x^{2}+a \right )^{p} c \right )}^{2}}{b \,x^{3}+a x}d x \right ) a p +{\mathrm {log}\left (\left (b \,x^{2}+a \right )^{p} c \right )}^{3}}{6 p} \] Input:

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

Output:

(6*int(log((a + b*x**2)**p*c)**2/(a*x + b*x**3),x)*a*p + log((a + b*x**2)* 
*p*c)**3)/(6*p)