Average Error: 0.3 → 0.2
Time: 19.7s
Precision: 64
\[x \cdot \log x\]
\[\mathsf{fma}\left(\log \left(\sqrt[3]{x}\right), x + x, x \cdot \log \left(\sqrt[3]{\sqrt[3]{x} \cdot \sqrt[3]{x}}\right) + \log \left(\sqrt[3]{\sqrt[3]{x}}\right) \cdot x\right)\]
x \cdot \log x
\mathsf{fma}\left(\log \left(\sqrt[3]{x}\right), x + x, x \cdot \log \left(\sqrt[3]{\sqrt[3]{x} \cdot \sqrt[3]{x}}\right) + \log \left(\sqrt[3]{\sqrt[3]{x}}\right) \cdot x\right)
double f(double x) {
        double r1641610 = x;
        double r1641611 = log(r1641610);
        double r1641612 = r1641610 * r1641611;
        return r1641612;
}

double f(double x) {
        double r1641613 = x;
        double r1641614 = cbrt(r1641613);
        double r1641615 = log(r1641614);
        double r1641616 = r1641613 + r1641613;
        double r1641617 = r1641614 * r1641614;
        double r1641618 = cbrt(r1641617);
        double r1641619 = log(r1641618);
        double r1641620 = r1641613 * r1641619;
        double r1641621 = cbrt(r1641614);
        double r1641622 = log(r1641621);
        double r1641623 = r1641622 * r1641613;
        double r1641624 = r1641620 + r1641623;
        double r1641625 = fma(r1641615, r1641616, r1641624);
        return r1641625;
}

Error

Bits error versus x

Derivation

  1. Initial program 0.3

    \[x \cdot \log x\]
  2. Using strategy rm
  3. Applied add-cube-cbrt0.3

    \[\leadsto x \cdot \log \color{blue}{\left(\left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) \cdot \sqrt[3]{x}\right)}\]
  4. Applied log-prod0.4

    \[\leadsto x \cdot \color{blue}{\left(\log \left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) + \log \left(\sqrt[3]{x}\right)\right)}\]
  5. Applied distribute-lft-in0.4

    \[\leadsto \color{blue}{x \cdot \log \left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) + x \cdot \log \left(\sqrt[3]{x}\right)}\]
  6. Simplified0.4

    \[\leadsto \color{blue}{\log \left(\sqrt[3]{x}\right) \cdot \left(x + x\right)} + x \cdot \log \left(\sqrt[3]{x}\right)\]
  7. Using strategy rm
  8. Applied fma-def0.3

    \[\leadsto \color{blue}{\mathsf{fma}\left(\log \left(\sqrt[3]{x}\right), x + x, x \cdot \log \left(\sqrt[3]{x}\right)\right)}\]
  9. Using strategy rm
  10. Applied add-cube-cbrt0.3

    \[\leadsto \mathsf{fma}\left(\log \left(\sqrt[3]{x}\right), x + x, x \cdot \log \left(\sqrt[3]{\color{blue}{\left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) \cdot \sqrt[3]{x}}}\right)\right)\]
  11. Applied cbrt-prod0.3

    \[\leadsto \mathsf{fma}\left(\log \left(\sqrt[3]{x}\right), x + x, x \cdot \log \color{blue}{\left(\sqrt[3]{\sqrt[3]{x} \cdot \sqrt[3]{x}} \cdot \sqrt[3]{\sqrt[3]{x}}\right)}\right)\]
  12. Applied log-prod0.2

    \[\leadsto \mathsf{fma}\left(\log \left(\sqrt[3]{x}\right), x + x, x \cdot \color{blue}{\left(\log \left(\sqrt[3]{\sqrt[3]{x} \cdot \sqrt[3]{x}}\right) + \log \left(\sqrt[3]{\sqrt[3]{x}}\right)\right)}\right)\]
  13. Applied distribute-lft-in0.2

    \[\leadsto \mathsf{fma}\left(\log \left(\sqrt[3]{x}\right), x + x, \color{blue}{x \cdot \log \left(\sqrt[3]{\sqrt[3]{x} \cdot \sqrt[3]{x}}\right) + x \cdot \log \left(\sqrt[3]{\sqrt[3]{x}}\right)}\right)\]
  14. Final simplification0.2

    \[\leadsto \mathsf{fma}\left(\log \left(\sqrt[3]{x}\right), x + x, x \cdot \log \left(\sqrt[3]{\sqrt[3]{x} \cdot \sqrt[3]{x}}\right) + \log \left(\sqrt[3]{\sqrt[3]{x}}\right) \cdot x\right)\]

Reproduce

herbie shell --seed 2019172 +o rules:numerics
(FPCore (x)
  :name "Statistics.Distribution.Binomial:directEntropy from math-functions-0.1.5.2"
  (* x (log x)))