Average Error: 0.1 → 0.1
Time: 11.6s
Precision: 64
\[\left(\left(\left(x + y\right) + z\right) - z \cdot \log t\right) + \left(a - 0.5\right) \cdot b\]
\[\left(x + y\right) + \left(\left(1 - \log t\right) \cdot z + \left(a - 0.5\right) \cdot b\right)\]
\left(\left(\left(x + y\right) + z\right) - z \cdot \log t\right) + \left(a - 0.5\right) \cdot b
\left(x + y\right) + \left(\left(1 - \log t\right) \cdot z + \left(a - 0.5\right) \cdot b\right)
double f(double x, double y, double z, double t, double a, double b) {
        double r1869 = x;
        double r1870 = y;
        double r1871 = r1869 + r1870;
        double r1872 = z;
        double r1873 = r1871 + r1872;
        double r1874 = t;
        double r1875 = log(r1874);
        double r1876 = r1872 * r1875;
        double r1877 = r1873 - r1876;
        double r1878 = a;
        double r1879 = 0.5;
        double r1880 = r1878 - r1879;
        double r1881 = b;
        double r1882 = r1880 * r1881;
        double r1883 = r1877 + r1882;
        return r1883;
}

double f(double x, double y, double z, double t, double a, double b) {
        double r1884 = x;
        double r1885 = y;
        double r1886 = r1884 + r1885;
        double r1887 = 1.0;
        double r1888 = t;
        double r1889 = log(r1888);
        double r1890 = r1887 - r1889;
        double r1891 = z;
        double r1892 = r1890 * r1891;
        double r1893 = a;
        double r1894 = 0.5;
        double r1895 = r1893 - r1894;
        double r1896 = b;
        double r1897 = r1895 * r1896;
        double r1898 = r1892 + r1897;
        double r1899 = r1886 + r1898;
        return r1899;
}

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.3
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. Applied associate-+l+0.1

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

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

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

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

Reproduce

herbie shell --seed 2020025 
(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)))