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

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

Optimal result

Integrand size = 21, antiderivative size = 118 \[ \int \frac {(d+e x)^3 \left (a+b \log \left (c x^n\right )\right )}{x^3} \, dx=-\frac {b d^3 n}{4 x^2}-\frac {3 b d^2 e n}{x}-b e^3 n x-\frac {3}{2} b d e^2 n \log ^2(x)-\frac {d^3 \left (a+b \log \left (c x^n\right )\right )}{2 x^2}-\frac {3 d^2 e \left (a+b \log \left (c x^n\right )\right )}{x}+e^3 x \left (a+b \log \left (c x^n\right )\right )+3 d e^2 \log (x) \left (a+b \log \left (c x^n\right )\right ) \] Output:

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

Mathematica [A] (verified)

Time = 0.09 (sec) , antiderivative size = 115, normalized size of antiderivative = 0.97 \[ \int \frac {(d+e x)^3 \left (a+b \log \left (c x^n\right )\right )}{x^3} \, dx=-\frac {b d^3 n}{4 x^2}-\frac {3 b d^2 e n}{x}+a e^3 x-b e^3 n x+b e^3 x \log \left (c x^n\right )-\frac {d^3 \left (a+b \log \left (c x^n\right )\right )}{2 x^2}-\frac {3 d^2 e \left (a+b \log \left (c x^n\right )\right )}{x}+\frac {3 d e^2 \left (a+b \log \left (c x^n\right )\right )^2}{2 b n} \] Input:

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

Output:

-1/4*(b*d^3*n)/x^2 - (3*b*d^2*e*n)/x + a*e^3*x - b*e^3*n*x + b*e^3*x*Log[c 
*x^n] - (d^3*(a + b*Log[c*x^n]))/(2*x^2) - (3*d^2*e*(a + b*Log[c*x^n]))/x 
+ (3*d*e^2*(a + b*Log[c*x^n])^2)/(2*b*n)
 

Rubi [A] (verified)

Time = 0.34 (sec) , antiderivative size = 114, normalized size of antiderivative = 0.97, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.095, Rules used = {2772, 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 {(d+e x)^3 \left (a+b \log \left (c x^n\right )\right )}{x^3} \, dx\)

\(\Big \downarrow \) 2772

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

\(\Big \downarrow \) 2009

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

Input:

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

Output:

-(b*n*(d^3/(4*x^2) + (3*d^2*e)/x + e^3*x + (3*d*e^2*Log[x]^2)/2)) - (d^3*( 
a + b*Log[c*x^n]))/(2*x^2) - (3*d^2*e*(a + b*Log[c*x^n]))/x + e^3*x*(a + b 
*Log[c*x^n]) + 3*d*e^2*Log[x]*(a + b*Log[c*x^n])
 

Defintions of rubi rules used

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 2772
Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*(x_)^(m_.)*((d_) + (e_.)*(x_)^(r_ 
.))^(q_.), x_Symbol] :> With[{u = IntHide[x^m*(d + e*x^r)^q, x]}, Simp[(a + 
 b*Log[c*x^n])   u, x] - Simp[b*n   Int[SimplifyIntegrand[u/x, x], x], x]] 
/; FreeQ[{a, b, c, d, e, n, r}, x] && IGtQ[q, 0] && IntegerQ[m] &&  !(EqQ[q 
, 1] && EqQ[m, -1])
 
Maple [A] (verified)

Time = 0.62 (sec) , antiderivative size = 143, normalized size of antiderivative = 1.21

