3.30.36 \(\int \frac {-54 x^4+9 x^5+12 x^6-3 x^7+(72 x^2-36 x^3+4 x^4) \log ^2(3)+(-18+7 x) \log ^4(3)+(18 x^5-2 x^7+(-18 x^3+8 x^4) \log ^2(3)) \log (x^2)+x^7 \log ^2(x^2)}{9 x^7-6 x^8+x^9} \, dx\) [2936]

Optimal. Leaf size=32 \[ 3+\frac {\left (\frac {-3+x+\frac {\log ^2(3)}{x^2}}{x}+\log \left (x^2\right )\right )^2}{3-x} \]

[Out]

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

________________________________________________________________________________________

Rubi [B] Leaf count is larger than twice the leaf count of optimal. \(168\) vs. \(2(32)=64\).
time = 0.80, antiderivative size = 168, normalized size of antiderivative = 5.25, number of steps used = 26, number of rules used = 14, integrand size = 111, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.126, Rules used = {1608, 27, 6874, 46, 78, 75, 2404, 2354, 2438, 2338, 2351, 31, 2341, 2355} \begin {gather*} \frac {\log ^4(3)}{(3-x) x^6}-\frac {2 \log ^2(3)}{x^4}+\frac {3}{x^2}+\frac {x \log ^2\left (x^2\right )}{3 (3-x)}+\frac {1}{3} \log ^2\left (x^2\right )-\frac {2 \left (27-\log ^2(3)\right ) \log \left (x^2\right )}{27 x}+\frac {2 x \log ^2(3) \log \left (x^2\right )}{81 (3-x)}+\frac {2 \log ^2(3) \log \left (x^2\right )}{9 x^2}+\frac {2 \log ^2(3) \log \left (x^2\right )}{3 x^3}+\frac {3}{x}+\frac {4}{81} \log ^2(3) \log (x)-\frac {4 \left (27-\log ^2(3)\right )}{27 x}-\frac {4 \log ^2(3)}{27 x} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-54*x^4 + 9*x^5 + 12*x^6 - 3*x^7 + (72*x^2 - 36*x^3 + 4*x^4)*Log[3]^2 + (-18 + 7*x)*Log[3]^4 + (18*x^5 -
2*x^7 + (-18*x^3 + 8*x^4)*Log[3]^2)*Log[x^2] + x^7*Log[x^2]^2)/(9*x^7 - 6*x^8 + x^9),x]

[Out]

3/x^2 + 3/x - (2*Log[3]^2)/x^4 - (4*Log[3]^2)/(27*x) + Log[3]^4/((3 - x)*x^6) - (4*(27 - Log[3]^2))/(27*x) + (
4*Log[3]^2*Log[x])/81 + (2*Log[3]^2*Log[x^2])/(3*x^3) + (2*Log[3]^2*Log[x^2])/(9*x^2) + (2*x*Log[3]^2*Log[x^2]
)/(81*(3 - x)) - (2*(27 - Log[3]^2)*Log[x^2])/(27*x) + Log[x^2]^2/3 + (x*Log[x^2]^2)/(3*(3 - x))

Rule 27

Int[(u_.)*((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[u*Cancel[(b/2 + c*x)^(2*p)/c^p], x] /; Fr
eeQ[{a, b, c}, x] && EqQ[b^2 - 4*a*c, 0] && IntegerQ[p]

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rule 46

Int[((a_) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d*x
)^n, x], x] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0] && ILtQ[m, 0] && IntegerQ[n] &&  !(IGtQ[n, 0] && Lt
Q[m + n + 2, 0])

Rule 75

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

Rule 78

Int[((a_.) + (b_.)*(x_))*((c_) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p_.), x_Symbol] :> Int[ExpandIntegran
d[(a + b*x)*(c + d*x)^n*(e + f*x)^p, x], x] /; FreeQ[{a, b, c, d, e, f, n}, x] && NeQ[b*c - a*d, 0] && ((ILtQ[
n, 0] && ILtQ[p, 0]) || EqQ[p, 1] || (IGtQ[p, 0] && ( !IntegerQ[n] || LeQ[9*p + 5*(n + 2), 0] || GeQ[n + p + 1
, 0] || (GeQ[n + p + 2, 0] && RationalQ[a, b, c, d, e, f]))))

Rule 1608

Int[(u_.)*((a_.)*(x_)^(p_.) + (b_.)*(x_)^(q_.) + (c_.)*(x_)^(r_.))^(n_.), x_Symbol] :> Int[u*x^(n*p)*(a + b*x^
(q - p) + c*x^(r - p))^n, x] /; FreeQ[{a, b, c, p, q, r}, x] && IntegerQ[n] && PosQ[q - p] && PosQ[r - p]

Rule 2338

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]

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
]

