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

Optimal result
Mathematica [A] (verified)
Rubi [A] (warning: unable to verify)
Maple [F]
Fricas [F]
Sympy [F]
Maxima [F]
Giac [F]
Mupad [F(-1)]
Reduce [F]

Optimal result

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

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

Mathematica [A] (verified)

Time = 0.19 (sec) , antiderivative size = 189, normalized size of antiderivative = 1.22 \[ \int \frac {\left (a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )\right )^2}{x^2} \, dx=2 \left (-\frac {\left (a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )\right )^2}{2 x}+b e n \left (-\frac {a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )}{d \sqrt {x}}+\frac {e \left (a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )\right )^2}{2 b d^2 n}-\frac {e \left (a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )\right ) \log \left (-\frac {e \sqrt {x}}{d}\right )}{d^2}+\frac {b n \left (-\frac {e \log \left (d+e \sqrt {x}\right )}{d}+\frac {e \log (x)}{2 d}\right )}{d}-\frac {b e n \operatorname {PolyLog}\left (2,\frac {d+e \sqrt {x}}{d}\right )}{d^2}\right )\right ) \] Input:

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

Output:

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

Rubi [A] (warning: unable to verify)

Time = 1.12 (sec) , antiderivative size = 143, normalized size of antiderivative = 0.92, number of steps used = 10, number of rules used = 9, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.375, Rules used = {2904, 2845, 2858, 27, 2789, 2751, 16, 2779, 2838}

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

\(\Big \downarrow \) 2904

\(\displaystyle 2 \int \frac {\left (a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )\right )^2}{x^{3/2}}d\sqrt {x}\)

\(\Big \downarrow \) 2845

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

\(\Big \downarrow \) 2858

\(\displaystyle 2 \left (b n \int \frac {a+b \log \left (c x^{n/2}\right )}{x^{3/2}}d\left (d+e \sqrt {x}\right )-\frac {\left (a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )\right )^2}{2 x}\right )\)

\(\Big \downarrow \) 27

\(\displaystyle 2 \left (b e^2 n \int \frac {a+b \log \left (c x^{n/2}\right )}{e^2 x^{3/2}}d\left (d+e \sqrt {x}\right )-\frac {\left (a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )\right )^2}{2 x}\right )\)

\(\Big \downarrow \) 2789

\(\displaystyle 2 \left (b e^2 n \left (\frac {\int \frac {a+b \log \left (c x^{n/2}\right )}{e^2 x}d\left (d+e \sqrt {x}\right )}{d}+\frac {\int -\frac {a+b \log \left (c x^{n/2}\right )}{e x}d\left (d+e \sqrt {x}\right )}{d}\right )-\frac {\left (a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )\right )^2}{2 x}\right )\)

\(\Big \downarrow \) 2751

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

\(\Big \downarrow \) 16

\(\displaystyle 2 \left (b e^2 n \left (\frac {\int -\frac {a+b \log \left (c x^{n/2}\right )}{e x}d\left (d+e \sqrt {x}\right )}{d}+\frac {\frac {b n \log \left (-e \sqrt {x}\right )}{d}-\frac {\left (d+e \sqrt {x}\right ) \left (a+b \log \left (c x^{n/2}\right )\right )}{d e \sqrt {x}}}{d}\right )-\frac {\left (a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )\right )^2}{2 x}\right )\)

\(\Big \downarrow \) 2779

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

\(\Big \downarrow \) 2838

\(\displaystyle 2 \left (b e^2 n \left (\frac {\frac {b n \log \left (-e \sqrt {x}\right )}{d}-\frac {\left (d+e \sqrt {x}\right ) \left (a+b \log \left (c x^{n/2}\right )\right )}{d e \sqrt {x}}}{d}+\frac {\frac {b n \operatorname {PolyLog}\left (2,\frac {d}{\sqrt {x}}\right )}{d}-\frac {\log \left (1-\frac {d}{\sqrt {x}}\right ) \left (a+b \log \left (c x^{n/2}\right )\right )}{d}}{d}\right )-\frac {\left (a+b \log \left (c \left (d+e \sqrt {x}\right )^n\right )\right )^2}{2 x}\right )\)

Input:

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

