Average Error: 9.6 → 0.4
Time: 8.0s
Precision: 64
\[\left(x \cdot \log y + z \cdot \log \left(1 - y\right)\right) - t\]
\[\left(\log \left({\left(\frac{1}{y}\right)}^{\frac{-1}{3}} \cdot \sqrt[3]{y}\right) \cdot x + \left(\log \left(\sqrt[3]{y}\right) \cdot x + \left(z \cdot \log 1 - \left(1 \cdot \left(z \cdot y\right) + \frac{1}{2} \cdot \frac{z \cdot {y}^{2}}{{1}^{2}}\right)\right)\right)\right) - t\]
\left(x \cdot \log y + z \cdot \log \left(1 - y\right)\right) - t
\left(\log \left({\left(\frac{1}{y}\right)}^{\frac{-1}{3}} \cdot \sqrt[3]{y}\right) \cdot x + \left(\log \left(\sqrt[3]{y}\right) \cdot x + \left(z \cdot \log 1 - \left(1 \cdot \left(z \cdot y\right) + \frac{1}{2} \cdot \frac{z \cdot {y}^{2}}{{1}^{2}}\right)\right)\right)\right) - t
double f(double x, double y, double z, double t) {
        double r355859 = x;
        double r355860 = y;
        double r355861 = log(r355860);
        double r355862 = r355859 * r355861;
        double r355863 = z;
        double r355864 = 1.0;
        double r355865 = r355864 - r355860;
        double r355866 = log(r355865);
        double r355867 = r355863 * r355866;
        double r355868 = r355862 + r355867;
        double r355869 = t;
        double r355870 = r355868 - r355869;
        return r355870;
}

double f(double x, double y, double z, double t) {
        double r355871 = 1.0;
        double r355872 = y;
        double r355873 = r355871 / r355872;
        double r355874 = -0.3333333333333333;
        double r355875 = pow(r355873, r355874);
        double r355876 = cbrt(r355872);
        double r355877 = r355875 * r355876;
        double r355878 = log(r355877);
        double r355879 = x;
        double r355880 = r355878 * r355879;
        double r355881 = log(r355876);
        double r355882 = r355881 * r355879;
        double r355883 = z;
        double r355884 = 1.0;
        double r355885 = log(r355884);
        double r355886 = r355883 * r355885;
        double r355887 = r355883 * r355872;
        double r355888 = r355884 * r355887;
        double r355889 = 0.5;
        double r355890 = 2.0;
        double r355891 = pow(r355872, r355890);
        double r355892 = r355883 * r355891;
        double r355893 = pow(r355884, r355890);
        double r355894 = r355892 / r355893;
        double r355895 = r355889 * r355894;
        double r355896 = r355888 + r355895;
        double r355897 = r355886 - r355896;
        double r355898 = r355882 + r355897;
        double r355899 = r355880 + r355898;
        double r355900 = t;
        double r355901 = r355899 - r355900;
        return r355901;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original9.6
Target0.3
Herbie0.4
\[\left(-z\right) \cdot \left(\left(0.5 \cdot \left(y \cdot y\right) + y\right) + \frac{0.333333333333333315}{1 \cdot \left(1 \cdot 1\right)} \cdot \left(y \cdot \left(y \cdot y\right)\right)\right) - \left(t - x \cdot \log y\right)\]

Derivation

  1. Initial program 9.6

    \[\left(x \cdot \log y + z \cdot \log \left(1 - y\right)\right) - t\]
  2. Taylor expanded around 0 0.3

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

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

    \[\leadsto \left(x \cdot \color{blue}{\left(\log \left(\sqrt[3]{y} \cdot \sqrt[3]{y}\right) + \log \left(\sqrt[3]{y}\right)\right)} + \left(z \cdot \log 1 - \left(1 \cdot \left(z \cdot y\right) + \frac{1}{2} \cdot \frac{z \cdot {y}^{2}}{{1}^{2}}\right)\right)\right) - t\]
  6. Applied distribute-rgt-in0.4

    \[\leadsto \left(\color{blue}{\left(\log \left(\sqrt[3]{y} \cdot \sqrt[3]{y}\right) \cdot x + \log \left(\sqrt[3]{y}\right) \cdot x\right)} + \left(z \cdot \log 1 - \left(1 \cdot \left(z \cdot y\right) + \frac{1}{2} \cdot \frac{z \cdot {y}^{2}}{{1}^{2}}\right)\right)\right) - t\]
  7. Applied associate-+l+0.4

    \[\leadsto \color{blue}{\left(\log \left(\sqrt[3]{y} \cdot \sqrt[3]{y}\right) \cdot x + \left(\log \left(\sqrt[3]{y}\right) \cdot x + \left(z \cdot \log 1 - \left(1 \cdot \left(z \cdot y\right) + \frac{1}{2} \cdot \frac{z \cdot {y}^{2}}{{1}^{2}}\right)\right)\right)\right)} - t\]
  8. Taylor expanded around inf 0.4

    \[\leadsto \left(\log \left(\color{blue}{{\left(\frac{1}{y}\right)}^{\frac{-1}{3}}} \cdot \sqrt[3]{y}\right) \cdot x + \left(\log \left(\sqrt[3]{y}\right) \cdot x + \left(z \cdot \log 1 - \left(1 \cdot \left(z \cdot y\right) + \frac{1}{2} \cdot \frac{z \cdot {y}^{2}}{{1}^{2}}\right)\right)\right)\right) - t\]
  9. Final simplification0.4

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

Reproduce

herbie shell --seed 2020024 
(FPCore (x y z t)
  :name "Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2, B"
  :precision binary64

  :herbie-target
  (- (* (- z) (+ (+ (* 0.5 (* y y)) y) (* (/ 0.3333333333333333 (* 1 (* 1 1))) (* y (* y y))))) (- t (* x (log y))))

  (- (+ (* x (log y)) (* z (log (- 1 y)))) t))