Rule 2351

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] - Dist[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 2354

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

Rule 2355

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)/((d_) + (e_.)*(x_))^2, x_Symbol] :> Simp[x*((a + b*Log[c*x^n])
^p/(d*(d + e*x))), x] - Dist[b*n*(p/d), Int[(a + b*Log[c*x^n])^(p - 1)/(d + e*x), x], x] /; FreeQ[{a, b, c, d,
 e, n, p}, x] && GtQ[p, 0]

Rule 2404

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*(RFx_), x_Symbol] :> With[{u = ExpandIntegrand[(a + b*Log[c*x^
n])^p, RFx, x]}, Int[u, x] /; SumQ[u]] /; FreeQ[{a, b, c, n}, x] && RationalFunctionQ[RFx, x] && IGtQ[p, 0]

Rule 2438

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 6874

Int[u_, x_Symbol] :> With[{v = ExpandIntegrand[u, x]}, Int[v, x] /; SumQ[v]]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {-54 x^4+9 x^5+12 x^6-3 x^7+\left (72 x^2-36 x^3+4 x^4\right ) \log ^2(3)+(-18+7 x) \log ^4(3)+\left (18 x^5-2 x^7+\left (-18 x^3+8 x^4\right ) \log ^2(3)\right ) \log \left (x^2\right )+x^7 \log ^2\left (x^2\right )}{x^7 \left (9-6 x+x^2\right )} \, dx\\ &=\int \frac {-54 x^4+9 x^5+12 x^6-3 x^7+\left (72 x^2-36 x^3+4 x^4\right ) \log ^2(3)+(-18+7 x) \log ^4(3)+\left (18 x^5-2 x^7+\left (-18 x^3+8 x^4\right ) \log ^2(3)\right ) \log \left (x^2\right )+x^7 \log ^2\left (x^2\right )}{(-3+x)^2 x^7} \, dx\\ &=\int \left (-\frac {3}{(-3+x)^2}-\frac {54}{(-3+x)^2 x^3}+\frac {9}{(-3+x)^2 x^2}+\frac {12}{(-3+x)^2 x}+\frac {4 (-6+x) \log ^2(3)}{(-3+x) x^5}+\frac {(-18+7 x) \log ^4(3)}{(-3+x)^2 x^7}-\frac {2 \left (-9 x^2+x^4+9 \log ^2(3)-4 x \log ^2(3)\right ) \log \left (x^2\right )}{(-3+x)^2 x^4}+\frac {\log ^2\left (x^2\right )}{(-3+x)^2}\right ) \, dx\\ &=-\frac {3}{3-x}-2 \int \frac {\left (-9 x^2+x^4+9 \log ^2(3)-4 x \log ^2(3)\right ) \log \left (x^2\right )}{(-3+x)^2 x^4} \, dx+9 \int \frac {1}{(-3+x)^2 x^2} \, dx+12 \int \frac {1}{(-3+x)^2 x} \, dx-54 \int \frac {1}{(-3+x)^2 x^3} \, dx+\left (4 \log ^2(3)\right ) \int \frac {-6+x}{(-3+x) x^5} \, dx+\log ^4(3) \int \frac {-18+7 x}{(-3+x)^2 x^7} \, dx+\int \frac {\log ^2\left (x^2\right )}{(-3+x)^2} \, dx\\ &=-\frac {3}{3-x}+\frac {\log ^4(3)}{(3-x) x^6}+\frac {x \log ^2\left (x^2\right )}{3 (3-x)}+\frac {4}{3} \int \frac {\log \left (x^2\right )}{-3+x} \, dx-2 \int \left (\frac {2 \log \left (x^2\right )}{3 (-3+x)}-\frac {2 \log \left (x^2\right )}{3 x}-\frac {\log ^2(3) \log \left (x^2\right )}{27 (-3+x)^2}+\frac {\log ^2(3) \log \left (x^2\right )}{x^4}+\frac {2 \log ^2(3) \log \left (x^2\right )}{9 x^3}+\frac {\left (-27+\log ^2(3)\right ) \log \left (x^2\right )}{27 x^2}\right ) \, dx+9 \int \left (\frac {1}{9 (-3+x)^2}-\frac {2}{27 (-3+x)}+\frac {1}{9 x^2}+\frac {2}{27 x}\right ) \, dx+12 \int \left (\frac {1}{3 (-3+x)^2}-\frac {1}{9 (-3+x)}+\frac {1}{9 x}\right ) \, dx-54 \int \left (\frac {1}{27 (-3+x)^2}-\frac {1}{27 (-3+x)}+\frac {1}{9 x^3}+\frac {2}{27 x^2}+\frac {1}{27 x}\right ) \, dx+\left (4 \log ^2(3)\right ) \int \left (-\frac {1}{81 (-3+x)}+\frac {2}{x^5}+\frac {1}{3 x^4}+\frac {1}{9 x^3}+\frac {1}{27 x^2}+\frac {1}{81 x}\right ) \, dx\\ &=\frac {3}{x^2}+\frac {3}{x}-\frac {2 \log ^2(3)}{x^4}-\frac {4 \log ^2(3)}{9 x^3}-\frac {2 \log ^2(3)}{9 x^2}-\frac {4 \log ^2(3)}{27 x}+\frac {\log ^4(3)}{(3-x) x^6}-\frac {4}{81} \log ^2(3) \log (3-x)+\frac {4}{81} \log ^2(3) \log (x)+\frac {4}{3} \log \left (1-\frac {x}{3}\right ) \log \left (x^2\right )+\frac {x \log ^2\left (x^2\right )}{3 (3-x)}-\frac {4}{3} \int \frac {\log \left (x^2\right )}{-3+x} \, dx+\frac {4}{3} \int \frac {\log \left (x^2\right )}{x} \, dx-\frac {8}{3} \int \frac {\log \left (1-\frac {x}{3}\right )}{x} \, dx+\frac {1}{27} \left (2 \log ^2(3)\right ) \int \frac {\log \left (x^2\right )}{(-3+x)^2} \, dx-\frac {1}{9} \left (4 \log ^2(3)\right ) \int \frac {\log \left (x^2\right )}{x^3} \, dx-\left (2 \log ^2(3)\right ) \int \frac {\log \left (x^2\right )}{x^4} \, dx+\frac {1}{27} \left (2 \left (27-\log ^2(3)\right )\right ) \int \frac {\log \left (x^2\right )}{x^2} \, dx\\ &=\frac {3}{x^2}+\frac {3}{x}-\frac {2 \log ^2(3)}{x^4}-\frac {4 \log ^2(3)}{27 x}+\frac {\log ^4(3)}{(3-x) x^6}-\frac {4 \left (27-\log ^2(3)\right )}{27 x}-\frac {4}{81} \log ^2(3) \log (3-x)+\frac {4}{81} \log ^2(3) \log (x)+\frac {2 \log ^2(3) \log \left (x^2\right )}{3 x^3}+\frac {2 \log ^2(3) \log \left (x^2\right )}{9 x^2}+\frac {2 x \log ^2(3) \log \left (x^2\right )}{81 (3-x)}-\frac {2 \left (27-\log ^2(3)\right ) \log \left (x^2\right )}{27 x}+\frac {1}{3} \log ^2\left (x^2\right )+\frac {x \log ^2\left (x^2\right )}{3 (3-x)}+\frac {8 \text {Li}_2\left (\frac {x}{3}\right )}{3}+\frac {8}{3} \int \frac {\log \left (1-\frac {x}{3}\right )}{x} \, dx+\frac {1}{81} \left (4 \log ^2(3)\right ) \int \frac {1}{-3+x} \, dx\\ &=\frac {3}{x^2}+\frac {3}{x}-\frac {2 \log ^2(3)}{x^4}-\frac {4 \log ^2(3)}{27 x}+\frac {\log ^4(3)}{(3-x) x^6}-\frac {4 \left (27-\log ^2(3)\right )}{27 x}+\frac {4}{81} \log ^2(3) \log (x)+\frac {2 \log ^2(3) \log \left (x^2\right )}{3 x^3}+\frac {2 \log ^2(3) \log \left (x^2\right )}{9 x^2}+\frac {2 x \log ^2(3) \log \left (x^2\right )}{81 (3-x)}-\frac {2 \left (27-\log ^2(3)\right ) \log \left (x^2\right )}{27 x}+\frac {1}{3} \log ^2\left (x^2\right )+\frac {x \log ^2\left (x^2\right )}{3 (3-x)}\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

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