method result size
parallelrisch \(\frac {4 x^{3} \ln \left (c \,x^{n}\right ) b \,e^{3} n -4 x^{3} b \,e^{3} n^{2}+12 \ln \left (x \right ) x^{2} a d \,e^{2} n +4 x^{3} a \,e^{3} n +6 e^{2} d b \ln \left (c \,x^{n}\right )^{2} x^{2}-12 x \ln \left (c \,x^{n}\right ) b \,d^{2} e n -12 x b \,d^{2} e \,n^{2}-12 x a \,d^{2} e n -2 \ln \left (c \,x^{n}\right ) b \,d^{3} n -b \,d^{3} n^{2}-2 a \,d^{3} n}{4 x^{2} n}\) \(143\)
risch \(-\frac {b \left (-6 e^{2} d \ln \left (x \right ) x^{2}-2 e^{3} x^{3}+6 d^{2} e x +d^{3}\right ) \ln \left (x^{n}\right )}{2 x^{2}}-\frac {-2 i \pi b \,e^{3} x^{3} \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2}+12 a \,d^{2} e x +2 a \,d^{3}+2 i \pi b \,e^{3} x^{3} \operatorname {csgn}\left (i c \,x^{n}\right )^{3}-12 \ln \left (x \right ) e^{2} d a \,x^{2}+i \pi b \,d^{3} \operatorname {csgn}\left (i c \,x^{n}\right )^{2} \operatorname {csgn}\left (i c \right )-4 \ln \left (c \right ) b \,e^{3} x^{3}+12 \ln \left (c \right ) b \,d^{2} e x +2 i \pi b \,e^{3} x^{3} \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right ) \operatorname {csgn}\left (i c \right )+6 i \pi b \,d^{2} e x \,\operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2}+6 i \pi b \,d^{2} \operatorname {csgn}\left (i c \,x^{n}\right )^{2} \operatorname {csgn}\left (i c \right ) e x +6 i \ln \left (x \right ) \pi b d \,e^{2} \operatorname {csgn}\left (i c \,x^{n}\right )^{3} x^{2}-12 \ln \left (x \right ) \ln \left (c \right ) b d \,e^{2} x^{2}+6 e^{2} d b n \ln \left (x \right )^{2} x^{2}+2 d^{3} b \ln \left (c \right )-i \pi b \,d^{3} \operatorname {csgn}\left (i c \,x^{n}\right )^{3}-4 a \,e^{3} x^{3}+b \,d^{3} n -i \pi b \,d^{3} \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right ) \operatorname {csgn}\left (i c \right )-2 i \pi b \,e^{3} x^{3} \operatorname {csgn}\left (i c \,x^{n}\right )^{2} \operatorname {csgn}\left (i c \right )-6 i \pi b \,d^{2} e x \operatorname {csgn}\left (i c \,x^{n}\right )^{3}+6 i \ln \left (x \right ) \pi b d \,e^{2} \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right ) \operatorname {csgn}\left (i c \right ) x^{2}+i \pi b \,d^{3} \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2}-6 i \pi b \,d^{2} e x \,\operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right ) \operatorname {csgn}\left (i c \right )-6 i \ln \left (x \right ) \pi b d \,e^{2} \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2} x^{2}-6 i \ln \left (x \right ) \pi b d \,e^{2} \operatorname {csgn}\left (i c \,x^{n}\right )^{2} \operatorname {csgn}\left (i c \right ) x^{2}+12 b \,d^{2} e n x +4 b \,e^{3} n \,x^{3}}{4 x^{2}}\) \(586\)

Input:

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

Output:

1/4/x^2*(4*x^3*ln(c*x^n)*b*e^3*n-4*x^3*b*e^3*n^2+12*ln(x)*x^2*a*d*e^2*n+4* 
x^3*a*e^3*n+6*e^2*d*b*ln(c*x^n)^2*x^2-12*x*ln(c*x^n)*b*d^2*e*n-12*x*b*d^2* 
e*n^2-12*x*a*d^2*e*n-2*ln(c*x^n)*b*d^3*n-b*d^3*n^2-2*a*d^3*n)/n
 

Fricas [A] (verification not implemented)

Time = 0.08 (sec) , antiderivative size = 150, normalized size of antiderivative = 1.27 \[ \int \frac {(d+e x)^3 \left (a+b \log \left (c x^n\right )\right )}{x^3} \, dx=\frac {6 \, b d e^{2} n x^{2} \log \left (x\right )^{2} - b d^{3} n - 2 \, a d^{3} - 4 \, {\left (b e^{3} n - a e^{3}\right )} x^{3} - 12 \, {\left (b d^{2} e n + a d^{2} e\right )} x + 2 \, {\left (2 \, b e^{3} x^{3} - 6 \, b d^{2} e x - b d^{3}\right )} \log \left (c\right ) + 2 \, {\left (2 \, b e^{3} n x^{3} + 6 \, b d e^{2} x^{2} \log \left (c\right ) - 6 \, b d^{2} e n x + 6 \, a d e^{2} x^{2} - b d^{3} n\right )} \log \left (x\right )}{4 \, x^{2}} \] Input:

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

