Average Error: 2.1 → 0.6
Time: 46.1s
Precision: 64
\[\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\]
\[\begin{array}{l} \mathbf{if}\;x \le -7.350566990880654625576653098125575830144 \cdot 10^{82} \lor \neg \left(x \le 3077508455594739684605952\right):\\ \;\;\;\;\left(x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}\right) \cdot \frac{1}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(\frac{x}{y} \cdot e^{\mathsf{fma}\left(\log z, y, \log a \cdot t\right) - b}\right) \cdot {\left(\frac{1}{{a}^{1}}\right)}^{1}\\ \end{array}\]
\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}
\begin{array}{l}
\mathbf{if}\;x \le -7.350566990880654625576653098125575830144 \cdot 10^{82} \lor \neg \left(x \le 3077508455594739684605952\right):\\
\;\;\;\;\left(x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}\right) \cdot \frac{1}{y}\\

\mathbf{else}:\\
\;\;\;\;\left(\frac{x}{y} \cdot e^{\mathsf{fma}\left(\log z, y, \log a \cdot t\right) - b}\right) \cdot {\left(\frac{1}{{a}^{1}}\right)}^{1}\\

\end{array}
double f(double x, double y, double z, double t, double a, double b) {
        double r70568 = x;
        double r70569 = y;
        double r70570 = z;
        double r70571 = log(r70570);
        double r70572 = r70569 * r70571;
        double r70573 = t;
        double r70574 = 1.0;
        double r70575 = r70573 - r70574;
        double r70576 = a;
        double r70577 = log(r70576);
        double r70578 = r70575 * r70577;
        double r70579 = r70572 + r70578;
        double r70580 = b;
        double r70581 = r70579 - r70580;
        double r70582 = exp(r70581);
        double r70583 = r70568 * r70582;
        double r70584 = r70583 / r70569;
        return r70584;
}

double f(double x, double y, double z, double t, double a, double b) {
        double r70585 = x;
        double r70586 = -7.350566990880655e+82;
        bool r70587 = r70585 <= r70586;
        double r70588 = 3.0775084555947397e+24;
        bool r70589 = r70585 <= r70588;
        double r70590 = !r70589;
        bool r70591 = r70587 || r70590;
        double r70592 = y;
        double r70593 = z;
        double r70594 = log(r70593);
        double r70595 = r70592 * r70594;
        double r70596 = t;
        double r70597 = 1.0;
        double r70598 = r70596 - r70597;
        double r70599 = a;
        double r70600 = log(r70599);
        double r70601 = r70598 * r70600;
        double r70602 = r70595 + r70601;
        double r70603 = b;
        double r70604 = r70602 - r70603;
        double r70605 = exp(r70604);
        double r70606 = r70585 * r70605;
        double r70607 = 1.0;
        double r70608 = r70607 / r70592;
        double r70609 = r70606 * r70608;
        double r70610 = r70585 / r70592;
        double r70611 = r70600 * r70596;
        double r70612 = fma(r70594, r70592, r70611);
        double r70613 = r70612 - r70603;
        double r70614 = exp(r70613);
        double r70615 = r70610 * r70614;
        double r70616 = pow(r70599, r70597);
        double r70617 = r70607 / r70616;
        double r70618 = pow(r70617, r70597);
        double r70619 = r70615 * r70618;
        double r70620 = r70591 ? r70609 : r70619;
        return r70620;
}

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

