Average Error: 0.1 → 0.1
Time: 7.9s
Precision: 64
\[\left(\left(\left(x + y\right) + z\right) - z \cdot \log t\right) + \left(a - 0.5\right) \cdot b\]
\[\left(\left(x + y\right) + \frac{1 - {\left(\log t\right)}^{3}}{\log t \cdot \left(\log t + 1\right) + 1} \cdot z\right) + \left(a - 0.5\right) \cdot b\]
\left(\left(\left(x + y\right) + z\right) - z \cdot \log t\right) + \left(a - 0.5\right) \cdot b
\left(\left(x + y\right) + \frac{1 - {\left(\log t\right)}^{3}}{\log t \cdot \left(\log t + 1\right) + 1} \cdot z\right) + \left(a - 0.5\right) \cdot b
double f(double x, double y, double z, double t, double a, double b) {
        double r440877 = x;
        double r440878 = y;
        double r440879 = r440877 + r440878;
        double r440880 = z;
        double r440881 = r440879 + r440880;
        double r440882 = t;
        double r440883 = log(r440882);
        double r440884 = r440880 * r440883;
        double r440885 = r440881 - r440884;
        double r440886 = a;
        double r440887 = 0.5;
        double r440888 = r440886 - r440887;
        double r440889 = b;
        double r440890 = r440888 * r440889;
        double r440891 = r440885 + r440890;
        return r440891;
}

double f(double x, double y, double z, double t, double a, double b) {
        double r440892 = x;
        double r440893 = y;
        double r440894 = r440892 + r440893;
        double r440895 = 1.0;
        double r440896 = t;
        double r440897 = log(r440896);
        double r440898 = 3.0;
        double r440899 = pow(r440897, r440898);
        double r440900 = r440895 - r440899;
        double r440901 = r440897 + r440895;
        double r440902 = r440897 * r440901;
        double r440903 = r440902 + r440895;
        double r440904 = r440900 / r440903;
        double r440905 = z;
        double r440906 = r440904 * r440905;
        double r440907 = r440894 + r440906;
        double r440908 = a;
        double r440909 = 0.5;
        double r440910 = r440908 - r440909;
        double r440911 = b;
        double r440912 = r440910 * r440911;
        double r440913 = r440907 + r440912;
        return r440913;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Bits error versus a

Bits error versus b

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.1
Target0.4
Herbie0.1
\[\left(\left(x + y\right) + \frac{\left(1 - {\left(\log t\right)}^{2}\right) \cdot z}{1 + \log t}\right) + \left(a - 0.5\right) \cdot b\]

Derivation

  1. Initial program 0.1

    \[\left(\left(\left(x + y\right) + z\right) - z \cdot \log t\right) + \left(a - 0.5\right) \cdot b\]
  2. Using strategy rm
  3. Applied associate--l+0.1

    \[\leadsto \color{blue}{\left(\left(x + y\right) + \left(z - z \cdot \log t\right)\right)} + \left(a - 0.5\right) \cdot b\]
  4. Taylor expanded around 0 0.1

    \[\leadsto \left(\left(x + y\right) + \color{blue}{z \cdot \left(1 - \log t\right)}\right) + \left(a - 0.5\right) \cdot b\]
  5. Simplified0.1

    \[\leadsto \left(\left(x + y\right) + \color{blue}{\left(1 - \log t\right) \cdot z}\right) + \left(a - 0.5\right) \cdot b\]
  6. Using strategy rm
  7. Applied flip3--0.1

    \[\leadsto \left(\left(x + y\right) + \color{blue}{\frac{{1}^{3} - {\left(\log t\right)}^{3}}{1 \cdot 1 + \left(\log t \cdot \log t + 1 \cdot \log t\right)}} \cdot z\right) + \left(a - 0.5\right) \cdot b\]
  8. Simplified0.1

    \[\leadsto \left(\left(x + y\right) + \frac{\color{blue}{1 - {\left(\log t\right)}^{3}}}{1 \cdot 1 + \left(\log t \cdot \log t + 1 \cdot \log t\right)} \cdot z\right) + \left(a - 0.5\right) \cdot b\]
  9. Simplified0.1

    \[\leadsto \left(\left(x + y\right) + \frac{1 - {\left(\log t\right)}^{3}}{\color{blue}{\log t \cdot \left(\log t + 1\right) + 1}} \cdot z\right) + \left(a - 0.5\right) \cdot b\]
  10. Final simplification0.1

    \[\leadsto \left(\left(x + y\right) + \frac{1 - {\left(\log t\right)}^{3}}{\log t \cdot \left(\log t + 1\right) + 1} \cdot z\right) + \left(a - 0.5\right) \cdot b\]

Reproduce

herbie shell --seed 2019353 
(FPCore (x y z t a b)
  :name "Numeric.SpecFunctions:logBeta from math-functions-0.1.5.2, A"
  :precision binary64

  :herbie-target
  (+ (+ (+ x y) (/ (* (- 1 (pow (log t) 2)) z) (+ 1 (log t)))) (* (- a 0.5) b))

  (+ (- (+ (+ x y) z) (* z (log t))) (* (- a 0.5) b)))