Output:

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

Sympy [A] (verification not implemented)

Time = 0.45 (sec) , antiderivative size = 182, normalized size of antiderivative = 1.54 \[ \int \frac {(d+e x)^3 \left (a+b \log \left (c x^n\right )\right )}{x^3} \, dx=\begin {cases} - \frac {a d^{3}}{2 x^{2}} - \frac {3 a d^{2} e}{x} + \frac {3 a d e^{2} \log {\left (c x^{n} \right )}}{n} + a e^{3} x - \frac {b d^{3} n}{4 x^{2}} - \frac {b d^{3} \log {\left (c x^{n} \right )}}{2 x^{2}} - \frac {3 b d^{2} e n}{x} - \frac {3 b d^{2} e \log {\left (c x^{n} \right )}}{x} + \frac {3 b d e^{2} \log {\left (c x^{n} \right )}^{2}}{2 n} - b e^{3} n x + b e^{3} x \log {\left (c x^{n} \right )} & \text {for}\: n \neq 0 \\\left (a + b \log {\left (c \right )}\right ) \left (- \frac {d^{3}}{2 x^{2}} - \frac {3 d^{2} e}{x} + 3 d e^{2} \log {\left (x \right )} + e^{3} x\right ) & \text {otherwise} \end {cases} \] Input:

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

Output:

Piecewise((-a*d**3/(2*x**2) - 3*a*d**2*e/x + 3*a*d*e**2*log(c*x**n)/n + a* 
e**3*x - b*d**3*n/(4*x**2) - b*d**3*log(c*x**n)/(2*x**2) - 3*b*d**2*e*n/x 
- 3*b*d**2*e*log(c*x**n)/x + 3*b*d*e**2*log(c*x**n)**2/(2*n) - b*e**3*n*x 
+ b*e**3*x*log(c*x**n), Ne(n, 0)), ((a + b*log(c))*(-d**3/(2*x**2) - 3*d** 
2*e/x + 3*d*e**2*log(x) + e**3*x), True))
 

Maxima [A] (verification not implemented)

Time = 0.03 (sec) , antiderivative size = 125, normalized size of antiderivative = 1.06 \[ \int \frac {(d+e x)^3 \left (a+b \log \left (c x^n\right )\right )}{x^3} \, dx=-b e^{3} n x + b e^{3} x \log \left (c x^{n}\right ) + a e^{3} x + \frac {3 \, b d e^{2} \log \left (c x^{n}\right )^{2}}{2 \, n} + 3 \, a d e^{2} \log \left (x\right ) - \frac {3 \, b d^{2} e n}{x} - \frac {3 \, b d^{2} e \log \left (c x^{n}\right )}{x} - \frac {b d^{3} n}{4 \, x^{2}} - \frac {3 \, a d^{2} e}{x} - \frac {b d^{3} \log \left (c x^{n}\right )}{2 \, x^{2}} - \frac {a d^{3}}{2 \, x^{2}} \] Input:

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

Output:

-b*e^3*n*x + b*e^3*x*log(c*x^n) + a*e^3*x + 3/2*b*d*e^2*log(c*x^n)^2/n + 3 
*a*d*e^2*log(x) - 3*b*d^2*e*n/x - 3*b*d^2*e*log(c*x^n)/x - 1/4*b*d^3*n/x^2 
 - 3*a*d^2*e/x - 1/2*b*d^3*log(c*x^n)/x^2 - 1/2*a*d^3/x^2
 

Giac [A] (verification not implemented)

Time = 0.12 (sec) , antiderivative size = 141, normalized size of antiderivative = 1.19 \[ \int \frac {(d+e x)^3 \left (a+b \log \left (c x^n\right )\right )}{x^3} \, dx=\frac {3}{2} \, b d e^{2} n \log \left (x\right )^{2} + {\left (x \log \left (x\right ) - x\right )} b e^{3} n - 3 \, b d^{2} e n {\left (\frac {\log \left (x\right )}{x} + \frac {1}{x}\right )} - \frac {1}{4} \, b d^{3} n {\left (\frac {2 \, \log \left (x\right )}{x^{2}} + \frac {1}{x^{2}}\right )} + b e^{3} x \log \left (c\right ) + 3 \, b d e^{2} \log \left (c\right ) \log \left ({\left | x \right |}\right ) + a e^{3} x + 3 \, a d e^{2} \log \left ({\left | x \right |}\right ) - \frac {3 \, b d^{2} e \log \left (c\right )}{x} - \frac {3 \, a d^{2} e}{x} - \frac {b d^{3} \log \left (c\right )}{2 \, x^{2}} - \frac {a d^{3}}{2 \, x^{2}} \] Input:

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

