3.15.63 \(\int \frac {6 \log (x)+6 \log (-x^2)}{x} \, dx\)

Optimal. Leaf size=11 \[ \left (\log (x)+\log \left (-x^2\right )\right )^2 \]

________________________________________________________________________________________

Rubi [A]  time = 0.02, antiderivative size = 19, normalized size of antiderivative = 1.73, number of steps used = 4, number of rules used = 2, integrand size = 17, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.118, Rules used = {14, 2301} \begin {gather*} \frac {3}{2} \log ^2\left (-x^2\right )+3 \log ^2(x) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(6*Log[x] + 6*Log[-x^2])/x,x]

[Out]

3*Log[x]^2 + (3*Log[-x^2]^2)/2

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 2301

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))/(x_), x_Symbol] :> Simp[(a + b*Log[c*x^n])^2/(2*b*n), x] /; FreeQ[{a
, b, c, n}, x]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \left (\frac {6 \log (x)}{x}+\frac {6 \log \left (-x^2\right )}{x}\right ) \, dx\\ &=6 \int \frac {\log (x)}{x} \, dx+6 \int \frac {\log \left (-x^2\right )}{x} \, dx\\ &=3 \log ^2(x)+\frac {3}{2} \log ^2\left (-x^2\right )\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.00, size = 19, normalized size = 1.73 \begin {gather*} 3 \log ^2(x)+\frac {3}{2} \log ^2\left (-x^2\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(6*Log[x] + 6*Log[-x^2])/x,x]

[Out]

3*Log[x]^2 + (3*Log[-x^2]^2)/2

________________________________________________________________________________________

fricas [C]  time = 1.27, size = 20, normalized size = 1.82 \begin {gather*} \frac {3}{2} i \, \pi \log \left (-x^{2}\right ) + \frac {9}{4} \, \log \left (-x^{2}\right )^{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

3/2*I*pi*log(-x^2) + 9/4*log(-x^2)^2

________________________________________________________________________________________

giac [C]  time = 0.41, size = 12, normalized size = 1.09 \begin {gather*} 6 i \, \pi \log \relax (x) + 9 \, \log \relax (x)^{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

6*I*pi*log(x) + 9*log(x)^2

________________________________________________________________________________________

maple [A]  time = 0.06, size = 18, normalized size = 1.64




method result size



default \(\frac {3 \ln \left (-x^{2}\right )^{2}}{2}+3 \ln \relax (x )^{2}\) \(18\)
norman \(-3 \ln \relax (x )^{2}+6 \ln \relax (x ) \ln \left (-x^{2}\right )\) \(18\)
risch \(9 \ln \relax (x )^{2}-3 i \pi \left (2 \mathrm {csgn}\left (i x^{2}\right )^{2}+\mathrm {csgn}\left (i x \right )^{2} \mathrm {csgn}\left (i x^{2}\right )-2 \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{2}\right )^{2}-\mathrm {csgn}\left (i x^{2}\right )^{3}-2\right ) \ln \relax (x )\) \(69\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((6*ln(x)+6*ln(-x^2))/x,x,method=_RETURNVERBOSE)

[Out]

3/2*ln(-x^2)^2+3*ln(x)^2

________________________________________________________________________________________

maxima [A]  time = 0.69, size = 11, normalized size = 1.00 \begin {gather*} {\left (\log \left (-x^{2}\right ) + \log \relax (x)\right )}^{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

(log(-x^2) + log(x))^2

________________________________________________________________________________________

mupad [B]  time = 1.03, size = 16, normalized size = 1.45 \begin {gather*} \ln \relax (x)\,\left (\ln \left (x^{12}\right )-3\,\ln \relax (x)+\pi \,6{}\mathrm {i}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((6*log(-x^2) + 6*log(x))/x,x)

[Out]

log(x)*(pi*6i + log(x^12) - 3*log(x))

________________________________________________________________________________________

sympy [C]  time = 0.22, size = 14, normalized size = 1.27 \begin {gather*} 9 \log {\relax (x )}^{2} + 6 i \pi \log {\relax (x )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((6*ln(x)+6*ln(-x**2))/x,x)

[Out]

9*log(x)**2 + 6*I*pi*log(x)

________________________________________________________________________________________