Optimal. Leaf size=29 \[ -2 x+\frac {\log \left (\frac {1}{3} (-2-x)-2 x-\frac {\log (4)}{x}\right )}{x} \]
________________________________________________________________________________________
Rubi [B] time = 0.77, antiderivative size = 107, normalized size of antiderivative = 3.69, number of steps used = 16, number of rules used = 8, integrand size = 82, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.098, Rules used = {1594, 6728, 1628, 634, 618, 204, 628, 2525} \begin {gather*} -2 x+\frac {\log \left (-\frac {7 x}{3}-\frac {\log (4)}{x}-\frac {2}{3}\right )}{x}+\frac {\sqrt {7 \log (64)-1} \log (4096) \tan ^{-1}\left (\frac {7 x+1}{\sqrt {7 \log (64)-1}}\right )}{\log ^2(64)}+\frac {\left (\log (4) (6-21 \log (64))-7 \log ^2(64)\right ) \tan ^{-1}\left (\frac {7 x+1}{\sqrt {7 \log (64)-1}}\right )}{\log ^2(64) \sqrt {7 \log (64)-1}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 204
Rule 618
Rule 628
Rule 634
Rule 1594
Rule 1628
Rule 2525
Rule 6728
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {7 x^2-4 x^3-14 x^4+\left (-3-6 x^2\right ) \log (4)+\left (-2 x-7 x^2-3 \log (4)\right ) \log \left (\frac {-2 x-7 x^2-3 \log (4)}{3 x}\right )}{x^2 \left (2 x+7 x^2+3 \log (4)\right )} \, dx\\ &=\int \left (\frac {-4 x^3-14 x^4+x^2 (7-6 \log (4))-3 \log (4)}{x^2 \left (2 x+7 x^2+\log (64)\right )}-\frac {\log \left (-\frac {2}{3}-\frac {7 x}{3}-\frac {\log (4)}{x}\right )}{x^2}\right ) \, dx\\ &=\int \frac {-4 x^3-14 x^4+x^2 (7-6 \log (4))-3 \log (4)}{x^2 \left (2 x+7 x^2+\log (64)\right )} \, dx-\int \frac {\log \left (-\frac {2}{3}-\frac {7 x}{3}-\frac {\log (4)}{x}\right )}{x^2} \, dx\\ &=\frac {\log \left (-\frac {2}{3}-\frac {7 x}{3}-\frac {\log (4)}{x}\right )}{x}-\int \frac {7 x^2-3 \log (4)}{x^2 \left (2 x+7 x^2+\log (64)\right )} \, dx+\int \left (-2-\frac {1}{x^2}+\frac {6 \log (4)}{x \log ^2(64)}+\frac {-12 \log (4)-42 x \log (4)+21 \log (4) \log (64)+7 \log ^2(64)-6 \log (4) \log ^2(64)+\log ^2(64) \log (4096)}{\log ^2(64) \left (2 x+7 x^2+\log (64)\right )}\right ) \, dx\\ &=\frac {1}{x}-2 x+\frac {6 \log (4) \log (x)}{\log ^2(64)}+\frac {\log \left (-\frac {2}{3}-\frac {7 x}{3}-\frac {\log (4)}{x}\right )}{x}+\frac {\int \frac {-12 \log (4)-42 x \log (4)+21 \log (4) \log (64)+7 \log ^2(64)-6 \log (4) \log ^2(64)+\log ^2(64) \log (4096)}{2 x+7 x^2+\log (64)} \, dx}{\log ^2(64)}-\int \left (-\frac {1}{x^2}+\frac {6 \log (4)}{x \log ^2(64)}+\frac {-12 \log (4)-42 x \log (4)+21 \log (4) \log (64)+7 \log ^2(64)}{\log ^2(64) \left (2 x+7 x^2+\log (64)\right )}\right ) \, dx\\ &=-2 x+\frac {\log \left (-\frac {2}{3}-\frac {7 x}{3}-\frac {\log (4)}{x}\right )}{x}-\frac {\int \frac {-12 \log (4)-42 x \log (4)+21 \log (4) \log (64)+7 \log ^2(64)}{2 x+7 x^2+\log (64)} \, dx}{\log ^2(64)}-\frac {(3 \log (4)) \int \frac {2+14 x}{2 x+7 x^2+\log (64)} \, dx}{\log ^2(64)}+\frac {\left (7 \log ^2(64)-\log (4096)+\log (64) \log (4398046511104)\right ) \int \frac {1}{2 x+7 x^2+\log (64)} \, dx}{\log ^2(64)}\\ &=-2 x+\frac {\log \left (-\frac {2}{3}-\frac {7 x}{3}-\frac {\log (4)}{x}\right )}{x}-\frac {3 \log (4) \log \left (2 x+7 x^2+\log (64)\right )}{\log ^2(64)}-\left (7-\frac {3 \log (4) (2-7 \log (64))}{\log ^2(64)}\right ) \int \frac {1}{2 x+7 x^2+\log (64)} \, dx+\frac {(3 \log (4)) \int \frac {2+14 x}{2 x+7 x^2+\log (64)} \, dx}{\log ^2(64)}-\frac {\left (2 \left (7 \log ^2(64)-\log (4096)+\log (64) \log (4398046511104)\right )\right ) \operatorname {Subst}\left (\int \frac {1}{-x^2+4 (1-7 \log (64))} \, dx,x,2+14 x\right )}{\log ^2(64)}\\ &=-2 x+\frac {\tan ^{-1}\left (\frac {1+7 x}{\sqrt {-1+7 \log (64)}}\right ) \sqrt {-1+7 \log (64)} \log (4096)}{\log ^2(64)}+\frac {\log \left (-\frac {2}{3}-\frac {7 x}{3}-\frac {\log (4)}{x}\right )}{x}+\left (2 \left (7-\frac {3 \log (4) (2-7 \log (64))}{\log ^2(64)}\right )\right ) \operatorname {Subst}\left (\int \frac {1}{-x^2+4 (1-7 \log (64))} \, dx,x,2+14 x\right )\\ &=-2 x-\frac {\tan ^{-1}\left (\frac {1+7 x}{\sqrt {-1+7 \log (64)}}\right ) \left (7-\frac {3 \log (4) (2-7 \log (64))}{\log ^2(64)}\right )}{\sqrt {-1+7 \log (64)}}+\frac {\tan ^{-1}\left (\frac {1+7 x}{\sqrt {-1+7 \log (64)}}\right ) \sqrt {-1+7 \log (64)} \log (4096)}{\log ^2(64)}+\frac {\log \left (-\frac {2}{3}-\frac {7 x}{3}-\frac {\log (4)}{x}\right )}{x}\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.23, size = 33, normalized size = 1.14 \begin {gather*} -\frac {\log (3)+\frac {x^2 \log (4096)}{\log (64)}-\log \left (-2-7 x-\frac {\log (64)}{x}\right )}{x} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.73, size = 32, normalized size = 1.10 \begin {gather*} -\frac {2 \, x^{2} - \log \left (-\frac {7 \, x^{2} + 2 \, x + 6 \, \log \relax (2)}{3 \, x}\right )}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.21, size = 31, normalized size = 1.07 \begin {gather*} -2 \, x + \frac {\log \left (-7 \, x^{2} - 2 \, x - 6 \, \log \relax (2)\right )}{x} - \frac {\log \left (3 \, x\right )}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.14, size = 28, normalized size = 0.97
method | result | size |
risch | \(\frac {\ln \left (\frac {-6 \ln \relax (2)-7 x^{2}-2 x}{3 x}\right )}{x}-2 x\) | \(28\) |
norman | \(\frac {-2 x^{2}+\ln \left (\frac {-6 \ln \relax (2)-7 x^{2}-2 x}{3 x}\right )}{x}\) | \(30\) |
default | \(-\frac {\ln \relax (3)}{x}+\frac {\ln \left (\frac {-6 \ln \relax (2)-7 x^{2}-2 x}{x}\right )}{x}-\frac {\sqrt {-1+42 \ln \relax (2)}\, \arctan \left (\frac {14 x +2}{2 \sqrt {-1+42 \ln \relax (2)}}\right )}{3 \ln \relax (2)}-2 x -\frac {\arctan \left (\frac {14 x +2}{2 \sqrt {-1+42 \ln \relax (2)}}\right )}{3 \ln \relax (2) \sqrt {-1+42 \ln \relax (2)}}+\frac {14 \arctan \left (\frac {14 x +2}{2 \sqrt {-1+42 \ln \relax (2)}}\right )}{\sqrt {-1+42 \ln \relax (2)}}\) | \(120\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [B] time = 1.11, size = 170, normalized size = 5.86 \begin {gather*} \frac {1}{6} \, {\left (\frac {2 \, {\left (21 \, \log \relax (2) - 1\right )} \arctan \left (\frac {7 \, x + 1}{\sqrt {42 \, \log \relax (2) - 1}}\right )}{\sqrt {42 \, \log \relax (2) - 1} \log \relax (2)^{2}} - \frac {\log \left (7 \, x^{2} + 2 \, x + 6 \, \log \relax (2)\right )}{\log \relax (2)^{2}} + \frac {2 \, \log \relax (x)}{\log \relax (2)^{2}} + \frac {6}{x \log \relax (2)}\right )} \log \relax (2) - \frac {{\left (21 \, \log \relax (2) - 1\right )} \arctan \left (\frac {7 \, x + 1}{\sqrt {42 \, \log \relax (2) - 1}}\right )}{3 \, \sqrt {42 \, \log \relax (2) - 1} \log \relax (2)} - \frac {12 \, x^{2} \log \relax (2) + 6 \, {\left (\log \relax (3) + 1\right )} \log \relax (2) - {\left (x + 6 \, \log \relax (2)\right )} \log \left (-7 \, x^{2} - 2 \, x - 6 \, \log \relax (2)\right ) + 2 \, {\left (x + 3 \, \log \relax (2)\right )} \log \relax (x)}{6 \, x \log \relax (2)} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 4.51, size = 25, normalized size = 0.86 \begin {gather*} \frac {\ln \left (-\frac {\frac {7\,x^2}{3}+\frac {2\,x}{3}+\ln \relax (4)}{x}\right )}{x}-2\,x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.22, size = 26, normalized size = 0.90 \begin {gather*} - 2 x + \frac {\log {\left (\frac {- \frac {7 x^{2}}{3} - \frac {2 x}{3} - 2 \log {\relax (2 )}}{x} \right )}}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________