\(\int \frac {12-54 x^2+12 x^2 \log (3 x)}{x} \, dx\) [6501]

   Optimal result
   Rubi [A] (verified)
   Mathematica [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)

Optimal result

Integrand size = 20, antiderivative size = 23 \[ \int \frac {12-54 x^2+12 x^2 \log (3 x)}{x} \, dx=3 \left (3+(1-x)^2+2 x+x^2\right ) (-5+\log (3 x)) \]

[Out]

3*(3+x^2+(1-x)^2+2*x)*(ln(3*x)-5)

Rubi [A] (verified)

Time = 0.01 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.83, number of steps used = 5, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {14, 2341} \[ \int \frac {12-54 x^2+12 x^2 \log (3 x)}{x} \, dx=-30 x^2+6 x^2 \log (3 x)+12 \log (x) \]

[In]

Int[(12 - 54*x^2 + 12*x^2*Log[3*x])/x,x]

[Out]

-30*x^2 + 12*Log[x] + 6*x^2*Log[3*x]

Rule 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
 &&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rule 2341

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[(d*x)^(m + 1)*((a + b*Log[c*x^
n])/(d*(m + 1))), x] - Simp[b*n*((d*x)^(m + 1)/(d*(m + 1)^2)), x] /; FreeQ[{a, b, c, d, m, n}, x] && NeQ[m, -1
]

Rubi steps \begin{align*} \text {integral}& = \int \left (-\frac {6 \left (-2+9 x^2\right )}{x}+12 x \log (3 x)\right ) \, dx \\ & = -\left (6 \int \frac {-2+9 x^2}{x} \, dx\right )+12 \int x \log (3 x) \, dx \\ & = -3 x^2+6 x^2 \log (3 x)-6 \int \left (-\frac {2}{x}+9 x\right ) \, dx \\ & = -30 x^2+12 \log (x)+6 x^2 \log (3 x) \\ \end{align*}

Mathematica [A] (verified)

Time = 0.01 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.83 \[ \int \frac {12-54 x^2+12 x^2 \log (3 x)}{x} \, dx=-30 x^2+12 \log (x)+6 x^2 \log (3 x) \]

[In]

Integrate[(12 - 54*x^2 + 12*x^2*Log[3*x])/x,x]

[Out]

-30*x^2 + 12*Log[x] + 6*x^2*Log[3*x]

Maple [A] (verified)

Time = 0.10 (sec) , antiderivative size = 20, normalized size of antiderivative = 0.87

method result size
risch \(6 x^{2} \ln \left (3 x \right )-30 x^{2}+12 \ln \left (x \right )\) \(20\)
parts \(6 x^{2} \ln \left (3 x \right )-30 x^{2}+12 \ln \left (x \right )\) \(20\)
derivativedivides \(6 x^{2} \ln \left (3 x \right )-30 x^{2}+12 \ln \left (3 x \right )\) \(22\)
default \(6 x^{2} \ln \left (3 x \right )-30 x^{2}+12 \ln \left (3 x \right )\) \(22\)
norman \(6 x^{2} \ln \left (3 x \right )-30 x^{2}+12 \ln \left (3 x \right )\) \(22\)
parallelrisch \(6 x^{2} \ln \left (3 x \right )-30 x^{2}+12 \ln \left (3 x \right )\) \(22\)

[In]

int((12*x^2*ln(3*x)-54*x^2+12)/x,x,method=_RETURNVERBOSE)

[Out]

6*x^2*ln(3*x)-30*x^2+12*ln(x)

Fricas [A] (verification not implemented)

none

Time = 0.26 (sec) , antiderivative size = 17, normalized size of antiderivative = 0.74 \[ \int \frac {12-54 x^2+12 x^2 \log (3 x)}{x} \, dx=-30 \, x^{2} + 6 \, {\left (x^{2} + 2\right )} \log \left (3 \, x\right ) \]

[In]

integrate((12*x^2*log(3*x)-54*x^2+12)/x,x, algorithm="fricas")

[Out]

-30*x^2 + 6*(x^2 + 2)*log(3*x)

Sympy [A] (verification not implemented)

Time = 0.07 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.83 \[ \int \frac {12-54 x^2+12 x^2 \log (3 x)}{x} \, dx=6 x^{2} \log {\left (3 x \right )} - 30 x^{2} + 12 \log {\left (x \right )} \]

[In]

integrate((12*x**2*ln(3*x)-54*x**2+12)/x,x)

[Out]

6*x**2*log(3*x) - 30*x**2 + 12*log(x)

Maxima [A] (verification not implemented)

none

Time = 0.18 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.83 \[ \int \frac {12-54 x^2+12 x^2 \log (3 x)}{x} \, dx=6 \, x^{2} \log \left (3 \, x\right ) - 30 \, x^{2} + 12 \, \log \left (x\right ) \]

[In]

integrate((12*x^2*log(3*x)-54*x^2+12)/x,x, algorithm="maxima")

[Out]

6*x^2*log(3*x) - 30*x^2 + 12*log(x)

Giac [A] (verification not implemented)

none

Time = 0.27 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.83 \[ \int \frac {12-54 x^2+12 x^2 \log (3 x)}{x} \, dx=6 \, x^{2} \log \left (3 \, x\right ) - 30 \, x^{2} + 12 \, \log \left (x\right ) \]

[In]

integrate((12*x^2*log(3*x)-54*x^2+12)/x,x, algorithm="giac")

[Out]

6*x^2*log(3*x) - 30*x^2 + 12*log(x)

Mupad [B] (verification not implemented)

Time = 12.66 (sec) , antiderivative size = 24, normalized size of antiderivative = 1.04 \[ \int \frac {12-54 x^2+12 x^2 \log (3 x)}{x} \, dx=12\,\ln \left (x\right )+6\,x^2\,\ln \left (x\right )+6\,x^2\,\ln \left (3\right )-30\,x^2 \]

[In]

int((12*x^2*log(3*x) - 54*x^2 + 12)/x,x)

[Out]

12*log(x) + 6*x^2*log(x) + 6*x^2*log(3) - 30*x^2