Output:

3/2*b*d*e^2*n*log(x)^2 + (x*log(x) - x)*b*e^3*n - 3*b*d^2*e*n*(log(x)/x + 
1/x) - 1/4*b*d^3*n*(2*log(x)/x^2 + 1/x^2) + b*e^3*x*log(c) + 3*b*d*e^2*log 
(c)*log(abs(x)) + a*e^3*x + 3*a*d*e^2*log(abs(x)) - 3*b*d^2*e*log(c)/x - 3 
*a*d^2*e/x - 1/2*b*d^3*log(c)/x^2 - 1/2*a*d^3/x^2
 

Mupad [B] (verification not implemented)

Time = 27.50 (sec) , antiderivative size = 139, normalized size of antiderivative = 1.18 \[ \int \frac {(d+e x)^3 \left (a+b \log \left (c x^n\right )\right )}{x^3} \, dx=\ln \left (x\right )\,\left (3\,a\,d\,e^2+\frac {9\,b\,d\,e^2\,n}{2}\right )-\ln \left (c\,x^n\right )\,\left (\frac {\frac {b\,d^3}{2}+3\,b\,d^2\,e\,x+\frac {9\,b\,d\,e^2\,x^2}{2}+2\,b\,e^3\,x^3}{x^2}-3\,b\,e^3\,x\right )-\frac {x\,\left (6\,a\,d^2\,e+6\,b\,d^2\,e\,n\right )+a\,d^3+\frac {b\,d^3\,n}{2}}{2\,x^2}+e^3\,x\,\left (a-b\,n\right )+\frac {3\,b\,d\,e^2\,{\ln \left (c\,x^n\right )}^2}{2\,n} \] Input:

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

Output:

log(x)*(3*a*d*e^2 + (9*b*d*e^2*n)/2) - log(c*x^n)*(((b*d^3)/2 + 2*b*e^3*x^ 
3 + 3*b*d^2*e*x + (9*b*d*e^2*x^2)/2)/x^2 - 3*b*e^3*x) - (x*(6*a*d^2*e + 6* 
b*d^2*e*n) + a*d^3 + (b*d^3*n)/2)/(2*x^2) + e^3*x*(a - b*n) + (3*b*d*e^2*l 
og(c*x^n)^2)/(2*n)
 

Reduce [B] (verification not implemented)

Time = 0.17 (sec) , antiderivative size = 142, normalized size of antiderivative = 1.20 \[ \int \frac {(d+e x)^3 \left (a+b \log \left (c x^n\right )\right )}{x^3} \, dx=\frac {6 \mathrm {log}\left (x^{n} c \right )^{2} b d \,e^{2} x^{2}-2 \,\mathrm {log}\left (x^{n} c \right ) b \,d^{3} n -12 \,\mathrm {log}\left (x^{n} c \right ) b \,d^{2} e n x +4 \,\mathrm {log}\left (x^{n} c \right ) b \,e^{3} n \,x^{3}+12 \,\mathrm {log}\left (x \right ) a d \,e^{2} n \,x^{2}-2 a \,d^{3} n -12 a \,d^{2} e n x +4 a \,e^{3} n \,x^{3}-b \,d^{3} n^{2}-12 b \,d^{2} e \,n^{2} x -4 b \,e^{3} n^{2} x^{3}}{4 n \,x^{2}} \] Input:

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

Output:

(6*log(x**n*c)**2*b*d*e**2*x**2 - 2*log(x**n*c)*b*d**3*n - 12*log(x**n*c)* 
b*d**2*e*n*x + 4*log(x**n*c)*b*e**3*n*x**3 + 12*log(x)*a*d*e**2*n*x**2 - 2 
*a*d**3*n - 12*a*d**2*e*n*x + 4*a*e**3*n*x**3 - b*d**3*n**2 - 12*b*d**2*e* 
n**2*x - 4*b*e**3*n**2*x**3)/(4*n*x**2)