Average Error: 1.9 → 0.7
Time: 2.5m
Precision: 64
Internal Precision: 384
\[\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1.0\right) \cdot \log a\right) - b}}{y}\]
\[\begin{array}{l} \mathbf{if}\;\frac{e^{b} \cdot y}{{z}^{y} \cdot \frac{{a}^{t}}{{a}^{1.0}}} \le -2.117059432185451 \cdot 10^{-137}:\\ \;\;\;\;\frac{x}{\frac{e^{b} \cdot y}{{z}^{y} \cdot \frac{{a}^{t}}{{a}^{1.0}}}}\\ \mathbf{if}\;\frac{e^{b} \cdot y}{{z}^{y} \cdot \frac{{a}^{t}}{{a}^{1.0}}} \le 9.536202689516137 \cdot 10^{-70}:\\ \;\;\;\;\frac{\left({z}^{y} \cdot {a}^{\left(-1.0\right)}\right) \cdot {a}^{t}}{\frac{y}{x} \cdot e^{b}}\\ \mathbf{else}:\\ \;\;\;\;\frac{x \cdot e^{\left(t - 1.0\right) \cdot \log a + \left(y \cdot \log z - b\right)}}{y}\\ \end{array}\]

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 3 regimes
  2. if (/ (* (exp b) y) (* (pow z y) (/ (pow a t) (pow a 1.0)))) < -2.117059432185451e-137

    1. Initial program 2.2

      \[\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1.0\right) \cdot \log a\right) - b}}{y}\]
    2. Using strategy rm
    3. Applied associate-/l*0.8

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

      \[\leadsto \frac{x}{\color{blue}{\frac{e^{b} \cdot y}{{z}^{y} \cdot {a}^{\left(t - 1.0\right)}}}}\]
    5. Using strategy rm
    6. Applied pow-sub0.1

      \[\leadsto \frac{x}{\frac{e^{b} \cdot y}{{z}^{y} \cdot \color{blue}{\frac{{a}^{t}}{{a}^{1.0}}}}}\]

    if -2.117059432185451e-137 < (/ (* (exp b) y) (* (pow z y) (/ (pow a t) (pow a 1.0)))) < 9.536202689516137e-70

    1. Initial program 8.3

      \[\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1.0\right) \cdot \log a\right) - b}}{y}\]
    2. Taylor expanded around inf 8.3

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

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

    if 9.536202689516137e-70 < (/ (* (exp b) y) (* (pow z y) (/ (pow a t) (pow a 1.0))))

    1. Initial program 1.0

      \[\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1.0\right) \cdot \log a\right) - b}}{y}\]
    2. Using strategy rm
    3. Applied add-exp-log1.0

      \[\leadsto \frac{x \cdot \color{blue}{e^{\log \left(e^{\left(y \cdot \log z + \left(t - 1.0\right) \cdot \log a\right) - b}\right)}}}{y}\]
    4. Applied simplify1.0

      \[\leadsto \frac{x \cdot e^{\color{blue}{\left(t - 1.0\right) \cdot \log a + \left(y \cdot \log z - b\right)}}}{y}\]
  3. Recombined 3 regimes into one program.

Runtime

Time bar (total: 2.5m)Debug logProfile

herbie shell --seed '#(1070833653 108281690 3330367898 3632331308 3494323072 43156186)' 
(FPCore (x y z t a b)
  :name "Numeric.SpecFunctions:incompleteBetaWorker from math-functions-0.1.5.2"
  (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))