Antiderivative was successfully verified.

[In]

Integrate[(-54*x^4 + 9*x^5 + 12*x^6 - 3*x^7 + (72*x^2 - 36*x^3 + 4*x^4)*Log[3]^2 + (-18 + 7*x)*Log[3]^4 + (18*
x^5 - 2*x^7 + (-18*x^3 + 8*x^4)*Log[3]^2)*Log[x^2] + x^7*Log[x^2]^2)/(9*x^7 - 6*x^8 + x^9),x]

[Out]

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

________________________________________________________________________________________

Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(87\) vs. \(2(32)=64\).
time = 0.10, size = 88, normalized size = 2.75

method result size
risch \(-\frac {\ln \left (x^{2}\right )^{2}}{x -3}-\frac {2 \left (x^{3}+\ln \left (3\right )^{2}-3 x^{2}\right ) \ln \left (x^{2}\right )}{\left (x -3\right ) x^{3}}-\frac {x^{6}+2 x^{3} \ln \left (3\right )^{2}-6 x^{5}+\ln \left (3\right )^{4}-6 x^{2} \ln \left (3\right )^{2}+9 x^{4}}{\left (x -3\right ) x^{6}}\) \(88\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((x^7*ln(x^2)^2+((8*x^4-18*x^3)*ln(3)^2-2*x^7+18*x^5)*ln(x^2)+(7*x-18)*ln(3)^4+(4*x^4-36*x^3+72*x^2)*ln(3)^
2-3*x^7+12*x^6+9*x^5-54*x^4)/(x^9-6*x^8+9*x^7),x,method=_RETURNVERBOSE)

[Out]

-1/(x-3)*ln(x^2)^2-2*(x^3+ln(3)^2-3*x^2)/(x-3)/x^3*ln(x^2)-(x^6+2*x^3*ln(3)^2-6*x^5+ln(3)^4-6*x^2*ln(3)^2+9*x^
4)/(x-3)/x^6

________________________________________________________________________________________

Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 400 vs. \(2 (31) = 62\).
time = 0.52, size = 400, normalized size = 12.50 \begin {gather*} \frac {1}{7290} \, {\left (\frac {3 \, {\left (140 \, x^{6} - 210 \, x^{5} - 210 \, x^{4} - 315 \, x^{3} - 567 \, x^{2} - 1134 \, x - 2430\right )}}{x^{7} - 3 \, x^{6}} + 140 \, \log \left (x - 3\right ) - 140 \, \log \left (x\right )\right )} \log \left (3\right )^{4} - \frac {7}{7290} \, {\left (\frac {3 \, {\left (20 \, x^{5} - 30 \, x^{4} - 30 \, x^{3} - 45 \, x^{2} - 81 \, x - 162\right )}}{x^{6} - 3 \, x^{5}} + 20 \, \log \left (x - 3\right ) - 20 \, \log \left (x\right )\right )} \log \left (3\right )^{4} - \frac {2}{81} \, {\left (\frac {3 \, {\left (20 \, x^{4} - 30 \, x^{3} - 30 \, x^{2} - 45 \, x - 81\right )}}{x^{5} - 3 \, x^{4}} + 20 \, \log \left (x - 3\right ) - 20 \, \log \left (x\right )\right )} \log \left (3\right )^{2} + \frac {4}{27} \, {\left (\frac {3 \, {\left (4 \, x^{3} - 6 \, x^{2} - 6 \, x - 9\right )}}{x^{4} - 3 \, x^{3}} + 4 \, \log \left (x - 3\right ) - 4 \, \log \left (x\right )\right )} \log \left (3\right )^{2} - \frac {2}{27} \, {\left (\frac {3 \, {\left (2 \, x^{2} - 3 \, x - 3\right )}}{x^{3} - 3 \, x^{2}} + 2 \, \log \left (x - 3\right ) - 2 \, \log \left (x\right )\right )} \log \left (3\right )^{2} + \frac {4}{81} \, \log \left (3\right )^{2} \log \left (x - 3\right ) - \frac {2 \, {\left (162 \, x^{3} \log \left (x\right )^{2} - 6 \, {\left (\log \left (3\right )^{2} - 27\right )} x^{3} + 9 \, {\left (\log \left (3\right )^{2} - 54\right )} x^{2} + 9 \, x \log \left (3\right )^{2} + 54 \, \log \left (3\right )^{2} + 2 \, {\left (x^{4} \log \left (3\right )^{2} - 3 \, {\left (\log \left (3\right )^{2} - 27\right )} x^{3} - 243 \, x^{2} + 81 \, \log \left (3\right )^{2}\right )} \log \left (x\right )\right )}}{81 \, {\left (x^{4} - 3 \, x^{3}\right )}} + \frac {3 \, {\left (2 \, x^{2} - 3 \, x - 3\right )}}{x^{3} - 3 \, x^{2}} - \frac {2 \, x - 3}{x^{2} - 3 \, x} - \frac {1}{x - 3} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((x^7*log(x^2)^2+((8*x^4-18*x^3)*log(3)^2-2*x^7+18*x^5)*log(x^2)+(7*x-18)*log(3)^4+(4*x^4-36*x^3+72*x
^2)*log(3)^2-3*x^7+12*x^6+9*x^5-54*x^4)/(x^9-6*x^8+9*x^7),x, algorithm="maxima")

[Out]

1/7290*(3*(140*x^6 - 210*x^5 - 210*x^4 - 315*x^3 - 567*x^2 - 1134*x - 2430)/(x^7 - 3*x^6) + 140*log(x - 3) - 1
40*log(x))*log(3)^4 - 7/7290*(3*(20*x^5 - 30*x^4 - 30*x^3 - 45*x^2 - 81*x - 162)/(x^6 - 3*x^5) + 20*log(x - 3)
 - 20*log(x))*log(3)^4 - 2/81*(3*(20*x^4 - 30*x^3 - 30*x^2 - 45*x - 81)/(x^5 - 3*x^4) + 20*log(x - 3) - 20*log
(x))*log(3)^2 + 4/27*(3*(4*x^3 - 6*x^2 - 6*x - 9)/(x^4 - 3*x^3) + 4*log(x - 3) - 4*log(x))*log(3)^2 - 2/27*(3*
(2*x^2 - 3*x - 3)/(x^3 - 3*x^2) + 2*log(x - 3) - 2*log(x))*log(3)^2 + 4/81*log(3)^2*log(x - 3) - 2/81*(162*x^3
*log(x)^2 - 6*(log(3)^2 - 27)*x^3 + 9*(log(3)^2 - 54)*x^2 + 9*x*log(3)^2 + 54*log(3)^2 + 2*(x^4*log(3)^2 - 3*(
log(3)^2 - 27)*x^3 - 243*x^2 + 81*log(3)^2)*log(x))/(x^4 - 3*x^3) + 3*(2*x^2 - 3*x - 3)/(x^3 - 3*x^2) - (2*x -
 3)/(x^2 - 3*x) - 1/(x - 3)

________________________________________________________________________________________

Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 79 vs. \(2 (31) = 62\).
time = 0.43, size = 79, normalized size = 2.47 \begin {gather*} -\frac {x^{6} \log \left (x^{2}\right )^{2} + x^{6} - 6 \, x^{5} + 9 \, x^{4} + \log \left (3\right )^{4} + 2 \, {\left (x^{3} - 3 \, x^{2}\right )} \log \left (3\right )^{2} + 2 \, {\left (x^{6} - 3 \, x^{5} + x^{3} \log \left (3\right )^{2}\right )} \log \left (x^{2}\right )}{x^{7} - 3 \, x^{6}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((x^7*log(x^2)^2+((8*x^4-18*x^3)*log(3)^2-2*x^7+18*x^5)*log(x^2)+(7*x-18)*log(3)^4+(4*x^4-36*x^3+72*x
^2)*log(3)^2-3*x^7+12*x^6+9*x^5-54*x^4)/(x^9-6*x^8+9*x^7),x, algorithm="fricas")

[Out]

-(x^6*log(x^2)^2 + x^6 - 6*x^5 + 9*x^4 + log(3)^4 + 2*(x^3 - 3*x^2)*log(3)^2 + 2*(x^6 - 3*x^5 + x^3*log(3)^2)*
log(x^2))/(x^7 - 3*x^6)

________________________________________________________________________________________

Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 87 vs. \(2 (24) = 48\).
time = 0.84, size = 87, normalized size = 2.72 \begin {gather*} \frac {- x^{6} + 6 x^{5} - 9 x^{4} - 2 x^{3} \log {\left (3 \right )}^{2} + 6 x^{2} \log {\left (3 \right )}^{2} - \log {\left (3 \right )}^{4}}{x^{7} - 3 x^{6}} + \frac {\left (- 2 x^{3} + 6 x^{2} - 2 \log {\left (3 \right )}^{2}\right ) \log {\left (x^{2} \right )}}{x^{4} - 3 x^{3}} - \frac {\log {\left (x^{2} \right )}^{2}}{x - 3} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((x**7*ln(x**2)**2+((8*x**4-18*x**3)*ln(3)**2-2*x**7+18*x**5)*ln(x**2)+(7*x-18)*ln(3)**4+(4*x**4-36*x
**3+72*x**2)*ln(3)**2-3*x**7+12*x**6+9*x**5-54*x**4)/(x**9-6*x**8+9*x**7),x)

[Out]

(-x**6 + 6*x**5 - 9*x**4 - 2*x**3*log(3)**2 + 6*x**2*log(3)**2 - log(3)**4)/(x**7 - 3*x**6) + (-2*x**3 + 6*x**
2 - 2*log(3)**2)*log(x**2)/(x**4 - 3*x**3) - log(x**2)**2/(x - 3)

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 147 vs. \(2 (31) = 62\).
time = 0.40, size = 147, normalized size = 4.59 \begin {gather*} -\frac {\log \left (3\right )^{4}}{729 \, {\left (x - 3\right )}} - \frac {2}{27} \, {\left (\frac {\log \left (3\right )^{2}}{x - 3} - \frac {x^{2} \log \left (3\right )^{2} + 3 \, x \log \left (3\right )^{2} - 27 \, x^{2} + 9 \, \log \left (3\right )^{2}}{x^{3}}\right )} \log \left (x^{2}\right ) - \frac {\log \left (x^{2}\right )^{2}}{x - 3} + \frac {x^{5} \log \left (3\right )^{4} + 3 \, x^{4} \log \left (3\right )^{4} + 9 \, x^{3} \log \left (3\right )^{4} + 27 \, x^{2} \log \left (3\right )^{4} - 729 \, x^{5} + 81 \, x \log \left (3\right )^{4} + 2187 \, x^{4} - 1458 \, x^{2} \log \left (3\right )^{2} + 243 \, \log \left (3\right )^{4}}{729 \, x^{6}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((x^7*log(x^2)^2+((8*x^4-18*x^3)*log(3)^2-2*x^7+18*x^5)*log(x^2)+(7*x-18)*log(3)^4+(4*x^4-36*x^3+72*x
^2)*log(3)^2-3*x^7+12*x^6+9*x^5-54*x^4)/(x^9-6*x^8+9*x^7),x, algorithm="giac")

[Out]

-1/729*log(3)^4/(x - 3) - 2/27*(log(3)^2/(x - 3) - (x^2*log(3)^2 + 3*x*log(3)^2 - 27*x^2 + 9*log(3)^2)/x^3)*lo
g(x^2) - log(x^2)^2/(x - 3) + 1/729*(x^5*log(3)^4 + 3*x^4*log(3)^4 + 9*x^3*log(3)^4 + 27*x^2*log(3)^4 - 729*x^
5 + 81*x*log(3)^4 + 2187*x^4 - 1458*x^2*log(3)^2 + 243*log(3)^4)/x^6

________________________________________________________________________________________

Mupad [B]
time = 2.00, size = 81, normalized size = 2.53 \begin {gather*} -\frac {x^3\,\left (2\,\ln \left (x^2\right )\,{\ln \left (3\right )}^2+2\,{\ln \left (3\right )}^2\right )-6\,x^2\,{\ln \left (3\right )}^2-x^5\,\left (6\,\ln \left (x^2\right )+6\right )+{\ln \left (3\right )}^4+9\,x^4+x^6\,\left ({\ln \left (x^2\right )}^2+2\,\ln \left (x^2\right )+1\right )}{x^6\,\left (x-3\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((log(3)^2*(72*x^2 - 36*x^3 + 4*x^4) + log(3)^4*(7*x - 18) - log(x^2)*(2*x^7 - 18*x^5 + log(3)^2*(18*x^3 -
8*x^4)) - 54*x^4 + 9*x^5 + 12*x^6 - 3*x^7 + x^7*log(x^2)^2)/(9*x^7 - 6*x^8 + x^9),x)

[Out]

-(x^3*(2*log(x^2)*log(3)^2 + 2*log(3)^2) - 6*x^2*log(3)^2 - x^5*(6*log(x^2) + 6) + log(3)^4 + 9*x^4 + x^6*(2*l
og(x^2) + log(x^2)^2 + 1))/(x^6*(x - 3))

________________________________________________________________________________________