Derivation

  1. Split input into 2 regimes
  2. if x < -7.350566990880655e+82 or 3.0775084555947397e+24 < x

    1. Initial program 0.7

      \[\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\]
    2. Using strategy rm
    3. Applied div-inv0.7

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

    if -7.350566990880655e+82 < x < 3.0775084555947397e+24

    1. Initial program 2.9

      \[\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}\]
    2. Using strategy rm
    3. Applied div-inv2.9

      \[\leadsto \color{blue}{\left(x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}\right) \cdot \frac{1}{y}}\]
    4. Using strategy rm
    5. Applied add-cube-cbrt2.9

      \[\leadsto \left(x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - \color{blue}{\left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right) \cdot \sqrt[3]{b}}}\right) \cdot \frac{1}{y}\]
    6. Applied add-sqr-sqrt50.4

      \[\leadsto \left(x \cdot e^{\color{blue}{\sqrt{y \cdot \log z + \left(t - 1\right) \cdot \log a} \cdot \sqrt{y \cdot \log z + \left(t - 1\right) \cdot \log a}} - \left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right) \cdot \sqrt[3]{b}}\right) \cdot \frac{1}{y}\]
    7. Applied prod-diff50.4

      \[\leadsto \left(x \cdot e^{\color{blue}{\mathsf{fma}\left(\sqrt{y \cdot \log z + \left(t - 1\right) \cdot \log a}, \sqrt{y \cdot \log z + \left(t - 1\right) \cdot \log a}, -\sqrt[3]{b} \cdot \left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right)\right) + \mathsf{fma}\left(-\sqrt[3]{b}, \sqrt[3]{b} \cdot \sqrt[3]{b}, \sqrt[3]{b} \cdot \left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right)\right)}}\right) \cdot \frac{1}{y}\]
    8. Applied exp-sum54.1

      \[\leadsto \left(x \cdot \color{blue}{\left(e^{\mathsf{fma}\left(\sqrt{y \cdot \log z + \left(t - 1\right) \cdot \log a}, \sqrt{y \cdot \log z + \left(t - 1\right) \cdot \log a}, -\sqrt[3]{b} \cdot \left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right)\right)} \cdot e^{\mathsf{fma}\left(-\sqrt[3]{b}, \sqrt[3]{b} \cdot \sqrt[3]{b}, \sqrt[3]{b} \cdot \left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right)\right)}\right)}\right) \cdot \frac{1}{y}\]
    9. Simplified25.6

      \[\leadsto \left(x \cdot \left(\color{blue}{\left(\frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot {z}^{y}\right)} \cdot e^{\mathsf{fma}\left(-\sqrt[3]{b}, \sqrt[3]{b} \cdot \sqrt[3]{b}, \sqrt[3]{b} \cdot \left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right)\right)}\right)\right) \cdot \frac{1}{y}\]
    10. Simplified18.4

      \[\leadsto \left(x \cdot \left(\left(\frac{{a}^{\left(t - 1\right)}}{e^{b}} \cdot {z}^{y}\right) \cdot \color{blue}{e^{b + \left(-b\right)}}\right)\right) \cdot \frac{1}{y}\]
    11. Using strategy rm
    12. Applied pow-sub18.4

      \[\leadsto \left(x \cdot \left(\left(\frac{\color{blue}{\frac{{a}^{t}}{{a}^{1}}}}{e^{b}} \cdot {z}^{y}\right) \cdot e^{b + \left(-b\right)}\right)\right) \cdot \frac{1}{y}\]
    13. Taylor expanded around inf 16.5

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

      \[\leadsto \color{blue}{\left(e^{\mathsf{fma}\left(-\left(-\log z\right), y, -\left(-\log a\right) \cdot t\right) - b} \cdot \frac{x}{y}\right) \cdot {\left(\frac{1}{{a}^{1}}\right)}^{1}}\]
  3. Recombined 2 regimes into one program.
  4. Final simplification0.6

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \le -7.350566990880654625576653098125575830144 \cdot 10^{82} \lor \neg \left(x \le 3077508455594739684605952\right):\\ \;\;\;\;\left(x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}\right) \cdot \frac{1}{y}\\ \mathbf{else}:\\ \;\;\;\;\left(\frac{x}{y} \cdot e^{\mathsf{fma}\left(\log z, y, \log a \cdot t\right) - b}\right) \cdot {\left(\frac{1}{{a}^{1}}\right)}^{1}\\ \end{array}\]

Reproduce

herbie shell --seed 2019325 +o rules:numerics
(FPCore (x y z t a b)
  :name "Numeric.SpecFunctions:incompleteBetaWorker from math-functions-0.1.5.2"
  :precision binary64
  (/ (* x (exp (- (+ (* y (log z)) (* (- t 1) (log a))) b))) y))