Output:

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

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 2751
Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*((d_) + (e_.)*(x_)^(r_.))^(q_), x 
_Symbol] :> Simp[x*(d + e*x^r)^(q + 1)*((a + b*Log[c*x^n])/d), x] - Simp[b* 
(n/d)   Int[(d + e*x^r)^(q + 1), x], x] /; FreeQ[{a, b, c, d, e, n, q, r}, 
x] && EqQ[r*(q + 1) + 1, 0]
 

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 2789
Int[(((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*((d_) + (e_.)*(x_))^(q_))/ 
(x_), x_Symbol] :> Simp[1/d   Int[(d + e*x)^(q + 1)*((a + b*Log[c*x^n])^p/x 
), x], x] - Simp[e/d   Int[(d + e*x)^q*(a + b*Log[c*x^n])^p, x], x] /; Free 
Q[{a, b, c, d, e, n}, x] && IGtQ[p, 0] && LtQ[q, -1] && IntegerQ[2*q]
 

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 2845
Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_)*((f_.) + (g_. 
)*(x_))^(q_.), x_Symbol] :> Simp[(f + g*x)^(q + 1)*((a + b*Log[c*(d + e*x)^ 
n])^p/(g*(q + 1))), x] - Simp[b*e*n*(p/(g*(q + 1)))   Int[(f + g*x)^(q + 1) 
*((a + b*Log[c*(d + e*x)^n])^(p - 1)/(d + e*x)), x], x] /; FreeQ[{a, b, c, 
d, e, f, g, n, q}, x] && NeQ[e*f - d*g, 0] && GtQ[p, 0] && NeQ[q, -1] && In 
tegersQ[2*p, 2*q] && ( !IGtQ[q, 0] || (EqQ[p, 2] && NeQ[q, 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 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])
 
Maple [F]

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

Input:

int((a+b*ln(c*(d+e*x^(1/2))^n))^2/x^2,x)
 

Output:

int((a+b*ln(c*(d+e*x^(1/2))^n))^2/x^2,x)
 

Fricas [F]

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

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

Output:

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

Sympy [F]

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

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

Output:

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

Maxima [F]

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

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

Output:

2*(log(e*sqrt(x)/d + 1)*log(sqrt(x)) + dilog(-e*sqrt(x)/d))*b^2*e^2*n^2/d^ 
2 + 2*(a*b*e^2*n - (e^2*n^2 - e^2*n*log(c))*b^2)*log(e*sqrt(x) + d)/d^2 - 
2*(b^2*e^2*n*log(c) + a*b*e^2*n)*log(sqrt(x))/d^2 + integrate((b^2*e^4*n^2 
*x + b^2*d^2*e^2*n^2)/x, x)/d^4 + 1/3*(2*b^2*e^5*n^2*x^(3/2) - 6*b^2*d^2*e 
^3*n^2*sqrt(x)*log(sqrt(x)) - 3*b^2*d*e^4*n^2*x + 12*b^2*d^2*e^3*n^2*sqrt( 
x))/d^5 - 1/3*(3*b^2*d^3*e^2*n^2*x^(3/2)*log(e*sqrt(x) + d)^2 + 2*b^2*e^5* 
n^2*x^3 - 3*b^2*d^2*e^3*n^2*x^2*log(x) + 12*b^2*d^2*e^3*n^2*x^2 + 3*b^2*d^ 
5*sqrt(x)*log((e*sqrt(x) + d)^n)^2 + 6*(b^2*d^4*e*n*log(c) + a*b*d^4*e*n)* 
x - 3*(2*b^2*d^3*e^2*n*x^(3/2)*log(e*sqrt(x) + d) - 2*b^2*d^4*e*n*x - (b^2 
*d^3*e^2*n*x*log(x) + 2*b^2*d^5*log(c) + 2*a*b*d^5)*sqrt(x))*log((e*sqrt(x 
) + d)^n))/(d^5*x^(3/2))
 

Giac [F]

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

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

Output:

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

Mupad [F(-1)]

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

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

Output:

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

Reduce [F]

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

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

Output:

( - 2*sqrt(x)*log((sqrt(x)*e + d)**n*c)*b**2*d*e*n - 2*sqrt(x)*a*b*d*e*n - 
 int(log((sqrt(x)*e + d)**n*c)/(d**2*x - e**2*x**2),x)*b**2*d**2*e**2*n*x 
+ int((sqrt(x)*log((sqrt(x)*e + d)**n*c))/(d**2*x - e**2*x**2),x)*b**2*d*e 
**3*n*x - 2*log(sqrt(x))*a*b*e**2*n*x + 2*log(sqrt(x))*b**2*e**2*n**2*x - 
log((sqrt(x)*e + d)**n*c)**2*b**2*d**2 - 2*log((sqrt(x)*e + d)**n*c)*a*b*d 
**2 + 2*log((sqrt(x)*e + d)**n*c)*a*b*e**2*x - 2*log((sqrt(x)*e + d)**n*c) 
*b**2*e**2*n*x - a**2*d**2)/(d**2*x)