Average Error: 0.1 → 0.1
Time: 5.8s
Precision: 64
\[\left(\left(x \cdot \log y - y\right) - z\right) + \log t\]
\[\mathsf{fma}\left(2, \log \left(\sqrt[3]{t}\right), \log y \cdot x\right) + \left(\log \left(\sqrt[3]{t}\right) - \left(y + z\right)\right)\]
\left(\left(x \cdot \log y - y\right) - z\right) + \log t
\mathsf{fma}\left(2, \log \left(\sqrt[3]{t}\right), \log y \cdot x\right) + \left(\log \left(\sqrt[3]{t}\right) - \left(y + z\right)\right)
double f(double x, double y, double z, double t) {
        double r117051 = x;
        double r117052 = y;
        double r117053 = log(r117052);
        double r117054 = r117051 * r117053;
        double r117055 = r117054 - r117052;
        double r117056 = z;
        double r117057 = r117055 - r117056;
        double r117058 = t;
        double r117059 = log(r117058);
        double r117060 = r117057 + r117059;
        return r117060;
}

double f(double x, double y, double z, double t) {
        double r117061 = 2.0;
        double r117062 = t;
        double r117063 = cbrt(r117062);
        double r117064 = log(r117063);
        double r117065 = y;
        double r117066 = log(r117065);
        double r117067 = x;
        double r117068 = r117066 * r117067;
        double r117069 = fma(r117061, r117064, r117068);
        double r117070 = z;
        double r117071 = r117065 + r117070;
        double r117072 = r117064 - r117071;
        double r117073 = r117069 + r117072;
        return r117073;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Derivation

  1. Initial program 0.1

    \[\left(\left(x \cdot \log y - y\right) - z\right) + \log t\]
  2. Simplified0.1

    \[\leadsto \color{blue}{\mathsf{fma}\left(\log y, x, \log t - \left(y + z\right)\right)}\]
  3. Using strategy rm
  4. Applied fma-udef0.1

    \[\leadsto \color{blue}{\log y \cdot x + \left(\log t - \left(y + z\right)\right)}\]
  5. Using strategy rm
  6. Applied add-cube-cbrt0.1

    \[\leadsto \log y \cdot x + \left(\log \color{blue}{\left(\left(\sqrt[3]{t} \cdot \sqrt[3]{t}\right) \cdot \sqrt[3]{t}\right)} - \left(y + z\right)\right)\]
  7. Applied log-prod0.1

    \[\leadsto \log y \cdot x + \left(\color{blue}{\left(\log \left(\sqrt[3]{t} \cdot \sqrt[3]{t}\right) + \log \left(\sqrt[3]{t}\right)\right)} - \left(y + z\right)\right)\]
  8. Applied associate--l+0.1

    \[\leadsto \log y \cdot x + \color{blue}{\left(\log \left(\sqrt[3]{t} \cdot \sqrt[3]{t}\right) + \left(\log \left(\sqrt[3]{t}\right) - \left(y + z\right)\right)\right)}\]
  9. Applied associate-+r+0.1

    \[\leadsto \color{blue}{\left(\log y \cdot x + \log \left(\sqrt[3]{t} \cdot \sqrt[3]{t}\right)\right) + \left(\log \left(\sqrt[3]{t}\right) - \left(y + z\right)\right)}\]
  10. Simplified0.1

    \[\leadsto \color{blue}{\mathsf{fma}\left(2, \log \left(\sqrt[3]{t}\right), \log y \cdot x\right)} + \left(\log \left(\sqrt[3]{t}\right) - \left(y + z\right)\right)\]
  11. Final simplification0.1

    \[\leadsto \mathsf{fma}\left(2, \log \left(\sqrt[3]{t}\right), \log y \cdot x\right) + \left(\log \left(\sqrt[3]{t}\right) - \left(y + z\right)\right)\]

Reproduce

herbie shell --seed 2020060 +o rules:numerics
(FPCore (x y z t)
  :name "Numeric.SpecFunctions:incompleteGamma from math-functions-0.1.5.2, A"
  :precision binary64
  (+ (- (- (* x (log y)) y) z) (log t)))